Skip to content

"Attachments" as targetDef not found #243

@Andreas-Meindl-msggroup

Description

@Andreas-Meindl-msggroup

Deleting files is not possible as in sdm.js file in method getAttachmentCompositions there is if statement "if (targetDef && targetDef.includes && targetDef.includes.includes('sap.attachments.Attachments'))".
In our case targetDef is not "sap.attachments.Attachments" but only "Attachments".
Deleting a file on UI results in a deleted file on UI attachment table but not in the DMS.

So we extended the if statement by targetDef.includes.includes('Attachments'))) and would like to contribute to this issue by a pull request.

Versions:
@cap-js/db-service: 2.9.0
@cap-js/hana: 2.7.0
@sap/cds: 9.8.3
@sap/cds-compiler: 6.7.3
@sap/cds-dk: 9.7.2
@sap/cds-dk (global): 9.1.0
@cap-js/dm: 1.9.0
Node.js: v22.22.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions