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