Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Notification service: Let Plugin developers easily output info, notice, warning, error messages on screen #4179

Closed
mattab opened this issue Sep 25, 2013 · 46 comments
Assignees
Labels
Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical.
Milestone

Comments

@mattab
Copy link
Member

mattab commented Sep 25, 2013

Right now our Notification mechanism is not quite consistent.

We use for example several techniques:

  • we add &updated=X to URL, which is then detected by Javascript or controller to display a particular message
  • Various messages are printed in the views using the class="ajaxSuccess" style.
  • setting ->errorMessage on the View object
  • etc.

Instead we could introduce a new Notification class or so, that would:

  • Let user easily Notify one or more messages to users
    • Choose between Info, Notice, Warning, Error
  • We would display the messages in the next page view (messages are stored in the session)
    • This way developer does not need to display its own HTML
  • If several messages are to be displayed, they are displayed on top of one another (one colored box each)
  • We'd use boostrap styles for notifications (4 colors)
  • The ajaxSuccess and ajaxError css styles should reuse the Success + Error notification CSS
    • Maybe the notification should be implemented as JS class (and have PHP helper output code to call this class in the View)

Optional:

  • make a message persistent. If set to persistent, display with a [Until user clicks X this message is displayed on all page views
  • by default messages are displayed only once
@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In 7b5943a: refs #4179 started to work on notifications

@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In 98fa154: refs #4179 set default properties

@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In 7c4d56e: refs #4179 render a list of notifications so they can be rendered by javascript

@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In c7ffd57: refs #4179 parse notifications

@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In 2220899: refs #4179 render a simple dom node for each notification

@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In a208bf4: refs #4179 added some less definitions

@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In b134848: refs #4179 fix notification is floated

@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In 93282a8: refs #4179 we do not support icons for now

@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In 1cebbce: refs #4179 handle options like title, noclear, message, ...

@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In d99772c: refs #4179 sort notifications by priority

@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In fe5cddd: refs #4179 display notifications in admin where they used to be displayed and use same font size

@tsteur
Copy link
Member

tsteur commented Oct 26, 2013

In 80bce10: refs #4179 throw errors if invalid params given, handle close event

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In 1cda21f: refs #4179 handle toast notifications

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In 3068233: refs #4179 set default type to transient

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In e793504: refs #4179 handle persistent notifications

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In 2a51eb4: refs #4179 better var naming

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In c46a68e: refs #4179 validate id

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In d4363aa: refs #4179 escape html attributes

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In 91160d9: refs #4179 added some documentation

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In eb7370f: refs #4179 coding style

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In 442185c: refs #4179 added example

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In c877300: refs #4179 save notifications until delivered

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In 38a6c59: refs #4179 fade notifications in

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In aa1ff54: refs #4179 do not expose the whole class for plugin developers, only the notify method

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In 5018227: refs #4179 fix title is hardcoded

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In be25ab0: refs #4179 extract some code into functions, added possibility to place notification in any node by specifying property placeAt

@tsteur
Copy link
Member

tsteur commented Oct 27, 2013

In a5ff495: refs #4179 added jsdoc

@tsteur
Copy link
Member

tsteur commented Oct 28, 2013

In 14b1a01: refs #4179 added possibility to disable animations and fixed animation

@tsteur
Copy link
Member

tsteur commented Oct 28, 2013

In 076c4ee: refs #4179 as we do not get the notification id in the iterator, the cancel of all notification did not work

@tsteur
Copy link
Member

tsteur commented Oct 28, 2013

In 867da50: refs #4179 code cleanup

sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
…ity to place notification in any node by specifying property placeAt
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
…ator, the cancel of all notification did not work
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
… close notification if there is one having same id
sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical.
Projects
None yet
Development

No branches or pull requests

2 participants