Changeset 12923
- Timestamp:
- 10/20/07 23:25:51 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/midcom/midcom.admin.settings/editor.php
r12922 r12923 45 45 var $_defaults = array(); 46 46 47 /** 48 * Simple helper which references all important members to the request data listing 49 * for usage within the style listing. 50 */ 51 function _prepare_request_data(&$data) 52 { 53 $this->_request_data['datamanager'] =& $this->_datamanager; 54 $this->_request_data['controller'] =& $this->_controller; 55 $this->_l10n = $_MIDCOM->i18n->get_l10n('midcom.admin.settings'); 56 57 $data['l10n'] = $this->_l10n; 58 $data['view_title'] = $this->_l10n->get('midcom.admin.settings'); 59 60 $data['asgard_toolbar'] = new midcom_helper_toolbar(); 61 62 $data['asgard_toolbar']->add_item 63 ( 64 array 65 ( 66 MIDCOM_TOOLBAR_URL => $_MIDCOM->get_context_data(MIDCOM_CONTEXT_ANCHORPREFIX), 67 MIDCOM_TOOLBAR_LABEL => $_MIDCOM->i18n->get_string('back to site', 'midgard.admin.asgard'), 68 MIDCOM_TOOLBAR_ICON => 'stock-icons/16x16/gohome.png', 69 ) 70 ); 71 72 $data['asgard_toolbar']->add_item 73 ( 74 array 75 ( 76 MIDCOM_TOOLBAR_URL => $_MIDCOM->get_context_data(MIDCOM_CONTEXT_ANCHORPREFIX)."midcom-logout-", 77 MIDCOM_TOOLBAR_LABEL => $_MIDCOM->i18n->get_string('logout','midcom'), 78 MIDCOM_TOOLBAR_ICON => 'stock-icons/16x16/exit.png', 79 ) 80 ); 81 } 47 82 48 83 49 /** … … 87 53 { 88 54 parent::midcom_baseclasses_components_handler(); 55 } 56 57 function _on_initialize() 58 { 89 59 $this->_config_storage = new midcom_db_page($_MIDGARD['page']); 90 60 … … 94 64 $_MIDCOM->load_library('midcom.admin.folder'); 95 65 96 $_MIDCOM->style->prepend_component_styledir('midgard.admin.asgard');97 $_MIDCOM->style->prepend_component_styledir('midcom.admin.settings');98 $_MIDCOM->skip_page_style = true;99 100 66 $this->_l10n = $_MIDCOM->i18n->get_l10n('midcom.admin.settings'); 101 102 67 $this->_debug_prefix = "midcom_admin_settings::"; 103 68 104 105 } 69 $this->_request_data['l10n'] = $this->_l10n; 70 $_MIDCOM->cache->content->no_cache(); 71 72 // Initialize Asgard plugin 73 midgard_admin_asgard_plugin::prepare_plugin($this->_l10n->get('midcom.admin.settings'),$this->_request_data); 74 75 } 76 106 77 107 78 function get_plugin_handlers() … … 121 92 } 122 93 94 /** 95 * Simple helper which references all important members to the request data listing 96 * for usage within the style listing. 97 */ 98 function _prepare_request_data(&$data) 99 { 100 $this->_request_data['datamanager'] =& $this->_datamanager; 101 $this->_request_data['controller'] =& $this->_controller; 102 midgard_admin_asgard_plugin::get_common_toolbar($data); 103 } 123 104 124 105 /** … … 239 220 $this->_prepare_request_data($data); 240 221 241 $_MIDCOM->set_pagetitle("{$this->_topic->extra}: {$this->_config_storage->title}");242 243 // Ensure we get the correct styles244 $_MIDCOM->style->prepend_component_styledir('midcom.admin.settings');245 246 $_MIDCOM->add_link_head247 (248 array249 (250 'rel' => 'stylesheet',251 'type' => 'text/css',252 'href' => MIDCOM_STATIC_URL.'/midcom.helper.datamanager2/legacy.css',253 )254 );255 256 222 // Add the view to breadcrumb trail 257 223 $tmp = Array(); trunk/midcom/midcom.admin.settings/style/midcom-admin-settings-edit.php
r12918 r12923 3 3 //$data =& $_MIDCOM->get_custom_context_data('request_data'); 4 4 ?> 5 6 5 <h1><?php echo $_MIDCOM->i18n->get_string('host configuration', 'midcom.admin.settings'); ?>: &(data['hostname']);</h1> 7 6 <div id="midcom_admin_settings"> 8 7 <?php 9 8 $data['controller']->display_form(); 10 9 ?> 10 </div>
