Comala Worflows variables in tempate
Asked by Luk?? Krti?ka:

Hello everyone,

I am looking for an easy way, to display an actor (reviewer), who changed the workflow state of an article and the date when a certain state was reached (published date).

<br />

Thank you for your advice.

Best regards,   

Lukas


Answers:
author: James Conway
body: Hi [@Luk?? Krti?ka](/t5/user/viewprofilepage/user-id/2610447)

Thanks for your question, could you confirm:

1. if you are using Confluence Server or Confluence Cloud,
2. if you are using Comala Document Approval, Comala Document Control or Comala Document Management

Thanks in advance

James  
Senior Product Manager

comments: author: Luk?? Krti?ka
body: Hi James,

Thanks for reaching out.   

1. Server 6.15.2  
2. We are using only Comala Document Management  

Thank you


author: James Conway
body: Hi [@Luk?? Krti?ka](/t5/user/viewprofilepage/user-id/2610447) ,

Thank you for your confirming. It is possible to show this information on your page, using a workflow trigger to set metadata values, and displaying these values in the page header. To get started, I recommend that you use the workflow builder markup editor (<https://wiki.comalatech.com/display/CDML/Markup+Editor+in+workflow+builder>) to add the following markup.

Note that you should change approval=Review and @Review\> to the name of the approval you want to display.

    {pageheader:visibility=all}
        ||Document Status|{pagestatus}|
        ||Approved By|{get-metadata:approvedby}|
        ||Approval Date/Time|{get-metadata:approveddate}|
    {pageheader}
    {trigger:pageapproved|approval=Review}
        {set-metadata:approvedby}@Review>approvers>wiki-link@{set-metadata}
        {set-metadata:approveddate}@datetime@{set-metadata}
    {trigger}

You can find more details on each macro here: <https://wiki.comalatech.com/display/CDML/Macros>.

I hope that helps, let me know if you have any further questions.

Kind regards

James


author: Ilona Knapp-Krubally
body: Hi [@James Conway](/t5/user/viewprofilepage/user-id/3320578) ,

thank you for explaining.

We have the same problem and I test your solution for our requirements to display the approval date in the page properties table.

```
{trigger:pageapproved|approval=Publish}
 {set-metadata:approveddate}@datetime@{set-metadata}
{trigger}
```

In page properties table I use get metadata macro to receive the date and time. It works perfect. But next time the page will be approved, this date is changed to new approval date even in the older version of the page.

This is not what we need. For Version 2 of the page we need the approvaldate for this version and in Version 7 the approval of this version....

In Activity Report there is always the date and time of respectiv approval and it does not change to new the next time the approval is executed aigain.

Is it possible to diplay this dates in Page Property Table?

Kind regards and thank you in advance

Ilona


author: Luk?? Krti?ka
body: Hello [@James Conway](/t5/user/viewprofilepage/user-id/3320578) ,

Thank you for the information.  
This is exactly what I need.   

Thanks again Lukas


author: Simon
body: [@Ilona Knapp-Krubally](/t5/user/viewprofilepage/user-id/3865671) , I'm facing the same issue with the approveddate. It shows the date of the most recent approval even if I'm looking at previously approved versions. Have you found a solution?


author: James Conway
body: Hi [@Simon](/t5/user/viewprofilepage/user-id/73143)

Comala Document Management only stores the current value of metadata. This is why you will see the most recent metadata value when you access previous versions via the page history.

We recommend that you take look at our new integration with K15t PDF Exporter that allows you to export and attach a PDF of your page at the moment of approval. For more information see the documentation:

<https://wiki.comalatech.com/display/CDML/pdf-export+macro>

Kind regards

James  
Senior Product Manager


author: Ilona Knapp-Krubally
body: Hi [@Simon](/t5/user/viewprofilepage/user-id/73143)

sorry for the late answer... we have a workaround which fits for us, but hopefully it is a temporary solution.   

{trigger:pageapproved\|approval=Publish}  
{include-segment} Approval date: @date@ {include-segment}  
{trigger}  

This leads to an corresponding entry above the page content.


author: James Conway
body: Hi [@Ilona Knapp-Krubally](/t5/user/viewprofilepage/user-id/3865671)

Thank you for your contribution - apologies for missing your post in April 2020. I just wanted to let you and [@Simon](/t5/user/viewprofilepage/user-id/73143) know that we had to deprecate the {include-segment} macro as of Comala Document Management 6.13.

If you need to capture a fixed view of a page at the moment of approval we recommend that you use the [PDF Export macro](https://wiki.comalatech.com/display/AWPD/Exporting+to+PDF+with+K15t+PDF+Exporter) that integrates with K15t Scroll PDF Exporter.

Kind regards

James  
Senior Product Manager


author: Ilona Knapp-Krubally
body: [@James Conway](/t5/user/viewprofilepage/user-id/3320578)

thank you for remember me about the include-segment.  
But with the introduction of Confluence and Comala Document management we try to get rid of the annoying Words and PDFs. Therefore it is not a suitable way for us to generate PDFs again.  
Since the date is correctly assigned in the activity report, it is difficult for me to understand why there is no way to fix this on the previously approved version. I hope you can find a better solution than generating PDF again in future.

Kind regards  
Ilona  


author: Simon Wolf
body: Hi [@Ilona Knapp-Krubally](/t5/user/viewprofilepage/user-id/3865671) ,

have you ever found a solutions?

We are facing the same problem....

Thanks!

Kind Regards,

Simon


Tags: cloud