@@ -16,6 +16,11 @@ discard block |
||
16 | 16 | // { |
17 | 17 | // } |
18 | 18 | |
19 | + /** |
|
20 | + * @param integer $key |
|
21 | + * @param string $ret |
|
22 | + * @param string $prefix_orig |
|
23 | + */ |
|
19 | 24 | public function _makePagesAdminOptions($key, &$ret, $prefix_orig, $objInsinstr, $class = 'odd', $prefix_curr = '') |
20 | 25 | { |
21 | 26 | if ($key > 0) { |
@@ -119,6 +124,11 @@ discard block |
||
119 | 124 | // === Дерево категорий в админке === |
120 | 125 | // ================================== |
121 | 126 | |
127 | + /** |
|
128 | + * @param integer $key |
|
129 | + * @param string $ret |
|
130 | + * @param string $prefix_orig |
|
131 | + */ |
|
122 | 132 | public function _makeCatsAdminOptions($key, &$ret, $prefix_orig, $cidinstrids = [], &$class = 'odd', $prefix_curr = '') |
123 | 133 | { |
124 | 134 | if ($key > 0) { |
@@ -204,6 +214,10 @@ discard block |
||
204 | 214 | // Список страниц на стороне пользователя |
205 | 215 | // ====================================== |
206 | 216 | |
217 | + /** |
|
218 | + * @param integer $key |
|
219 | + * @param string $ret |
|
220 | + */ |
|
207 | 221 | public function _makePagesUserTree($key, &$ret, $currpageid = 0, &$lastpageids = [], $level = 0) |
208 | 222 | { |
209 | 223 | |
@@ -308,6 +322,10 @@ discard block |
||
308 | 322 | |
309 | 323 | // Находим предыдущую и следующую страницы. |
310 | 324 | // Находим последнии страницы на каждом уровне. |
325 | + |
|
326 | + /** |
|
327 | + * @param integer $key |
|
328 | + */ |
|
311 | 329 | public function _makePagesUserCalc($key, $currpageid = 0, &$prevpages = [], &$nextpages = [], &$lastpageids = [], $level = 0) |
312 | 330 | { |
313 | 331 |
@@ -9,7 +9,7 @@ |
||
9 | 9 | |
10 | 10 | /** @var InstructionUtility $utilityClass */ |
11 | 11 | $utilityClass = ucfirst($moduleDirName) . 'Utility'; |
12 | -if (!class_exists($utilityClass)) { |
|
12 | +if ( ! class_exists($utilityClass)) { |
|
13 | 13 | xoops_load('utility', $moduleDirName); |
14 | 14 | } |
15 | 15 |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | |
32 | 32 | // Подключаем трей |
33 | 33 | |
34 | - include_once __DIR__ . '/../class/tree.php'; |
|
34 | + include_once __DIR__ . '/../class/tree.php'; |
|
35 | 35 | //include_once $GLOBALS['xoops']->path('modules/instruction/class/tree.php'); |
36 | 36 | |
37 | 37 | // Заголовок админки |
@@ -102,7 +102,7 @@ discard block |
||
102 | 102 | case 'savecat': |
103 | 103 | |
104 | 104 | // Проверка |
105 | - if (!$GLOBALS['xoopsSecurity']->check()) { |
|
105 | + if ( ! $GLOBALS['xoopsSecurity']->check()) { |
|
106 | 106 | redirect_header('cat.php', 3, implode(',', $GLOBALS['xoopsSecurity']->getErrors())); |
107 | 107 | } |
108 | 108 | // Если мы редактируем |
@@ -128,12 +128,12 @@ discard block |
||
128 | 128 | |
129 | 129 | // Проверка веса |
130 | 130 | if (0 == $weight) { |
131 | - $err = true; |
|
131 | + $err = true; |
|
132 | 132 | $message_err .= _AM_INSTRUCTION_ERR_WEIGHT . '<br>'; |
133 | 133 | } |
134 | 134 | // Проверка категорий |
135 | 135 | if ($cid && ($cid == $pid)) { |
136 | - $err = true; |
|
136 | + $err = true; |
|
137 | 137 | $message_err .= _AM_INSTRUCTION_ERR_PCAT . '<br>'; |
138 | 138 | } |
139 | 139 | // Если были ошибки |
@@ -241,7 +241,7 @@ discard block |
||
241 | 241 | |
242 | 242 | $objInscat = $instructioncatHandler->get($cid); |
243 | 243 | // Если нет такой категории |
244 | - if (!is_object($objInscat)) { |
|
244 | + if ( ! is_object($objInscat)) { |
|
245 | 245 | redirect_header('cat.php', 3, _AM_INSTRUCTION_ERR_CATNOTSELECT); |
246 | 246 | } |
247 | 247 | |
@@ -257,12 +257,12 @@ discard block |
||
257 | 257 | } |
258 | 258 | |
259 | 259 | // Нажали ли мы на кнопку OK |
260 | - $ok = isset($_POST['ok']) ? (int)$_POST['ok'] : 0; |
|
260 | + $ok = isset($_POST['ok']) ? (int) $_POST['ok'] : 0; |
|
261 | 261 | // Если мы нажали на кнопку |
262 | 262 | if ($ok) { |
263 | 263 | |
264 | 264 | // Проверка |
265 | - if (!$GLOBALS['xoopsSecurity']->check()) { |
|
265 | + if ( ! $GLOBALS['xoopsSecurity']->check()) { |
|
266 | 266 | redirect_header('cat.php', 3, implode(',', $GLOBALS['xoopsSecurity']->getErrors())); |
267 | 267 | } |
268 | 268 | // Пытаемся удалить категорию |