Exemplo n.º 1
0
 function init()
 {
     parent::init();
     if (method_exists($this, 'defineFields')) {
         throw $this->exception('model->defineField() is obsolete. Change to init()', 'Obsolete')->addMoreInfo('class', get_class($this));
     }
 }
Exemplo n.º 2
0
 function init()
 {
     parent::init();
     $this->soap = new SoapClient($this->owner->url, array('trace' => true, 'exceptions' => true));
     $this->set('ApiKey', $this->owner->key);
     $this->set('ClientID', $this->owner->client);
 }
Exemplo n.º 3
0
 function init()
 {
     parent::init();
     $this->setPage(null);
     $this->addStickyArguments();
     $this->extension = $this->api->getConfig('url_postfix', $this->extension);
 }
Exemplo n.º 4
0
 function init()
 {
     parent::init();
     $this->template = $this->add('SMlite');
     $this->template->loadTemplateFromString($this->getXML());
     $timestamp = strftime("%Y%m%d%H%M%S");
     $this->set('orderid', $timestamp . "-" . mt_rand(1, 999));
     $this->set('merchantid', $this->api->getConfig('billing/realex/merchantid'));
     $this->set('timestamp', $timestamp);
     $this->set('account', $this->api->getConfig('billing/realex/account'));
 }
Exemplo n.º 5
0
 function init()
 {
     parent::init();
     if (!isset($this->api->pm)) {
         throw $this->exception('You must initialize PageManager first');
     }
     if (!$this->api->pm->base_url) {
         throw $this->exception('PageManager is did not parse request URL. Use either parseRequestedURL or setURL (if you are in CLI application)');
     }
     $this->addStickyArguments();
     $this->extension = $this->api->getConfig('url_postfix', $this->extension);
 }
Exemplo n.º 6
0
Arquivo: Part.php Projeto: atk4/atk4
 public function init()
 {
     parent::init();
     // Initialize template of this part
     $t = $this->defaultTemplate();
     $this->template = $this->add($this->owner->template_class);
     /** @type TMail_Template $this->template */
     $this->template->loadTemplate($t[0], '.mail');
     if ($t[1]) {
         $this->template = $this->template->cloneRegion($t[1]);
     }
 }
Exemplo n.º 7
0
Arquivo: Basic.php Projeto: atk4/atk4
 public function init()
 {
     parent::init();
     /** @type TMail_Template $master_template */
     $master_template = $this->add($this->template_class);
     $master_template->loadTemplate('shared', '.mail');
     $this->template = $master_template->cloneRegion('body');
     $this->headers = $master_template->cloneRegion('headers');
     $this->boundary = str_replace('.', '', uniqid('atk4tmail', true));
     if ($t = $this->app->getConfig('tmail/transport', false)) {
         $this->addTransport($t);
     }
 }
Exemplo n.º 8
0
 /**
  * init
  *
  * @return void
  */
 function init()
 {
     parent::init();
     // first let's see if we authenticate
     if ($this->authenticate === true || $this->authenticate !== false && ($this->hasMethod('authenticate') || $this->app->hasMethod('authenticate'))) {
         $result = false;
         if ($this->hasMethod('authenticate')) {
             $result = $this->authenticate();
         }
         if (!$result && $this->app->hasMethod('authenticate')) {
             $result = $this->app->authenticate();
         }
         if (!$result) {
             throw $this->exception('Authentication Failed', null, 403);
         }
         if (is_object($result)) {
             $this->user = $result;
         }
     }
     $m = $this->_model();
     if ($m) {
         $this->setModel($m);
     }
 }
Exemplo n.º 9
0
 /**
  * Initialization of the object
  *
  * @return void
  */
 function init()
 {
     parent::init();
     $this->debug('ProcessIO initialised, setting descriptor options');
     $this->descriptorspec = array(0 => array("pipe", "r"), 1 => array("pipe", "w"), 2 => array("pipe", "w"));
 }
Exemplo n.º 10
0
 function init()
 {
     parent::init();
     $this->cache =& $this->api->smlite_cache;
     $this->settings = array_merge($this->getDefaultSettings(), $this->api->getConfig('template', array()));
 }
Exemplo n.º 11
0
 function init()
 {
     parent::init();
     $this->relative_path = $this->short_name;
     if ($this->short_name[0] == '/' || strlen($this->short_name) > 1 && $this->short_name[1] == ':') {
         // Absolute path. Independent from base_location
     } else {
         $this->setParent($this->owner->base_location);
     }
 }
Exemplo n.º 12
0
 function init()
 {
     parent::init();
     $this->table_alias = $this->short_name;
 }
Exemplo n.º 13
0
 public function init()
 {
     parent::init();
 }
Exemplo n.º 14
0
 /**
  * Initialization of the object.
  */
 public function init()
 {
     parent::init();
     $this->debug('ProcessIO initialised, setting descriptor options');
     $this->descriptorspec = array(0 => array('pipe', 'r'), 1 => array('pipe', 'w'), 2 => array('pipe', 'w'));
 }
Exemplo n.º 15
0
 function init()
 {
     parent::init();
     $path = array();
     $this->cache =& $this->app->smlite_cache;
     $this->settings = $this->getDefaultSettings();
     $this->settings['extension'] = $this->app->getConfig('smlite/extension', '.html');
 }
Exemplo n.º 16
0
 public function init()
 {
     parent::init();
     $this->addField($this->id_field)->system(true);
 }
Exemplo n.º 17
0
 function init()
 {
     parent::init();
     $this->del('fields')->del('table')->del('options');
 }