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