Example #1
0
 public function save()
 {
     $success = parent::save();
     if (isset($this->data['tags'])) {
         $this->locationRepository->tagsDestroy($this->entity->id);
         $this->locationRepository->tagsAttach($this->entity->id, $this->data['tags']);
     }
 }
Example #2
0
 public function save()
 {
     $success = parent::save();
     if (isset($this->data['resources'])) {
         $this->roleRepository->resourceDestroy($this->entity->id);
         $this->roleRepository->resourcesAttach($this->entity->id, $this->data['resources']);
     }
 }