0
votes

I was hoping you could help me. I have a calendar in SharePoint 2010 that I want to run a Nintex Workflow when the following conditions are true:

  1. A new item is created
  2. The "Type of Leave" field equals "Vacation". This field I created as just a category for the types of requests.
  3. The date that the item was created for already has an entry with the "Type of Leave" field equaling "Vacation."

The use of this will be that the first person to enter vacation on a day will be automatically granted. But if more than one person enters vacation on the day that another vacation day is on, it will go through an approval process through their manager.

Here's what I've tried/reviewed: - Using a Condition within a workflow. I can't find an option that would complete this. - I did try looking on line searching for different solutions. I've watched some tutorials but nothing with this kind of solution was present. - One thought I did have was to have an additional calculated column that counted how many entries for the same day with "Vacation" and then use that in a condition if the column was greater than 1 but I couldn't figure out the syntax.

This is on SharePoint 2010.

Thank you!

2
What have you tried so far? Read through meta.stackexchange.com/questions/156810/… and see if you can provide a little more information.Mark
You should edit your question to include those details.Mark

2 Answers

0
votes

have you considered using the rest interface to query the list from nintex:

http://msdn.microsoft.com/en-us/library/office/ff521587(v=office.14).aspx

You can call this service from nintext using the call web service action.

Apply the filters on the url as per documentation above and count the records returned you can then include that in the nintext condition.

I am not sure if Nintext supports calls to Restfull services (from memory i think it does).

If not, you can use the Soap web service, same principle as above just the parameters to call it are slightly more complicated:

http://msdn.microsoft.com/en-us/library/lists.lists.getlistitems(v=office.12).aspx

0
votes

I don't think there's an need for REST. Once your workflow starts, query the list for items matching the current item booking date and put the result in a collection. You can query the collection length, and if it's >0 you can use that condition to steer the logic of your workflow.