<?php
namespace WpBookingEventFrontend\app\views\service;
use WpBookingEvent\Mvc\Model\Model;
use WpBookingEvent\Mvc\View\View;
use WpBookingEvent\Factory as FactoryAlias;

class ServiceView extends View
{
    public function display($tpl){
        $input = FactoryAlias::getInput();
        $service_id = $input->getInt('service_id',0);
        $modelService=Model::getInstance('service');
        $this->item=$modelService->getItem($service_id);
        $this->form = $modelService->getForm();
        $this->list_event=$modelService->getEventByServiceId($service_id);
        $this->list_review=$modelService->getReviewByServiceId($service_id);

        return parent::display($tpl);
    }
}