-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added workflows to folders #7
base: master
Are you sure you want to change the base?
Conversation
Added a new step applyWorkflows() that will add workflows to folders that use them.
Was the idea here to use the |
Yes sorry I wasn't sure how to make changes to multiple files in one commit. Anyways the applyWorkflows() function in index.php makes use of the editWorkflowSettings() function in cascade_soap_lib.php FYI readWorkflowSettings() is called earlier and outside of applyWorkflows(). It's called whenever a folder is being looked at, in order to determine if that folder has a workflow. If so, the workflowSettings are appended to an array and at the end of the first pass, there is a loop over the array to which applyWorkflows is called on each iteration. This way the workflows and folders definitely exist before trying to apply them. |
// check to see if folder has a workflow | ||
$workflowSettingsParams->type = $type; | ||
$workflowSettingsParams->path = $path; | ||
$workflowSettingsParams->identifier = $workflowSettingsParams; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not quite following this. You're creating an object to pass to readWorkflowSettings
and then setting the identifier
property on that object to itself?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking at this now looks wonky. Probably should have wrote it like this instead:
$workflowSettingsParams->identifier->type = $type;
$workflowSettingsParams->identifier->path = $path;
which is equivalent to the code above.
@earlfogel would you have the time or interest in looking this over as the original author of this tool? |
I'd like to say yes, but I have too many other things on my plate these days. Sorry. |
No problem. Thanks for the heads up. On Mon, Aug 11, 2014 at 5:54 PM, Earl Fogel [email protected]
|
Added a new step applyWorkflows() that will add workflows to folders that use them.