예제 #1
0
파일: Mapper.php 프로젝트: yeaha/owl-orm
 protected function doDelete(\Owl\DataMapper\Data $data, \Owl\Service $service = null, $collection = null)
 {
     $service = $service ?: $this->getService();
     $collection = $collection ?: $this->getCollection();
     list($where, $params) = $this->whereID($service, $data->id(true));
     return $service->delete($collection, $where, $params);
 }
예제 #2
0
파일: Mapper.php 프로젝트: tempbottle/owl
 protected function doDelete(\Owl\DataMapper\Data $data, Service $service = null, $collection = null)
 {
     $service = $service ?: $this->getService();
     $collection = $collection ?: $this->getCollection();
     return $service->delete($collection, $data->id());
 }
예제 #3
0
 /**
  * delete cache before refresh data
  *
  * @param \Owl\DataMapper\Data $data
  * @return \Owl\DataMapper\Data
  */
 public function refresh(\Owl\DataMapper\Data $data)
 {
     $this->deleteCache($data->id());
     return parent::refresh($data);
 }