assign('APP', $appStrings); $mod = array_merge( return_module_language($current_language,'FieldFormulas'), return_module_language($current_language,'Settings')); $jsStrings = array( 'NEED_TO_ADD_A'=>$mod['NEED_TO_ADD_A'], 'CUSTOM_FIELD' =>$mod['LBL_CUSTOM_FIELD'], 'LBL_USE_FUNCTION_DASHDASH'=>$mod['LBL_USE_FUNCTION_DASHDASH'], 'LBL_USE_FIELD_VALUE_DASHDASH'=>$mod['LBL_USE_FIELD_VALUE_DASHDASH'], 'LBL_DELETE_EXPRESSION_CONFIRM'=>$mod['LBL_DELETE_EXPRESSION_CONFIRM'] ); $smarty->assign("JS_STRINGS", Zend_Json::encode($jsStrings)); $smarty->assign("MOD", $mod); $smarty->assign("THEME",$theme); $smarty->assign("IMAGE_PATH",$image_path); $smarty->assign("MODULE_NAME", 'FieldFormulas'); $smarty->assign("PAGE_NAME", 'LBL_FIELDFORMULAS'); $smarty->assign("PAGE_TITLE", 'LBL_FIELDFORMULAS'); $smarty->assign("PAGE_DESC", 'LBL_FIELDFORMULAS_DESCRIPTION'); $smarty->assign("FORMODULE", $formodule); if(file_exists("modules/$formodule/$formodule.php")) { $focus = CRMEntity::getInstance($formodule); $validationArray = split_validationdataArray(getDBValidationData($focus->tab_name, getTabid($formodule))); $smarty->assign('VALIDATION_DATA_FIELDNAME',$validationArray['fieldname']); $smarty->assign('VALIDATION_DATA_FIELDDATATYPE',$validationArray['datatype']); $smarty->assign('VALIDATION_DATA_FIELDLABEL',$validationArray['fieldlabel']); } $smarty->display(vtlib_getModuleTemplate('FieldFormulas', 'EditExpressions.tpl')); } $modules = vtGetModules($adb); if(vtlib_isModuleActive('FieldFormulas') && in_array(getTranslatedString($_REQUEST['formodule']),$modules)) { vtEditExpressions($adb, $app_strings, $current_language, $theme, $_REQUEST['formodule']); } else { echo "
"; echo "
".$app_strings['LBL_PERMISSION']."
$app_strings[LBL_BACK]
"; echo "
";die; } ?>