Altinn / altinn-studio

Next generation open source Altinn platform and applications.
https://docs.altinn.studio
BSD 3-Clause "New" or "Revised" License
111 stars 70 forks source link

Service owners should be able to retrieve identification number of person who created, updated etc. an instance #5751

Closed khurram-khan-ske closed 2 years ago

khurram-khan-ske commented 3 years ago

Is your feature request related to a problem? Please describe

At the norwegian tax administration (Skatteetaten) we are using Altinn3 for receving tax reports. When we receive instance data we need to know identification (fnr/orgnr) of the end user who performed different tasks on that instance. Tasks may be "instance created, data uploaded, moved to next task" etc.

Since a task may be performed by others then person herself we need to know about the person who performed the task. This information is needed so we can show it to the end user when they are logged on in our web portal.

Describe the solution you'd like

Add a new field 'performedBy' and return it when in following endpoints:

For example when we call the last endpoint we should get this response: { “processHistory”: [ { “eventType”: “process_StartEvent”, “elementId”: “StartEvent_1”, “occured”: “2021-02-25T06:44:26.1256979Z”, “started”: null, “ended”: null, "performedBy": "1233445" }, ...

Lorem ipsum

Suggested solution

Considerations

Tasks

einarhartvigolsenskattetaten commented 3 years ago

Hi, I am wondering when this is up for consideration.

jeevananthank commented 2 years ago

tested with 4.31.1-alpha

event types: process_StartEvent, process_StartTask, process_EndTask, process_EndEvent, Submited are populated with user.nationalIdentityNumber

event types: Created, Saved are NOT populated with user.nationalIdentityNumber @acn-sbuad

instanceEvents are populated with the new parameter nationalIdentityNumber, and NOT the process as mentioned in the issue.

acn-sbuad commented 2 years ago

Created and Saved are events created in Platform storage where we don't have the data about person number available. Checking with SKD what their use case is, to clarify. ProcessHistory only includes the event types that now include personnumber

acn-sbuad commented 2 years ago

Remaining test requirements is to confirm that processHistory in storage includes the personNumber, where it is available in the performedBy prop.

jeevananthank commented 2 years ago

test is complete with ttd/apps-test with nuget version 4.31.1.