/** * Apply for lessons/workshops page * @param $workshop_id int * @return \Illuminate\View\View */ public function showApply($workshop_id) { $include_right = false; $page_workshop = $this->workshop->findOrNew($workshop_id); //Check if the workshop is already full if ($page_workshop->isFull()) { return $this->getView('lessonfull', ['page_workshop' => $page_workshop]); } //Check if the workshop is still current if ($page_workshop->isPassedDate()) { return $this->getView('lessonexpired', ['page_workshop' => $page_workshop]); } $left_image = $this->getLeftGutterImage(); $blog_menu = $this->blog->getBlogMenu(); $this->title = 'Yogaground Apply for ' . $page_workshop->name; return $this->getView('lessonform', ['include_right' => $include_right, 'page_workshop' => $page_workshop, 'left_image' => $left_image, 'blog_menu' => $blog_menu]); }