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