Solved

Send grouped list items to corresponding user (Document Review)

  • 18 June 2020
  • 4 replies
  • 82 views

Badge +3

Hi all,

 

Im in the middle of developing a Site Workflow thats supposed to send out emails with document links to users in the "Created By" collumn based on a date/time filter (End Date).

 

I have some parts working already... The WF picks the correct items from my list and sends them out in a mail. I've used a build string action to add .../Dispform.aspx?ID=X to each listed document in the mail.

 

The one problem I have right now is, that the email contains all documents for every user.

 

My list basically looks like this

DocName Created By
Doc1 User A
Doc2 User B
Doc3 User A
Doc4 User B
Doc5 User C

 

The Mail that gets send out to User A should only contain Doc1 and Doc3 for example.

 

I've looked at the following posts already but got lost at some point with the instructions:

https://community.nintex.com/t5/Community-Blogs/Send-grouped-notification-based-on-list-items/ba-p/82143

https://community.nintex.com/t5/Nintex-for-SharePoint/how-do-you-send-a-single-email-for-multiple-list-items/m-p/31573#M25996

 

Would someone be so kind and give me some hints on how to achieve this?

 

Thanks a lot!

 

Michael

icon

Best answer by mike_m 9 July 2020, 16:52

View original

4 replies

Badge +8

Hi @mike_m,


to me this looks like you have to add a loop to be able to filter by user as well as date/time. Something like this (actions are not configured):



 


 

Badge +3

Hi @Tarf ,


Im really sorry for the late reply and thanks a lot for your response.


I've been working on this again a bit and your suggestion pointed me in the right direction. Here is what I came up with:



First im getting all Users for the corresponding list and store them in a collection variable, then remove duplicate users from the collection variable so Im only looping through each user once.


 


I needed the first 'set variable' action for the 'Created By' filter to work in the list query. For some reason Nintex doesn't like to filter values based on the OOTB 'Created By' Column. I also had to use the CAML editor to do my list query and modify the code a bit. (Thanks to this thread btw. Solved: Query List - People column - Nintex Community)


 


2nd 'set variable' action clears the Mail variable from the 'build string' action after each loop. Else only User A gets the right items mailed to him. User B would see all previous items from User A and his aswel. User C would receive items from User A, B and his... etc.  


 


The loop inside the loop gets all the items that got queried and creates the /.../Dispform.aspx={ID} string for each item.


 


Finally I send out the mail to 'Created By'.


 


I hope this helps someone to achieve what I've been struggling with for a while 🙂

Hi @mike_m


 


I am also trying to accomplish the same thing as you. As a Nintex newbie, would you mind guiding me through the workflow, as well as the settings within each step of the workflow?

Badge +3

Hi @nintexnoob21 


 


I already explained a bit what Im doing in each step in my last post above.


Can you tell me where exactly you're having problems with setting up the WF?


 


We're not using Nintex anymore to build Workflows in SharePoint. Therefore Im unable to provide you with any more screenshots unfortunately. 

Reply