예제 #1
0
 /**
  * Handle the command.
  *
  * @param  UpdateCostCommand  $command
  * @return void
  */
 public function handle(UpdateCostCommand $command)
 {
     $cost = Cost::whereId($command->id)->first();
     if ($cost) {
         $cost->salary = $command->salary;
         $cost->save = $command->save;
         if ($cost->save()) {
             return $cost;
         }
     }
     return false;
 }