-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
151 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
src/Domain/Profile/models/ProfilePatchActivationRequest.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
<?php | ||
|
||
namespace App\Domain\Profile\models; | ||
|
||
use App\Domain\Common\models\AuthorizationRequestTrait; | ||
use Psr\Http\Message\RequestInterface; | ||
|
||
class ProfilePatchActivationRequest | ||
{ | ||
private ?string $token; | ||
private ?string $profileUid; | ||
private ?bool $activate; | ||
|
||
use AuthorizationRequestTrait; | ||
|
||
public function __construct(RequestInterface $request, array $arg) | ||
{ | ||
$this->token = $this->extractToken($request); | ||
$this->profileUid = $arg['uid']; | ||
$this->activate = json_decode($request->getBody(), true)['activate']; | ||
} | ||
|
||
public function getToken(): ?string | ||
{ | ||
return $this->token; | ||
} | ||
|
||
public function setToken(?string $token): void | ||
{ | ||
$this->token = $token; | ||
} | ||
|
||
public function getProfileUid(): ?string | ||
{ | ||
return $this->profileUid; | ||
} | ||
|
||
public function setProfileUid(?string $profileUid): void | ||
{ | ||
$this->profileUid = $profileUid; | ||
} | ||
|
||
public function getActivate(): ?bool | ||
{ | ||
return $this->activate; | ||
} | ||
|
||
public function setActivate(?bool $activate): void | ||
{ | ||
$this->activate = $activate; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters