Esempio n. 1
0
 public function initialize()
 {
     parent::initialize();
     $this->belongsTo('advertiser_id', 'App\\Models\\Users', 'id', array('alias' => 'advertiser'));
     $this->hasManyToMany("id", 'App\\Models\\BannersZones', "banner_id", "zone_id", 'App\\Models\\Zones', "id", array('alias' => 'zones'));
     $this->hasMany('id', 'App\\Models\\Views', 'banner_id', array('alias' => 'views', 'foreignKey' => array('action' => \Phalcon\Mvc\Model\Relation::ACTION_CASCADE)));
 }
Esempio n. 2
0
 public function initialize()
 {
     parent::initialize();
     $this->hasMany('id', __NAMESPACE__ . '\\Tokens', 'user_id', array('alias' => 'Tokens', 'foreignKey' => array('action' => \Phalcon\Mvc\Model\Relation::ACTION_CASCADE)));
 }
Esempio n. 3
0
 public function __construct()
 {
     parent::__construct('relation');
 }
Esempio n. 4
0
 public function __construct()
 {
     parent::__construct('user');
 }
Esempio n. 5
0
 public function __construct()
 {
     parent::__construct('truck');
 }
Esempio n. 6
0
 public function __construct()
 {
     parent::__construct('price');
 }
Esempio n. 7
0
 public function __construct()
 {
     parent::__construct('product');
 }