SAP / openui5-fhir

The openui5-fhir project connects the worlds of UI5 and FHIR®. Build beautiful and enterprise-ready web applications based on the FHIR® specification.
https://sap.github.io/openui5-fhir
Apache License 2.0
33 stars 6 forks source link

feat: return deleted resources object from submitChanges #445

Closed kanikasharma97 closed 6 months ago

kanikasharma97 commented 7 months ago

This PR aims to enhance the handling of deleted resources during the submit changes process. Currently, when a resource is deleted, only a status code is returned from the API without providing any details regarding the deleted resource. This PR addresses this limitation by introducing improvements in two key scenarios:

  1. Handling Individual Resource Deletion:

    • Before submitting changes, the list of deleted resources is fetched in getRemovedResourcesObject method in FHIRModel.js
    • Upon successful deletion, it is ensured that the details of the deleted resources are returned along with the response.
  2. Handling Partial Deletion:

    • In cases where multiple resources are being deleted and only partial deletion is successful, the details of the resource(s) for which deletion was successful iS gathered through newly introduced method getsIdFromOperationOutcome located in FHIRUtility.js.
    • Only the details of the successfully deleted resource(s) are returned as part of oError.resources.
cla-assistant[bot] commented 7 months ago

CLA assistant check
All committers have signed the CLA.

coveralls commented 7 months ago

Coverage Status

coverage: 95.68% (-0.07%) from 95.745% when pulling 37693114bdbd4ac8338e1fb2038acf0e0d3d2b26 on kanikasharma97:task/returnDltdResources into 707b026a80a7234b34fd3d5075fa4d9058eb3d49 on SAP:master.

openui5fhirbot commented 6 months ago

:tada: This PR is included in version 2.4.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket: