1 <?php
2
3 namespace Objednavky;
4
5 use Nette,
6 App\Model;
7 use PLus\Orders\Repositories;
8
9
10 11 12
13 class HomepagePresenter extends BasePresenter
14 {
15
16
17 public $orderRepository;
18
19
20 public function renderDefault()
21 {
22 $this->template->countorder = $this->orderRepository->getCountOrder();
23 $this->template->countcompleteorder = $this->orderRepository->getCounterCompleteOrder();
24 $this->template->countnocompleteorder = $this->orderRepository->getCounterNoCompleteOrder();
25
26
27 $this->template->donut = $this->orderRepository->statisticOrderDonut();
28 $this->template->line = $this->orderRepository->statisticOrderLine();
29 }
30
31 }
32