diff --git a/CHANGES.rst b/CHANGES.rst index 2b36490..6439c89 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -2,7 +2,7 @@ Changelog ========= -0.13 (unreleased) +0.15 (unreleased) ----------------- - Call JS on portal_url so it can be cached by the browser. @@ -12,6 +12,19 @@ Changelog - Manage profiles differently [sgeulette] + +0.14 (2018-07-23) +----------------- + +- Generate new uid when message is activated or re-activated. + [sgeulette] + +0.13 (2018-06-13) +----------------- + +- Add around cross to ease override. + [mgennart] + 0.12 (2017-05-30) ----------------- diff --git a/README.rst b/README.rst index ebfa208..d282f49 100644 --- a/README.rst +++ b/README.rst @@ -14,7 +14,7 @@ collective.messagesviewlet Add-on displaying manager defined messages in a viewlet -.. image:: https://raw.githubusercontent.com/collective/collective.messagesviewlet/master/docs/messageviewletinaction.png +.. image:: https://raw.githubusercontent.com/collective/collective.messagesviewlet/master/docs/messageviewletinaction.png :alt: The three message types. :width: 1300 :height: 495 @@ -25,12 +25,12 @@ Features Messages are defined in control panel. -Multiple messages can be displayed together in the viewlet. +Multiple messages can be displayed together in the viewlet. A message contains the following configuration attributes: * text : displayed text in the viewlet -* message type : info, warning, important (different layout in the viewlet) +* message type : info, significant, warning (different layout in the viewlet) * can hide : if checked, the user can hide the message (mark as read) * start date : displaying start date (optional) * end date : displaying end date (optional) @@ -38,12 +38,12 @@ A message contains the following configuration attributes: * use local roles : message displayed for users having Reader local role on message (optional) * location : full site or homepage only -The collective.behavior.talcondition is enabled, providing 2 attributes. +The collective.behavior.talcondition is enabled, providing 2 attributes. * tal condition : optional tal expression evaluated on viewlet context * bypassing roles : optional roles bypassing the tal condition -.. image:: https://raw.githubusercontent.com/collective/collective.messagesviewlet/master/docs/messageviewletinconfiguration.png +.. image:: https://raw.githubusercontent.com/collective/collective.messagesviewlet/master/docs/messageviewletinconfiguration.png :alt: The management interface. :width: 1252 :height: 1362 @@ -55,8 +55,8 @@ A workflow is provided with the following states: * inactive : not displayed * activated : displayed -The hiding functionality uses a cookie. It is necessary to deactivate a message to "reset" the cookie. -When activating again, the message will be displayed again even for users that hide it. +The hiding functionality uses a cookie. It is necessary to (re-)activate a message to "reset" the cookie. +After new activation, the message will be displayed again even for users that hide it. The optional 'messages' profile adds some usefull examples that can be activated when needed: diff --git a/setup.py b/setup.py index b591c08..a05e273 100644 --- a/setup.py +++ b/setup.py @@ -19,7 +19,7 @@ setup( name='collective.messagesviewlet', - version='0.13.dev0', + version='0.15.dev0', description="Add-on displaying manager defined messages in a viewlet", long_description=long_description, # Get more from http://pypi.python.org/pypi?%3Aaction=list_classifiers diff --git a/src/collective/messagesviewlet/browser/messagesviewlet.pt b/src/collective/messagesviewlet/browser/messagesviewlet.pt index 85cc0d7..939ff49 100644 --- a/src/collective/messagesviewlet/browser/messagesviewlet.pt +++ b/src/collective/messagesviewlet/browser/messagesviewlet.pt @@ -12,12 +12,13 @@
- + + + diff --git a/src/collective/messagesviewlet/subscribers.py b/src/collective/messagesviewlet/subscribers.py index 3ac428e..45bf1e2 100644 --- a/src/collective/messagesviewlet/subscribers.py +++ b/src/collective/messagesviewlet/subscribers.py @@ -4,7 +4,7 @@ def change_hidden_uid(message, event): """ - Generate a new uid if the message is deactivated + Generate a new uid if the message is activated """ - if event.action == 'deactivate': + if event.action == 'activate': message.hidden_uid = generate_uid() diff --git a/versions.cfg b/versions.cfg index c184653..197aa9a 100644 --- a/versions.cfg +++ b/versions.cfg @@ -1,6 +1,6 @@ [versions] ipdb = 0.8 -ipython = 2.1.0 +ipython = 5.7.0 zc.buildout = 2.10.0 setuptools = zc.recipe.egg = 2.0.1