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