@@ -4,18 +4,16 @@ |
||
| 4 | 4 | |
| 5 | 5 | namespace Canvas\Api\Controllers; |
| 6 | 6 | |
| 7 | -use Canvas\Models\Users; |
|
| 8 | -use Phalcon\Http\Response; |
|
| 9 | -use Phalcon\Validation\Validator\PresenceOf; |
|
| 10 | -use Canvas\Exception\BadRequestHttpException; |
|
| 11 | -use Canvas\Exception\ServerErrorHttpException; |
|
| 12 | 7 | use Baka\Auth\UsersController as BakaUsersController; |
| 13 | 8 | use Canvas\Contracts\Controllers\ProcessOutputMapperTrait; |
| 14 | 9 | use Canvas\Dto\User as UserDto; |
| 15 | 10 | use Canvas\Http\Exception\InternalServerErrorException; |
| 16 | 11 | use Canvas\Mapper\UserMapper; |
| 17 | -use Canvas\Validation as CanvasValidation; |
|
| 12 | +use Canvas\Models\Users; |
|
| 18 | 13 | use Canvas\Models\UsersAssociatedApps; |
| 14 | +use Canvas\Validation as CanvasValidation; |
|
| 15 | +use Phalcon\Http\Response; |
|
| 16 | +use Phalcon\Validation\Validator\PresenceOf; |
|
| 19 | 17 | |
| 20 | 18 | /** |
| 21 | 19 | * Class UsersController. |
@@ -328,7 +328,7 @@ discard block |
||
| 328 | 328 | /** |
| 329 | 329 | * Get the User key for redis. |
| 330 | 330 | * |
| 331 | - * @return string |
|
| 331 | + * @return integer |
|
| 332 | 332 | */ |
| 333 | 333 | public function getKey() : int |
| 334 | 334 | { |
@@ -382,7 +382,6 @@ discard block |
||
| 382 | 382 | /** |
| 383 | 383 | * Strat a free trial. |
| 384 | 384 | * |
| 385 | - * @param Users $user |
|
| 386 | 385 | * @return Subscription |
| 387 | 386 | */ |
| 388 | 387 | public function startFreeTrial() : Subscription |
@@ -515,7 +514,7 @@ discard block |
||
| 515 | 514 | /** |
| 516 | 515 | * update user role for the specific app. |
| 517 | 516 | * |
| 518 | - * @return void |
|
| 517 | + * @return boolean |
|
| 519 | 518 | */ |
| 520 | 519 | protected function updatePermissionRoles(): bool |
| 521 | 520 | { |
@@ -590,7 +589,7 @@ discard block |
||
| 590 | 589 | /** |
| 591 | 590 | * Overwrite the relationship. |
| 592 | 591 | * |
| 593 | - * @return void |
|
| 592 | + * @return string|null |
|
| 594 | 593 | */ |
| 595 | 594 | public function getPhoto() |
| 596 | 595 | { |
@@ -600,7 +599,6 @@ discard block |
||
| 600 | 599 | /** |
| 601 | 600 | * Update the user current default company. |
| 602 | 601 | * |
| 603 | - * @param integer $companyId |
|
| 604 | 602 | * @return void |
| 605 | 603 | */ |
| 606 | 604 | public function switchDefaultCompanyByBranch(int $branchId): void |
@@ -3,26 +3,25 @@ |
||
| 3 | 3 | |
| 4 | 4 | namespace Canvas\Models; |
| 5 | 5 | |
| 6 | +use Baka\Auth\Models\Users as BakUser; |
|
| 7 | +use Baka\Database\Contracts\HashTableTrait; |
|
| 8 | +use Canvas\Auth\App as AppAuth; |
|
| 9 | +use Canvas\Contracts\Notifications\NotifiableTrait; |
|
| 10 | +use Canvas\Hashing\Password; |
|
| 11 | +use Canvas\Traits\EventManagerAwareTrait; |
|
| 12 | +use Canvas\Traits\FileSystemModelTrait; |
|
| 6 | 13 | use Canvas\Traits\PermissionsTrait; |
| 7 | 14 | use Canvas\Traits\SubscriptionPlanLimitTrait; |
| 8 | -use Phalcon\Cashier\Billable; |
|
| 15 | +use Canvas\Validations\PasswordValidation; |
|
| 9 | 16 | use Carbon\Carbon; |
| 17 | +use Exception; |
|
| 18 | +use Phalcon\Cashier\Billable; |
|
| 19 | +use Phalcon\Di; |
|
| 20 | +use Phalcon\Security\Random; |
|
| 10 | 21 | use Phalcon\Validation; |
| 11 | 22 | use Phalcon\Validation\Validator\Email; |
| 12 | 23 | use Phalcon\Validation\Validator\PresenceOf; |
| 13 | -use Phalcon\Validation\Validator\Regex; |
|
| 14 | 24 | use Phalcon\Validation\Validator\Uniqueness; |
| 15 | -use Canvas\Traits\FileSystemModelTrait; |
|
| 16 | -use Phalcon\Security\Random; |
|
| 17 | -use Baka\Database\Contracts\HashTableTrait; |
|
| 18 | -use Canvas\Contracts\Notifications\NotifiableTrait; |
|
| 19 | -use Canvas\Traits\EventManagerAwareTrait; |
|
| 20 | -use Phalcon\Di; |
|
| 21 | -use Canvas\Auth\App as AppAuth; |
|
| 22 | -use Exception; |
|
| 23 | -use Canvas\Validations\PasswordValidation; |
|
| 24 | -use Baka\Auth\Models\Users as BakUser; |
|
| 25 | -use Canvas\Hashing\Password; |
|
| 26 | 25 | |
| 27 | 26 | /** |
| 28 | 27 | * Class Users. |
@@ -70,7 +70,6 @@ |
||
| 70 | 70 | /** |
| 71 | 71 | * Given the weebhook id, we run a test for it. |
| 72 | 72 | * |
| 73 | - * @param integer $id |
|
| 74 | 73 | * @return Response |
| 75 | 74 | */ |
| 76 | 75 | public function execute(string $name): Response |
@@ -7,8 +7,8 @@ |
||
| 7 | 7 | use Canvas\Http\Exception\UnprocessableEntityException; |
| 8 | 8 | use Canvas\Models\UserWebhooks; |
| 9 | 9 | use Canvas\Validation; |
| 10 | -use Phalcon\Http\Response; |
|
| 11 | 10 | use Canvas\Webhooks; |
| 11 | +use Phalcon\Http\Response; |
|
| 12 | 12 | use Phalcon\Validation\Validator\PresenceOf; |
| 13 | 13 | use function Canvas\Core\isJson; |
| 14 | 14 | |
@@ -145,6 +145,7 @@ |
||
| 145 | 145 | /** |
| 146 | 146 | * Get element by Id. |
| 147 | 147 | * |
| 148 | + * @param integer $id |
|
| 148 | 149 | * @return Webhooks |
| 149 | 150 | */ |
| 150 | 151 | public static function getById($id): self |
@@ -4,8 +4,8 @@ |
||
| 4 | 4 | namespace Canvas\Models; |
| 5 | 5 | |
| 6 | 6 | use Phalcon\Di; |
| 7 | -use Phalcon\Validation\Validator\Url; |
|
| 8 | 7 | use Phalcon\Validation; |
| 8 | +use Phalcon\Validation\Validator\Url; |
|
| 9 | 9 | |
| 10 | 10 | class UserWebhooks extends AbstractModel |
| 11 | 11 | { |
@@ -4,8 +4,8 @@ |
||
| 4 | 4 | |
| 5 | 5 | namespace Canvas\Traits; |
| 6 | 6 | |
| 7 | -use Canvas\Models\SystemModules; |
|
| 8 | 7 | use Canvas\Models\Notifications; |
| 8 | +use Canvas\Models\SystemModules; |
|
| 9 | 9 | use Phalcon\Di; |
| 10 | 10 | |
| 11 | 11 | /** |
@@ -72,7 +72,7 @@ |
||
| 72 | 72 | * - pass the data you are sending |
| 73 | 73 | * - then we send it over to the URl. |
| 74 | 74 | * |
| 75 | - * @param string $model |
|
| 75 | + * @param string $module |
|
| 76 | 76 | * @param mixed $data |
| 77 | 77 | * @param string $action |
| 78 | 78 | * @throws Exception |
@@ -4,14 +4,13 @@ |
||
| 4 | 4 | |
| 5 | 5 | namespace Canvas; |
| 6 | 6 | |
| 7 | +use Canvas\Models\SystemModules; |
|
| 7 | 8 | use Canvas\Models\UserWebhooks; |
| 8 | -use Throwable; |
|
| 9 | -use Phalcon\Http\Response; |
|
| 10 | 9 | use GuzzleHttp\Client; |
| 11 | 10 | use Phalcon\Di; |
| 12 | -use Canvas\Models\SystemModules; |
|
| 11 | +use Phalcon\Http\Response; |
|
| 12 | +use Throwable; |
|
| 13 | 13 | use function Canvas\Core\isJson; |
| 14 | -use Canvas\Http\Exception\UnprocessableEntityException; |
|
| 15 | 14 | |
| 16 | 15 | /** |
| 17 | 16 | * Class Validation. |
@@ -4,8 +4,8 @@ |
||
| 4 | 4 | |
| 5 | 5 | namespace Canvas\Middleware; |
| 6 | 6 | |
| 7 | -use Canvas\Traits\TokenTrait; |
|
| 8 | 7 | use Canvas\Traits\SubscriptionPlanLimitTrait; |
| 8 | +use Canvas\Traits\TokenTrait; |
|
| 9 | 9 | use Phalcon\Mvc\Micro\MiddlewareInterface; |
| 10 | 10 | |
| 11 | 11 | /** |
@@ -142,7 +142,7 @@ discard block |
||
| 142 | 142 | * Get System Module by its model_name. |
| 143 | 143 | * |
| 144 | 144 | * @deprecated v2 |
| 145 | - * @param string $model_name |
|
| 145 | + * @param string $modelName |
|
| 146 | 146 | * @return ModelInterface |
| 147 | 147 | */ |
| 148 | 148 | public static function getSystemModuleByModelName(string $modelName): ModelInterface |
@@ -162,7 +162,7 @@ discard block |
||
| 162 | 162 | /** |
| 163 | 163 | * Get System Module by its model_name. |
| 164 | 164 | * |
| 165 | - * @param string $model_name |
|
| 165 | + * @param string $modelName |
|
| 166 | 166 | * @return ModelInterface |
| 167 | 167 | */ |
| 168 | 168 | public static function getByModelName(string $modelName): ModelInterface |
@@ -200,7 +200,6 @@ discard block |
||
| 200 | 200 | /** |
| 201 | 201 | * Get System Module by id. |
| 202 | 202 | * |
| 203 | - * @param int $id |
|
| 204 | 203 | * @return ModelInterface |
| 205 | 204 | */ |
| 206 | 205 | public static function getBySlug(string $slug): ModelInterface |
@@ -3,8 +3,8 @@ |
||
| 3 | 3 | |
| 4 | 4 | namespace Canvas\Models; |
| 5 | 5 | |
| 6 | -use Phalcon\Di; |
|
| 7 | 6 | use Canvas\Http\Exception\InternalServerErrorException; |
| 7 | +use Phalcon\Di; |
|
| 8 | 8 | use Phalcon\Mvc\ModelInterface; |
| 9 | 9 | |
| 10 | 10 | class SystemModules extends AbstractModel |
@@ -389,7 +389,6 @@ |
||
| 389 | 389 | * Set the email config array we are going to be sending. |
| 390 | 390 | * |
| 391 | 391 | * @todo deprecated move to notifications |
| 392 | - * @param String $emailAction |
|
| 393 | 392 | * @param Users $user |
| 394 | 393 | * @deprecated version 1 |
| 395 | 394 | * @return void |
@@ -4,30 +4,30 @@ |
||
| 4 | 4 | |
| 5 | 5 | namespace Canvas\Api\Controllers; |
| 6 | 6 | |
| 7 | -use Canvas\Models\Users; |
|
| 7 | +use Baka\Auth\Models\Sessions; |
|
| 8 | +use Baka\Auth\Models\Users as BakaUsers; |
|
| 9 | +use Canvas\Auth\Factory; |
|
| 10 | +use Canvas\Exception\ModelException; |
|
| 11 | +use Canvas\Http\Exception\InternalServerErrorException; |
|
| 12 | +use Canvas\Http\Exception\NotFoundException; |
|
| 8 | 13 | use Canvas\Models\Sources; |
| 9 | 14 | use Canvas\Models\UserLinkedSources; |
| 10 | -use Canvas\Exception\ModelException; |
|
| 11 | -use Baka\Auth\Models\Users as BakaUsers; |
|
| 15 | +use Canvas\Models\Users; |
|
| 16 | +use Canvas\Notifications\PasswordUpdate; |
|
| 17 | +use Canvas\Notifications\ResetPassword; |
|
| 18 | +use Canvas\Notifications\Signup; |
|
| 19 | +use Canvas\Notifications\UpdateEmail; |
|
| 12 | 20 | use Canvas\Traits\AuthTrait; |
| 13 | 21 | use Canvas\Traits\SocialLoginTrait; |
| 14 | -use Canvas\Http\Exception\NotFoundException; |
|
| 22 | +use Canvas\Traits\TokenTrait; |
|
| 23 | +use Canvas\Validation as CanvasValidation; |
|
| 24 | +use Canvas\Validations\PasswordValidation; |
|
| 15 | 25 | use Exception; |
| 16 | 26 | use Phalcon\Http\Response; |
| 17 | 27 | use Phalcon\Validation\Validator\Confirmation; |
| 18 | 28 | use Phalcon\Validation\Validator\Email as EmailValidator; |
| 19 | 29 | use Phalcon\Validation\Validator\PresenceOf; |
| 20 | 30 | use Phalcon\Validation\Validator\StringLength; |
| 21 | -use Baka\Auth\Models\Sessions; |
|
| 22 | -use Canvas\Auth\Factory; |
|
| 23 | -use Canvas\Http\Exception\InternalServerErrorException; |
|
| 24 | -use Canvas\Validation as CanvasValidation; |
|
| 25 | -use Canvas\Notifications\ResetPassword; |
|
| 26 | -use Canvas\Notifications\PasswordUpdate; |
|
| 27 | -use Canvas\Notifications\Signup; |
|
| 28 | -use Canvas\Notifications\UpdateEmail; |
|
| 29 | -use Canvas\Validations\PasswordValidation; |
|
| 30 | -use Canvas\Traits\TokenTrait; |
|
| 31 | 31 | |
| 32 | 32 | /** |
| 33 | 33 | * Class AuthController. |