开发者

Which Activity to use to represent a long wait for a document in my WF app?

Basically, I have a point in my workflow where after a document has been sent and a number of things will/might happen.

  • The customer has 10 days to send a response
  • When the customer's response h开发者_如何学编程as been received anytime within the 10 days, the wait is over and the response should move to the next step of the workflow
  • On day 8 or day 9, if there is no response, an email should be sent to the customer
  • On the 11th day, an email should be sent to the customer stating the response is late
  • Afterwards, an email should be sent every 3 or 5 days to the customer until the response is received

I'm not sure if I should or could use a While Activity in the workflow or use a Code Activity with a While loop in the Code-behind. I'll be tracking the day the document is sent, its due date, and when the response is received. I'm just not sure on the best practices/approach to doing this.


This is my first attempt at WF. Does this look right? Based on my criteria above?

Which Activity to use to represent a long wait for a document in my WF app?


So I'll go through this with small explanations

  • Transmittal Event: This is an event captured from the hosting app (ie. ASP.NET Web form) and sent to the workflow. With this event the workflow starts.
  • TrackDates Code Activity: The workflow captures certain about the document here. Such as: Date and Time when it was sent, Date and Time when it will be due, and FileName
  • ListenActivity1: This gives to two branches (it can be more) that are listening to events. Similar to an if/else statement, however only an event can determine which path will be taken. In this workflow, there are two paths. Left path is when a document returns and has been loaded by the Webform. The right path is if nothing has returned in 10 days.
  • WaitForTenDays Delay Event: The timer in this event will be set to wait 10 days after the document has been sent.
  • SendEmailToCustomer Code Activity: After the WaitForTenDays event is triggered, this activity will send an email to the customer informing them that they are late.
  • WhileReturnIsLate loop: This checks the database to see if the document has been returned. If not is will continue on to the next Activity.
  • ListenActivity2: please see ListenActivity1 for general description
  • WaitForFiveDays Delay Event: Please WaitForTenDays for general description
  • SendEmailEveryFiveDays Code Activity: Check the dates to see if another 5 days have passed, if so send an email to the customer reminding that they are late.
  • LinkReturnToTransmitted Code Activity: Links the returned document to the transmitted document through the database
  • SendEmailToPMNDoc Code Activity: Sends email to project manager and documentation department that the document has been returned by the customer.
  • HandleExternalEventActivity1 Event: Receives an event from Webform that the document has been returned by the customer.
  • HandleExternalEventActivity2 Event: Please see HandleExternalEventActivity1 Event

If anyone has any comments, criticisms, or improvements that could made to this. Please share. Thanks.

Which Activity to use to represent a long wait for a document in my WF app?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜