1. Overview 1.1 Overview
This document aims to help developers quickly use Workflow Components to complete system development work involving Workflow Components, such as OA or approval.
1.2 Component Composition 1.2.1 component hierarchy chart
Link ID
Processing decisions
Handling objects
User List
Draft preparation
First user
User/user 1
User 1
Review
First user
User/user 2
User 2
Review
Task sharing
Role/role 1
User 1, user 2, user 3, user 4, user 5
Issuing Certificates
First user
User/user 6
User 6
L A subprocess is included in the [review] process and is regression. That is, the main process must wait until the subprocess is completed.
L all links support rollback, redirection, suspension, cancellation, forced archiving, deletion, backup, and other commands
3 code development 3.1 create a database and import scripts and Data
L create an SQLServer Database
L open the 02. db script folder and go to the query analyzer.
N run the "init_workflow_sqlserver. SQL" file to create a script.
3.2 Create a solution
Name |
Description |
Navi. Example. Workflow |
Entire solution name |
Navi. Example. Workflow. WinForm |
WinForm sample file |
Navi. Example. Workflow. WebForm |
WebForm sample file |
Navi. Example. Workflow. WebMVC3 |
WebMVC3 sample file |
3.3 project reference DLL file
Node name
Description
RunMode
System running scenarios: WinForm, WebForm, WebMVC
PermissionService
Permission center component, entity operation string, used for reflection. inherited from IpermissionService Interface
PermissionDataBaseService
Permission center component, database operation string
PermissionDbConnectionString
Permission center component, database connection string
WorkflowDebugMode
Workflow component. debugging mode
WorkflowLoadMode
Workflow component. template data source types, including Xml and Db
WorkflowLoadFileName
Workflow component. template data file name
WorkflowService
Workflow component operation string
WorkflowDataBaseService
Workflow component. Database Operation string
WorkflowDbConnectionString
Workflow component. database connection string
WorkflowTimingService
Workflow component. scheduled service operation string
3.5 register Environment Variables
As shown in. Use WinForm as an example.
First add exception capture, then obtain the application path and name, then register the permission component and workflow component, and finally open the Home Page
Note: You can also register database components and register multiple databases at the same time.
3.6 functional module 3.6.1 proposed list
3.6.1.1 search
The search condition is the Template Name. Fuzzy search is supported.
3.6.1.2 launch
List of selected launch templates. If the launch is successful, the system prompts that the launch is successful.
If the template fails to be initiated, the causes include:
N the user does not have the template launch permission
N selected template, whose version is not the max version number. History templates cannot be initiated.
N problems occurred during the initiation. For example, the user has not found a role or organization, or the input parameters are incorrect. The problem must be analyzed in detail.
3.6.1.3 launch (including business)
Similar to the launch function, the difference is that the UI business form corresponding to the template is displayed based on the selected template. In this DEMO, the service form configuration is not supported.
3.6.1.4 new delegation
Function Description
N delegation is precise to the template stage and can be set as an organization, role, or user.
N delegation is performed within a certain period of time. You need to set the start time and end time. Someone's to-do data should be handled by another person or multiple people.
N expiration processing includes: Undo and continue. Used in the workflow timing engine service
N indicates whether to delegate data immediately after it is added successfully. It is not based on the start time and end time.
N to-do hiding: Indicates whether to filter out the to-do list of the delegated user in the user's to-do list.
3.6.1.5 delegation list
Function Description
L search
The search criteria include the link ID, start time, and end time, and whether to use the link.Note:The data itself has been based on the templateIDAnd version Filtering
L view
View template delegate details.Note:View Only,Cannot be modified
L revoke Delegation
After the template delegate is revoked, the process instance initiated after the template does not have the delegate information. The delegate information of the previously initiated process instance still exists.
L Delete Delegation
Directly delegate data to the template. This function has been used to revoke the delegation function and delete the data directly from the Db table.
3.6.2 process instance
3.6.2.1 module description
L tree control on the left, which is differentiated by the process instance status type. Select a level-1 node and load the process instance data of the logged-on user in this status.
L The search condition can be filtered by Template Name, version, process instance ID, and Operation user. Note: If you log on as an administrator, you can use the operation user search condition to retrieve the process instance data of this user.
L functional commands adopt the toolbar layout, including functions such as flow, end, and rollback
L batch data topic names include: link ID, handling time limit and unit, start time, and motion status. The corresponding entity class is WFWaitDealModel.
3.6.2.2 Transfer
L click [transfer] to bring up the transfer configuration page, as shown in
L Function Description
N uses the Tabpage control. Each panel indicates the information of the link to be transferred to the to-do user, which is the to-do user of the link to be transferred.
N on the left is the list of users to be selected. This configuration information is used for template procedures.Note:Regardless of whether the authorization type is an organizational unit,Role or user.Will eventually become a user,For users
At the top right of u, the list of selected users is recorded.
U permission
Ø target link processing decision: you have configured a link to process the decision during template configuration. Here, you can modify the decision again. Reason: there are many cases of transfer to the link, including normal transfer, rollback, and redirection.
Whether distribution is allowed: used for parallel operations. assume that five users are selected. if this option is not selected, one link data entry and five link approval opinion data entry are generated. If this option is selected, five link data entries are generated, each link data generates one link approval comment data.
Pre-generated data: task sharing is used for Link processing and decision-making. when all the users in the Link request, the 1st users do not generate the to-do data for the target link after the process is completed. if this option is selected, the to-do data of the target link is selected, but the operation is not allowed.
The bottom right of u is the sub-process list. During the transfer process, you need to initiate additional templates to help complete this process.
At the bottom of u, you can configure the options for sending messages. You can send messages to SMS, email, and insite emails. Note: each sending option is implemented through an interface provided for direct implementation.
L after the operation is complete, click the [OK] button to execute the [SubmitWFInstance] Method in the workflow component service. If the operation is successful, the instance ID of the current link of the Process instance is returned.
3.6.2.3 complete
The end command is only applicable to link processing and decision-making and task sharing. not used by the last user. indicates that the user has completed the process. if the operation is successful, the instance ID of the current link of the Process instance is returned. if the operation fails, the possible causes are as follows:
3.6.2.4 rollback
L click [rollback] to bring up the rollback configuration page, as shown in
L Function Description
N has the same layout and functions as the [flow] Panel.
L after the operation is complete, click [OK] to execute the [BackWFInstance] Method in the workflow component service. If the operation is successful, the instance ID of the current link of the Process instance is returned.
3.6.2.5 redirection
L click [jump] to bring up the jump configuration page, as shown in
L Function Description
N the navigation link list is displayed on the left. Note: You can jump to any link, including initiated or uninitiated links. Status columns are used to differentiate links.
N the user list for the selected link on the left is displayed on the right. You can select multiple links.
N is another configuration at the bottom, which means to send this information to the to-do user
L after selecting the link and link handling user, click OK to execute the workflow component [SkipWFInstance] method. If the operation succeeds, the instance ID of the current link of the Process instance is returned.
3.6.2.6 replacement
L click the [Replace] button to bring up the replace configuration page, as shown in
L Function Description
N page layout by organization + User List
N select the left-side Tree node, and the right-side list loads users under the Organization for selection.
L select the user information and click OK to execute the [ChangeWFInstance] Method of the workflow component.
3.6.2.7 Archiving
The archive command sets the running status of the Process instance to end, indicating that the flow of the Process instance has been completed and no other operations are required.Note:This command only archives the process instance data at the last stage..Non-last-level links cannot be archived
3.6.2.8 forced Archiving
The Force archiving command has the same function as archiving. The difference is that the process instance is not limited to the last stage. You can archive process instances at any stage.
3.6.2.9 revoke Delegation
The revoke delegate command is not a template-level revoke delegate. It is to delete the delegate data in the process instance, which is called revoke delegate in the same way as the revoke delegate function in the template.
3.6.2.10 pending
L click [suspend] to bring up the suspend configuration page, as shown in
L Function Description
N start time and end time, indicating the start time and end time of the Process instance suspension
N expiration method, including undo and continue. Used for workflow SCHEDULED SERVICE
N indicates the reason for Suspension
N whether to suspend immediately depends on the start time and end time. After the suspended data is successfully saved, the data of the corresponding process instance is directly suspended.
L after data entry is complete, click OK to complete the pending operation.
3.6.2.11 copy
The Copy command completely copies the data of the Process instance, and the process instance ID is new. the copied data includes process instances, link instances, link approval comments, and process monitoring data.
3.6.2.11 backup
The backup command changes the running status of the Process instance to "backup", indicating that the process instance does not appear in the user's to-do list or running status.
3.6.2.12 Delete
DELETE command to directly Delete the process instance from the Db table. Note: At the same time, store the data in the process instance to the persistent table for Future Search
3.6.2.13 monitoring
L click the [monitoring] command to bring up the monitoring page, as shown in
L Function Description
N displays basic information about the process instance at the top, including the template ID and version.
N link transfer information on the left
N The Link operation information is displayed on the right. For example, execution pending, restoration, and replacement are recorded.
3.6.3 configuration options
3.6.3.1 search
The search condition is the option name and activation status. The option name supports fuzzy search.
3.6.3.2 new
Add configuration options, as shown in
After entering the data, click Save to save the data to the database.
3.6.3.3 Modification
Modify the configuration option values in the list, as shown in
After modifying the data, click Save to save the data to the database.
Note:If the configuration option is system configuration,It cannot be modified,The dialog box shown in is displayed.
3.6.3.4 Delete
Delete the configuration options in the list
Note:If the configuration option is system configuration,Cannot be deleted
3.6.4 workflow calendar
3.6.4.1 search
Search criteria include start and end dates, date types (date and time), date types (work days and rest days)
3.6.4.2 new
Add date, as shown in
After entering the data, click Save to save the data to the database.
3.6.4.3 Modification
Modify the date, as shown in
After the data is modified, click Save to save the data to the database.
3.6.4.4 Delete
Delete calendar from the list
3.6.5 default approval comments
3.6.5.1 search
The search is divided into two parts: one is based on the user's search; the other is based on the approval comments, and fuzzy search is supported.
3.6.5.2 add
Add approval comment data, as shown in
The template information can be selected on the pop-up page, as shown in
After entering the data, click Save to save the data to the database.
3.6.5.3 Delete
Delete the selected approval comment data from the list
4. Designer 4.1 (WinForm) 4.1.1 template list
Function Description
L tree control on the left. Load the template names of different versions. Click the tree node to load the list of different versions of the template names.Note:Click top-level node,Load all templates
L The top right side is the search condition. The search condition is the Template Name and activation status.
L The toolbar list is displayed at the top right, including adding, copying, adding, modifying, deleting, importing, and exporting templates.
N Add: The template document page is displayed to add
N new copy: Get and load the template ID and version of the selected row. The details are loaded into the form for users to modify.Note:Automatic version number+ 1Processing
N modify: Modify the template information of the selected row.Note:Modify operation,You cannot delete links or other information.
N delete: The delete function includes deleting the template information of the selected row (a version), deleting the information of a template (all versions), and deleting a template (a version) generated Process instance information
N Import and Export: supports exporting template data to Xml and SQL, in two file formats
L the right half of the page contains the upper and lower content. The launch permission list of this template is displayed above. The following shows the template link list.
4.1.2 template form
Function Description
L The toolbar is displayed at the top, including the launch permission addition, release template, and close.
N launch permission: maintain who is allowed to launch this template
N Release template: After the template is designed, click this button to save it to the database.
L The upper part is the basic information of the template, including the Template Name, launch time, and handling time.
L The lower part is the template link information. The functions include adding, copying, deleting, and quick entry.
N add link: The new link form is displayed.
N replication link: copy the new link based on the selected link information, and its identifier + 1 is processed.
N Delete link: Delete the selected row Link
N select a row and click "set". The modify link form is displayed.
4.1.3 template initiation permission
Function Description
L permission types include
N to person
N to role
N to the Organization
N dynamic to template handling person: refers to the list of handling users configured in the template.
N dynamic to process instance to-do list: it refers to the user column table configured by the user in the template stage, select who can handle this stage
N dynamic to process instance handler: refers to the list of users actually handled by the instance in this link
L multiple initiation permissions are allowed, and the permission types can be different
4.1.4 template link form. Basic Information
Function Description
L status ID: the link identifier, which is unique in the template and cannot be repeated.
L handling time limit: the time limit for handling this link. units include minutes, hours, and days.
L status type: identifies whether this link is a special link of the template: the first or last link. the first step refers to the link that is transferred to after the template is initiated, and the last step refers to the link where the template allows archiving.Note:The entire Template,There is only one first and last link
L processing decision-making: the condition type that allows this link to flow down, including first user and task sharing. Note: For the differences between the two, see the operation manual.
L parallel settings: This option is used to initiate and aggregate parallel branches. when the launch option is configured, user to-do data must be generated for all the pending branches in this link. When the aggregation option is configured, this indicates that the allowed conditions for this link should be used to determine whether all the to-do data flowing to this link has been transferred. If so, downward flow is allowed.
4.1.5 template link information. Handling Permissions
Function Description
Note:The configuration method is the same as the template launch permission.,Omitted
4.1.6 template link information. Condition Branch
Function Description
L link condition branch refers to the direction of the branch that allows Downward Flow in this link. it is equivalent to reaching the destination, and there can be many routes, which is equivalent to the condition branch. the condition branch is for the user to select.
L condition branch entry page
Function Description
N branch name: link ID. It must be a link ID.
N branch labels: used for parallel branches. If the branch labels of several branches are the same, these branches need to be processed in parallel.
N default branch: used by the timer engine. If you have not completed the operation within the specified time, the timer engine can automatically flow to the default branch.
N filter the organization and role. It is used to filter out the users who are in the same organization or role as the logged-on user Based on the organization and role of the currently logged-on user.
N-link processing decision: it refers to the processing decision of the target link, which can be modified here
4.1.7 template stage information. Sub-Process
Function Description
L The Subprocess of a link allows another template to be initiated in this link. Note: Multiple templates can be initiated in the same link.
L subprocess entry page
Function Description
N subprocess information, which is loaded by selecting a template form, as shown in
Whether n is returned to the main process, indicating whether the main process needs to wait for the initiated sub-process
N subflow versions are replaced by Max. Since the template is constantly adjusted according to the business and a new template is re-initiated, the version of the subflow at a certain time point may be a template of a previous version. if this option is selected, the template version of the sub-process is always up to date. The template information of the maximum version is used.
4.2 designer (WebForm Version)
Not available for the moment. Please refer to WinForm page development
4.3 designer (WebMVC Version)
Not available for the moment. Please refer to WinForm page development
5. integration with other systems
Sample file
Http://pan.baidu.com/s/1qWjVFgK