Hello Everyone
I am trying to figure out how I can lock adding notes to converted leads for all users. The reason for this is we want to force all notes to be added in the contact page once it has been converted.
Any ideas?
Thanks
Hello Everyone
I am trying to figure out how I can lock adding notes to converted leads for all users. The reason for this is we want to force all notes to be added in the contact page once it has been converted.
Any ideas?
Thanks
You need to create a view.detail.php for Leads and implement the methods
Perhaps you have to modify something, but that is the idea.PHP Code:function displaySubPanels() {
if (isset($this->bean) && !empty($this->bean->id) && (file_exists('modules/' . $this->module . '/metadata/subpaneldefs.php') || file_exists('custom/modules/' . $this->module . '/metadata/subpaneldefs.php') || file_exists('custom/modules/' . $this->module . '/Ext/Layoutdefs/layoutdefs.ext.php'))) {
$layout_def_override = $this->open_layout_defs($this->module);
if($this->bean->converted == 1) {
foreach($layout_def_override['subpanel_setup'] as $sub_name => $sub_defs){
if($sub_defs['module'] == 'History') {
foreach($layout_def_override['subpanel_setup'][$sub_name]['top_buttons'] as $button_id => $button_defs) {
if($button_defs['widget_class'] == 'SubPanelTopCreateNoteButton') {
unset($layout_def_override['subpanel_setup'][$sub_name]['top_buttons'][$button_id]);
}
}
}
}
}
$GLOBALS['focus'] = $this->bean;
require_once ('include/SubPanel/SubPanelTiles.php');
$subpanel = new SubPanelTiles($this->bean, $this->module, $layout_def_override);
echo $subpanel->display();
}
}
function open_layout_defs ( $layout_def_key = '' , $original_only = false ) {
$layout_defs [ $this->bean->module_dir ] = array ( ) ;
$layout_defs [ $layout_def_key ] = array ( ) ;
if (file_exists ( 'modules/' . $this->bean->module_dir . '/metadata/subpaneldefs.php' )) {
require ('modules/' . $this->bean->module_dir . '/metadata/subpaneldefs.php') ;
}
if (! $original_only && file_exists ( 'custom/modules/' . $this->bean->module_dir . '/Ext/Layoutdefs/layoutdefs.ext.php' )) {
require ('custom/modules/' . $this->bean->module_dir . '/Ext/Layoutdefs/layoutdefs.ext.php') ;
}
if (! empty ( $layout_def_key )) {
$layout_defs = $layout_defs [ $layout_def_key ] ;
} else {
$layout_defs = $layout_defs [ $this->bean->module_dir ] ;
}
return $layout_defs;
}
Regards
André Lopes
DevToolKit / Project of the Month - June 2009
Lampada Global Services- Open Source Solutions
Avenida Ipiranga, 318
Bloco B - CJ 1602
São Paulo, SP 01046-010
Brazil
Office: +55 11 3237-3110
Mobile: +55 11 7636-5859
e-mail: andre@lampadaglobal.com
Lampada Global delivers offshore software development and support services to customers around the world.
Lampada is proud to be a SugarCRM Gold Partner, revolutionizing Customer Relationship Management.
I DO NOT answer questions through PM and Email. If you need some help post your question into SugarForum.
Thanks a bunch!
What directory should I put this file in?
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks