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