Attachments being added to incidents creates comments in the activity

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-04-2018 06:38 AM
We have noticed that when you add an attachment to an incident is causes comments with a link to the attachment to appear. We would like to change this to worker notes. We disabled the Business rule that calls that script include AttachmentAuditTrailHelper but the attachment is still appearing in the comments so it does not appear to be this script include causing the comments to be created. Anybody have any idea on what makes these updates?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-05-2018 04:47 AM
That is going to remove all the attachments. I just want to hide the ones they did not create.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-05-2018 06:46 AM
Hello Bricast,
Like I said in my post, that block is what is responsible for adding the attachment, you can control the conditions in the ng-if rather than commenting out from there.
Since you want to remove the attachment all together including the box, Probably makes more sense to remove it at the ng-repeat level.
To do this you will need to add 1 line of code, and edit another:
Here is the text to paste: data.user_id = gs.getUserID();
Here is the condition to paste into the ng-repeat:
Do a Ctrl+F and find
ng-repeat="e
Then add this to attribute to the HTML:
ng-if="e.element == 'attachment' && e.user_sys_id == data.user_id || e.element != 'attachment'"
Best,
Andrew

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-05-2018 11:58 AM
I was able to end up doing this easier by putting a condition on one of the OOB ACL on the attachment table to only run if the table name is not incident and then creating an ACL specifically for when the table name is incident.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-20-2024 02:55 AM
What was the ACL you updated?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-07-2024 12:42 AM