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)
unlock/submit DCR
andres1
I have a workflow that our editors use to submit HTML files to a web server and works fine, with the exception that it does not include the DCRs used to create the HTML files, so they are not submitted and as a result stay locked.
My workflow calls an external task that published the selected files and starts an OpenDeploy deployment.
I have added the following code to my external ask to submit the DCR associated with the HTML files and it works fine the first time only. If the DCR has not been changed any subsequent time the workflow runs, it gives me an error with the following message:
ERROR:02401: File or directory is the same as the other version
Here is the code I have added to my external task:
$dcr = run("iwextattr -g TeamSite/Templating/PrimaryDCR Y:$area\\$files[$counter]");
$fulldcr = "\\\\gdvcms01".$area."\\templatedata\\TodaysNews\\TodaysNews_pages\\data\\".$dcr;
run("iwsubmit -w $fulldcr 'unlocking'");
Is there a way to attach the DCRs to my workflow in the first place, so I don’t have to go through all this pain after all?
Find more posts tagged with
Comments
Adam Stoller
The externaltask could loop through the files (as you are doing presumably), extract the DCR information (if present, as you are doing), and then - instead of submitting the file, just attach it to the task [$task->AddFile($area_rel_path_to_dcr, "comment");] - then when your workflow hits the actual submittask, the dcr(s) will already be attached and will be included in the submit operation.
Alternatively - your code for submitting the DCRs directly from within the externaltask - could check the error message to see if it matches /:02401:/ - and if so, ignore the error.
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com