Create an approval workflow with many pages without having to manually select each page with the mouse (such as creating a script / macro for repetitive tasks) ?
Hi everyone, I have a question about creating workflows in AEM (and automating repetitive tasks in general).
Our process to create a workflow in AEM is:
- Navigate to Sites > {your product's v1 folder}
- Select the icon for the page to be reviewed (if you need more than one page reviewed, additional pages can be added later from within the workflow). Various buttons become visible in the toolbar above, including "+Create".
- Click Create in the top (far left) nav. The button expands, revealing several options.
- Click Workflow. The Create Workflow window opens.
- Select Workflow Model - type 'E' or scroll to find EDP Sequential Workflow or EDP Daily Workflow. The applicable fields are displayed (workflow title, keep workflow package, package title, change summary, date, approver, publisher, etc.)
- (Fill out the various fields for your workflow.)
- If you have multiple pages to review (or your product is available to multiple countries / languages), now you can add additional pages to the workflow.
- Click Add content (top left). A modal opens, displaying the usual Sites landing page:
- Navigate to
{portal} > (language-specific site, e.g., "en-us") > {department} > products > {product} > v1 > {page}
and select another single page. - Click the blue Select button at the top right to add the page.
- (Repeat the above process for any additional pages. If your product is available in other countries, repeat the above process to Add content for the version(s) for those as well.)
- When you've added all relevant pages: Check the box next to Title to select all pages.
- Click Next at the top right. The pages will appear listed on the screen.
- Click Super Select All or Select All to select all pages. The Create button should now be enabled (turn blue).
- Click Create.
- Etc. Etc.
It's the steps under 7 (in red) that are killing us. To add a page you have to not just click, but navigate, 9 times to add the page. It's not uncommon for us to update 15 or more pages. We have customers in multiple countries, for example USA, Canada and Puerto Rico. Which means that we have to click [Add Content], then navigate all the way through the columns (and the navigation for each column is NOT alphabetized) to get to each page, then click the Select button, for each page under USA, then do it all over again for the Canada, then do it AGAIN for Puerto Rico. That's 9 clicks times 15 pages times 3 countries. That's enough to give anyone carpal tunnel syndrome.
So my question is:
How might we add many / multiple pages to the approval workflow without having to go through all the steps of manually selecting each page separately with the mouse in the UI, and instead just paste in the page paths?
For example:
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-1
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-2
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-3
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-4
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-5
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-6
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-7
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-8
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-9
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-10
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-11
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-12
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-13
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-14
/content/my-portal/en-us/my-department/products/my-product/v1/my-topic-15
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-1
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-2
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-3
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-4
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-5
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-6
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-7
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-8
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-9
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-10
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-11
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-12
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-13
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-14
/content/my-portal/en-ca/my-department/products/my-product/v1/my-topic-15
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-1
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-2
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-3
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-4
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-5
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-6
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-7
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-8
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-9
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-10
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-11
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-12
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-13
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-14
/content/my-portal/en-pr/my-department/products/my-product/v1/my-topic-15
Surely there has to be a better way to do this??
Or in more general terms, does AEM provide some way to create a macro or script to automate these repetitive tasks?
Any help would be much appreciated.