Results 1 to 6 of 6

Thread: Mass update needs to be disabled or made 'invincible'

  1. #1
    rehlers is offline Member
    Join Date
    Nov 2008
    Posts
    9

    Default Mass update needs to be disabled or made 'invincible'

    Issue:
    Mass update needs to be disabled or made 'invincible'
    Reason: obvious, various sales and marketing personell can 'update at random and create havock.

    I understand there different ways of doing so, theroratically we don't need that module at all. So the simplest way is probably the best.

    Version 5.0.0a (Build 3120)

    Thank you.

    R.


  2. #2
    eggsurplus's Avatar
    eggsurplus is offline Sugar Community Member
    Join Date
    Dec 2005
    Location
    Minnesota
    Posts
    2,343

    Default Re: Mass update needs to be disabled or made 'invincible'

    This not upgrade safe but:
    include/MVC/View/views/view.list.php:

    Find $params = array('massupdate' => true); around line 122. Change to:
    PHP Code:

            
    global $current_user;
            
    $params = array('massupdate' => (is_admin($current_user)?true:false)); 
    This will make it so that the MassUpdate area only shows for admin users.

  3. #3
    rehlers is offline Member
    Join Date
    Nov 2008
    Posts
    9

    Default Re: Mass update needs to be disabled or made 'invincible'

    Hmmm.

    Actually - it didn't do anything different. Not even an error message. Mass update is still available to every user.

    I haven't changed code back yet as I am thinking about it. If you have any other ideas, please let me know.

    I believe this is a very common request, we really want to upgrade and use Sugar, I start loving it. I have 2 more issues to sort - nothing big, ha, ha. Like module doesn't work

    This first, IF anybody could help - would be great.

    Thanks,

    R.

  4. #4
    URtech is offline Sugar Community Member
    Join Date
    Oct 2006
    Posts
    34

    Default Re: Mass update needs to be disabled or made 'invincible'

    Hi eggsurplus,

    Your recommendation worked for me; however, it looks like it also restricts selecting records and using export or merge duplicates features if you're not an admin which is an undesired side effect. Therefore, it's not exactly as granular a control over locking down the mass update than I'm looking for.

    I've got to believe Sugar will be adding this kind of control to the Roles functionality. Anyone from Sugar care to chime in?

    In the meantime, I found a helpful approach to hide mass update here: http://www.sugarcrm.com/forums/showt...t=33384&page=2

    Cheers, Sean
    Last edited by URtech; 2008-12-16 at 08:46 PM.

  5. #5
    wynn is offline Sugar Team Member
    Join Date
    Aug 2008
    Posts
    372

    Default Re: Mass update needs to be disabled or made 'invincible'

    This is really a problem, you can only make it display:none.

    now, your checked value all stores in the Massupdate form. and Delete, export all make use of this form. And in future release, the pagination will use this form to aviod a pagination bug.


    So I think you'd better make it to be in a <div style="display:none;">

  6. #6
    kuske's Avatar
    kuske is offline Sugar Community Member
    Join Date
    Oct 2007
    Location
    Germany
    Posts
    2,597

    Default Re: Mass update needs to be disabled or made 'invincible'

    In module \include\Massupdate.php you can change the Definition of the div

    $html = "<div id='massupdate_form'>" . get_form_header($app_strings['LBL_MASS_UPDATE'], '', false);

    to

    $html = "<div id='massupdate_form' style='display:none;'>" . get_form_header($app_strings['LBL_MASS_UPDATE'], '', false);

    as wynn described it.

    You can define dependencies like which module was called
    if ($_REQUEST['module'] == 'Accounts') ...

    or who is the caller
    if ($current_user->user_name == 'admin') ...

    or whether the caller is admin
    if ($current_user->is_admin == 1) ...
    etc. pp.

    Example:
    $hyde = "";
    if ($current_user->is_admin != 1)
    $hyde=" style='display:none;' ";
    $html = "<div id='massupdate_form' ".$hyde.">" . get_form_header($app_strings['LBL_MASS_UPDATE'], '', false);
    Harald Kuske
    Pre-Sales Engineer Central Europe

    SUGARCRM Deutschland GmbH
    Erika-Mann-Str. 53, 80636 Munich, Germany
    Email: hkuske@sugarcrm.com
    Home: http://www.sugarcrm.com


Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Mass Update
    By jmcalderond in forum General Discussion
    Replies: 12
    Last Post: 2008-08-05, 09:39 PM
  2. Replies: 0
    Last Post: 2007-06-16, 02:20 PM
  3. Mass Update Customisation
    By duncanb in forum Developer Help
    Replies: 4
    Last Post: 2007-05-16, 06:17 AM
  4. Mass Update won't work!
    By rsantiago in forum Help
    Replies: 6
    Last Post: 2006-08-18, 02:54 AM

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
  •