16. (Optional) Clean up your environment by deleting the application artifacts
This optional step describes how you can clean your environment by deleting the artifacts that you created in this tutorial. For example, if you are working in a shared environment, you may want to delete your tutorial applications to keep your environment clean and tidy.
Use the Management site to delete deployed workflows
Begin by deleting the deployed versions of the Leave Request Workflow from the server. First, you must delete any active process instances, then delete the deployed workflow versions.
- From the Management site, delete any process instances associated with the Leave Request Workflow. You are deleting any process instances that are active, running, stopped, or in error. You can also choose to remove reporting data as well.
Location: Categories > Learning > Leave Request > Workflow > Leave Request Workflow > Instances (remember that Learning might have a different name in your environment).- From the Categories menu, navigate to the Learning > Leave Request node (remember that Learning might have a different name in your environment). Expand the Workflow category and select Leave Request Workflow.
- In the central pane, click the Instances tab. Check to see if there are any active, running, stopped, or erred process instances. If there are, select them one-by-one and click the Delete button (there may be more than one instance). You see a pop-up where you have the option to delete reporting logs. Check the Delete Reporting Data (Logs) box, then click Delete. This removes any reporting data generated for the process instance.
- Repeat the step above until you have deleted all process instances for the Leave Request Workflow.
- From the Categories menu, navigate to the Learning > Leave Request node (remember that Learning might have a different name in your environment). Expand the Workflow category and select Leave Request Workflow.
- Delete all versions of the workflow. You may see more than one version and you have the option to delete all versions or specific versions. In this case, you delete all versions along with the historical data and workflow reporting SmartObjects.
Location: Workflow Server > Workflows > Workflow > Leave Request Workflow > Versions.Your artifact names may not match the steps exactly if you added your initials to make them unique. When an artifact name is referenced, use the name you entered when creating it. Artifacts include views, forms, SmartObjects, workflows, service instances, roles, groups, and SharePoint lists and libraries.- Expand the Workflow Server > Workflows node. Expand the Workflow category and select Leave Request Workflow.
- In the central pane, click the Versions tab. In the image below, there is only one version of the Leave Request Workflow. You may have several versions, depending on how many times you deployed the workflow. Notice the columns for Active, Running, Stopped, and Error instances. You should see zeros here, since you deleted all process instances in the prior step. Select a version and click Delete.
- On the Delete Workflow screen, select Delete all versions, then check the option to delete all historical data and workflow reporting SmartObjects. Click OK. Repeat this step until you have deleted all versions of the workflow.
- Expand the Workflow Server > Workflows node. Expand the Workflow category and select Leave Request Workflow.
Use the Designer to delete application elements
The next step is to remove application elements using the Designer. Here, you can remove views, forms, SmartObjects, workflow design files and categories.
- In the Designer, delete the Leave Request Workflow design file. (In the previous step, you removed workflows published to the server. In this step, you are removing the "design" copy of your workflow.)
Location: All Items > Learning > Leave Request > Workflow. Remember that the Learning category might have a different name in your environment.- Return to the Designer. Navigate to your Learning > Leave Request categories - remember that the Learning category might have a different name in your environment . Expand the Workflow category and select Leave Request Workflow. Right-click and select Delete. Click Yes for the confirmation.
- Return to the Designer. Navigate to your Learning > Leave Request categories - remember that the Learning category might have a different name in your environment . Expand the Workflow category and select Leave Request Workflow. Right-click and select Delete. Click Yes for the confirmation.
- Delete the Leave Request Form. (You must delete forms first, followed by the views used on those forms.)
Location: All Items > Learning > Leave Request > Forms.- Expand the Forms category.
- Right-click Leave Request Form and select Delete. Click Yes for the confirmation. If you see a message about associated workflows, you can ignore it and continue.
- Delete each view. (There is no specific order for deleting views).
Location: All Items > Learning > Leave Request > Views.- Expand the Views category. Right-click each view and select Delete. There is no specific order you must follow for deleting views. Click Yes for each confirmation.
- Expand the Views category. Right-click each view and select Delete. There is no specific order you must follow for deleting views. Click Yes for each confirmation.
- Delete the Leave Request SmartObject.
Location: All Items > Learning > Leave Request > SmartObjects.In the next step, you delete the Leave Request SmartObject.
- Expand the SmartObjects category. Right-click the Leave Request SmartObject and select Delete. Click Yes for the confirmation.
- Expand the SmartObjects category. Right-click the Leave Request SmartObject and select Delete. Click Yes for the confirmation.
- Delete the learning categories. You must delete the subcategories first (Forms, Views, SmartObjects, Workflow) and then Leave Request. Finally, you can delete Learning if you do not intend building more tutorials, and remember that the Learning category might have a different name in your environment.
- Delete the application’s categories. You must delete the subcategories first (Forms, Views, SmartObjects, Workflow) and then Leave Request.
- Finally, you can delete the Learning category if you do not intend building more tutorials. Remember that the Learning category might have a different name in your environment.
- Delete the application’s categories. You must delete the subcategories first (Forms, Views, SmartObjects, Workflow) and then Leave Request.
Summary
If everything worked as you expected: congratulations!
Having completed this tutorial, you learned about three main application components: data, forms and workflow. At this point, you should have a basic understanding of how to build SmartObjects, views, forms and workflows, and how to combine them together in the context of a workflow-centric application.