当前位置: 首页>>代码示例>>PHP>>正文


PHP Croogo::hookAdminBox方法代码示例

本文整理汇总了PHP中Croogo::hookAdminBox方法的典型用法代码示例。如果您正苦于以下问题:PHP Croogo::hookAdminBox方法的具体用法?PHP Croogo::hookAdminBox怎么用?PHP Croogo::hookAdminBox使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Croogo的用法示例。


在下文中一共展示了Croogo::hookAdminBox方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: _adminTabs

 /**
  * Hook admin tabs for controllers whom its primary model has MetaBehavior attached.
  */
 protected function _adminTabs()
 {
     $Model = $this->_controller->{$this->_controller->modelClass};
     if ($Model && !$Model->Behaviors->attached('Meta')) {
         return;
     }
     $controller = $this->_controller->name;
     $title = __d('croogo', 'Custom Fields');
     $element = 'Meta.admin/meta_tab';
     Croogo::hookAdminBox("{$controller}/admin_add", $title, $element);
     Croogo::hookAdminBox("{$controller}/admin_edit", $title, $element);
 }
开发者ID:dlpc,项目名称:CakeWX,代码行数:15,代码来源:MetaComponent.php

示例2: array

CroogoNav::add('sidebar', 'webshop', array('title' => __d('webshop', 'Webshop'), 'url' => '#', 'weight' => 30, 'children' => array('customers' => array('title' => __d('webshop', 'Customers'), 'url' => array('plugin' => 'webshop', 'controller' => 'customers', 'action' => 'index')), 'products' => array('title' => __d('webshop', 'Products'), 'url' => array('plugin' => 'webshop', 'controller' => 'products', 'action' => 'index')), 'Configuration groups' => array('title' => __d('webshop', 'Configuration groups'), 'url' => array('plugin' => 'webshop', 'controller' => 'configuration_groups', 'action0' => 'index')), 'Configuration options' => array('title' => __d('webshop', 'Configuration options'), 'url' => array('plugin' => 'webshop', 'controller' => 'configuration_options', 'action' => 'index')), 'configuration' => array('title' => __d('webshop', 'Configuration'), 'url' => '#'))));
CroogoNav::add('sidebar', 'settings.children.webshop', array('title' => __d('webshop', 'Webshop'), 'url' => '#'));
CroogoNav::add('webshop-dashboard-address_details-actions', 'edit', array('title' => __d('webshop', 'Edit'), 'url' => array('controller' => 'address_details', 'action' => 'edit', '_id'), 'htmlAttributes' => array('class' => 'btn-primary')));
CroogoNav::add('webshop-dashboard-customer_contacts-actions', 'edit', array('title' => __d('webshop', 'Edit'), 'url' => array('controller' => 'customer_contacts', 'action' => 'edit', '_id'), 'htmlAttributes' => array('class' => 'btn-primary')));
//endregion
//region Helpers
Croogo::hookHelper('*', 'Webshop.Product');
Croogo::hookHelper('*', 'Webshop.ConfigurationOption');
Croogo::hookHelper('*', 'Webshop.Webshop');
//endregion
//region Behaviors
Croogo::hookBehavior('Node', 'Webshop.Product');
//endregion
//region Components
Croogo::hookComponent('*', 'Webshop.CustomerAccess');
//endregion
Configure::write('Webshop.customer_access_providers', array());
Croogo::mergeConfig('Translate.models.ConfigurationOption', array('fields' => array('name' => 'nameTranslation'), 'translateModel' => 'Webshop.ConfigurationOption'));
//region Panel prefix setup
Croogo::mergeConfig('Routing.prefixes', array('panel'));
Router::reload();
//endregion
//region Admin panels
//region Admin tabs
Croogo::hookAdminTab('Products/admin_edit', 'Configuration implementation', 'Pltfrm.admin/node_webhosting_product_tab');
//endregion
//region Admin hooks
Croogo::hookAdminBox('Products/admin_edit', 'Configuration group', 'Webshop.admin/product/box_configuration_group_selector');
//endregion
//endregion
App::build(array('CustomerAccessProvider' => array('%s' . 'CustomerAccessProvider' . DS)), App::REGISTER);
开发者ID:cvo-technologies,项目名称:croogo-webshop-plugin,代码行数:31,代码来源:bootstrap.php


注:本文中的Croogo::hookAdminBox方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。