Sugar 7 : how to disable "create lead" button in Main Menu?

Hello everyone,
Here i come again with a new problem/question !

Sugar 7.2.0, Pro edition :
My Leads are automatically created (by .csv imports or by another way), and I would like to disable the standard creation for all users.

My question could be cut in two parts :
 - How do I disable the "Create a Lead" button in the module tab's dropdown on the Main Menu?
( tried to disable it via custom/modules/Leads/clients/base/views/headerpane/headerpane.php, ran QRR, but did nothing)
 - How do I disable the "Create" button in the Leads' ListView?
(i checked out custom/modules/Leads/clients/base/views/list/list.php and there is nothing about buttons)
 - How do i disable every create leads button, in all the application, in fact?

Thanks a lot for giving me clues on where i should search :)
Parents
  • I disabled the list view create by removing the button from list-headerpain.php
  • Sorry I was unclear as usual

    In my case it was for a custom module and I created modules/zz_expenses_detail/clients/base/views/list-headerpane/list-headerpane.php

    I havent tested it but I'm pretty certain for leads you could create it in custom/modules/leads/....

    my code is

    $viewdefs['zz_expenses_detail']['base']['view']['list-headerpane'] = array(
        'template' => 'headerpane',
        'title' => 'LBL_MODULE_NAME',
        'buttons' => array(
            array(
                'name' => 'sidebar_toggle',
                'type' => 'sidebartoggle',
            ),
        ),
    );


  • thanks Mike, i made a mistake on my $viewdefs array and did not specify the leads module, that is why it removed every module's name. :)
    But, by doing this, strangely i erase the module-title 'Leads', on top of the page, exactly in the list-headerpane.. Does it displays right to you?
     i have to search on that...

    Thanks a lot
Reply
  • thanks Mike, i made a mistake on my $viewdefs array and did not specify the leads module, that is why it removed every module's name. :)
    But, by doing this, strangely i erase the module-title 'Leads', on top of the page, exactly in the list-headerpane.. Does it displays right to you?
     i have to search on that...

    Thanks a lot
Children
No Data