@@ -53,7 +53,7 @@ |
||
| 53 | 53 | } |
| 54 | 54 | |
| 55 | 55 | /** |
| 56 | - * @return bool|string |
|
| 56 | + * @return false|string |
|
| 57 | 57 | */ |
| 58 | 58 | public function getPjaxUrl() |
| 59 | 59 | { |
@@ -91,7 +91,7 @@ |
||
| 91 | 91 | } |
| 92 | 92 | |
| 93 | 93 | /** |
| 94 | - * @return Model|SearchModelTrait |
|
| 94 | + * @return \hiqdev\hiart\ActiveRecord |
|
| 95 | 95 | */ |
| 96 | 96 | public function getSearchModel() |
| 97 | 97 | { |
@@ -82,6 +82,9 @@ discard block |
||
| 82 | 82 | return $this->switch->controller->runAction($action); |
| 83 | 83 | } |
| 84 | 84 | |
| 85 | + /** |
|
| 86 | + * @param string $postfix |
|
| 87 | + */ |
|
| 85 | 88 | public function run($postfix = null) |
| 86 | 89 | { |
| 87 | 90 | return $this->runAction($postfix); |
@@ -91,7 +94,7 @@ discard block |
||
| 91 | 94 | * Setter for action. Saves the action to the controller. |
| 92 | 95 | * |
| 93 | 96 | * @param mixed $action action config. |
| 94 | - * @param null $postfix |
|
| 97 | + * @param string $postfix |
|
| 95 | 98 | */ |
| 96 | 99 | public function setAction($action, $postfix = null) |
| 97 | 100 | { |
@@ -12,7 +12,6 @@ |
||
| 12 | 12 | namespace hipanel\actions; |
| 13 | 13 | |
| 14 | 14 | use Yii; |
| 15 | -use yii\base\Model; |
|
| 16 | 15 | use yii\data\ActiveDataProvider; |
| 17 | 16 | use yii\web\BadRequestHttpException; |
| 18 | 17 | use yii\web\NotFoundHttpException; |
@@ -68,7 +68,6 @@ discard block |
||
| 68 | 68 | } |
| 69 | 69 | |
| 70 | 70 | /** |
| 71 | - * @param string $submodel the submodel that will be added to the ClassName |
|
| 72 | 71 | * @return string Main Model class name |
| 73 | 72 | */ |
| 74 | 73 | public static function modelClassName() |
@@ -94,7 +93,7 @@ discard block |
||
| 94 | 93 | |
| 95 | 94 | /** |
| 96 | 95 | * @param array $config config to be used to create the [[Model]] |
| 97 | - * @return ActiveRecord|SearchModelTrait Search Model object |
|
| 96 | + * @return ActiveRecord Search Model object |
|
| 98 | 97 | */ |
| 99 | 98 | public static function searchModel($config = []) |
| 100 | 99 | { |
@@ -199,11 +198,17 @@ discard block |
||
| 199 | 198 | return $this->render('index'); |
| 200 | 199 | } |
| 201 | 200 | |
| 201 | + /** |
|
| 202 | + * @param string $id |
|
| 203 | + */ |
|
| 202 | 204 | public function setInternalAction($id, $action) |
| 203 | 205 | { |
| 204 | 206 | $this->_internalActions[$id] = $action; |
| 205 | 207 | } |
| 206 | 208 | |
| 209 | + /** |
|
| 210 | + * @param string $id |
|
| 211 | + */ |
|
| 207 | 212 | public function hasInternalAction($id) |
| 208 | 213 | { |
| 209 | 214 | return array_key_exists($id, $this->_internalActions); |
@@ -20,7 +20,6 @@ discard block |
||
| 20 | 20 | { |
| 21 | 21 | /** |
| 22 | 22 | * AHNAMES Lang to Yii2 i18n. |
| 23 | - * @param null $txt |
|
| 24 | 23 | * @param string $path |
| 25 | 24 | * |
| 26 | 25 | * @return string |
@@ -31,6 +30,9 @@ discard block |
||
| 31 | 30 | return $res === $str ? Yii::t($str, $path) : $res; |
| 32 | 31 | } |
| 33 | 32 | |
| 33 | + /** |
|
| 34 | + * @return string |
|
| 35 | + */ |
|
| 34 | 36 | public static function lang($txt = null, $path = 'app') |
| 35 | 37 | { |
| 36 | 38 | return preg_replace_callback('/{(lang):([^}]*)}/i', ['hipanel\base\Lang', 'translate'], $txt); |
@@ -35,11 +35,18 @@ |
||
| 35 | 35 | |
| 36 | 36 | public $urlCallback; |
| 37 | 37 | |
| 38 | + /** |
|
| 39 | + * @param string $type |
|
| 40 | + */ |
|
| 38 | 41 | public function getColor($type) |
| 39 | 42 | { |
| 40 | 43 | return $this->colors[$type] ?: $type; |
| 41 | 44 | } |
| 42 | 45 | |
| 46 | + /** |
|
| 47 | + * @param Model $model |
|
| 48 | + * @param integer $index |
|
| 49 | + */ |
|
| 43 | 50 | public function getUrl($model, $key, $index) |
| 44 | 51 | { |
| 45 | 52 | return $this->urlCallback ? call_user_func($this->urlCallback, $model, $key, $index) : null; |
@@ -13,7 +13,6 @@ |
||
| 13 | 13 | |
| 14 | 14 | use yii\base\Widget; |
| 15 | 15 | use yii\helpers\Html; |
| 16 | -use yii\helpers\Json; |
|
| 17 | 16 | |
| 18 | 17 | class BulkButtons extends Widget |
| 19 | 18 | { |
@@ -34,6 +34,9 @@ |
||
| 34 | 34 | return $this->_emailHash; |
| 35 | 35 | } |
| 36 | 36 | |
| 37 | + /** |
|
| 38 | + * @param string $email |
|
| 39 | + */ |
|
| 37 | 40 | public static function hashEmail($email) |
| 38 | 41 | { |
| 39 | 42 | $email = strtolower(trim($email)); |