- Timestamp:
- 01/23/12 22:57:45 (4 months ago)
- Location:
- trunk/studio/templates/base/scripts
- Files:
-
- 10 edited
-
BxBaseStudioFormsDisplays.php (modified) (2 diffs)
-
BxBaseStudioFormsFields.php (modified) (1 diff)
-
BxBaseStudioFormsForms.php (modified) (2 diffs)
-
BxBaseStudioFormsPreLists.php (modified) (1 diff)
-
BxBaseStudioGrid.php (modified) (2 diffs)
-
BxBaseStudioNavigationImport.php (modified) (2 diffs)
-
BxBaseStudioNavigationItems.php (modified) (2 diffs)
-
BxBaseStudioNavigationMenus.php (modified) (2 diffs)
-
BxBaseStudioNavigationSets.php (modified) (2 diffs)
-
BxBaseStudioPermissionsActions.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/studio/templates/base/scripts/BxBaseStudioFormsDisplays.php
r15906 r15911 160 160 } 161 161 162 protected function _getCellModule($mixedValue, $sKey, $aField, $aRow) { 163 $mixedValue = $this->_limitMaxLength($this->getModuleTitle($aRow['module']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow); 164 return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow); 165 } 166 162 167 protected function _getCellFormTitle ($mixedValue, $sKey, $aField, $aRow) { 163 168 $mixedValue = $this->_limitMaxLength(_t($aRow['form_title']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow); … … 216 221 'value' => '', 217 222 'values' => array( 218 array('key' => '', 'value' => _t('_adm_form_txt_all_modules')), 219 array('key' => BX_DOL_STUDIO_GRID_MODULE_SYSTEM, 'value' => _t('_adm_txt_module_system')), 220 ) 221 ); 222 223 bx_import('BxDolModuleQuery'); 224 $aModules = BxDolModuleQuery::getInstance()->getModulesBy(array('type' => 'modules', 'active' => 1)); 225 foreach($aModules as $aModule) 226 $aInputModules['values'][] = array('key' => $aModule['name'], 'value' => $aModule['title']); 223 array('key' => '', 'value' => _t('_adm_form_txt_all_modules')) 224 ) 225 ); 226 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules(false)); 227 227 228 228 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioFormsFields.php
r15906 r15911 149 149 protected function _getCellTitle ($mixedValue, $sKey, $aField, $aRow) { 150 150 $mixedValue = $this->_limitMaxLength(_t($aRow['title']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow); 151 return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow); 152 } 153 154 protected function _getCellModule($mixedValue, $sKey, $aField, $aRow) { 155 $mixedValue = $this->_limitMaxLength($this->getModuleTitle($aRow['module']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow); 151 156 return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow); 152 157 } -
trunk/studio/templates/base/scripts/BxBaseStudioFormsForms.php
r15870 r15911 160 160 } 161 161 162 protected function _getCellModule($mixedValue, $sKey, $aField, $aRow) { 163 $mixedValue = $this->_limitMaxLength($this->getModuleTitle($aRow['module']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow); 164 return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow); 165 } 166 162 167 protected function _getCellDisplays ($mixedValue, $sKey, $aField, $aRow) { 163 168 $aDisplayes = array(); … … 191 196 'value' => '', 192 197 'values' => array( 193 array('key' => '', 'value' => _t('_adm_form_txt_all_modules')), 194 array('key' => BX_DOL_STUDIO_GRID_MODULE_SYSTEM, 'value' => _t('_adm_txt_module_system')) 198 array('key' => '', 'value' => _t('_adm_form_txt_all_modules')) 195 199 ) 196 200 ); 197 198 bx_import('BxDolModuleQuery'); 199 $aModules = BxDolModuleQuery::getInstance()->getModulesBy(array('type' => 'modules', 'active' => 1)); 200 foreach($aModules as $aModule) 201 $aInputModules['values'][] = array('key' => $aModule['name'], 'value' => $aModule['title']); 201 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules(false)); 202 202 203 203 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioFormsPreLists.php
r15888 r15911 319 319 } 320 320 321 protected function _getCellModule($mixedValue, $sKey, $aField, $aRow) { 322 $mixedValue = $this->_limitMaxLength($this->getModuleTitle($aRow['module']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow); 323 return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow); 324 } 325 321 326 protected function _getCellUseForSets ($mixedValue, $sKey, $aField, $aRow) { 322 327 $aChanger = array( -
trunk/studio/templates/base/scripts/BxBaseStudioGrid.php
r15794 r15911 21 21 } 22 22 23 protected function _getModuleTitle($sName) { 23 protected function getModuleTitle($sName) { 24 $sPrefix = '_adm_txt_module_'; 25 26 if(in_array($sName, array(BX_DOL_STUDIO_GRID_MODULE_SYSTEM, BX_DOL_STUDIO_GRID_MODULE_CUSTOM))) 27 return _t($sPrefix . $sName); 28 24 29 bx_import('BxDolModuleQuery'); 25 30 $aModule = BxDolModuleQuery::getInstance()->getModuleByName($sName); … … 27 32 return $aModule['title']; 28 33 29 return _t('_adm_txt_module_' . strtolower($sName)); 34 return _t($sPrefix . strtolower($sName)); 35 } 36 37 protected function getModules($bShowCustom = true, $bShowSystem = true) { 38 $aResult = array(); 39 40 if($bShowSystem) 41 $aResult[] = array('key' => BX_DOL_STUDIO_GRID_MODULE_SYSTEM, 'value' => $this->getModuleTitle(BX_DOL_STUDIO_GRID_MODULE_SYSTEM)); 42 43 if($bShowCustom) 44 $aResult[] = array('key' => BX_DOL_STUDIO_GRID_MODULE_CUSTOM, 'value' => $this->getModuleTitle(BX_DOL_STUDIO_GRID_MODULE_CUSTOM)); 45 46 bx_import('BxDolModuleQuery'); 47 $aModules = BxDolModuleQuery::getInstance()->getModulesBy(array('type' => 'modules', 'active' => 1)); 48 foreach($aModules as $aModule) 49 $aResult[] = array('key' => $aModule['name'], 'value' => $aModule['title']); 50 51 return $aResult; 30 52 } 31 53 } -
trunk/studio/templates/base/scripts/BxBaseStudioNavigationImport.php
r15820 r15911 120 120 } 121 121 122 protected function _getCellModule($mixedValue, $sKey, $aField, $aRow) { 123 $mixedValue = $this->_limitMaxLength($this->getModuleTitle($aRow['module']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow); 124 return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow); 125 } 126 122 127 protected function _getActionDone ($sType, $sKey, $a, $isSmall = false, $isDisabled = false, $aRow = array()) { 123 128 $a['attr']['onclick'] = "$('.bx-popup-applied:visible').dolPopupHide()"; … … 163 168 'values' => array( 164 169 array('key' => '', 'value' => _t('_adm_nav_txt_all_modules')), 165 array('key' => BX_DOL_STUDIO_GRID_MODULE_SYSTEM, 'value' => _t('_adm_txt_module_system')),166 array('key' => BX_DOL_STUDIO_GRID_MODULE_CUSTOM, 'value' => _t('_adm_txt_module_custom'))167 170 ) 168 171 ); 169 170 bx_import('BxDolModuleQuery'); 171 $aModules = BxDolModuleQuery::getInstance()->getModulesBy(array('type' => 'modules', 'active' => 1)); 172 foreach($aModules as $aModule) 173 $aInputModules['values'][] = array('key' => $aModule['name'], 'value' => $aModule['title']); 172 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules()); 174 173 175 174 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioNavigationItems.php
r15902 r15911 571 571 } 572 572 573 protected function _getCellModule($mixedValue, $sKey, $aField, $aRow) { 574 $mixedValue = $this->_limitMaxLength($this->getModuleTitle($aRow['module']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow); 575 return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow); 576 } 577 573 578 protected function _getCellVisibleForLevels ($mixedValue, $sKey, $aField, $aRow) { 574 579 $iIndex = 1; … … 659 664 'value' => '', 660 665 'values' => array( 661 array('key' => '', 'value' => _t('_adm_nav_txt_all_modules')), 662 array('key' => BX_DOL_STUDIO_GRID_MODULE_SYSTEM, 'value' => _t('_adm_txt_module_system')), 663 array('key' => BX_DOL_STUDIO_GRID_MODULE_CUSTOM, 'value' => _t('_adm_txt_module_custom')) 666 array('key' => '', 'value' => _t('_adm_nav_txt_all_modules')) 664 667 ) 665 668 ); 666 667 bx_import('BxDolModuleQuery'); 668 $aModules = BxDolModuleQuery::getInstance()->getModulesBy(array('type' => 'modules', 'active' => 1)); 669 foreach($aModules as $aModule) 670 $aInputModules['values'][] = array('key' => $aModule['name'], 'value' => $aModule['title']); 669 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules()); 671 670 672 671 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioNavigationMenus.php
r15817 r15911 401 401 } 402 402 403 protected function _getCellModule($mixedValue, $sKey, $aField, $aRow) { 404 $mixedValue = $this->_limitMaxLength($this->getModuleTitle($aRow['module']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow); 405 return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow); 406 } 407 403 408 protected function _getActionDelete ($sType, $sKey, $a, $isSmall = false, $isDisabled = false, $aRow = array()) { 404 409 if ($sType == 'single' && (int)$aRow['deleteable'] != 1) … … 426 431 'values' => array( 427 432 array('key' => '', 'value' => _t('_adm_nav_txt_all_modules')), 428 array('key' => BX_DOL_STUDIO_GRID_MODULE_SYSTEM, 'value' => _t('_adm_txt_module_system')),429 array('key' => BX_DOL_STUDIO_GRID_MODULE_CUSTOM, 'value' => _t('_adm_txt_module_custom'))430 433 ) 431 434 ); 432 433 bx_import('BxDolModuleQuery'); 434 $aModules = BxDolModuleQuery::getInstance()->getModulesBy(array('type' => 'modules', 'active' => 1)); 435 foreach($aModules as $aModule) 436 $aInputModules['values'][] = array('key' => $aModule['name'], 'value' => $aModule['title']); 435 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules()); 437 436 438 437 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioNavigationSets.php
r15818 r15911 307 307 } 308 308 309 protected function _getCellModule($mixedValue, $sKey, $aField, $aRow) { 310 $mixedValue = $this->_limitMaxLength($this->getModuleTitle($aRow['module']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow); 311 return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow); 312 } 313 309 314 protected function _getCellItems ($mixedValue, $sKey, $aField, $aRow) { 310 315 $aSets = array(); … … 345 350 'value' => '', 346 351 'values' => array( 347 array('key' => '', 'value' => _t('_adm_nav_txt_all_modules')), 348 array('key' => BX_DOL_STUDIO_GRID_MODULE_SYSTEM, 'value' => _t('_adm_txt_module_system')), 349 array('key' => BX_DOL_STUDIO_GRID_MODULE_CUSTOM, 'value' => _t('_adm_txt_module_custom')) 352 array('key' => '', 'value' => _t('_adm_nav_txt_all_modules')) 350 353 ) 351 354 ); 352 353 bx_import('BxDolModuleQuery'); 354 $aModules = BxDolModuleQuery::getInstance()->getModulesBy(array('type' => 'modules', 'active' => 1)); 355 foreach($aModules as $aModule) 356 $aInputModules['values'][] = array('key' => $aModule['name'], 'value' => $aModule['title']); 355 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules()); 357 356 358 357 $sContent .= $oForm->genRow($aInputModules); -
trunk/studio/templates/base/scripts/BxBaseStudioPermissionsActions.php
r15794 r15911 232 232 233 233 protected function _getCellModule($mixedValue, $sKey, $aField, $aRow) { 234 $mixedValue = $this->_limitMaxLength($this-> _getModuleTitle($aRow['Module']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow);234 $mixedValue = $this->_limitMaxLength($this->getModuleTitle($aRow['Module']), $sKey, $aField, $aRow, $this->_isDisplayPopupOnTextOverflow); 235 235 return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow); 236 236 } … … 281 281 'values' => array( 282 282 array('key' => '', 'value' => _t('_adm_prm_txt_all_modules')), 283 array('key' => 'system', 'value' => _t('_adm_txt_module_system'))284 283 ) 285 284 ); 286 287 bx_import('BxDolModuleQuery'); 288 $aModules = BxDolModuleQuery::getInstance()->getModulesBy(array('type' => 'modules', 'active' => 1)); 289 foreach($aModules as $aModule) 290 $aInputModules['values'][] = array('key' => $aModule['name'], 'value' => $aModule['title']); 285 $aInputModules['values'] = array_merge($aInputModules['values'], $this->getModules(false)); 291 286 292 287 $sContent .= $oForm->genRow($aInputModules);
Note: See TracChangeset
for help on using the changeset viewer.