當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Page_Controller::__construct方法代碼示例

本文整理匯總了PHP中Page_Controller::__construct方法的典型用法代碼示例。如果您正苦於以下問題:PHP Page_Controller::__construct方法的具體用法?PHP Page_Controller::__construct怎麽用?PHP Page_Controller::__construct使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Page_Controller的用法示例。


在下文中一共展示了Page_Controller::__construct方法的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: Page

 function __construct($data = null)
 {
     if (!$data) {
         $data = new Page();
         $data->Title = "Unsubscribe";
     }
     parent::__construct($data);
 }
開發者ID:ramziammar,項目名稱:websites,代碼行數:8,代碼來源:Unsubscribe.php

示例2: __construct

 public function __construct($controller, $name, DataObjectInterface $payable, $amount)
 {
     if (!is_numeric($amount)) {
         throw new InvalidArgumentException("Amount must be numeric");
     }
     $record = new Page(array('ID' => -1, 'Title' => $controller->Title, 'ParentID' => $controller->ID, 'URLSegment' => $name));
     parent::__construct($record);
     $this->payable = $payable;
     $this->amount = $amount;
     //get currency from defaults
     $defaults = Payment::config()->defaults;
     if (isset($defaults['MoneyCurrency'])) {
         $this->currency = $defaults['MoneyCurrency'];
     }
     $this->successurl = $controller->Link();
 }
開發者ID:8secs,項目名稱:cocina,代碼行數:16,代碼來源:PaymentController.php

示例3: __construct

 public function __construct()
 {
     parent::__construct();
     $this->news_repository = new SapphireNewsRepository();
 }
開發者ID:Thingee,項目名稱:openstack-org,代碼行數:5,代碼來源:NewsPage_Controller.php

示例4:

 function __construct($data = null)
 {
     parent::__construct($data);
 }
開發者ID:tractorcow,項目名稱:silverstripe-newsletter,代碼行數:4,代碼來源:UnsubscribeController.php

示例5: __construct

 public function __construct()
 {
     parent::__construct();
     $this->news_repository = new SapphireNewsRepository();
     $this->manager = new NewsRequestManager(new SapphireNewsRepository(), new SapphireSubmitterRepository(), new NewsFactory(), new NewsValidationFactory(), new SapphireFileUploadService(), SapphireTransactionManager::getInstance());
 }
開發者ID:OpenStackweb,項目名稱:openstack-org,代碼行數:6,代碼來源:NewsRequestPage.php

示例6: __construct

 /**
  * Constructs a new controller for creating a registration.
  *
  * @param Controller $parent
  * @param RegisterableDateTime $datetime
  */
 public function __construct($parent, $datetime)
 {
     $this->parent = $parent;
     $this->datetime = $datetime;
     parent::__construct($parent->data());
 }
開發者ID:nyeholt,項目名稱:silverstripe-eventmanagement,代碼行數:12,代碼來源:EventRegisterController.php

示例7: __construct

 /**
  * SummitVideoApp_Controller constructor.
  * @param null $dataRecord
  */
 public function __construct($dataRecord = null)
 {
     parent::__construct($dataRecord);
     $this->backend = Injector::inst()->get('SummitVideoAppBackend');
 }
開發者ID:OpenStackweb,項目名稱:openstack-org,代碼行數:9,代碼來源:SummitVideoApp.php

示例8: __construct

 /**
  * @param RequestHandler $parent
  * @param string $name
  */
 public function __construct($parent, $name)
 {
     $this->parent = $parent;
     $this->name = $name;
     parent::__construct();
 }
開發者ID:helpfulrobot,項目名稱:ajshort-silverstripe-memberprofiles,代碼行數:10,代碼來源:MemberProfileViewer.php

示例9: __construct

 public function __construct($parent, $time)
 {
     $this->parent = $parent;
     $this->time = $time;
     parent::__construct($parent->data()->customise(array('Title' => $this->Title())));
 }
開發者ID:helpfulrobot,項目名稱:ajshort-silverstripe-eventmanagement,代碼行數:6,代碼來源:EventTimeDetailsController.php

示例10: __construct

 public function __construct($parent, $registration)
 {
     $this->parent = $parent;
     $this->registration = $registration;
     parent::__construct($parent->data()->customise(array('Title' => $this->Title())));
 }
開發者ID:helpfulrobot,項目名稱:ajshort-silverstripe-eventmanagement,代碼行數:6,代碼來源:EventRegistrationDetailsController.php


注:本文中的Page_Controller::__construct方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。