Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
Workflow Disabling
mindy1
I need to enable a Workflow file for a folder structure in a branch but i want the same workflow file to be disabled as we go deeper into the same folder structure and in the same branch.
If i am implementing the below Scenario,the workflow is still getting invoked.
Scenario:
<template_file name="ABC" path="xyz/ABC.wft">
<command_list>
<command value="all" include="yes"/>
</command_list>
<role_list>
<role value="all" include="yes" allusers="yes"/>
</role_list>
<branch_list>
<branch value="/default/main/<branchname>/quest/WORKAREA/quest/sites/*" include="yes"/>
<branch value="/default/main/<branchname>/quest/WORKAREA/quest/sites/*/pages" include="no"/>
</branch_list>
</template_file>
I want ABC Workflow file to be enabled for this folder structure and branch:
<branch value="/default/main/<branchname>/quest/WORKAREA/quest/sites/*" include="yes"/>
I want same ABC workflow file to be disabled as we go deeper into the same folder sturcture and in the same branch
<branch value="/default/main/<branchname>/quest/WORKAREA/quest/sites/*/pages" include="no"/>
Ideally i need to enable the WF file at sites folder structure level in quest workarea and disabled the same WF file at site/*/pages/ folder structure level in quest workarea itself.
Please resolve this query.
Thanks,
Find more posts tagged with
Comments
Adam Stoller
Reverse the ordering of the two branch elements so that the more restrictive (sites/*/pages/*) is above the less-restrictive (sites/*) clause.
This should work for things like New Job and Submit, but will probably not work as desired for tt_data (initiating jobs after saving/closing an Edit DCR session) - as that doesn't provide path information beyond the branch level.
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com
jbonifaci
Btw, this is a regular expression, so /* is looking for 0 or more /'s. You need to add in a period, which matches any character. So /.* will match a / followed by any number of characters.
~Jeff
Adam Stoller
Good catch - I meant to note that but forgot - thanks
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com
mindy1
Even this doesnot work.The workflow window automatically closed when i select NEw job from Action menu dropdown.
Please provide a solution to it
Thanks,
mindy1
This doesnt work.
If i put the restricted branch_list value before the unrestricted one,the workflow eindow gets closed automtically when i say New Job.
Please provide a solution to it
Thanks,
Adam Stoller
Please provide more details:
- What version of TeamSite (including SPs and patches)?
- What platform / OS is TeamSite running on?
- What browser (include version information) are you using to access TeamSite when the problem occurs?
- Which of the TeamSite GUIs are you using [varies based on product version]?
- Have you looked at any / all of the various TeamSite log files to see if there is a [more] descriptive error message that might indicate the actual source of the problem?
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com
jbonifaci
Mindy,
The problem is you have the order of your yes and no's messed up. Put the deeper matches above the shallower matches. As soon as a match is found, the remaining branch elements are ignored. So you need to put the deeper match first:
<branch value="/default/main/<branchname>/quest/WORKAREA/quest/sites/.*/pages" include="no" />
<branch value="/default/main/<branchname>/quest/WORKAREA/quest/sites" include="yes" />
Is the pages directory directly below the sites directory? The above regular expression will block this workflow from the following:
../sites/subDirectory1/pages
../sites/subDirectory1/subDirectory2/pages
../sites/subDirectory1/pages/subDirectory2
But allow the following:
../sites/pages
../sites/pages/subDirectory1
../sites/pages/subDirectory2
If it is directly below sites, you would then want this instead:
<branch value="/default/main/<branchname>/quest/WORKAREA/quest/sites/pages" include="no" />
<branch value="/default/main/<branchname>/quest/WORKAREA/quest/sites" include="yes" />
Also, I am assuming that you don't actually have <branchname> in the available templates file, but the actual branch name, correct?
If neither of the above work, please post the exact branch/workarea/directory paths you want to match on for both yes and no and also post your available_templates.cfg file.
~Jeff
nipper
You are attempting to use a feature in a way that is not supported.
the <branch> element is for a branch. It does work for Sub Directories
some times and some times not.
If you get it to work, great, if not, then your choices are limited. I beleive
there is a FR for this to be directory specific, you should attach your company
to it. However the main reason it is unsupported is that, what happens if I
start a job with 2 objects, one from each "side" ?
The other option is to, using Perl combine your 2 WFs to one. It would need to
build on the fly the WF and execute it.
Andy