@@ -109,6 +109,10 @@ |
||
109 | 109 | return $this->createRequest($query); |
110 | 110 | } |
111 | 111 | |
112 | + /** |
|
113 | + * @param string $action |
|
114 | + * @param string $table |
|
115 | + */ |
|
112 | 116 | public function perform($action, $table, $body, $options = []) |
113 | 117 | { |
114 | 118 | $query = $this->createQuery($action, $table, $options)->body($body); |
@@ -68,6 +68,9 @@ discard block |
||
68 | 68 | return $this->uri; |
69 | 69 | } |
70 | 70 | |
71 | + /** |
|
72 | + * @return string |
|
73 | + */ |
|
71 | 74 | public function getFullUri() |
72 | 75 | { |
73 | 76 | if ($this->fullUri === null) { |
@@ -82,6 +85,9 @@ discard block |
||
82 | 85 | return ($this->isFullUri($this->uri) ? '' : $this->getDb()->getBaseUri()) . $this->uri; |
83 | 86 | } |
84 | 87 | |
88 | + /** |
|
89 | + * @param string $uri |
|
90 | + */ |
|
85 | 91 | public function isFullUri($uri) |
86 | 92 | { |
87 | 93 | return preg_match('/^https?:\\/\\//i', $uri); |
@@ -26,7 +26,7 @@ discard block |
||
26 | 26 | * By default, the "hiart" application component is used as the database connection. |
27 | 27 | * You may override this method if you want to use a different database connection. |
28 | 28 | * |
29 | - * @return Connection the database connection used by this AR class |
|
29 | + * @return ConnectionInterface the database connection used by this AR class |
|
30 | 30 | */ |
31 | 31 | public static function getDb() |
32 | 32 | { |
@@ -128,7 +128,7 @@ discard block |
||
128 | 128 | * |
129 | 129 | * @throws InvalidConfigException |
130 | 130 | * |
131 | - * @return string|callable|array |
|
131 | + * @return string |
|
132 | 132 | * |
133 | 133 | * @author SilverFire |
134 | 134 | */ |
@@ -316,6 +316,9 @@ discard block |
||
316 | 316 | return $result === false ? false : true; |
317 | 317 | } |
318 | 318 | |
319 | + /** |
|
320 | + * @param string $defaultScenario |
|
321 | + */ |
|
319 | 322 | public function performScenario($defaultScenario, $data, array $options = []) |
320 | 323 | { |
321 | 324 | $action = $this->getScenarioAction($defaultScenario); |
@@ -323,6 +326,9 @@ discard block |
||
323 | 326 | return static::perform($action, $data, $options); |
324 | 327 | } |
325 | 328 | |
329 | + /** |
|
330 | + * @param string $action |
|
331 | + */ |
|
326 | 332 | public static function perform($action, $data, array $options = []) |
327 | 333 | { |
328 | 334 | return static::getDb()->createCommand()->perform($action, static::from(), $data, $options); |
@@ -130,6 +130,9 @@ |
||
130 | 130 | return $this->_viewPath; |
131 | 131 | } |
132 | 132 | |
133 | + /** |
|
134 | + * @param string $file |
|
135 | + */ |
|
133 | 136 | public function render($file, $data) |
134 | 137 | { |
135 | 138 | return Yii::$app->view->render($file, $data, $this); |
@@ -133,6 +133,10 @@ |
||
133 | 133 | return $this; |
134 | 134 | } |
135 | 135 | |
136 | + /** |
|
137 | + * @param string $name |
|
138 | + * @param boolean $value |
|
139 | + */ |
|
136 | 140 | public function addOption($name, $value) |
137 | 141 | { |
138 | 142 | if (!isset($this->options[$name])) { |