#68 - finish notification class. Content notification on validate brief working
This commit is contained in:
parent
3fb043210e
commit
fa36c9ef4a
12 changed files with 246 additions and 24 deletions
27
public/site/plugins/classes/Author.php
Normal file
27
public/site/plugins/classes/Author.php
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
<?php
|
||||
|
||||
namespace adrienpayet;
|
||||
|
||||
class Author
|
||||
{
|
||||
protected string $name;
|
||||
protected string $email;
|
||||
protected string $uuid;
|
||||
protected string $role;
|
||||
|
||||
public function __construct($author) {
|
||||
$this->name = (string) $author->name();
|
||||
$this->email = (string) $author->email();
|
||||
$this->uuid = (string) $author->uuid();
|
||||
$this->role = (string) $author->role();
|
||||
}
|
||||
|
||||
public function toArray() {
|
||||
return [
|
||||
"name" => $this->name,
|
||||
"email" => $this->email,
|
||||
"uuid" => $this->uuid,
|
||||
"role" => $this->role,
|
||||
];
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue