# HG changeset patch # User Thierry Florac # Date 1528497852 -7200 # Node ID 5c16e7815b69c7cb04d3386492a52eb8934cd3a5 # Parent 33811e279b1dc1e79ac76fafbb041c70da470409 Updated workflow publication form diff -r 33811e279b1d -r 5c16e7815b69 src/pyams_content/shared/blog/zmi/manager.py --- a/src/pyams_content/shared/blog/zmi/manager.py Sat Jun 09 00:07:00 2018 +0200 +++ b/src/pyams_content/shared/blog/zmi/manager.py Sat Jun 09 00:44:12 2018 +0200 @@ -186,6 +186,6 @@ def updateWidgets(self, prefix=None): super(BlogManagerWorkflowPublicationEditForm, self).updateWidgets(prefix) if 'publication_effective_date' in self.widgets: - widget = self.widgets['publication_effective_date'] - if not widget.value: - widget.value = tztime(datetime.utcnow()).strftime('%d/%m/%y %H:%M') + pub_info = IWorkflowPublicationInfo(self.context) + if pub_info.publication_effective_date is None: + self.widgets['publication_effective_date'].value = tztime(datetime.utcnow()).strftime('%d/%m/%y %H:%M')