Trading Networks 10.3 | Administering and Monitoring B2B Transactions | Trading Networks Administrator's Guide | Example of User Status in Document Processing | An Example of User Status while Processing a Document
 
An Example of User Status while Processing a Document
1. Trading Networks receives a document and recognizes that its document type is PO. The document types does not specify to extract the UserStatus system attribute, so the user status is null.
2. The document matches the processing rule criteria that the document type must be PO and the document can have any user status. The rule specifies the Alert e-Mail action, and the e-mail contains a URL for a Web page that displays the PO. The processing rule also changes the user status to Needs Approval.
3. The user clicks the URL to open the Web page to view the PO. The Web page contains an HTML form that lets the user accept or reject the PO.
4. If the user accepts the PO, the code uses the built-in service wm.tn.doc:changeStatus to set the user status associated with the document to Accepted. If the user rejects the PO, the code uses the built-in service to set the user status associated with the document to Rejected.
5. The code for the Web form invokes the wm.tn:submit built-in service that sends the document back to the Integration Server for processing. Trading Networks recognizes the document type is PO and determines the user status.
6. The document matches either the processing rule that indicates the document type must be PO and the user status is Accepted or the document type is PO and the user status is Rejected. The rule specifies the Execute a Service action, and the service processes the purchase order.
The image shows the service execution flow