Results 1 to 4 of 4

Thread: User Roles not in the roles table?

  1. #1
    doctorlard is offline Sugar Community Member
    Join Date
    Mar 2006
    Posts
    26

    Default User Roles not in the roles table?

    Okay I give up - where on earth are the roles stored? The most logical place I would have thought would have been, gee I don't know, maybe the roles and roles_users database tables.

    Imagine my surprise when I found them to be empty! I hope this isn't another one of those really crap solutions like dropdowns - "Oh I know let's hide them in the app_list_strings array in a language include .php file!" Speaking of which, is there any sane reason why there isn't dropdowns and dropdown_items database tables? If anyone says "database performance" I will find out where you live and mail you a fake plastic poo. Failing that, I have a very simple piece of code to contribute :-)

    Stressed (and only kidding about the fake plastic poo),
    Luv Jonathan.

  2. #2
    frb
    frb is offline Sugar Community Member
    Join Date
    Feb 2006
    Posts
    79

    Default Re: User Roles not in the roles table?

    Found them under acl_roles... still trying to figure out why there are 2 modules, one called ACLRoles and another Roles... only the ACLRoles one is visible via the Admin screen.

    Replace by ACLRoles by Roles in the url.. and you magically get access to the empty roles ,roles_users tables.

    I discovered that one, while wondering why tabs I disallowed in ACLRoles to some users were still visible... and the other hand access to the given module (like read) was disallowed.

    Mhhhh... half of the code relies on ACLRoles, some other part on Roles. That's not nice!

    Franck

  3. #3
    julian's Avatar
    julian is offline Sugar Team Member
    Join Date
    Sep 2004
    Posts
    1,639

    Default Re: User Roles not in the roles table?

    Hello doctorlard,

    I hate to say it, but there are "database performance" considerations to think about. It's also much easier for translators to modify files than a database dump, plus the language strings are conveniently available in a native array without any extra work required.
    Julian Ostrow
    Systems and Applications Engineer
    SugarCRM Inc.

  4. #4
    doctorlard is offline Sugar Community Member
    Join Date
    Mar 2006
    Posts
    26

    Default Re: User Roles not in the roles table?

    Rubbish.

    Let's pretend I have a custom field for accounts called "assigned engineer" which I want to only contain users from the "Customer Engineer" role. So, why not dynamically generate dropdowns that contain id => user_name values for each role? This would be a handy feature, surely.

    Dropdowns should be in the database. There is no reason for it to be otherwise. Putting them in language files is just lazy.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •