UPDATE: Sien hierdie MSDN bespreking, veral die laaste inskrywing: http://forums.microsoft.com/MSDN/showpost.aspx?postid=2631057&siteid=1. It describes a condition that may short circuit this whole thing. In kort, Dit kan so eenvoudig wees as om ten minste een van die velde verpligte.
Ek het 'n dokument biblioteek wat ondersteun agt inhoud tipes.
I have a SharePoint Designer workflow that wants to calculate and assign a "reminder date" deur eenvoudig te trek 30 dae vanaf 'n ander kolom, "due date". This should only happen for one of the content types, "Insurance". The business objective is to produce a KPI that shows two categories of insurance documents: "about to expire" and "expired." (Jy kan meer lees oor hierdie soort van KPI en meer aansienlike boor-down hier).
I have configured the workflow to fire when a new item is created and when an item is modified. The idea is that when an insurance document is uploaded, we calculate a "warning date" based on the expiration date. A pair of views work in connection with a KPI List to highlight these conditions when users hit their home page.
Hierdie strategie werk nie wanneer ek laai 'n dokument.
I upload the document and I am presented with the meta data entry screen. Op hierdie punt, I’m already in trouble. SharePoint has already, voortydig uit my perspektief, fired the workflow. I haven’t had a chance to pick the correct content type nor assign a due date. Op dieselfde tyd, the workflow does not fire when I hit the submit button at this time. There’s some built-in logic that "believes" that first submit is part of the "create" event. So … my workflow het gevuur en wanneer dit uitgevoer, it was passed default meta data values.
The best work-around I know of is to insert a "pause until" activity in the workflow. I have the workflow pause for 1 minute. While it’s pausing, Ek kies die korrekte inhoud tipe, enter the meta data and submit. The pause completes and the workflow proceeds as needed. (Let daarop dat in my omgewing, timer workflow activities from SPD do not work out of the box. You may have the same trouble. Sien hier vir meer besonderhede).
I don’t like "magic delay" work-around. What happens if the user uploads a document and the phone rings and the ensuing conversation outlasts the pause? I can make the pause longer, maar ek het nog nie daarvan hou nie.
Ek het geskryf oor hierdie op die MSDN forums hier: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2430725&SiteID=1