Improvements to notification system

Bug #1299993 reported by Nathan Lewis on 2014-03-31
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
Wishlist
Nathan Lewis
1.10
Low
Unassigned
15.04
Wishlist
Nathan Lewis

Bug Description

This patch implements some improvements to notification settings which will also allow us to more easily implement further features. Included in this patch:

- Each activity type can specify a default notification method. They default to 'email' to remain backwards compatible.
- Each activity type can specify if it is allowed to be set to 'none'. Defaults to 'allowed' for backwards compatibility.
- Removed 'required' from notification settings - it didn't make sense, and the change above deals with this in a better way.
- The site wide defaults for each activity type can be edited in Site options -> Notification settings. These are applied to new users or whenever a user does not have the appropriate usr_activity_preference records.
- There is a separate help next to each activity type to explain what messages will be affected by the setting.

The following additional changes were made internally to allow the above:

- Most activity types can now be set to 'none'. We feel that only user to user and system messages should be enforeced and everything else should be optional.
- The way 'none' is handled was changed. A missing usr_activity_preference record indicates that the settings has not yet been set, so the default should be user. Null method indicates 'none' was selected.
- The function pieform_get_help was modified to check for element fields 'helpplugintype', 'helppluginname' and 'helpformname' so that the notification settings form elements could be reused in the site options. (We want to use the same help files on more than one form, but the help files are saved with the form name, so we had to allow the form name to be specified for the help).

Activity type plugin authors should be aware of the following changes:

- 'enablenonemethod' and 'defaultmethod' are values that can be specified when specifying an activity type. Both are optional.
- Help files can be specified for each activity type. The help files can be placed in the plugin's subfolder (e.g. artefact/myplugin/lang/...). Help files are optional, but should be provided, otherwise "There was no help found for this item." will be displayed.

Version: master

Changed in mahara:
status: New → In Progress
Changed in mahara:
assignee: nobody → Nathan Lewis (nathan-lewis)
importance: Undecided → Wishlist

Reviewed: https://reviews.mahara.org/3148
Committed: http://gitorious.org/mahara/mahara/commit/63e0484d13398819a06ecf2223f6ff2141236207
Submitter: Robert Lyon (<email address hidden>)
Branch: master

commit 63e0484d13398819a06ecf2223f6ff2141236207
Author: Nathan Lewis <email address hidden>
Date: Tue Apr 1 09:59:21 2014 +1300

Improvements to notification system (Bug #1299993)

- Each activity type can specify a default notification method. They default
to 'email' to remain backwards compatible.
- Each activity type can specify if it is allowed to be set to 'none'. Defaults
to 'allowed' for backwards compatibility.
- Removed 'required' from notification settings - it didn't make sense, and the
change above deals with this in a better way.
- The site wide defaults for each activity type can be edited in
Site options -> Notification settings. These are applied to new users or
whenever a user does not have the appropriate usr_activity_preference records.
- Removed 'Default notification method' as it's functionality is now covered by
the change above.
- There is a separate help next to each activity type to explain what messages
will be affected by the setting.

Change-Id: I131cdeefbeaa8e43688aefd9d770fc8cb9bceea8
Signed-off-by: Nathan Lewis <email address hidden>

A summary of what this patch adds:

1. Help messages next to activity types

2. A "Notification settings" section under Administration -> Site Options, which lets the site admin set the default notification method for each activity type.

Leaving this bug open for now, because the "Notification settings" section needs some additional help text to explain that it's only setting *default* notification types for new users.

Changed in mahara:
milestone: none → 1.10.0
tags: added: nominatedfeature
Steven (stevens-q) wrote :

=== How to test ===
[✔] 1. log in as admin
[✔] 2. browse to the Administration section -> configure site -> Notification settings
[✔] 3. Confirm that all of the settings for this section are set to "Email" as default
[✔] 4. Confirm that each selection in this section has an Info icon that displays help text on mouse click
[✔] 5. confirm that a user can set all but System message & Message from other users to None
[✔] 6. confirm that a User can select the following options
[✔] --- a) email (default)
[✔] --- b) email digest
[✔] --- c) Inbox
[✔] --- d) None (except for "System message" & "Message from other users")
[✔] 7. confirm that none of the fields are marked as required

BUGS

1. Objectionable content in forum info modal is missing a title before the help text
2. Objectionable content info modal has 1.5 line spacing - should be 1

Steven (stevens-q) wrote :

8. confirm there is help text at the top of the section as follows :

"Here you can set the default options for new users to get notifications. Users can override these settings on their own "Settings -> Notifications" page. If you select either of the email options, notifications will still arrive in the user's inbox, but they will be automatically marked as read."

Catalyst QA Approved ✔

Reviewed: https://reviews.mahara.org/3663
Committed: http://gitorious.org/mahara/mahara/commit/9b3f4b56d8f81bfb86a017875f27e30e84812166
Submitter: Son Nguyen (<email address hidden>)
Branch: master

commit 9b3f4b56d8f81bfb86a017875f27e30e84812166
Author: Robert Lyon <email address hidden>
Date: Mon Aug 25 16:22:42 2014 +1200

Adding additional description text to explain the settings (Bug #1299993)

Change-Id: I9b87550d4b542b5e46df9a055968fdd48cb6867f
Signed-off-by: Robert Lyon <email address hidden>

Robert Lyon (robertl-9) on 2014-09-18
Changed in mahara:
status: In Progress → Fix Committed
Aaron Wells (u-aaronw) on 2014-10-21
Changed in mahara:
status: Fix Committed → Fix Released

Reviewed: https://reviews.mahara.org/4241
Committed: http://gitorious.org/mahara/mahara/commit/bf18281f37420a6614af6131459a241eab657d3d
Submitter: Robert Lyon (<email address hidden>)
Branch: master

commit bf18281f37420a6614af6131459a241eab657d3d
Author: Eduardo Schicker <email address hidden>
Date: Mon Feb 2 14:54:08 2015 +1300

Behat test: Multiple notification choices (Bug 1299993)

Change-Id: I17658b720a8ad1fce22a77afd18408f1f2e24d2f
Signed-off-by: Jinelle Foley-Barnes <email address hidden>

tags: added: behat has-behat
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers