status = 'complete'; return $service->save(); } catch (Exception $e) { throw new WorkflowActionNotPerformedException(); } } /** * Perform the verify action. * * @param Service $service * * @return Service */public function verify(Service $service) { try { $service->status = 'verify'; return $service->save(); } catch (Exception $e) { throw new WorkflowActionNotPerformedException(); } } /** * Perform the approve action. * * @param Service $service * * @return Service */public function approve(Service $service) { try { $service->status = 'approve'; return $service->save(); } catch (Exception $e) { throw new WorkflowActionNotPerformedException(); } } /** * Perform the publish action. * * @param Service $service * * @return Service */public function publish(Service $service) { try { $service->status = 'publish'; return $service->save(); } catch (Exception $e) { throw new WorkflowActionNotPerformedException(); } } /** * Perform the archive action. * * @param Service $service * * @return Service */ public function archive(Service $service) { try { $service->status = 'archive'; return $service->save(); } catch (Exception $e) { throw new WorkflowActionNotPerformedException(); } } /** * Perform the unpublish action. * * @param Service $service * * @return Service */ public function unpublish(Service $service) { try { $service->status = 'unpublish'; return $service->save(); } catch (Exception $e) { throw new WorkflowActionNotPerformedException(); } } }