Changeset 15953
- Timestamp:
- 02/07/12 00:01:09 (4 months ago)
- Location:
- trunk
- Files:
-
- 1 added
- 23 edited
-
install/sql/v70.sql (modified) (3 diffs)
-
modules/boonex/articles/install/config.php (modified) (1 diff)
-
modules/boonex/english/install/data/langs/en.xml (modified) (2 diffs)
-
modules/boonex/groups/install/config.php (modified) (1 diff)
-
studio/classes/BxDolStudioFormsQuery.php (modified) (1 diff)
-
studio/classes/BxDolStudioGrid.php (modified) (2 diffs)
-
studio/classes/BxDolStudioPage.php (modified) (2 diffs)
-
studio/classes/BxDolStudioUtils.php (added)
-
studio/inc/utils.inc.php (modified) (1 diff)
-
studio/js/permissions_actions.js (modified) (1 diff)
-
studio/js/polyglot_keys.js (modified) (1 diff)
-
studio/templates/base/scripts/BxBaseStudioBuilderPage.php (modified) (4 diffs)
-
studio/templates/base/scripts/BxBaseStudioFormsDisplays.php (modified) (3 diffs)
-
studio/templates/base/scripts/BxBaseStudioFormsFields.php (modified) (3 diffs)
-
studio/templates/base/scripts/BxBaseStudioFormsForms.php (modified) (1 diff)
-
studio/templates/base/scripts/BxBaseStudioFormsPreValues.php (modified) (2 diffs)
-
studio/templates/base/scripts/BxBaseStudioNavigationImport.php (modified) (2 diffs)
-
studio/templates/base/scripts/BxBaseStudioNavigationItems.php (modified) (2 diffs)
-
studio/templates/base/scripts/BxBaseStudioNavigationMenus.php (modified) (1 diff)
-
studio/templates/base/scripts/BxBaseStudioNavigationSets.php (modified) (1 diff)
-
studio/templates/base/scripts/BxBaseStudioPermissionsActions.php (modified) (2 diffs)
-
studio/templates/base/scripts/BxBaseStudioPermissionsLevels.php (modified) (2 diffs)
-
studio/templates/base/scripts/BxBaseStudioPermissionsPrices.php (modified) (1 diff)
-
studio/templates/base/scripts/BxBaseStudioPolyglotKeys.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/install/sql/v70.sql
r15945 r15953 2789 2789 ('sys_studio_nav_items', 'Sql', 'SELECT * FROM `sys_menu_items` WHERE 1 ', 'sys_menu_items', 'id', 'order', 'active', '', 100, NULL, 'start_it', '', 'title,link', 'auto', '', 'BxTemplStudioNavigationItems', ''), 2790 2790 ('sys_studio_nav_import', 'Sql', 'SELECT * FROM `sys_menu_items` WHERE 1 ', 'sys_menu_items', 'id', '', '', '', 5, NULL, 'start_im', '', 'title,link', 'auto', '', 'BxTemplStudioNavigationImport', ''), 2791 ('sys_studio_forms', 'Sql', 'SELECT * FROM `sys_objects_form` WHERE 1 ', 'sys_objects_form', 'id', ' ', 'active', '', 100, NULL, 'start', '', 'title,module', 'auto', '', 'BxTemplStudioFormsForms', ''),2792 ('sys_studio_forms_displays', 'Sql', 'SELECT `td`.`id` AS `id`, `td`.`object` AS `object`, `td`.`display_name` AS `display_name`, `td`.`title` AS `title`, `td`.`module` AS `module`, `tf`.`title` AS `form_title` FROM `sys_form_displays` AS `td` LEFT JOIN `sys_objects_form` AS `tf` ON `td`.`object`=`tf`.`object` WHERE 1 ', 'sys_form_displays', 'id', ' ', '', '', 100, NULL, 'start', '', 'td`.`title,td`.`module', 'auto', '', 'BxTemplStudioFormsDisplays', ''),2791 ('sys_studio_forms', 'Sql', 'SELECT * FROM `sys_objects_form` WHERE 1 ', 'sys_objects_form', 'id', 'module,title', 'active', '', 100, NULL, 'start', '', 'title,module', 'auto', 'title,module', 'BxTemplStudioFormsForms', ''), 2792 ('sys_studio_forms_displays', 'Sql', 'SELECT `td`.`id` AS `id`, `td`.`object` AS `object`, `td`.`display_name` AS `display_name`, `td`.`title` AS `title`, `td`.`module` AS `module`, `tf`.`title` AS `form_title` FROM `sys_form_displays` AS `td` LEFT JOIN `sys_objects_form` AS `tf` ON `td`.`object`=`tf`.`object` WHERE 1 ', 'sys_form_displays', 'id', 'module,object,title', '', '', 100, NULL, 'start', '', 'td`.`title,td`.`module', 'auto', 'title,module,form_title', 'BxTemplStudioFormsDisplays', ''), 2793 2793 ('sys_studio_forms_fields', 'Sql', 'SELECT `tdi`.`id` AS `id`, `ti`.`caption` AS `title`, `ti`.`type` AS `type`, `ti`.`module` AS `module`, `tdi`.`visible_for_levels` AS `visible_for_levels`, `tdi`.`active` AS `active`, `ti`.`editable` AS `editable`, `ti`.`deletable` AS `deletable`, `tdi`.`order` AS `order` FROM `sys_form_display_inputs` AS `tdi` LEFT JOIN `sys_form_inputs` AS `ti` ON `tdi`.`input_name`=`ti`.`name` AND `ti`.`object`=? WHERE 1 AND `tdi`.`display_name`=?', 'sys_form_display_inputs', 'id', 'order', 'active', '', 100, NULL, 'start', '', 'ti`.`type,ti`.`caption', 'auto', '', 'BxTemplStudioFormsFields', ''), 2794 ('sys_studio_forms_pre_lists', 'Sql', 'SELECT * FROM `sys_form_pre_lists` WHERE 1 ', 'sys_form_pre_lists', 'id', ' ', '', '', 100, NULL, 'start', '', 'module,key,title', 'auto', '', 'BxTemplStudioFormsPreLists', ''),2795 ('sys_studio_forms_pre_values', 'Sql', 'SELECT * FROM `sys_form_pre_values` WHERE 1 ', 'sys_form_pre_values', 'id', 'Order', '', '', 100 , NULL, 'start', '', 'Key,Value,LKey,LKey2', 'auto', '', 'BxTemplStudioFormsPreValues', '');2794 ('sys_studio_forms_pre_lists', 'Sql', 'SELECT * FROM `sys_form_pre_lists` WHERE 1 ', 'sys_form_pre_lists', 'id', 'title', '', '', 100, NULL, 'start', '', 'module,key,title', 'auto', 'module,key,title', 'BxTemplStudioFormsPreLists', ''), 2795 ('sys_studio_forms_pre_values', 'Sql', 'SELECT * FROM `sys_form_pre_values` WHERE 1 ', 'sys_form_pre_values', 'id', 'Order', '', '', 1000, NULL, 'start', '', 'Key,Value,LKey,LKey2', 'auto', '', 'BxTemplStudioFormsPreValues', ''); 2796 2796 2797 2797 CREATE TABLE IF NOT EXISTS `sys_grid_fields` ( … … 2872 2872 ('sys_studio_forms_fields', 'module', '_adm_form_txt_fields_module', '15%', '13', '', 5), 2873 2873 ('sys_studio_forms_fields', 'actions', '', '20%', '', '', 6), 2874 ('sys_studio_forms_pre_lists', ' key', '_adm_form_txt_pre_lists_key', '20%', '23', '', 1),2875 ('sys_studio_forms_pre_lists', ' title', '_adm_form_txt_pre_lists_title', '25%', '28', '', 2),2874 ('sys_studio_forms_pre_lists', 'title', '_adm_form_txt_pre_lists_title', '25%', '28', '', 1), 2875 ('sys_studio_forms_pre_lists', 'key', '_adm_form_txt_pre_lists_key', '20%', '23', '', 2), 2876 2876 ('sys_studio_forms_pre_lists', 'module', '_adm_form_txt_pre_lists_module', '13%', '11', '', 3), 2877 2877 ('sys_studio_forms_pre_lists', 'values', '_adm_form_txt_pre_lists_values', '12%', '10', '', 3), … … 2930 2930 ('sys_studio_forms_pre_lists', 'single', 'edit', '', 'document--pencil.png', 0, 1), 2931 2931 ('sys_studio_forms_pre_lists', 'single', 'delete', '', 'cross.png', 1, 2), 2932 ('sys_studio_forms_pre_values', 'independent', 'add', '_adm_form_btn_ values_create', '', 0, 1),2932 ('sys_studio_forms_pre_values', 'independent', 'add', '_adm_form_btn_pre_values_create', '', 0, 1), 2933 2933 ('sys_studio_forms_pre_values', 'single', 'edit', '', 'document--pencil.png', 0, 1), 2934 2934 ('sys_studio_forms_pre_values', 'single', 'delete', '', 'cross.png', 1, 2); -
trunk/modules/boonex/articles/install/config.php
r15751 r15953 135 135 * Category for language keys. 136 136 */ 137 'language_category' => 'Boon ex Articles',137 'language_category' => 'BoonEx Articles', 138 138 /** 139 139 * Permissions Section -
trunk/modules/boonex/english/install/data/langs/en.xml
r15949 r15953 2237 2237 <string name="_adm_lmi_cpt_displays"><![CDATA[Displays]]></string> 2238 2238 <string name="_adm_lmi_cpt_fields"><![CDATA[Fields]]></string> 2239 <string name="_adm_lmi_cpt_pre_lists"><![CDATA[ PredefinedLists]]></string>2240 <string name="_adm_lmi_cpt_pre_values"><![CDATA[ PredefinedItems]]></string>2239 <string name="_adm_lmi_cpt_pre_lists"><![CDATA[Data Lists]]></string> 2240 <string name="_adm_lmi_cpt_pre_values"><![CDATA[Data Items]]></string> 2241 2241 <string name="_adm_form_txt_all_modules"><![CDATA[All Modules]]></string> 2242 2242 <string name="_adm_form_txt_all_forms"><![CDATA[All Forms]]></string> 2243 2243 <string name="_adm_form_txt_select_display"><![CDATA[Select Display]]></string> 2244 <string name="_adm_form_txt_select_list"><![CDATA[Select List ]]></string>2244 <string name="_adm_form_txt_select_list"><![CDATA[Select List...]]></string> 2245 2245 <string name="_adm_form_err_cannot_process_action"><![CDATA[Cannot process action. It does not have an associated handler.]]></string> 2246 2246 <string name="_adm_form_txt_forms_title"><![CDATA[Title]]></string> … … 2406 2406 <string name="_adm_form_err_pre_lists_create"><![CDATA[Cannot add list]]></string> 2407 2407 <string name="_adm_from_err_pre_lists_delete"><![CDATA[Cannot delete list]]></string> 2408 <string name="_adm_form_txt_pre_lists_ create_popup"><![CDATA[Edit "{0}" List]]></string>2408 <string name="_adm_form_txt_pre_lists_edit_popup"><![CDATA[Edit "{0}" List]]></string> 2409 2409 <string name="_adm_form_err_pre_lists_edit"><![CDATA[Cannot update list]]></string> 2410 2410 <string name="_adm_form_txt_pre_lists_key"><![CDATA[Key]]></string> -
trunk/modules/boonex/groups/install/config.php
r15767 r15953 148 148 * Category for language keys. 149 149 */ 150 'language_category' => 'Boon ex Groups',150 'language_category' => 'BoonEx Groups', 151 151 152 152 /** -
trunk/studio/classes/BxDolStudioFormsQuery.php
r15924 r15953 95 95 $sSelectClause = ", `tf`.`title` AS `form_title`"; 96 96 $sJoinClause = "LEFT JOIN `sys_objects_form` AS `tf` ON `td`.`object`=`tf`.`object` "; 97 $sOrderClause = "ORDER BY `td`.`object` ASC, `td`.`title` ASC"; 97 98 break; 98 99 } -
trunk/studio/classes/BxDolStudioGrid.php
r15936 r15953 10 10 11 11 bx_import('BxTemplGrid'); 12 bx_import('BxDolStudioUtils'); 12 13 13 14 define('BX_DOL_STUDIO_GRID_PARAMS_DIVIDER', '#-#'); … … 25 26 26 27 public function getSystemName($sValue) { 27 return stdGetSystemName($sValue);28 return BxDolStudioUtils::getSystemName($sValue); 28 29 } 29 30 30 31 public function getClassName($sValue) { 31 return stdGetClassName($sValue);32 return BxDolStudioUtils::getClassName($sValue); 32 33 } 33 34 34 35 protected function getModuleTitle($sName) { 35 return stdGetModuleTitle($sName);36 return BxDolStudioUtils::getModuleTitle($sName); 36 37 } 37 38 38 39 protected function getModules($bShowCustom = true, $bShowSystem = true) { 39 return stdGetModules($bShowCustom, $bShowSystem);40 return BxDolStudioUtils::getModules($bShowCustom, $bShowSystem); 40 41 } 41 42 -
trunk/studio/classes/BxDolStudioPage.php
r15939 r15953 10 10 11 11 bx_import('BxDol'); 12 bx_import('BxDolStudioUtils'); 12 13 bx_import('BxDolStudioPageQuery'); 13 14 … … 101 102 102 103 protected function getSystemName($sValue) { 103 return stdGetSystemName($sValue);104 return BxDolStudioUtils::getSystemName($sValue); 104 105 } 105 106 106 107 protected function getClassName($sValue) { 107 return stdGetClassName($sValue);108 return BxDolStudioUtils::getClassName($sValue); 108 109 } 109 110 110 111 protected function getModuleTitle($sName) { 111 return stdGetModuleTitle($sName);112 return BxDolStudioUtils::getModuleTitle($sName); 112 113 } 113 114 115 protected function getModuleIcon($sName) { 116 return BxDolStudioUtils::getModuleIcon($sName); 117 } 118 114 119 protected function getModules($bShowCustom = true, $bShowSystem = true) { 115 return stdGetModules($bShowCustom, $bShowSystem);120 return BxDolStudioUtils::getModules($bShowCustom, $bShowSystem); 116 121 } 117 122 } -
trunk/studio/inc/utils.inc.php
r15949 r15953 7 7 defined('BX_DOL') or die('hack attempt'); 8 8 9 define('BX_DOL_STUDIO_MODULE_SYSTEM', 'system');10 define('BX_DOL_STUDIO_MODULE_CUSTOM', 'custom');11 12 function stdGetSystemName($sValue) {13 return str_replace(' ', '_', strtolower($sValue));14 }15 16 function stdGetClassName($sValue) {17 return str_replace(' ', '', ucwords(str_replace('_', ' ', $sValue)));18 }19 20 function stdGetModuleIcon($sName, $sType = 'menu') {21 $aType2Prefix = array('menu' => 'mi', 'page' => 'pi');22 23 $oTemplate = BxDolStudioTemplate::getInstance();24 $sDefaultIcon = $oTemplate->getIconUrl($aType2Prefix[$sType] . '-mod-empty.png');25 26 bx_import('BxDolModuleQuery');27 $aModule = BxDolModuleQuery::getInstance()->getModuleByName($sName);28 if(!empty($aModule))29 return $sDefaultIcon;30 31 $sModuleIcon = isset($aModule['path']) ? $oTemplate->getIconUrl('modules/' . $aModule['path'] . '|std-' . $aType2Prefix[$sType] . '.png') : '';32 return !empty($sModuleIcon) ? $sModuleIcon : $sDefaultIcon;33 }34 35 function stdGetModuleTitle($sName) {36 $sPrefix = '_adm_txt_module_';37 38 if(in_array($sName, array(BX_DOL_STUDIO_MODULE_SYSTEM, BX_DOL_STUDIO_MODULE_CUSTOM)))39 return _t($sPrefix . $sName);40 41 bx_import('BxDolModuleQuery');42 $aModule = BxDolModuleQuery::getInstance()->getModuleByName($sName);43 if(!empty($aModule))44 return $aModule['title'];45 46 return _t($sPrefix . strtolower($sName));47 }48 49 function stdGetModules($bShowCustom = true, $bShowSystem = true) {50 $aResult = array();51 52 if($bShowSystem)53 $aResult[] = array('key' => BX_DOL_STUDIO_MODULE_SYSTEM, 'value' => stdGetModuleTitle(BX_DOL_STUDIO_MODULE_SYSTEM));54 55 if($bShowCustom)56 $aResult[] = array('key' => BX_DOL_STUDIO_MODULE_CUSTOM, 'value' => stdGetModuleTitle(BX_DOL_STUDIO_MODULE_CUSTOM));57 58 bx_import('BxDolModuleQuery');59 $aModules = BxDolModuleQuery::getInstance()->getModulesBy(array('type' => 'modules', 'active' => 1));60 foreach($aModules as $aModule)61 $aResult[] = array('key' => $aModule['name'], 'value' => $aModule['title']);62 63 return $aResult;64 }65 66 function stdAddInArray($aInput, $sKey, $aValues) {67 reset($aInput);68 $iInput = count($aInput);69 for($i = 0; $i < $iInput; $i++, next($aInput))70 if(key($aInput) == $sKey)71 break;72 73 $aOutput = array_slice($aInput, 0, $i + 1);74 $aOutput = array_merge($aOutput, $aValues);75 $aOutput = array_merge($aOutput, array_slice($aInput, $i + 1));76 77 return $aOutput;78 }79 9 /** @} */ -
trunk/studio/js/permissions_actions.js
r15794 r15953 19 19 20 20 BxDolStudioPermissionsActions.prototype.onChangeLevel = function() { 21 var iLevel = parseInt($('#bx-grid-level-' + this.sObjNameGrid).val() );21 var iLevel = parseInt($('#bx-grid-level-' + this.sObjNameGrid).val().replace('id-', '')); 22 22 document.location.href = this.sPageUrl + (iLevel > 0 ? '&level=' + iLevel : ''); 23 23 }; -
trunk/studio/js/polyglot_keys.js
r15706 r15953 17 17 18 18 BxDolStudioPolyglotKeys.prototype.onChangeFilter = function() { 19 var sValueModule = $('#bx-grid-module-' + this.sObjNameGrid).val() ;19 var sValueModule = $('#bx-grid-module-' + this.sObjNameGrid).val().replace('id-', ''); 20 20 21 21 var sValueSearch = $('#bx-grid-search-' + this.sObjNameGrid).val(); -
trunk/studio/templates/base/scripts/BxBaseStudioBuilderPage.php
r15949 r15953 10 10 defined('BX_DOL') or die('hack attempt'); 11 11 12 bx_import('BxDolStudioUtils'); 12 13 bx_import('BxDolStudioBuilderPage'); 13 14 bx_import('BxTemplStudioFormView'); … … 141 142 'onclick' => $sJsObject . ".performAction('block_edit', {id: " . $aBlock['id'] . "})", 142 143 'title' => _t($aBlock['title']), 143 'icon' => stdGetModuleIcon($aBlock['module']),144 'module' => stdGetModuleTitle($aBlock['module']),144 'icon' => $this->getModuleIcon($aBlock['module']), 145 'module' => $this->getModuleTitle($aBlock['module']), 145 146 'bx_if:show_checkbox' => array( 146 147 'condition' => false, … … 359 360 if($oForm->isSubmittedAndValid()) { 360 361 $sTitleValue = $oForm->getCleanValue('title'); 361 $sObject = stdGetSystemName($sTitleValue);362 $sObject = BxDolStudioUtils::getSystemName($sTitleValue); 362 363 $sTitleKey = '_sys_bpb_caption_' . $sObject; 363 364 $oForm->setSubmittedValue('title', $sTitleKey, $aForm['form_attrs']['method']); … … 1317 1318 'html_id' => $this->aHtmlIds['block_id'] . $aBlock['id'], 1318 1319 'title' => _t($aBlock['title']), 1319 'icon' => stdGetModuleIcon($aBlock['module']),1320 'module' => stdGetModuleTitle($aBlock['module']),1320 'icon' => $this->getModuleIcon($aBlock['module']), 1321 'module' => $this->getModuleTitle($aBlock['module']), 1321 1322 'bx_if:show_checkbox' => array( 1322 1323 'condition' => true, -
trunk/studio/templates/base/scripts/BxBaseStudioFormsDisplays.php
r15936 r15953 200 200 ), 201 201 'value' => $this->sForm, 202 'values' => array( 203 array('key' => '', 'value' => _t('_adm_form_txt_all_forms')), 204 ) 202 'values' => array() 205 203 ); 206 204 … … 208 206 $this->oDb->getForms(array('type' => 'all'), $aForms, false); 209 207 foreach($aForms as $aForm) 210 $aInputForms['values'][] = array('key' => $aForm['object'], 'value' => _t($aForm['title'])); 208 $aInputForms['values'][$aForm['object']] = _t($aForm['title']); 209 210 asort($aInputForms['values']); 211 $aInputForms['values'] = array_merge(array('' => _t('_adm_form_txt_all_forms')), $aInputForms['values']); 211 212 212 213 $sContent .= $oForm->genRow($aInputForms); … … 220 221 ), 221 222 'value' => '', 222 'values' => array(223 array('key' => '', 'value' => _t('_adm_form_txt_all_modules'))224 ) 225 );226 $aInputModules['values'] = array_merge( $aInputModules['values'], $this->getModules(false));227 223 'values' => $this->getModules(false) 224 ); 225 226 asort($aInputModules['values']); 227 $aInputModules['values'] = array_merge(array('' => _t('_adm_form_txt_all_modules')), $aInputModules['values']); 228 228 229 $sContent .= $oForm->genRow($aInputModules); 229 230 -
trunk/studio/templates/base/scripts/BxBaseStudioFormsFields.php
r15943 r15953 197 197 'value' => $this->sObject . $this->sParamsDivider . $this->sDisplay, 198 198 'values' => array( 199 array('key' => '', 'value' => _t('_adm_form_txt_select_display')),199 '' => _t('_adm_form_txt_select_display'), 200 200 ) 201 201 ); … … 205 205 206 206 foreach($aDisplays as $aDisplay) 207 $aDisplaysGrouped[$aDisplay['object']][] = $aDisplay; 207 $aDisplaysGrouped[_t($aDisplay['form_title'])][] = $aDisplay; 208 ksort($aDisplaysGrouped); 208 209 209 210 foreach($aDisplaysGrouped as $sForm => $aDisplays) { … … 211 212 $aInputDisplays['values'][] = array('type' => 'group_header', 'value' => _t($aDisplays[0]['form_title'])); 212 213 214 $aDisplaysSubgroup = array(); 213 215 foreach($aDisplays as $aDisplay) 214 $aInputDisplays['values'][] = array('key' => $aDisplay['object'] . $this->sParamsDivider . $aDisplay['name'], 'value' => _t($aDisplay['title'])); 216 $aDisplaysSubgroup[$aDisplay['object'] . $this->sParamsDivider . $aDisplay['name']] = _t($aDisplay['title']); 217 218 asort($aDisplaysSubgroup); 219 $aInputDisplays['values'] = array_merge($aInputDisplays['values'], $aDisplaysSubgroup); 215 220 216 221 if(count($aDisplays) > 0) -
trunk/studio/templates/base/scripts/BxBaseStudioFormsForms.php
r15936 r15953 195 195 ), 196 196 'value' => '', 197 'values' => array( 198 array('key' => '', 'value' => _t('_adm_form_txt_all_modules')) 199 ) 197 'values' => $this->getModules(false) 200 198 ); 201 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules(false)); 199 200 asort($aInputModules['values']); 201 $aInputModules['values'] = array_merge(array('' => _t('_adm_form_txt_all_modules')), $aInputModules['values']); 202 202 203 203 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioFormsPreValues.php
r15936 r15953 430 430 ), 431 431 'value' => $this->sList, 432 'values' => array( 433 array('key' => '0', 'value' => _t('_adm_form_txt_select_list')) 434 ) 432 'values' => array() 435 433 ); 436 434 … … 438 436 $this->oDb->getLists(array('type' => 'all'), $aLists, false); 439 437 foreach($aLists as $aList) 440 $aInputLists['values'][] = array('key' => $aList['key'], 'value' => _t($aList['title'])); 438 $aInputLists['values'][$aList['key']] = _t($aList['title']); 439 440 asort($aInputLists['values']); 441 $aInputLists['values'] = array_merge(array('' => _t('_adm_form_txt_select_list')), $aInputLists['values']); 441 442 442 443 $sContent .= $oForm->genRow($aInputLists); -
trunk/studio/templates/base/scripts/BxBaseStudioNavigationImport.php
r15936 r15953 146 146 ), 147 147 'value' => '', 148 'values' => array( 149 array('key' => '0', 'value' => _t('_adm_nav_txt_all_sets')) 150 ) 148 'values' => array() 151 149 ); 152 150 153 151 $aSets = array(); 154 $ iSets = $this->oDb->getSets(array('type' => 'all', 'except' => $this->sSet), $aSets);152 $this->oDb->getSets(array('type' => 'all', 'except' => $this->sSet), $aSets, false); 155 153 foreach($aSets as $aSet) 156 $aInputSets['values'][] = array('key' => $aSet['name'], 'value' => _t($aSet['title'])); 154 $aInputSets['values'][$aSet['name']] = _t($aSet['title']); 155 156 asort($aInputSets['values']); 157 $aInputSets['values'] = array_merge(array('' => _t('_adm_nav_txt_select_set')), $aInputSets['values']); 157 158 158 159 $sContent .= $oForm->genRow($aInputSets); … … 166 167 ), 167 168 'value' => '', 168 'values' => array( 169 array('key' => '', 'value' => _t('_adm_nav_txt_all_modules')), 170 ) 169 'values' => $this->getModules() 171 170 ); 172 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules()); 171 172 asort($aInputModules['values']); 173 $aInputModules['values'] = array_merge(array('' => _t('_adm_nav_txt_all_modules')), $aInputModules['values']); 173 174 174 175 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioNavigationItems.php
r15936 r15953 645 645 ), 646 646 'value' => $this->sSet, 647 'values' => array( 648 array('key' => '0', 'value' => _t('_adm_nav_txt_select_set')) 649 ) 647 'values' => array() 650 648 ); 651 649 652 650 $aSets = array(); 653 $ iSets = $this->oDb->getSets(array('type' => 'all'), $aSets);651 $this->oDb->getSets(array('type' => 'all'), $aSets, false); 654 652 foreach($aSets as $aSet) 655 $aInputSets['values'][] = array('key' => $aSet['name'], 'value' => _t($aSet['title'])); 653 $aInputSets['values'][$aSet['name']] = _t($aSet['title']); 654 655 asort($aInputSets['values']); 656 $aInputSets['values'] = array_merge(array('' => _t('_adm_nav_txt_select_set')), $aInputSets['values']); 656 657 657 658 $sContent .= $oForm->genRow($aInputSets); … … 667 668 ), 668 669 'value' => '', 669 'values' => array( 670 array('key' => '', 'value' => _t('_adm_nav_txt_all_modules')) 671 ) 670 'values' => $this->getModules() 672 671 ); 673 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules()); 672 673 asort($aInputModules['values']); 674 $aInputModules['values'] = array_merge(array('' => _t('_adm_nav_txt_all_modules')), $aInputModules['values']); 674 675 675 676 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioNavigationMenus.php
r15936 r15953 528 528 ), 529 529 'value' => '', 530 'values' => array( 531 array('key' => '', 'value' => _t('_adm_nav_txt_all_modules')), 532 ) 530 'values' => $this->getModules() 533 531 ); 534 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules()); 532 533 asort($aInputModules['values']); 534 $aInputModules['values'] = array_merge(array('' => _t('_adm_nav_txt_all_modules')), $aInputModules['values']); 535 535 536 536 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioNavigationSets.php
r15936 r15953 349 349 ), 350 350 'value' => '', 351 'values' => array( 352 array('key' => '', 'value' => _t('_adm_nav_txt_all_modules')) 353 ) 351 'values' => $this->getModules() 354 352 ); 355 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules()); 353 354 asort($aInputModules['values']); 355 $aInputModules['values'] = array_merge(array('' => _t('_adm_nav_txt_all_modules')), $aInputModules['values']); 356 356 357 357 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioPermissionsActions.php
r15936 r15953 257 257 ), 258 258 'value' => $this->iLevel, 259 'values' => array( 260 array('key' => '0', 'value' => _t('_adm_prm_txt_select_level')) 261 ) 259 'values' => array() 262 260 ); 263 261 264 262 $aLevels = array(); 265 $ iLevels = $this->oDb->getLevels(array('type' => 'all'), $aLevels);263 $this->oDb->getLevels(array('type' => 'all'), $aLevels, false); 266 264 foreach($aLevels as $aLevel) 267 $aInputLevels['values'][] = array('key' => $aLevel['id'], 'value' => _t($aLevel['name'])); 265 $aInputLevels['values']['id-' . $aLevel['id']] = _t($aLevel['name']); 266 267 asort($aInputLevels['values']); 268 $aInputLevels['values'] = array_merge(array('id-0' => _t('_adm_prm_txt_select_level')), $aInputLevels['values']); 268 269 269 270 $sContent .= $oForm->genRow($aInputLevels); … … 279 280 ), 280 281 'value' => '', 281 'values' => array( 282 array('key' => '', 'value' => _t('_adm_prm_txt_all_modules')), 283 ) 282 'values' => $this->getModules(false) 284 283 ); 285 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules(false)); 284 285 asort($aInputModules['values']); 286 $aInputModules['values'] = array_merge(array('' => _t('_adm_prm_txt_all_modules')), $aInputModules['values']); 286 287 287 288 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioPermissionsLevels.php
r15936 r15953 450 450 } 451 451 protected function _getCellIcon ($mixedValue, $sKey, $aField, $aRow) { 452 $sSrc = BX_DOL_URL_ROOT . 'media/images/membership/' . $mixedValue;452 $sSrc = ''; 453 453 if(is_numeric($mixedValue)) { 454 454 bx_import('BxDolStorage'); … … 458 458 $sSrc = $sFileUrl; 459 459 } 460 else 461 $sSrc = $this->_oTemplate->getImageUrl($mixedValue); 460 462 461 463 $mixedValue = $this->_oTemplate->parseHtmlByName('bx_img.html', array( -
trunk/studio/templates/base/scripts/BxBaseStudioPermissionsPrices.php
r15936 r15953 330 330 ), 331 331 'value' => $this->iLevel, 332 'values' => array( 333 array('key' => '0', 'value' => _t('_adm_prm_txt_select_level')) 334 ) 332 'values' => array() 335 333 ); 336 334 337 335 $aLevels = array(); 338 $ iLevels = $this->oDb->getLevels(array('type' => 'all'), $aLevels);336 $this->oDb->getLevels(array('type' => 'all'), $aLevels, false); 339 337 foreach($aLevels as $aLevel) 340 $aInputLevels['values'][] = array('key' => $aLevel['id'], 'value' => _t($aLevel['name'])); 338 $aInputLevels['values']['id-' . $aLevel['id']] = _t($aLevel['name']); 339 340 asort($aInputLevels['values']); 341 $aInputLevels['values'] = array_merge(array('id-0' => _t('_adm_prm_txt_select_level')), $aInputLevels['values']); 341 342 342 343 $sContent .= $oForm->genRow($aInputLevels); -
trunk/studio/templates/base/scripts/BxBaseStudioPolyglotKeys.php
r15817 r15953 295 295 parent::_getFilterControls(); 296 296 297 $sContent = ""; 298 297 299 bx_import('BxTemplStudioFormView'); 298 300 $oForm = new BxTemplStudioFormView(array()); … … 305 307 'onChange' => 'javascript:' . $this->getJsObject() . '.onChangeFilter()' 306 308 ), 307 'values' => array( 308 array('key' => '0', 'value' => _t('_adm_pgt_txt_all_categories')) 309 ) 309 'values' => array() 310 310 ); 311 311 … … 313 313 $iCategories = $this->oDb->getCategoriesBy(array('type' => 'all'), $aCategories); 314 314 foreach($aCategories as $aCategory) 315 $aInputModules['values'][] = array('key' => $aCategory['id'], 'value' => $aCategory['name']); 315 $aInputModules['values']['id-' . $aCategory['id']] = $aCategory['name']; 316 317 asort($aInputModules['values']); 318 $aInputModules['values'] = array_merge(array('id-0' => _t('_adm_pgt_txt_all_categories')), $aInputModules['values']); 319 320 $sContent .= $oForm->genRow($aInputModules); 316 321 317 322 $aInputSearch = array( … … 324 329 ); 325 330 326 return $oForm->genRow($aInputModules) . $oForm->genRow($aInputSearch); 331 $sContent .= $oForm->genRow($aInputSearch); 332 333 return $sContent; 327 334 } 328 335 }
Note: See TracChangeset
for help on using the changeset viewer.