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