Paperyard
Senders.php
Go to the documentation of this file.
1 <?php
2 
4 
11 
16 class Senders extends BasicController
17 {
24  public function __construct(Twig $view, LoggerInterface $logger, Messages $flash)
25  {
26  $this->view = $view;
27  $this->logger = $logger;
28  $this->flash = $flash;
29 
30  $this->registerPlugin('datatables.min');
31  }
32 
39  public function __invoke(Request $request, Response $response, $args)
40  {
41 
42  // show rule list
43  $this->view->render($response, 'rule/senders.twig', $this->render());
44  return $response;
45  }
46 
51  public function render()
52  {
53  return array(
54  'plugins' => parent::getPlugins(),
55  'rules' => \Paperyard\Models\Rule\Senders::all(),
56  'languageFlag' => parent::getLanguageFlag()
57  );
58  }
59 }
__construct(Twig $view, LoggerInterface $logger, Messages $flash)
Definition: Senders.php:24
registerPlugin($name, $type=PluginType::NORMAL)
__invoke(Request $request, Response $response, $args)
Definition: Senders.php:39