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