@@ -8,7 +8,6 @@ |
||
8 | 8 | |
9 | 9 | use Application\Form\Form; |
10 | 10 | use Phalcon\Forms\Element\TextArea; |
11 | -use Phalcon\Forms\Element\Hidden; |
|
12 | 11 | |
13 | 12 | class JavascriptForm extends Form |
14 | 13 | { |
@@ -143,7 +143,7 @@ |
||
143 | 143 | } |
144 | 144 | |
145 | 145 | /** |
146 | - * @return mixed |
|
146 | + * @return integer |
|
147 | 147 | */ |
148 | 148 | public function getDepth() |
149 | 149 | { |
@@ -249,7 +249,7 @@ discard block |
||
249 | 249 | } |
250 | 250 | |
251 | 251 | /** |
252 | - * @return mixed |
|
252 | + * @return integer |
|
253 | 253 | */ |
254 | 254 | public function getLimit() |
255 | 255 | { |
@@ -325,7 +325,7 @@ discard block |
||
325 | 325 | } |
326 | 326 | |
327 | 327 | /** |
328 | - * @param mixed $display_date |
|
328 | + * @param integer $display_date |
|
329 | 329 | */ |
330 | 330 | public function setDisplayDate($display_date) |
331 | 331 | { |
@@ -7,7 +7,6 @@ |
||
7 | 7 | namespace Seo\Controller; |
8 | 8 | |
9 | 9 | use Application\Mvc\Controller; |
10 | -use Seo\Form\ManagerAddForm; |
|
11 | 10 | use Seo\Form\ManagerForm; |
12 | 11 | use Seo\Model\Manager; |
13 | 12 |
@@ -8,10 +8,10 @@ |
||
8 | 8 | |
9 | 9 | namespace YonaCMS\Plugin; |
10 | 10 | |
11 | -use Phalcon\Mvc\Dispatcher, |
|
12 | - Phalcon\Mvc\User\Plugin, |
|
13 | - Phalcon\Mvc\View, |
|
14 | - Application\Acl\DefaultAcl; |
|
11 | +use Phalcon\Mvc\Dispatcher; |
|
12 | +use Phalcon\Mvc\User\Plugin; |
|
13 | +use Phalcon\Mvc\View; |
|
14 | +use Application\Acl\DefaultAcl; |
|
15 | 15 | |
16 | 16 | class Acl extends Plugin |
17 | 17 | { |
@@ -53,6 +53,9 @@ discard block |
||
53 | 53 | |
54 | 54 | } |
55 | 55 | |
56 | + /** |
|
57 | + * @param string $resourceKey |
|
58 | + */ |
|
56 | 59 | private function accessDenied($role, $resourceKey = null, $resourceVal = null, View $view) |
57 | 60 | { |
58 | 61 | if (in_array($role, ['guest', 'member'])) { |
@@ -71,6 +74,9 @@ discard block |
||
71 | 74 | exit; |
72 | 75 | } |
73 | 76 | |
77 | + /** |
|
78 | + * @param string $resourceKey |
|
79 | + */ |
|
74 | 80 | private function resourceNotFound($resourceKey, View $view) |
75 | 81 | { |
76 | 82 | $view->setViewsDir(__DIR__ . '/../modules/Index/views/'); |
@@ -84,6 +90,9 @@ discard block |
||
84 | 90 | exit; |
85 | 91 | } |
86 | 92 | |
93 | + /** |
|
94 | + * @param string $url |
|
95 | + */ |
|
87 | 96 | private function redirect($url, $code = 302) |
88 | 97 | { |
89 | 98 | switch ($code) { |
@@ -47,10 +47,10 @@ |
||
47 | 47 | { |
48 | 48 | $validator = new Validation(); |
49 | 49 | $validator->add('slug', new UniquenessValidator( |
50 | - [ |
|
51 | - "model" => $this, |
|
52 | - "message" => "Category with slug '" . $this->slug . "' is already exists. Take another title" |
|
53 | - ] |
|
50 | + [ |
|
51 | + "model" => $this, |
|
52 | + "message" => "Category with slug '" . $this->slug . "' is already exists. Take another title" |
|
53 | + ] |
|
54 | 54 | )); |
55 | 55 | return $this->validate($validator); |
56 | 56 | } |
@@ -143,7 +143,7 @@ |
||
143 | 143 | } |
144 | 144 | |
145 | 145 | /** |
146 | - * @return mixed |
|
146 | + * @return integer |
|
147 | 147 | */ |
148 | 148 | public function getDepth() |
149 | 149 | { |
@@ -245,7 +245,7 @@ |
||
245 | 245 | } |
246 | 246 | |
247 | 247 | /** |
248 | - * @return mixed |
|
248 | + * @return string |
|
249 | 249 | */ |
250 | 250 | public function getUpdatedAt() |
251 | 251 | { |
@@ -53,7 +53,7 @@ |
||
53 | 53 | |
54 | 54 | public function afterUpdate() |
55 | 55 | { |
56 | - $this->getDi()->get('cacheManager')->delete([ |
|
56 | + $this->getDi()->get('cacheManager')->delete([ |
|
57 | 57 | Keys::PAGE, |
58 | 58 | $this->slug, |
59 | 59 | self::$lang |
@@ -22,7 +22,7 @@ |
||
22 | 22 | $typeLimit = ($typeModel->getLimit()) ? $typeModel->getLimit() : 10; |
23 | 23 | $limit = $this->request->getQuery('limit', 'string', $typeLimit); |
24 | 24 | if ($limit != 'all') { |
25 | - $paginatorLimit = (int)$limit; |
|
25 | + $paginatorLimit = (int) $limit; |
|
26 | 26 | } else { |
27 | 27 | $paginatorLimit = 9999; |
28 | 28 | } |
@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | $slug, |
21 | 21 | $lang |
22 | 22 | |
23 | - ], function() use ($slug, $lang, $lifeTime) { |
|
23 | + ], function () use ($slug, $lang, $lifeTime) { |
|
24 | 24 | $columns = [ |
25 | 25 | 'p.*', |
26 | 26 | 't_slug' => 't.slug' |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | $lang = ($lang) ? $lang : LANG; |
48 | 48 | |
49 | 49 | $fields = []; |
50 | - foreach($this->translateFields as $field) { |
|
50 | + foreach ($this->translateFields as $field) { |
|
51 | 51 | $fields[] = "(SELECT tr.value FROM [$this->translateModel] AS tr WHERE tr.foreign_id = p.id AND tr.lang = '$lang' AND tr.key = '$field') AS $field"; |
52 | 52 | } |
53 | 53 | return $fields; |