[ Index ]

PHP Cross Reference of ACL Module

title

Body

[close]

/components/strategies/nestedSet/pathMaterialization/models/ -> PmAco.php (source)

   1  <?php
   2  
   3  /**

   4   * 

   5   * The Access Control Object specialization for path materilization

   6   *

   7   * @author dispy <dispyfree@googlemail.com>

   8   * @license LGPLv2

   9   * @package acl.strategies.nestedSet.pathMaterialiization

  10   */
  11  class PmAco extends PmAclObject
  12  {
  13      
  14      /**

  15       * Returns the static model of the specified AR class.

  16       * @param string $className active record class name.

  17       * @return PM_Aco the static model class

  18       */
  19      public static function model($className=__CLASS__)
  20      {
  21          return parent::model($className);
  22      }
  23  
  24      /**

  25       * @return string the associated database table name

  26       */
  27      public function tableName()
  28      {
  29          return '{{aco_collection}}';
  30      }
  31  
  32      /**

  33       * @return array validation rules for model attributes.

  34       */
  35      public function rules()
  36      {
  37          // NOTE: you should only define rules for those attributes that

  38          // will receive user inputs.

  39          return array(
  40          );
  41      }
  42  
  43      /**

  44       * @return array relational rules.

  45       */
  46      public function relations()
  47      {
  48          // NOTE: you may need to adjust the relation name and the related

  49          // class name for the relations automatically generated below.

  50          return array(
  51              'acoNodes' => array(static::HAS_MANY, 'PmAcoNode', 'collection_id'),
  52              'permissions' => array(static::HAS_MANY, 'Permission', 'aco_id')
  53          );
  54      }
  55  
  56      /**

  57       * @return array customized attribute labels (name=>label)

  58       */
  59      public function attributeLabels()
  60      {
  61          return array(
  62              'id' => 'ID',
  63              'alias' => 'Alias',
  64              'model' => 'Model',
  65              'foreign_key' => 'Foreign Key',
  66              'creaed' => 'Created'
  67          );
  68      }
  69  
  70  } 
  71  ?>


Generated: Sun Jul 1 19:24:45 2012 Cross-referenced by PHPXref 0.7.1