- Timestamp:
- 09/27/11 15:50:14 (13 years ago)
- Location:
- branches/2.2/contactcenter
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.2/contactcenter/inc/class.ui_preferences.inc.php
r3707 r5104 20 20 'set_preferences' => true, 21 21 ); 22 23 function index()24 {25 $GLOBALS['phpgw_info']['flags']['app_header'] = lang('ContactCenter').' - '.lang('Preferences');26 $GLOBALS['phpgw']->common->phpgw_header();27 echo parse_navbar();28 22 29 $GLOBALS['phpgw']->template->set_file(array('pref' => 'preferences.tpl'));30 31 /* Get Saved Preferences */32 $actual = $this->get_preferences();33 34 /* Get the catalog options */35 $pCatalog = CreateObject('contactcenter.bo_people_catalog');36 $types = $pCatalog->get_all_connections_types();37 38 if (is_array($types))39 {40 $options_email = '';41 foreach($types as $id => $name)42 {43 $options_email .= '<option value="'.$id.'"';44 45 if ($actual['personCardEmail'] == $id)46 {47 $options_email .= ' selected ';48 }49 50 $options_email .= '>'.$name."</option>\n";51 }52 53 $options_phone = '';54 foreach($types as $id => $name)55 {56 $options_phone .= '<option value="'.$id.'"';57 58 if ($actual['personCardPhone'] == $id)59 {60 $options_phone .= ' selected ';61 }62 63 $options_phone .= '>'.$name."</option>\n";64 }65 }66 else67 {68 $options_email = '';69 $options_phone = '';70 }71 72 if ($actual['displayConnector'] or !$actual['displayConnectorDefault'])73 {74 $GLOBALS['phpgw']->template->set_var('displayConnector', 'checked');75 }76 else77 {78 $GLOBALS['phpgw']->template->set_var('displayConnector', '');79 }80 81 if ($actual['empNum'])82 {83 $GLOBALS['phpgw']->template->set_var('empNum', 'checked');84 }85 else86 {87 $GLOBALS['phpgw']->template->set_var('empNum', '');88 }89 90 if ($actual['cell'])91 {92 $GLOBALS['phpgw']->template->set_var('cell', 'checked');93 }94 else95 {96 $GLOBALS['phpgw']->template->set_var('cell', '');97 }98 99 if ($actual['department'])100 {101 $GLOBALS['phpgw']->template->set_var('department', 'checked');102 }103 else104 {105 $GLOBALS['phpgw']->template->set_var('department', '');106 }107 108 $GLOBALS['phpgw']->template->set_var('personCardEmail', $options_email);109 $GLOBALS['phpgw']->template->set_var('personCardPhone', $options_phone);110 111 /* Translate the fields */112 $this->translate('pref');113 114 $GLOBALS['phpgw']->template->set_var('form_action', $GLOBALS['phpgw']->link('/index.php', 'menuaction=contactcenter.ui_preferences.set_preferences'));115 116 $GLOBALS['phpgw']->template->pparse('out', 'pref');117 }118 119 23 function translate($handle) 120 24 { -
branches/2.2/contactcenter/inc/hook_preferences.inc.php
r1409 r5104 17 17 $title = $appname; 18 18 $file = Array( 19 'Preferences' => $GLOBALS['phpgw']->link('/index.php','menuaction=contactcenter.ui_preferences.index'),20 'Grant Access' 19 'Preferences' => $GLOBALS['phpgw']->link('/preferences/preferences.php','appname='.$appname), 20 'Grant Access' => $GLOBALS['phpgw']->link('/index.php','menuaction=preferences.uiaclprefs.index&acl_app='.$appname), 21 21 //'Edit Categories' => $GLOBALS['phpgw']->link('/index.php','menuaction=preferences.uicategories.index&cats_app='.$appname . '&cats_level=True&global_cats=True') 22 22 ); -
branches/2.2/contactcenter/setup/setup.inc.php
r4350 r5104 38 38 $setup_info['contactcenter']['hooks'][] = 'config_validate'; 39 39 $setup_info['contactcenter']['hooks'][] = 'sidebox_menu'; 40 $setup_info['contactcenter']['hooks'][] = 'settings'; 40 41 41 42 /* ContactCenter Tables */
Note: See TracChangeset
for help on using the changeset viewer.