Jump to:
| Project: | Mailout |
| Version: | 6.x-1.x-dev |
| Component: | Miscellaneous |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Issue Summary
I'm using Drupal as CRM and our agents (users) manage their own content, which in our case are prospect lists. So, this module is being used to send emails not to drupal users, but rather contacts that we manage withing the drupal. I would like this module to have an ability to restrict user access to the mailing lists that users create and manage. Right now, if I allows agents to use mailout - they all will see each other mailing lists.
Any idea if this kind of functionality can be implemented in the future? If not, would you have any suggestions on how this kind of functionality could be implemented the best. It would nice to have a sub-module that plugs into the main module (like CCK has) and adds additional options - this way the main mailout module could be still easily updated without hacking into it.
Comments
#1
I think that would be a good feature. I'm going to line it up for Drupal 6 version
#2
If anyone interested, this is what I did for now:
1. I added UID column to the mailout_list table - for the mailing list author's user id.
2. Then added a hidden field to the mailout_list_edit_form to hold current user's UID.
3. Updated all other functions that validate form and insert/update values into the table.
4. Added a condition to mailout_get_lists that checks current user's role, and it's not Admin, it adds "AND uid = $user->uid" criteria to the WHERE clause on SELECT from mailout_list table.
It's a quick and dirty hack, but it works for now to allow users to create and manage their own mailing lists without exposing them to each other.
#3
Thanks gemini, appreciated
#4
Actually, there are more places that need hacking. I though I could avoid making too many adjustments, but ended up editing too many functions.