my question is, how can i access a node last publish date (not last update date, it's different).
In Umbraco, if I click "Save" or "Save and publish" the property "UpdateDate" is updated. What I want is to know the date when a node has been published. Is there any wat i can achieve this?
Scenario:
2016/03/29 10:00:00: User creates node A
2016/03/29 10:15:00: User "Save and publish" node A
2016/03/29 10:20:00: User changes content and "Save" node A
Both "10:15:00" and "10:20:00" actions will update "UpdateDate", but I want to get the las publish date (2016/03/29 10:15:00).
Node published date - Save vs. Save and publish
Hi everyone,
my question is, how can i access a node last publish date (not last update date, it's different).
In Umbraco, if I click "Save" or "Save and publish" the property "UpdateDate" is updated. What I want is to know the date when a node has been published. Is there any wat i can achieve this?
Scenario: 2016/03/29 10:00:00: User creates node A 2016/03/29 10:15:00: User "Save and publish" node A 2016/03/29 10:20:00: User changes content and "Save" node A
Both "10:15:00" and "10:20:00" actions will update "UpdateDate", but I want to get the las publish date (2016/03/29 10:15:00).
Thanks in advanced.
Hi,
You could create a property (label) on the document type, and hook into the SentToPublish event and update that field with the current date.
After that you'd just need to grab the date from that property whenever you need it.
You can get details on events here: https://our.umbraco.org/documentation/Reference/Events/ContentService-Events
is working on a reply...