Пример #1
0
 /**
  * Initialize method
  *
  * @param array $config The configuration for the Table.
  * @return void
  */
 public function initialize(array $config)
 {
     parent::initialize($config);
     $this->table('spider_plugins_plugins');
     $this->displayField('name');
     $this->primaryKey('id');
 }
Пример #2
0
 /**
  * Initialize method
  *
  * @param array $config The configuration for the Table.
  * @return void
  */
 public function initialize(array $config)
 {
     parent::initialize($config);
     $this->table('spider_aclmanager_users_roles');
     $this->primaryKey('id');
     $this->belongsTo('Users', ['className' => 'Users.Users', 'foreignKey' => 'user_id']);
     $this->belongsTo('Roles', ['className' => 'AclManager.Roles', 'foreignKey' => 'role_id']);
 }
Пример #3
0
 /**
  * Initialize method
  *
  * @param array $config The configuration for the Table.
  * @return void
  */
 public function initialize(array $config)
 {
     parent::initialize($config);
     $this->table('spider_settings_settings');
     $this->displayField('title');
     $this->primaryKey('id');
     $this->addBehavior('Timestamp');
 }
Пример #4
0
 /**
  * Initialize method
  *
  * @param array $config The configuration for the Table.
  * @return void
  */
 public function initialize(array $config)
 {
     parent::initialize($config);
     $this->table('spider_aclmanager_acos');
     $this->displayField('name');
     $this->primaryKey('id');
     $this->belongsToMany('Aros', ['foreignKey' => 'aco_id', 'targetForeignKey' => 'aro_id', 'joinTable' => 'spider_aclmanager_aros_acos', 'className' => 'AclManager.Aros']);
 }
Пример #5
0
 /**
  * Initialize method
  *
  * @param array $config The configuration for the Table.
  * @return void
  */
 public function initialize(array $config)
 {
     parent::initialize($config);
     $this->table('spider_users_users');
     $this->displayField('alias');
     $this->primaryKey('id');
     $this->addBehavior('Timestamp');
     $this->hasMany('Users.ActivationKeys', ['foreignKey' => 'user_id', 'className' => 'Users.ActivationKeys']);
 }
Пример #6
0
 /**
  * Initialize method
  *
  * @param array $config The configuration for the Table.
  * @return void
  */
 public function initialize(array $config)
 {
     parent::initialize($config);
     $this->table('spider_aclmanager_roles');
     $this->displayField('name');
     $this->primaryKey('id');
     $this->addBehavior('Tree');
     $this->belongsTo('ParentRoles', ['className' => 'AclManager.Roles', 'foreignKey' => 'parent_id']);
     $this->hasMany('ChildRoles', ['className' => 'AclManager.Roles', 'foreignKey' => 'parent_id']);
     $this->belongsToMany('Users.Users', ['through' => 'AclManager.UsersRoles']);
 }