当前位置: 首页>>代码示例>>PHP>>正文


PHP ModelBehavior::afterDelete方法代码示例

本文整理汇总了PHP中ModelBehavior::afterDelete方法的典型用法代码示例。如果您正苦于以下问题:PHP ModelBehavior::afterDelete方法的具体用法?PHP ModelBehavior::afterDelete怎么用?PHP ModelBehavior::afterDelete使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ModelBehavior的用法示例。


在下文中一共展示了ModelBehavior::afterDelete方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: afterDelete

 function afterDelete(\Model $model)
 {
     parent::afterDelete($model);
     $data = array('model' => $model->alias, 'model_id' => $model->id, 'activity_type' => 'D', 'user_id' => $model->loginUser['id']);
     $activity = new Activity();
     $activity->save($data);
 }
开发者ID:khaled-saiful-islam,项目名称:zen_v1.0,代码行数:7,代码来源:ActivityBehavior.php

示例2: afterDelete

 public function afterDelete(\Model $model)
 {
     //$this->log('after delete model');
     //$this->log($model);
     //$orderProductID = isset($model->id) ? $model->id : 0;
     //$this->updateTotalOrder($orderProductID);
     return parent::afterDelete($model);
 }
开发者ID:jgprolluxer,项目名称:prosales,代码行数:8,代码来源:OrderProductBehavior.php

示例3: afterDelete

 /**
  * afterDelete method
  *
  * @param Model $model
  * @return void
  */
 public function afterDelete(Model $model)
 {
     $settings = $this->settings[$model->alias];
     if (!isset($settings['afterDelete']) || $settings['afterDelete'] === 'off') {
         return parent::afterDelete($model);
     }
     switch ($settings['afterDelete']) {
         case 'on':
             echo 'afterDelete success';
             break;
     }
 }
开发者ID:magooemp,项目名称:eramba,代码行数:18,代码来源:BehaviorCollectionTest.php

示例4: afterDelete

 /**
  * After delete is called after any delete occurs on the attached model.
  *
  * @param Model $model Model using this behavior
  * @return void
  */
 public function afterDelete(Model $model)
 {
     parent::afterDelete($model);
     $this->writeAudit($model);
 }
开发者ID:jsemander,项目名称:cakephp-utilities,代码行数:11,代码来源:AuditableBehavior.php

示例5: afterDelete

 /**
  * After delete is called after any delete occurs on the attached model.
  * Intercepts delete to use the caching datasource instead
  * 
  * @param Model $model Model using this behavior
  * @return void
  */
 public function afterDelete(Model $model)
 {
     if ($this->settings[$model->alias]['clearOnDelete']) {
         $this->clearCache($model);
     }
     return parent::afterDelete($model);
 }
开发者ID:oanhnn,项目名称:cache,代码行数:14,代码来源:CachedBehavior.php

示例6: afterDelete

 /**
  *
  *
  * @param Model $Model
  */
 public function afterDelete(Model $Model)
 {
     parent::afterDelete($Model);
     $this->logQuery($Model, 'delete');
 }
开发者ID:radig,项目名称:auditable,代码行数:10,代码来源:AuditableBehavior.php

示例7: afterDelete

 /**
  * Trigger the update of the counts of the relevant associated habtm model
  * records, e.g. the Tags of the Post that was just deleted.
  *
  * @param AppModel $model
  */
 public function afterDelete(\Model $model)
 {
     parent::afterDelete($model);
     $this->_updateCounterCache($model);
 }
开发者ID:hurad,项目名称:hurad,代码行数:11,代码来源:HabtmCounterCacheBehavior.php


注:本文中的ModelBehavior::afterDelete方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。