2

We have designed a very basic Workflow with the following activities:

1) The first activity is Manual and in diagram we have set the Approval State as "Publish_Stage", which means that the page with this component can only be published to Staging & not to Live.

2) The second activity is "Automatic" with Approval State as "Publish_Stage" and this assigns the task to group of Approver based on some business logic.

3) The third task is to either "Approve" the content or "Return to Editor" which ends the Workflow with the Approval Status as "Publish_Live" & "Publish_Stage" respectively.

The problem we are facing is that the component locked by the WF can still be published to Live, though we have the Minimal Approval Approval Status set "Publish_Live" which is somehow getting set automatically overriding the Approval Status I have set in Workflow Diagram i.e. "Publish_Stage"

I can explain it with the following scenario:

  • Edit an existing/approved Component which has the Approval Status as “Publish_Live“, now check-in the component.
  • The Workflow gets invoked on that component and a manual activity is assigned to the editor with the Approval Status as “Unapproved”.
  • Now Editor open the activity and click “Finish Activity”, the Approval Status changes to “Publish_Live” instead of “Publish_Stage“ even though being explicitly set in Visio diagram.
  • At this stage if someone try to publish the page to Live, it gets published successfully being component locked by the WF.

I have reached to the conclusion that Visio setting is overridden by the last Approval Status because I tried another scenario:

  • Edit an approved Component which has the Approval Status as “Publish_Live“, now check-in the component.
  • Open the Admin console and force finish the Workflow by setting the Approval Status to "Publish_Stage".
  • The component is now saved & checked in with Approvals Status as “Publish_Stage”.
  • Now edit the same component, and check-in after making changes, the component gets saved with status “Unapproved” and locked by the Workflow.
  • Editor clicks on “Finish Activity”, and this time the Approval Status being printed in logs as “Publish_Stage” (i.e. the last state of the Component).

I have put the loggers to get the Approval Status on different events like:

 EventSystem.Subscribe<Component, SaveEventArgs>(ComponentSaved, EventPhases.TransactionCommitted);
 EventSystem.Subscribe<ActivityInstance, FinishActivityEventArgs>(FinishActivityCall, EventPhases.Initiated);
 EventSystem.Subscribe<ActivityInstance, AssignActivityEventArgs>(AssignActivityCall, EventPhases.Initiated);
 EventSystem.Subscribe<ActivityInstance, ReAssignActivityEventArgs>(ReAssignActivityCall, EventPhases.Initiated);

Can someone please provide some pointers what could be the reason for such strange behavior, because the Workflow diagram is not really complex and its very straight forward.

The SDL version is 2013SP1.

Thanks in advance.

  • 1
    If the item is in Workflow and does not meet the minimum approval status, the Content Manager publishes the last checked-in version of the item (if it exists and if it does have a minimum approval status that allows it to be published) see docs, and as per your first scenario the previous version was having status as Publish_Live. – Ashutosh Aug 10 '16 at 6:29
  • Hi Ashutosh, but that is what I am asking that in Workflow diagram I have explicitly set Approval Status as "Publish_Stage" as soon as component enters Workflow cycle which is not happening and somehow the approval status is being overridden by "Publish_Live" which make the component eligible to be published. – Yash Aug 10 '16 at 7:56
  • component is still in workflow in your case , right? if yes then the current version(updated one) that is in workflow is having Publish_Staging status and not being published as you need. it's just the old/existing version that got published. --Also if you complete the workflow with final status as Publish_Staging then the item should not be published to your Live target – Ashutosh Aug 10 '16 at 8:37
  • @Yash - when you say the approval status is being overridden, what do you mean? Have you got evidence that the component now has an approval status of Publish_Live, or are you saying that it has AS of Publsh_Stage? – Dominic Cronin Aug 10 '16 at 8:53
  • Hi @DominicCronin, Yes I have the evidence, and I confirmed it by printing the debug logs at different events being triggered during the entire Workflow cycle. So after "Unapproved" state as per my Workflow diagram the status should be "Publish_Stage" but instead it is coming as "Publish_Live". – Yash Aug 10 '16 at 8:56
2

Please Check the Following:

  1. Your updated workflow process definition is updated to Tridion: To do so I'd open Visio -> Go to ADD-INs -> Click Open (second icon from left) -> Select the Process Definition. Now check carefully if the definition is updated.
  2. The order of the Approval Status List : It should be top to down as we progress in approval status values.

    enter image description here

  3. Minimum Approval Status of Publication Targets: Check if the right value is selected there. enter image description here

Also When you say :

"The problem we are facing is that the component locked by the WF can still be published to Live, though we have the Minimal Approval Approval Status set "Publish_Live" at Publication target."

Which version of component is getting published, "In Workflow Version (minor)" or "Last Major Version"? Because if you have a previous version with the minimum approval status, It will be published and it is a expected behavior.

  • Thanks @Saurabh but all these basic steps are in place. – Yash Aug 9 '16 at 16:52
  • Hi @Saurabh, last checkedin version of the component is being published and I understand it is expected but I have asked in my question that why the approval status is being overridden when I am explicitly setting "Publish_Stage" in workflow diagram which won't let component meet the the minimal approval status. Hope you got the question now. – Yash Aug 10 '16 at 8:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.