@@ -13,6 +13,9 @@ |
||
13 | 13 | // Abstract Class |
14 | 14 | class MailCoreModel extends Framework\Mvc\Model\Engine\Model |
15 | 15 | { |
16 | + /** |
|
17 | + * @param string $iProfileId |
|
18 | + */ |
|
16 | 19 | public static function countUnreadMsg($iProfileId) |
17 | 20 | { |
18 | 21 | $rStmt = Db::getInstance()->prepare('SELECT COUNT(status) AS unread FROM' . Db::prefix('Messages') . |
@@ -84,7 +84,7 @@ |
||
84 | 84 | * @param string $sApiParams Parameters to send to the API. |
85 | 85 | * @param string $sApiVersion Version of the API it will use. If fails from the API server, it will ignore it. |
86 | 86 | * |
87 | - * @return void |
|
87 | + * @return string|boolean |
|
88 | 88 | */ |
89 | 89 | private function getApiResults($sApiUrl, $sApiParams, $sApiVersion) |
90 | 90 | { |
@@ -60,6 +60,9 @@ discard block |
||
60 | 60 | $this->sRoutePath = PH7_PATH_APP_CONFIG . 'routes/' . $this->sDefLangRoute . '.xml'; |
61 | 61 | } |
62 | 62 | |
63 | + /** |
|
64 | + * @param string $sModsDirModFolder |
|
65 | + */ |
|
63 | 66 | public function setPath($sModsDirModFolder) |
64 | 67 | { |
65 | 68 | $this->sModsDirModFolder = $sModsDirModFolder; |
@@ -277,7 +280,7 @@ discard block |
||
277 | 280 | * Note: This method is valid only for public methods, it is not necessary to check the private methods. |
278 | 281 | * @param string $sSwitch The check constant. |
279 | 282 | * |
280 | - * @return string Returns the constant if it is correct, otherwise an error message with exit() function. |
|
283 | + * @return integer|null Returns the constant if it is correct, otherwise an error message with exit() function. |
|
281 | 284 | */ |
282 | 285 | private function checkParam($sSwitch) |
283 | 286 | { |
@@ -162,7 +162,7 @@ |
||
162 | 162 | /** |
163 | 163 | * @param stdClass $oProfile |
164 | 164 | * |
165 | - * @return bool |
|
165 | + * @return string |
|
166 | 166 | */ |
167 | 167 | private function getBirthDate(stdClass $oProfile) |
168 | 168 | { |
@@ -118,7 +118,7 @@ discard block |
||
118 | 118 | /** |
119 | 119 | * Authenticate user with Twitter. |
120 | 120 | * |
121 | - * @return bool Authentication successful. |
|
121 | + * @return boolean|null Authentication successful. |
|
122 | 122 | */ |
123 | 123 | public function auth() |
124 | 124 | { |
@@ -289,7 +289,7 @@ discard block |
||
289 | 289 | /** |
290 | 290 | * Obtain an access token from Twitter. |
291 | 291 | * |
292 | - * @return bool Returns FALSE if request failed. |
|
292 | + * @return null|false Returns FALSE if request failed. |
|
293 | 293 | */ |
294 | 294 | private function getAccessToken() |
295 | 295 | { |
@@ -67,7 +67,7 @@ |
||
67 | 67 | } |
68 | 68 | |
69 | 69 | /** |
70 | - * @return int Return the love amount. |
|
70 | + * @return string Return the love amount. |
|
71 | 71 | */ |
72 | 72 | public function get() |
73 | 73 | { |
@@ -12,6 +12,13 @@ discard block |
||
12 | 12 | |
13 | 13 | class PictureModel extends PictureCoreModel |
14 | 14 | { |
15 | + /** |
|
16 | + * @param string $iProfileId |
|
17 | + * @param string $sTitle |
|
18 | + * @param string $sDescription |
|
19 | + * @param string $sThumb |
|
20 | + * @param string $sCreatedDate |
|
21 | + */ |
|
15 | 22 | public function addAlbum($iProfileId, $sTitle, $sDescription, $sThumb, $sCreatedDate, $iApproved = 1) |
16 | 23 | { |
17 | 24 | $rStmt = Db::getInstance()->prepare('INSERT INTO' . Db::prefix('AlbumsPictures') . '(profileId, name, description, thumb, createdDate, approved) |
@@ -27,6 +34,13 @@ discard block |
||
27 | 34 | return $rStmt->execute(); |
28 | 35 | } |
29 | 36 | |
37 | + /** |
|
38 | + * @param string $iProfileId |
|
39 | + * @param integer $iAlbumId |
|
40 | + * @param string $sTitle |
|
41 | + * @param string $sFile |
|
42 | + * @param string $sCreatedDate |
|
43 | + */ |
|
30 | 44 | public function addPhoto($iProfileId, $iAlbumId, $sTitle, $sDescription, $sFile, $sCreatedDate, $iApproved = 1) |
31 | 45 | { |
32 | 46 | $rStmt = Db::getInstance()->prepare('INSERT INTO' . Db::prefix('Pictures') . '(profileId, albumId, title, description, file, createdDate, approved) |
@@ -52,6 +66,9 @@ discard block |
||
52 | 66 | return $rStmt->execute(); |
53 | 67 | } |
54 | 68 | |
69 | + /** |
|
70 | + * @param string $iProfileId |
|
71 | + */ |
|
55 | 72 | public function getAlbumsName($iProfileId) |
56 | 73 | { |
57 | 74 | $this->cache->start(self::CACHE_GROUP, 'albumName' . $iProfileId, static::CACHE_TIME); |
@@ -69,6 +86,13 @@ discard block |
||
69 | 86 | return $oData; |
70 | 87 | } |
71 | 88 | |
89 | + /** |
|
90 | + * @param string $iProfileId |
|
91 | + * @param string $iAlbumId |
|
92 | + * @param string $iPictureId |
|
93 | + * @param integer $iOffset |
|
94 | + * @param integer $iLimit |
|
95 | + */ |
|
72 | 96 | public function photo($iProfileId, $iAlbumId, $iPictureId = null, $iApproved = 1, $iOffset, $iLimit) |
73 | 97 | { |
74 | 98 | $this->cache->start(self::CACHE_GROUP, 'photo' . $iProfileId . $iAlbumId . $iPictureId . $iApproved . $iOffset . $iLimit, static::CACHE_TIME); |
@@ -135,6 +159,13 @@ discard block |
||
135 | 159 | return $iData; |
136 | 160 | } |
137 | 161 | |
162 | + /** |
|
163 | + * @param string $iProfileId |
|
164 | + * @param integer $iAlbumId |
|
165 | + * @param string $sTitle |
|
166 | + * @param string $sDescription |
|
167 | + * @param string $sUpdatedDate |
|
168 | + */ |
|
138 | 169 | public function updateAlbum($iProfileId, $iAlbumId, $sTitle, $sDescription, $sUpdatedDate) |
139 | 170 | { |
140 | 171 | $rStmt = Db::getInstance()->prepare('UPDATE' . Db::prefix('AlbumsPictures') . |
@@ -149,6 +180,14 @@ discard block |
||
149 | 180 | return $rStmt->execute(); |
150 | 181 | } |
151 | 182 | |
183 | + /** |
|
184 | + * @param string $iProfileId |
|
185 | + * @param integer $iAlbumId |
|
186 | + * @param integer $iPictureId |
|
187 | + * @param string $sTitle |
|
188 | + * @param string $sDescription |
|
189 | + * @param string $sUpdatedDate |
|
190 | + */ |
|
152 | 191 | public function updatePhoto($iProfileId, $iAlbumId, $iPictureId, $sTitle, $sDescription, $sUpdatedDate) |
153 | 192 | { |
154 | 193 | $rStmt = Db::getInstance()->prepare('UPDATE' . Db::prefix('Pictures') . |
@@ -12,6 +12,10 @@ discard block |
||
12 | 12 | |
13 | 13 | class VideoModel extends VideoCoreModel |
14 | 14 | { |
15 | + /** |
|
16 | + * @param string $sTitle |
|
17 | + * @param string $sThumb |
|
18 | + */ |
|
15 | 19 | public function addAlbum($iProfileId, $sTitle, $sDescription, $sThumb, $sCreatedDate, $iApproved = 1) |
16 | 20 | { |
17 | 21 | $rStmt = Db::getInstance()->prepare('INSERT INTO' . Db::prefix('AlbumsVideos') . '(profileId, name, description, thumb, createdDate, approved) |
@@ -27,6 +31,14 @@ discard block |
||
27 | 31 | return $rStmt->execute(); |
28 | 32 | } |
29 | 33 | |
34 | + /** |
|
35 | + * @param string $iProfileId |
|
36 | + * @param integer $iAlbumId |
|
37 | + * @param string $sTitle |
|
38 | + * @param string $sFile |
|
39 | + * @param string $sThumb |
|
40 | + * @param string $sCreatedDate |
|
41 | + */ |
|
30 | 42 | public function addVideo($iProfileId, $iAlbumId, $sTitle, $sDescription, $sFile, $sThumb, $sDuration, $sCreatedDate, $iApproved = 1) |
31 | 43 | { |
32 | 44 | $rStmt = Db::getInstance()->prepare('INSERT INTO' . Db::prefix('Videos') . '(profileId, albumId, title, description, file, thumb, duration, createdDate, approved) |
@@ -54,6 +66,9 @@ discard block |
||
54 | 66 | return $rStmt->execute(); |
55 | 67 | } |
56 | 68 | |
69 | + /** |
|
70 | + * @param string $iProfileId |
|
71 | + */ |
|
57 | 72 | public function getAlbumsName($iProfileId) |
58 | 73 | { |
59 | 74 | $this->cache->start(self::CACHE_GROUP, 'albumName' . $iProfileId, static::CACHE_TIME); |
@@ -71,6 +86,13 @@ discard block |
||
71 | 86 | return $oData; |
72 | 87 | } |
73 | 88 | |
89 | + /** |
|
90 | + * @param string $iProfileId |
|
91 | + * @param string $iAlbumId |
|
92 | + * @param string $iVideoId |
|
93 | + * @param integer $iOffset |
|
94 | + * @param integer $iLimit |
|
95 | + */ |
|
74 | 96 | public function video($iProfileId, $iAlbumId, $iVideoId = null, $iApproved = 1, $iOffset, $iLimit) |
75 | 97 | { |
76 | 98 | $this->cache->start(self::CACHE_GROUP, 'video' . $iProfileId . $iAlbumId . $iVideoId . $iApproved . $iOffset . $iLimit, static::CACHE_TIME); |
@@ -137,6 +159,10 @@ discard block |
||
137 | 159 | return $iData; |
138 | 160 | } |
139 | 161 | |
162 | + /** |
|
163 | + * @param integer $iAlbumId |
|
164 | + * @param string $sTitle |
|
165 | + */ |
|
140 | 166 | public function updateAlbum($iProfileId, $iAlbumId, $sTitle, $sDescription, $sUpdatedDate) |
141 | 167 | { |
142 | 168 | $rStmt = Db::getInstance()->prepare('UPDATE' . Db::prefix('AlbumsVideos') . 'SET name =:name, description =:description, updatedDate =:updatedDate |
@@ -151,6 +177,14 @@ discard block |
||
151 | 177 | return $rStmt->execute(); |
152 | 178 | } |
153 | 179 | |
180 | + /** |
|
181 | + * @param string $iProfileId |
|
182 | + * @param integer $iAlbumId |
|
183 | + * @param integer $iVideoId |
|
184 | + * @param string $sTitle |
|
185 | + * @param string $sDescription |
|
186 | + * @param string $sUpdatedDate |
|
187 | + */ |
|
154 | 188 | public function updateVideo($iProfileId, $iAlbumId, $iVideoId, $sTitle, $sDescription, $sUpdatedDate) |
155 | 189 | { |
156 | 190 | $rStmt = Db::getInstance()->prepare('UPDATE' . Db::prefix('Videos') . 'SET title =:title, description =:description, updatedDate =:updatedDate |
@@ -166,7 +166,7 @@ discard block |
||
166 | 166 | * Gets the data cache. |
167 | 167 | * |
168 | 168 | * @param bool $bPrint Default FALSE |
169 | - * @return bool|int|float|string|array|object Returns the converted cache value if successful, FALSE otherwise. |
|
169 | + * @return \stdClass Returns the converted cache value if successful, FALSE otherwise. |
|
170 | 170 | */ |
171 | 171 | public function get($bPrint = false) |
172 | 172 | { |
@@ -184,7 +184,7 @@ discard block |
||
184 | 184 | * |
185 | 185 | * @param string $sData |
186 | 186 | * |
187 | - * @return string|null|self If the cache is disabled, returns null, otherwise returns this class. |
|
187 | + * @return null|Cache If the cache is disabled, returns null, otherwise returns this class. |
|
188 | 188 | */ |
189 | 189 | public function put($sData) |
190 | 190 | { |