'; echo get_module_title("Users", 'Profile Information', true); global $adb; global $theme; global $theme_path; global $image_path; $theme_path="themes/".$theme."/"; $image_path=$theme_path."images/"; require_once($theme_path.'layout_utils.php'); $profileid = $_REQUEST["profileid"]; //Retreiving the tabs permisson array $tab_perr_array = getTabsPermission($profileid); $act_perr_arry = getTabsActionPermission($profileid); $act_utility_arry = getTabsUtilityActionPermission($profileid); $xtpl=new XTemplate ('modules/Users/ProfileDetailView.html'); $standCustFld = getStdOutput($tab_perr_array, $act_perr_arry, $act_utility_arry,$profileid); //Standard PickList Fields function getStdOutput($tab_perr_array, $act_perr_arry, $act_utility_arry,$profileid) { global $adb; $standCustFld = ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; //Check for Current Profile global $current_user; $current_profile = fetchUserProfileId($current_user->id); $standCustFld .= '
  '; if($profileid != 1 && $profileid != 2 && $profileid != 3 && $profileid != 4 && $profileid != $current_profile) { $standCustFld .= ''; } $standCustFld .= '

'; $standCustFld .= '
'; $standCustFld .= get_form_header("Profile Standard Access Information", "", false ); $standCustFld .= '
'; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $i = 1; foreach($act_perr_arry as $tabid=>$action_array) { $entity_name = getTabname($tabid); //Tab Permission $tab_allow_per_id = $tab_perr_array[$tabid]; $tab_allow_per = getDisplayValue($tab_allow_per_id); //Create/Edit Permission $tab_create_per_id = $action_array['1']; $tab_create_per = getDisplayValue($tab_create_per_id); //Delete Permission $tab_delete_per_id = $action_array['2']; $tab_delete_per = getDisplayValue($tab_delete_per_id); //View Permission $tab_view_per_id = $action_array['4']; $tab_view_per = getDisplayValue($tab_view_per_id); if ($i%2==0) { $trowclass = 'evenListRow'; } else { $trowclass = 'oddListRow'; } $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $i++; } $standCustFld .='
Entity
Allow
Create/Edit
Delete
View
'.$entity_name.'
'.$tab_allow_per.'
'.$tab_create_per.'
'.$tab_delete_per.'
'.$tab_view_per.'
'; //echo $standCustFld; $standCustFld .= '
'; $standCustFld .= '
'; $standCustFld .= get_form_header("Profile Utility Access Information", "", false ); $standCustFld .= '
'; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $i = 1; foreach($act_utility_arry as $tabid=>$action_array) { $entity_name = getTabname($tabid); //Import Permission $tab_import_per_id = $action_array['5']; $tab_import_per = getDisplayValue($tab_import_per_id); //Export Permission $tab_export_per_id = $action_array['6']; $tab_export_per = getDisplayValue($tab_export_per_id); if ($i%2==0) { $trowclass = 'evenListRow'; } else { $trowclass = 'oddListRow'; } $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $standCustFld .= ''; $i++; } $standCustFld .='
Entity
Import
Export
'.$entity_name.'
'.$tab_import_per.'
'.$tab_export_per.'
'; return $standCustFld; } $xtpl->assign("MOD", $mod_strings); $xtpl->assign("STANDARDPERMISSIONS", $standCustFld); $xtpl->parse("main"); $xtpl->out("main"); function getDisplayValue($id) { global $image_path; if($id == '') { $value = ' '; } elseif($id == 0) { $value = ''; } elseif($id == 1) { $value = ''; } else { $value = ' '; } return $value; } ?>