Can Realted List data can be added to Activities field ?

thirumala2
Tera Guru

Hi ,

Can we show / add related list data(document revision , user permission ,grp permission  etc ) or other tables data  into Activities /activities logs?

If Yes ,How ?

find_real_file.png

find_real_file.png

 

1 ACCEPTED SOLUTION

Jaspal Singh
Mega Patron
Mega Patron

Hi Thirumala,

 

As suggested by Aman in comments before you need an After insert/update Business Rule on the Related list table that then updates the Activity of actual form where you see records as related list.

View solution in original post

7 REPLIES 7

Aman Kumar S
Kilo Patron

Yes, you certainly can but you will need to create a BR on the table to print the work notes for those records

Best Regards
Aman Kumar

Hey,

Hope I have answered your question!

 

Feel free to mark correct, If I answered your query.

Will be helpful for future visitors looking for similar questions 🙂

Best Regards
Aman Kumar

Hi ,

Thanks for replying .

I have tried the below script for  above problem :

I have used after inert/update br on dms_document_user_permission _table with condition as : User changes ,  but its printing duplicates users in activity logs .

var rev1 = new GlideRecord('dms_document');
rev1.addQuery('sys_id', current.document);
rev1.query();
if (rev1.next()) {
    var rev = new GlideRecord('dms_document_user_permission');
    rev.addQuery('document', rev1.sys_id);
    rev.query();

   while(rev.next()) {
        rev1.u_work_notes = 'User :'  + current.user.getDisplayValue()  +'Type :' + current.type;
        rev1.update();
    }

 

Can you please help me understand where it is going wrong .

Its because you are using after BR and also using update(), that is going to trigger this BR recursively.

I would suggest to use rev1.setWorkflow(false) just before update statement, then it should work

Best Regards
Aman Kumar