getModuleName();
if ($moduleName == 'Activity') {
$arr = array('Task' => 'Calendar', 'Emails' => 'Emails');
$moduleName = $arr[getActivityType($entityData->getId())];
if ($moduleName == null) {
$moduleName = 'Events';
}
}
return $moduleName;
}
/**
* Insert redirection script
*/
function redirectTo($to, $message) {
?>
is_admin) === 'on';
}
/* function to check if the module has workflow
* @params :: $modulename - name of the module
*/
function checkModuleWorkflow($modulename) {
$result = true;
//SalesPlatform.ru start workflow for PBXManager
//if (in_array($modulename, array('Emails', 'PBXManager', 'Faq', 'Users')) || !getTabid($modulename)) {
if (in_array($modulename, array('Emails', 'Faq', 'Users')) || !getTabid($modulename)) {
//SalesPlatform.ru end
$result = false;
}
return $result;
}
function vtGetModules($adb) {
$modules_not_supported = array('Emails', 'PBXManager');
$sql = "select distinct vtiger_field.tabid, name
from vtiger_field
inner join vtiger_tab
on vtiger_field.tabid=vtiger_tab.tabid
where vtiger_tab.name not in(" . generateQuestionMarks($modules_not_supported) . ") and vtiger_tab.isentitytype=1 and vtiger_tab.presence in (0,2) ";
$it = new SqlResultIterator($adb, $adb->pquery($sql, array($modules_not_supported)));
$modules = array();
foreach ($it as $row) {
$modules[] = $row->name;
}
return $modules;
}
}