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


PHP AdminBaseController类代码示例

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


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

示例1: __construct

 /**
  * @param AdRepository $adRepository
  * @param PhotoRepository $photoRepository
  */
 public function __construct(AdRepository $adRepository, PhotoRepository $photoRepository)
 {
     $this->photoRepository = $photoRepository;
     $this->adRepository = $adRepository;
     parent::__construct();
     $this->beforeFilter('Admin');
 }
开发者ID:christiannwamba,项目名称:laravel-site,代码行数:11,代码来源:AdminAdsController.php

示例2: __construct

 /**
  * Constructor
  */
 public function __construct()
 {
     parent::__construct();
     // Security check
     $security = $this->app->security;
     $security->authorized('editor');
 }
开发者ID:wolfmoritz,项目名称:osc,代码行数:10,代码来源:AdminServiceController.php

示例3:

 /**
  * @param PaymentRepository $paymentRepository
  * @param SubscriptionRepository $subscriptionRepository
  * @param RefundRepository $refundRepository
  */
 function __construct(PaymentRepository $paymentRepository, SubscriptionRepository $subscriptionRepository, RefundRepository $refundRepository)
 {
     $this->paymentRepository = $paymentRepository;
     $this->subscriptionRepository = $subscriptionRepository;
     $this->refundRepository = $refundRepository;
     parent::__construct();
 }
开发者ID:christiannwamba,项目名称:laravel-site,代码行数:12,代码来源:AdminRefundsController.php

示例4: __construct

 public function __construct()
 {
     parent::__construct();
     $this->data['dashboardActive'] = 'active';
     $this->data['dashboardOpen'] = 'active open';
     $this->data['pageTitle'] = 'Dashboard';
 }
开发者ID:rodrigopbel,项目名称:ong,代码行数:7,代码来源:AdminDashboardController.php

示例5: beforeAction

 public function beforeAction($handlerAdapter)
 {
     parent::beforeAction($handlerAdapter);
     if (!Wekit::load('ADMIN:service.srv.AdminFounderService')->isFounder($this->adminUser->username)) {
         $this->showError('APPCENTER:upgrade.founder');
     }
 }
开发者ID:fanqimeng,项目名称:4tweb,代码行数:7,代码来源:FixupController.php

示例6: getInstructions

 /**
  * Short Description.
  *
  * @param $id
  * @return null|string
  */
 public function getInstructions($id)
 {
     switch ($id) {
         case self::EMAIL_SENDING_OPTIONS:
             return "<p>These settings control under what circumstances emails are sent out. If you are looking for SMTP server settings, those can be configured under " . CHtml::link("System->Setup->Email Servers", $this->createUrl('system/edit', array('id' => 5))) . ".</p><p>For subject lines, the following variables are available: {storename}, {orderid}, {customername}</p>";
         case self::CUSTOMER_REGISTRATION:
             return "You can edit the Customer database including access levels by clicking " . CHtml::link("Edit Customers", $this->createUrl("databaseadmin/customers"));
         case self::TEMPLATE_OPTIONS:
             return "If you want to choose a new Theme for your site, they can be found under " . CHtml::link("Themes", $this->createUrl("theme/index"));
         case self::INVENTORY:
             return "You can use the code <strong>{qty}</strong> in Inventory Messages to display the actual quantity available.";
         case self::LOCALIZATION:
             return "To edit the actual language strings, use the Translation menu options under " . CHtml::link("Database", $this->createUrl("databaseadmin/index"));
         case self::PRODUCT_PHOTOS:
             if (Yii::app()->params['LIGHTSPEED_MT'] == 1) {
                 return "Change settings for how product images are processed for your Web Store.";
             } else {
                 return "Please note these settings affect photos as they are uploaded. You will need to reflag a product photo and Update Store to see the changes.";
             }
         case self::SEO_PRODUCT:
             return "<P>These settings control the Page Title and Meta Description using keys that represent product information. Each of these keys is wrapped in curly braces ({}). Most represent fields in the Product Card. {crumbtrail} and {rcrumbtrail} (reverse crumbtrail) are the product's category path. Below is the available list of keys:</p><P>{storename}, {name}, {description}, {shortdescription}, {longdescription}, {price}, {family}, {class}, {crumbtrail}, {rcrumbtrail}</p>You can use {storename} and {storetagline} for the homepage.";
         case self::SEO_CATEGORY:
             return "<P>These settings control the Category and Custom Page Titles and Meta Descriptions using keys that represent category name or store information. Each of these keys is wrapped with in curly braces ({}). {crumbtrail} and {rcrumbtrail} (reverse crumbtrail) are the product's category path. Below is the available list of keys:</p>\n<P>{storename}, {name}, {crumbtrail}, {rcrumbtrail}{</p>";
         default:
             return parent::getInstructions($id);
     }
 }
开发者ID:uiDeveloper116,项目名称:webstore,代码行数:33,代码来源:DefaultController.php

示例7: beforeAction

 public function beforeAction($action)
 {
     $this->scanModules('payment');
     $arrModules = Modules::model()->findAllByAttributes(array('category' => 'payment'), array('order' => 'module'));
     $this->_allowAdvancedPayments = CPropertyValue::ensureBoolean(Yii::app()->params['ALLOW_ADVANCED_PAY_METHODS']);
     $menuSidebar = array();
     foreach ($arrModules as $module) {
         $currentModule = Yii::app()->getComponent($module->module);
         if (is_null($currentModule)) {
             continue;
         }
         if ($currentModule->cloudCompatible === false && _xls_get_conf('LIGHTSPEED_CLOUD') > 0) {
             continue;
         }
         if ($currentModule->isDisplayable() === false) {
             continue;
         }
         $menuSidebar[] = array('label' => $currentModule->AdminName, 'url' => array('payments/module', 'id' => $module->module), 'advancedPayment' => $currentModule->advancedMode);
     }
     $advancedPaymentMethods = where($menuSidebar, array('advancedPayment' => true));
     $simplePaymentMethods = where($menuSidebar, array('advancedPayment' => false));
     $this->menuItems = array_merge(array(array('label' => 'Simple Integration Modules', 'linkOptions' => array('class' => 'nav-header'))), $simplePaymentMethods, array(array('label' => 'Advanced Integration Modules', 'linkOptions' => array('class' => 'nav-header'), 'visible' => count($advancedPaymentMethods) > 0)), $advancedPaymentMethods, $this->getPaymentSetupLinks());
     $objModules = Modules::model()->findAllByAttributes(array('category' => 'payment', 'active' => 1));
     if (count($objModules) === 0 && $action->id == "index") {
         $this->noneActive = 1;
         Yii::app()->user->setFlash('error', Yii::t('admin', 'WARNING: You have no payment modules activated. No one can checkout.'));
     }
     return parent::beforeAction($action);
 }
开发者ID:uiDeveloper116,项目名称:webstore,代码行数:29,代码来源:PaymentsController.php

示例8: __construct

 public function __construct(LocationRepository $locationRepository, UserRepository $userRepository, CountryRepository $countryRepository)
 {
     $this->locationRepository = $locationRepository;
     $this->userRepository = $userRepository;
     $this->countryRepository = $countryRepository;
     $this->beforeFilter('Admin');
     parent::__construct();
 }
开发者ID:christiannwamba,项目名称:laravel-site,代码行数:8,代码来源:AdminLocationsController.php

示例9: __construct

 /**
  * @param SettingRepository $settingRepository
  * @param CountryRepository $countryRepository
  * @param EventRepository $eventRepository
  * @param EventPriceRepository $eventPriceRepository
  */
 public function __construct(SettingRepository $settingRepository, CountryRepository $countryRepository, EventRepository $eventRepository, EventPriceRepository $eventPriceRepository)
 {
     $this->settingRepository = $settingRepository;
     $this->countryRepository = $countryRepository;
     parent::__construct();
     $this->eventRepository = $eventRepository;
     $this->eventPriceRepository = $eventPriceRepository;
 }
开发者ID:christiannwamba,项目名称:laravel-site,代码行数:14,代码来源:AdminSettingsController.php

示例10: beforeAction

 public function beforeAction($handlerAdapter)
 {
     parent::beforeAction($handlerAdapter);
     $config = Wekit::C('site', 'windid');
     if ($config == 'client') {
         $this->showError('WINDID:is.server.config');
     }
 }
开发者ID:fanqimeng,项目名称:4tweb,代码行数:8,代码来源:StorageController.php

示例11: __construct

 /**
  * Inject the models.
  * @param User $user
  * @param Role $role
  * @param Permission $permission
  */
 public function __construct(User $user, Role $role, Permission $permission)
 {
     $this->user = $user;
     $this->role = $role;
     $this->permission = $permission;
     $this->beforeFilter('Admin');
     parent::__construct();
 }
开发者ID:christiannwamba,项目名称:laravel-site,代码行数:14,代码来源:AdminRolesController.php

示例12: beforeAction

 public function beforeAction($handlerAdapter)
 {
     parent::beforeAction($handlerAdapter);
     $var = unserialize($this->getInput('var'));
     if (is_array($var)) {
         $this->setOutput($var, 'condition');
     }
 }
开发者ID:chendong0444,项目名称:phpwind,代码行数:8,代码来源:TaskConditionMemberController.php

示例13: edit

 public function edit($id)
 {
     $request = $this->status->with(array('user', 'event'))->find($id);
     if (is_null($request)) {
         return parent::redirectToAdmin();
     }
     return View::make('admin.requests.edit', compact('request'));
 }
开发者ID:christiannwamba,项目名称:laravel-site,代码行数:8,代码来源:AdminStatusesController.php

示例14:

 function __construct(SubscriptionRepository $subscriptionRepository, EventRepository $eventRepository, PackageRepository $packageRepository, UserRepository $userRepository)
 {
     $this->subscriptionRepository = $subscriptionRepository;
     $this->eventRepository = $eventRepository;
     $this->packageRepository = $packageRepository;
     $this->userRepository = $userRepository;
     parent::__construct();
 }
开发者ID:christiannwamba,项目名称:laravel-site,代码行数:8,代码来源:AdminSubscriptionsController.php

示例15: actions

	public function actions()
	{
		return CMap::mergeArray(parent::actions(), array(
			'createNode'=>'ext.QTreeGridView.actions.Create',
            'updateNode'=>'ext.QTreeGridView.actions.Update',
            'deleteNode'=>'ext.QTreeGridView.actions.Delete',
            'moveNode'=>'ext.QTreeGridView.actions.MoveNode',
            'makeRoot'=>'ext.QTreeGridView.actions.MakeRoot',
    	));
	}
开发者ID:nizsheanez,项目名称:PolymorphCMS,代码行数:10,代码来源:CategoriesController.php


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