public function startup()
 {
     parent::startup();
     $this->pkHead = $this->model->getPkUser($this->user->id);
     if (!(!$this->pkHead == null || $this->user->isInRole("manager"))) {
         $this->flashMessage("Nemáte oprávnění.", "danger");
         $this->redirect("Homepage:default");
     }
 }
 public function renderApprove($id)
 {
     $data = $this->model->get($id);
     $this->template->data = $data;
 }