Hi all,
the last few days I thought about the need to enable/disable various notification backends. This is especially useful for backends which produce costs (SMS) or backends that do not fit into the environment (winpopup).
So, here’s the way I coded it into my local copy. If you have any suggestions and whishes to that, please let me know.
First of all, the admin can enable/disable the backends via admin->notifications:
In this example, all backends are enabled. I would prefer to have egwpopup enabled and any other one disabled for fresh installations.
Now, the user decides to be always notified via winpopup.
One day, the admin decides to disable winpopup in general, cause he cannot live further with the microsoft*-ish way of life … :-). So, he does this again in admin->notifications:
Now, how does notifications cope with that? Two things:
- The next time, the user gets notified, he doesn’t get the notification via winpopup (it’s disabled). Notifications instead switches to the fallback backend, so the user get’s it’s notification by email.
- If the user again visits his notifications pref, he will see the following:
So, the user recognizes that his notificaton-chain has been disabled by the administrator and he can choose another (enabled) chain:
My only concern about that is, that the list gets a bit too long if we have many backends in the future. On the other hand, if I don’t display the disabled chains in the user-prefs, the selectbox falls back to “Use default” and that’s not right.
Another thing will be to prepend a message like “You get this notification by mail cause …” if mail is the fallback for a disabled chain.
So, what do you think?
Bye
Christian