ここの情報は古いです。ご理解頂いた上でお取り扱いください。

Changeset 9595


Ignore:
Timestamp:
Dec 19, 2008, 2:55:52 PM (12 years ago)
Author:
ebihara
Message:

#3131:removed automatically calling opActivateBehavior::enable()

Location:
OpenPNE3/trunk/lib
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • OpenPNE3/trunk/lib/behavior/opActivateBehavior.class.php

    r9514 r9595  
    1010      $criteria->add(call_user_func(array($class, 'translateFieldName'), 'is_active', BasePeer::TYPE_FIELDNAME, BasePeer::TYPE_COLNAME), 0, Criteria::NOT_EQUAL);
    1111    }
    12     else
    13     {
    14       self::enable();
    15     }
    1612  }
    1713
     
    2117    {
    2218      $criteria->add(call_user_func(array($class, 'translateFieldName'), 'is_active', BasePeer::TYPE_FIELDNAME, BasePeer::TYPE_COLNAME), 0, Criteria::NOT_EQUAL);
    23     }
    24     else
    25     {
    26       self::enable();
    2719    }
    2820  }
  • OpenPNE3/trunk/lib/config/sfOpenPNEApplicationConfiguration.class.php

    r9590 r9595  
    2020    include($this->getConfigCache()->checkConfig('config/member_config.yml'));
    2121
    22     sfPropelBehavior::registerHooks('activate', array (
    23       'Peer:doSelectStmt' => array ('opActivateBehavior', 'doSelectStmt'),
    24       'Peer:doCount' => array ('opActivateBehavior', 'doCount'),
    25     ));
    26 
    27     sfPropelBehavior::registerMethods('check_privilege_belong', array (
    28       array ('opCheckPrivilegeBelongBehavior', 'checkPrivilegeBelong'),
    29       array ('opCheckPrivilegeBelongBehavior', 'isPrivilegeBelong'),
    30     ));
    31 
    32     sfPropelBehavior::registerMethods('check_privilege_owner', array (
    33       array ('opCheckPrivilegeOwnerBehavior', 'checkPrivilegeOwner'),
    34       array ('opCheckPrivilegeOwnerBehavior', 'isPrivilegeOwner'),
    35     ));
     22    $this->setBehaviors();
    3623  }
    3724
     
    228215    return $dirs;
    229216  }
     217
     218  protected function setBehaviors()
     219  {
     220    sfPropelBehavior::registerHooks('activate', array (
     221      'Peer:doSelectStmt:doSelectStmt' => array('opActivateBehavior', 'doSelectStmt'),
     222      'Peer:doCount:doCount'           => array('opActivateBehavior', 'doCount'),
     223    ));
     224
     225    sfPropelBehavior::registerMethods('check_privilege_belong', array (
     226      array ('opCheckPrivilegeBelongBehavior', 'checkPrivilegeBelong'),
     227      array ('opCheckPrivilegeBelongBehavior', 'isPrivilegeBelong'),
     228    ));
     229
     230    sfPropelBehavior::registerMethods('check_privilege_owner', array (
     231      array ('opCheckPrivilegeOwnerBehavior', 'checkPrivilegeOwner'),
     232      array ('opCheckPrivilegeOwnerBehavior', 'isPrivilegeOwner'),
     233    ));
     234  }
    230235}
Note: See TracChangeset for help on using the changeset viewer.