Can I archive data from a list and clear a task form for next day use?


Badge +8

Hello

I wasn't quite sure how to search for this so I am asking my trusty Nintex friends.

I have a SP2013 list and have attached a Nintex form to it. The list is a validation list that people have to go in daily/weekly/monthly/etc to validate line items and pass or fail. I want to create a workflow that when an item gets put in "Pass" status, the data archives to another folder and that line item clears out specific fields to get it ready for the next day/week/month/etc's validation.

Is this something that is possible with workflow? I am new as of 1 day to Nintex Workflow. Thanks in advance.

Josh

Cassy FreemanPatrick AbelEmily BillingPhilipp LucasRyan Duguidjenn kelleyJamie TruranCeline BaldeviaJason SiebertEmily Slagle


72 replies

Badge +16

I would create a secondary list (not folder) as the "live" list in the exact same structure and call it archives or something similar.

Have a workflow that runs on modified when item is marked as pass

In the workflow use the create item action to take the current item and copy it to the archive list

then update the fields in current item to be ready for the next day

if you let me know more about the structures if you get stuck I can do a small demo for you.

Badge +8

I have the workflow created but I am stuck at the part where I clear items and get ready for the next day. Do I use a "delete item" action for this part? I tried that but don't really know how it's works.

184328_pastedImage_0.png

Badge +16

Don't delete it if you need it again for the next day. Use update item to reset the fields our need ready for the next approval...

Badge +16

You not our...

this forum is so difficult on a mobile device!!

Badge +8

Hello Cassy Freeman​, I am not having much luck with this. Do I need to have values in these fields? And do I need to use the "start workflow" action? That confuses me because you specify in the workflow settings, what kicks it off. Thanks!

184366_pastedImage_0.png

This is what I have

184367_pastedImage_1.png

Badge +16

Ok so where it says value use list lookup current item and choose the same column name from the current item to move into archive list. Do this for all fields.

Badge +8

Cassy, you are wonderful! Can you just come sit next to me please? lol. Seriously, thank you for the time you keep taking to help me out. I hope it doesn't sound like I am asking you to do it all for me. You have taught me a lot though.

So with that, another question. After I send the data to the new list, how do I update the old data to get ready for the next review? I tried the update action to replace with blank. That doesn't seem to work. And also...when would I use the "Start a Workflow" action? I am confused on why this action is available. Should I be using it?

184477_pastedImage_0.png

Badge +16

Ok so you could use update item (current item)  choose the fiel from the drop down that you want to update. that should work. But if it doesn't then try set field value and update each field where required.

sorry for the typos - I am on my mobile again and for some reason it won't let me correct them! Frank Field​ we really need to make this more mobile friendly!

the start workflow action is awesome but you won't use it that often. I use it if I have a particularly meaty workflow that I want to breakdown into separate workflow. Then inside workflow 1 I will start workflow 2 and wait for that to complete before continuing  workflow 1. more typos there sorry - so frustrating!

i dont think you need start workflow in this scenario. happy.png

Badge +16

Just looked at your screenshot. Why are you using function? Do you just want to set them to blank again? If so, create a text variable with no default (essentially blank) and set your fields in the update item action to variable.

Badge +16

how did you get on?

Badge +8

Hi Cassy! Ok, so I have everything written to your specifications. Something still isn't working.

I have my main list where the audit will be performed daily. I created a 2nd list with the exact same fields and field types called Archive.

I created a workflow that starts with a "run if" action that says run if field "Review Process Completed equals "Value "Yes"

Next action is a "create item" to create item in ICR Archive (2nd list referenced above). For every field I chose "List Lookup", Source was "Current Item" and fields matched the fields I selected in the field dropdown.

My last action is an "Update" action. The action is to Update "current item" and I created the "Blank Field" variable and selected every field I wanted to blank out on the main list and did a Equals: Value "Blank Field"

Complete Workflow

184784_pastedImage_0.png

Cassy Freeman

184785_pastedImage_1.png

184786_pastedImage_2.png

184787_pastedImage_3.png

184788_pastedImage_4.png

Badge +16

OK so first of all - those actions should be inside the container for run if.

Secondly - when you say it's not quite working - what isn't working?  is it erroring?  it is creating the item in the archive list?

Badge +8

Ok, so it's not working at all. It's not erroring out or anything. Just not moving fields to the archive list and not resetting the old ones to blank.

So I need to use the Action Set action as a container?

Badge +16

Can you send screen shot of your list  settings columns and which fields you want to reset and I'll have a go x

Badge +8

Here re my columns from the original audit list. The columns in the red box are the ones I want to reset every time. The ones outside the box are static.

184789_pastedImage_0.png

Badge +8

I did lie about one thing. :-) On my Archive list, I did not format the columns as above. Because I exported the main list and deleted the data and re-imported as the archive. So most fields are single line of text except for the big ones like comments. I made those multiple lines of text.

Badge +8

Btw...in my create action to where I move the data to the sheet, I am moving ALL those columns you see above. In the meantime, I did find something online regarding using action items. Looking into it now.

Badge +16

OK Josh that will cause you some issues I expect if you are taking a choice column and copying it to a single line of text field.

Can I suggest that you save the above list as a template (without the data) and create your archived list with that template so that they are identical - I honestly think it will be better in the long run.

Once you have done that, your create item action should work perfectly fine if you choose list lookup - current item - field (matching) for each field to insert the data.  Perhaps try creating a workflow that does just that first, and test it by running it manually on an item.  Once you are happy that you can copy an item from original to archive list exactly, move on to the update item.

As for the update item, I have a proposal:

  • Have an item in your list that is basically a template (ie what you want your reset item to look like).

ListWithItemsAndTemplate.PNG

  • In the update item, set the columns equal to list lookup, name of current list, choose field where title = Template with blank fields (or match on ID if you know the ID of the template item)

Josh - UpdateItem.PNG

Note in the above my TestForJosh list is the name of the list I am running my workflow on (so for you this would be the name of the original list) and then using when to find the template item.

  • Do this for all fields you need to reset (pay attention and take your time as it is easy to make a mistake)

I have created a smaller version of your list as pictured below and run the update item action, you can see below it reset all the values and the workflow shows as completed:

ListWithItemsAndTemplateUpdated.PNG

Let me know how you get on.  I really hope we can get to the bottom of this one for you!

Badge +8

Wow! You're good! You got that to work exactly how I wanted. I am working on your suggestions now and redoing my archive list template. May take me awhile.

What do you mean by "Let me know how you get on"?

Badge +16

Erm we say it in England all the time, it means tell me if that works or not I guess (never really thought about it's meaning so hard before!)

Badge +8

Now I am imagining you telling how to do all this in a English accent lol

Badge +16

haha look up "The Only Way is Essex" and you will get my accent - then you'll take me a whole lot less seriously happy.png

Badge +8

Haha well you were right about that. Now I have a whole different vision of you. Maybe I shouldn't have watched the Lauren Pope video on youtube. haha. She is funny. Are you on the show?

Badge +16

Not a chance!! I like to think i have a few too many brain cells and not enough plastic surgery for that!

Badge +8

Haha. Well, you definitely have the smarts. We already know that. I'm in the states, if you haven't figured that out.

Reply