@@ -42,10 +42,10 @@ discard block |
||
42 | 42 | */ |
43 | 43 | private $module; |
44 | 44 | |
45 | - /** |
|
46 | - * @var Api |
|
47 | - */ |
|
48 | - private $api; |
|
45 | + /** |
|
46 | + * @var Api |
|
47 | + */ |
|
48 | + private $api; |
|
49 | 49 | |
50 | 50 | /** |
51 | 51 | * @var User |
@@ -55,17 +55,17 @@ discard block |
||
55 | 55 | /** @var TokenStorageInterface */ |
56 | 56 | private $token_storage; |
57 | 57 | |
58 | - /** |
|
59 | - * AccessRights constructor. |
|
60 | - * @param ContainerInterface $container |
|
61 | - * @param RouterInterface $router |
|
62 | - * @param SessionInterface $session |
|
63 | - * @param RequestStack $request |
|
64 | - * @param TokenStorageInterface $tokenStorage |
|
65 | - * @param Globals $globals |
|
66 | - * @param ModuleService $module |
|
67 | - * @param Api $api |
|
68 | - */ |
|
58 | + /** |
|
59 | + * AccessRights constructor. |
|
60 | + * @param ContainerInterface $container |
|
61 | + * @param RouterInterface $router |
|
62 | + * @param SessionInterface $session |
|
63 | + * @param RequestStack $request |
|
64 | + * @param TokenStorageInterface $tokenStorage |
|
65 | + * @param Globals $globals |
|
66 | + * @param ModuleService $module |
|
67 | + * @param Api $api |
|
68 | + */ |
|
69 | 69 | public function __construct(ContainerInterface $container, RouterInterface $router, SessionInterface $session, RequestStack $request, TokenStorageInterface $tokenStorage, Globals $globals, ModuleService $module, Api $api) |
70 | 70 | { |
71 | 71 | $this->container = $container; |
@@ -77,8 +77,8 @@ discard block |
||
77 | 77 | $this->api = $api; |
78 | 78 | $this->token_storage = $tokenStorage; |
79 | 79 | if ($this->token_storage->getToken() && is_object($this->token_storage->getToken()->getUser()) && $this->token_storage->getToken()->getUser()->getUser()) { |
80 | - $this->user = $this->token_storage->getToken()->getUser()->getUser(); |
|
81 | - } |
|
80 | + $this->user = $this->token_storage->getToken()->getUser()->getUser(); |
|
81 | + } |
|
82 | 82 | } |
83 | 83 | |
84 | 84 | public function onKernelController() |
@@ -119,14 +119,14 @@ discard block |
||
119 | 119 | |
120 | 120 | throw new AccessDeniedException("No access"); |
121 | 121 | } else if ($api === "api" && strpos($route, "login") === false && strpos($route, "register") === false) { |
122 | - if ($this->api->userIslogged($this->request->getCurrentRequest()->get("infos"), $this->request->getCurrentRequest()->get("token")) === false) { |
|
123 | - throw new AccessDeniedException("User is not connected"); |
|
124 | - } |
|
125 | - } |
|
122 | + if ($this->api->userIslogged($this->request->getCurrentRequest()->get("infos"), $this->request->getCurrentRequest()->get("token")) === false) { |
|
123 | + throw new AccessDeniedException("User is not connected"); |
|
124 | + } |
|
125 | + } |
|
126 | 126 | } |
127 | 127 | |
128 | 128 | /** |
129 | - * function that allow to test a right directly in the view |
|
129 | + * function that allow to test a right directly in the view |
|
130 | 130 | * @param string $right |
131 | 131 | * @return bool |
132 | 132 | */ |
@@ -137,9 +137,9 @@ discard block |
||
137 | 137 | |
138 | 138 | $all_rights = array_merge($user_rights, $list_rights); |
139 | 139 | |
140 | - if (in_array("*", $all_rights)) { |
|
141 | - return true; |
|
142 | - } |
|
140 | + if (in_array("*", $all_rights)) { |
|
141 | + return true; |
|
142 | + } |
|
143 | 143 | |
144 | 144 | if (in_array($right, $all_rights)) { |
145 | 145 | return true; |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | } |
150 | 150 | |
151 | 151 | /** |
152 | - * test if route_right is found in users rights |
|
152 | + * test if route_right is found in users rights |
|
153 | 153 | * @param array $route_right |
154 | 154 | * @return bool |
155 | 155 | */ |
@@ -161,8 +161,8 @@ discard block |
||
161 | 161 | $all_rights = array_merge($user_rights, $list_rights); |
162 | 162 | |
163 | 163 | if (in_array("*", $all_rights)) { |
164 | - return true; |
|
165 | - } |
|
164 | + return true; |
|
165 | + } |
|
166 | 166 | |
167 | 167 | foreach ($all_rights as $right) { |
168 | 168 | if (in_array($right, $route_right)) { |
@@ -174,7 +174,7 @@ discard block |
||
174 | 174 | } |
175 | 175 | |
176 | 176 | /** |
177 | - * function that search if the right contain an url or more |
|
177 | + * function that search if the right contain an url or more |
|
178 | 178 | * @param $needle |
179 | 179 | * @param $haystack |
180 | 180 | * @return bool|mixed |
@@ -198,7 +198,7 @@ discard block |
||
198 | 198 | } |
199 | 199 | |
200 | 200 | /** |
201 | - * function that retun a array that contain all user rights or empty array if no right found |
|
201 | + * function that retun a array that contain all user rights or empty array if no right found |
|
202 | 202 | * @return array |
203 | 203 | */ |
204 | 204 | private function getUserRights(): array |
@@ -213,7 +213,7 @@ discard block |
||
213 | 213 | } |
214 | 214 | |
215 | 215 | /** |
216 | - * function that retun a array that contain all rights of rattached list right of the current user |
|
216 | + * function that retun a array that contain all rights of rattached list right of the current user |
|
217 | 217 | * @return array |
218 | 218 | */ |
219 | 219 | private function getRightsListOfUser(): array |
@@ -6,91 +6,91 @@ |
||
6 | 6 | |
7 | 7 | trait CreatedUpdatedTrait |
8 | 8 | { |
9 | - /** |
|
10 | - * @ORM\Column(name="created_at", type="datetime", nullable=true) |
|
11 | - */ |
|
12 | - protected $created_at; |
|
9 | + /** |
|
10 | + * @ORM\Column(name="created_at", type="datetime", nullable=true) |
|
11 | + */ |
|
12 | + protected $created_at; |
|
13 | 13 | |
14 | - /** |
|
15 | - * @ORM\ManyToOne(targetEntity="PiouPiou\RibsAdminBundle\Entity\User") |
|
16 | - * @ORM\JoinColumn(name="created_by", referencedColumnName="id", nullable=false) |
|
17 | - */ |
|
18 | - protected $created_by; |
|
14 | + /** |
|
15 | + * @ORM\ManyToOne(targetEntity="PiouPiou\RibsAdminBundle\Entity\User") |
|
16 | + * @ORM\JoinColumn(name="created_by", referencedColumnName="id", nullable=false) |
|
17 | + */ |
|
18 | + protected $created_by; |
|
19 | 19 | |
20 | - /** |
|
21 | - * @ORM\Column(name="updated_at", type="datetime", nullable=true) |
|
22 | - */ |
|
23 | - protected $updated_at; |
|
20 | + /** |
|
21 | + * @ORM\Column(name="updated_at", type="datetime", nullable=true) |
|
22 | + */ |
|
23 | + protected $updated_at; |
|
24 | 24 | |
25 | - /** |
|
26 | - * @ORM\ManyToOne(targetEntity="PiouPiou\RibsAdminBundle\Entity\User") |
|
27 | - * @ORM\JoinColumn(name="updated_by", referencedColumnName="id", nullable=false) |
|
28 | - */ |
|
29 | - protected $updated_by; |
|
25 | + /** |
|
26 | + * @ORM\ManyToOne(targetEntity="PiouPiou\RibsAdminBundle\Entity\User") |
|
27 | + * @ORM\JoinColumn(name="updated_by", referencedColumnName="id", nullable=false) |
|
28 | + */ |
|
29 | + protected $updated_by; |
|
30 | 30 | |
31 | - /** |
|
32 | - * @return mixed |
|
33 | - */ |
|
34 | - public function getCreatedAt() |
|
35 | - { |
|
36 | - return $this->created_at; |
|
37 | - } |
|
31 | + /** |
|
32 | + * @return mixed |
|
33 | + */ |
|
34 | + public function getCreatedAt() |
|
35 | + { |
|
36 | + return $this->created_at; |
|
37 | + } |
|
38 | 38 | |
39 | - /** |
|
40 | - * @param mixed $created_at |
|
41 | - */ |
|
42 | - public function setCreatedAt($created_at) |
|
43 | - { |
|
44 | - $this->created_at = $created_at; |
|
45 | - } |
|
39 | + /** |
|
40 | + * @param mixed $created_at |
|
41 | + */ |
|
42 | + public function setCreatedAt($created_at) |
|
43 | + { |
|
44 | + $this->created_at = $created_at; |
|
45 | + } |
|
46 | 46 | |
47 | - /** |
|
48 | - * @return mixed |
|
49 | - */ |
|
50 | - public function getCreatedBy() |
|
51 | - { |
|
52 | - return $this->created_by; |
|
53 | - } |
|
47 | + /** |
|
48 | + * @return mixed |
|
49 | + */ |
|
50 | + public function getCreatedBy() |
|
51 | + { |
|
52 | + return $this->created_by; |
|
53 | + } |
|
54 | 54 | |
55 | - /** |
|
56 | - * @ORM\PrePersist |
|
57 | - * @param mixed $created_by |
|
58 | - */ |
|
59 | - public function setCreatedBy($created_by) |
|
60 | - { |
|
61 | - $this->created_by = $created_by; |
|
62 | - } |
|
55 | + /** |
|
56 | + * @ORM\PrePersist |
|
57 | + * @param mixed $created_by |
|
58 | + */ |
|
59 | + public function setCreatedBy($created_by) |
|
60 | + { |
|
61 | + $this->created_by = $created_by; |
|
62 | + } |
|
63 | 63 | |
64 | - /** |
|
65 | - * @return mixed |
|
66 | - */ |
|
67 | - public function getUpdatedAt() |
|
68 | - { |
|
69 | - return $this->updated_at; |
|
70 | - } |
|
64 | + /** |
|
65 | + * @return mixed |
|
66 | + */ |
|
67 | + public function getUpdatedAt() |
|
68 | + { |
|
69 | + return $this->updated_at; |
|
70 | + } |
|
71 | 71 | |
72 | - /** |
|
73 | - * @param mixed $updated_at |
|
74 | - */ |
|
75 | - public function setUpdatedAt($updated_at) |
|
76 | - { |
|
77 | - $this->updated_at = $updated_at; |
|
78 | - } |
|
72 | + /** |
|
73 | + * @param mixed $updated_at |
|
74 | + */ |
|
75 | + public function setUpdatedAt($updated_at) |
|
76 | + { |
|
77 | + $this->updated_at = $updated_at; |
|
78 | + } |
|
79 | 79 | |
80 | - /** |
|
81 | - * @return mixed |
|
82 | - */ |
|
83 | - public function getUpdatedBy() |
|
84 | - { |
|
85 | - return $this->updated_by; |
|
86 | - } |
|
80 | + /** |
|
81 | + * @return mixed |
|
82 | + */ |
|
83 | + public function getUpdatedBy() |
|
84 | + { |
|
85 | + return $this->updated_by; |
|
86 | + } |
|
87 | 87 | |
88 | - /** |
|
89 | - * @ORM\PreUpdate |
|
90 | - * @param mixed $updated_by |
|
91 | - */ |
|
92 | - public function setUpdatedBy($updated_by) |
|
93 | - { |
|
94 | - $this->updated_by = $updated_by; |
|
95 | - } |
|
88 | + /** |
|
89 | + * @ORM\PreUpdate |
|
90 | + * @param mixed $updated_by |
|
91 | + */ |
|
92 | + public function setUpdatedBy($updated_by) |
|
93 | + { |
|
94 | + $this->updated_by = $updated_by; |
|
95 | + } |
|
96 | 96 | } |
@@ -12,38 +12,38 @@ |
||
12 | 12 | */ |
13 | 13 | private $user; |
14 | 14 | |
15 | - /** |
|
16 | - * CreateUpdateAwareListener constructor. |
|
17 | - * @param TokenStorage $tokenStorage |
|
18 | - */ |
|
19 | - public function __construct(TokenStorage $tokenStorage) |
|
15 | + /** |
|
16 | + * CreateUpdateAwareListener constructor. |
|
17 | + * @param TokenStorage $tokenStorage |
|
18 | + */ |
|
19 | + public function __construct(TokenStorage $tokenStorage) |
|
20 | 20 | { |
21 | - if ($tokenStorage->getToken() && is_object($tokenStorage->getToken()->getUser()) && $tokenStorage->getToken()->getUser()->getUser()) { |
|
22 | - $this->user = $tokenStorage->getToken()->getUser()->getUser(); |
|
23 | - } else { |
|
24 | - $this->user = null; |
|
25 | - } |
|
21 | + if ($tokenStorage->getToken() && is_object($tokenStorage->getToken()->getUser()) && $tokenStorage->getToken()->getUser()->getUser()) { |
|
22 | + $this->user = $tokenStorage->getToken()->getUser()->getUser(); |
|
23 | + } else { |
|
24 | + $this->user = null; |
|
25 | + } |
|
26 | 26 | } |
27 | 27 | |
28 | 28 | public function prePersist($entity) |
29 | 29 | { |
30 | - if ($this->user) { |
|
31 | - if ($entity->getCreatedBy() === null) { |
|
32 | - $entity->setCreatedAt(new \DateTime()); |
|
33 | - $entity->setCreatedBy($this->user); |
|
34 | - } |
|
35 | - if ($entity->getUpdatedBy() === null) { |
|
36 | - $entity->setUpdatedAt(new \DateTime()); |
|
37 | - $entity->setUpdatedBy($this->user); |
|
38 | - } |
|
39 | - } |
|
30 | + if ($this->user) { |
|
31 | + if ($entity->getCreatedBy() === null) { |
|
32 | + $entity->setCreatedAt(new \DateTime()); |
|
33 | + $entity->setCreatedBy($this->user); |
|
34 | + } |
|
35 | + if ($entity->getUpdatedBy() === null) { |
|
36 | + $entity->setUpdatedAt(new \DateTime()); |
|
37 | + $entity->setUpdatedBy($this->user); |
|
38 | + } |
|
39 | + } |
|
40 | 40 | } |
41 | 41 | |
42 | - public function preUpdate($entity) |
|
43 | - { |
|
44 | - if ($this->user) { |
|
45 | - $entity->setUpdatedAt(new \DateTime()); |
|
46 | - $entity->setUpdatedBy($this->user); |
|
47 | - } |
|
48 | - } |
|
42 | + public function preUpdate($entity) |
|
43 | + { |
|
44 | + if ($this->user) { |
|
45 | + $entity->setUpdatedAt(new \DateTime()); |
|
46 | + $entity->setUpdatedBy($this->user); |
|
47 | + } |
|
48 | + } |
|
49 | 49 | } |
@@ -16,157 +16,157 @@ |
||
16 | 16 | */ |
17 | 17 | class AccountToken |
18 | 18 | { |
19 | - use GuidTrait; |
|
20 | - use CreatedUpdatedTrait; |
|
21 | - |
|
22 | - /** |
|
23 | - * @ORM\Id |
|
24 | - * @ORM\Column(type="integer") |
|
25 | - * @ORM\GeneratedValue(strategy="AUTO") |
|
26 | - */ |
|
27 | - protected $id; |
|
28 | - |
|
29 | - /** |
|
30 | - * @ORM\Column(type="string", length=200) |
|
31 | - */ |
|
32 | - protected $token; |
|
33 | - |
|
34 | - /** |
|
35 | - * @ORM\Column(type="datetime", nullable=true) |
|
36 | - */ |
|
37 | - protected $endToken; |
|
38 | - |
|
39 | - /** |
|
40 | - * @ORM\Column(type="string", length=200) |
|
41 | - */ |
|
42 | - protected $userAgent; |
|
43 | - |
|
44 | - /** |
|
45 | - * @ORM\Column(type="string", length=200) |
|
46 | - */ |
|
47 | - protected $ip; |
|
48 | - |
|
49 | - /** |
|
50 | - * @ORM\ManyToOne(targetEntity="Account", inversedBy="tokens") |
|
51 | - * @ORM\JoinColumn(name="account_id", referencedColumnName="id", nullable=false) |
|
52 | - */ |
|
53 | - protected $account; |
|
54 | - |
|
55 | - /** |
|
56 | - * @return mixed |
|
57 | - */ |
|
58 | - public function getId() |
|
59 | - { |
|
60 | - return $this->id; |
|
61 | - } |
|
62 | - |
|
63 | - /** |
|
64 | - * @param mixed $id |
|
65 | - * @return AccountToken |
|
66 | - */ |
|
67 | - public function setId($id) |
|
68 | - { |
|
69 | - $this->id = $id; |
|
70 | - |
|
71 | - return $this; |
|
72 | - } |
|
73 | - |
|
74 | - /** |
|
75 | - * @return mixed |
|
76 | - */ |
|
77 | - public function getToken() |
|
78 | - { |
|
79 | - return $this->token; |
|
80 | - } |
|
81 | - |
|
82 | - /** |
|
83 | - * @param mixed $token |
|
84 | - * @return AccountToken |
|
85 | - */ |
|
86 | - public function setToken($token) |
|
87 | - { |
|
88 | - $this->token = $token; |
|
89 | - |
|
90 | - return $this; |
|
91 | - } |
|
92 | - |
|
93 | - /** |
|
94 | - * @return mixed |
|
95 | - */ |
|
96 | - public function getEndToken() |
|
97 | - { |
|
98 | - return $this->endToken; |
|
99 | - } |
|
100 | - |
|
101 | - /** |
|
102 | - * @param mixed $endToken |
|
103 | - * @return AccountToken |
|
104 | - */ |
|
105 | - public function setEndToken($endToken) |
|
106 | - { |
|
107 | - $this->endToken = $endToken; |
|
108 | - |
|
109 | - return $this; |
|
110 | - } |
|
111 | - |
|
112 | - /** |
|
113 | - * @return mixed |
|
114 | - */ |
|
115 | - public function getUserAgent() |
|
116 | - { |
|
117 | - return $this->userAgent; |
|
118 | - } |
|
119 | - |
|
120 | - /** |
|
121 | - * @param mixed $userAgent |
|
122 | - * @return AccountToken |
|
123 | - */ |
|
124 | - public function setUserAgent($userAgent) |
|
125 | - { |
|
126 | - $this->userAgent = $userAgent; |
|
127 | - |
|
128 | - return $this; |
|
129 | - } |
|
130 | - |
|
131 | - /** |
|
132 | - * @return mixed |
|
133 | - */ |
|
134 | - public function getIp() |
|
135 | - { |
|
136 | - return $this->ip; |
|
137 | - } |
|
138 | - |
|
139 | - /** |
|
140 | - * @param mixed $ip |
|
141 | - * @return AccountToken |
|
142 | - */ |
|
143 | - public function setIp($ip) |
|
144 | - { |
|
145 | - $this->ip = $ip; |
|
146 | - |
|
147 | - return $this; |
|
148 | - } |
|
149 | - |
|
150 | - /** |
|
151 | - * Set Account entity (many to one). |
|
152 | - * |
|
153 | - * @param Account $account |
|
154 | - * @return AccountToken |
|
155 | - */ |
|
156 | - public function setAccount(Account $account = null) |
|
157 | - { |
|
158 | - $this->account = $account; |
|
159 | - |
|
160 | - return $this; |
|
161 | - } |
|
162 | - |
|
163 | - /** |
|
164 | - * Get Account entity (many to one). |
|
165 | - * |
|
166 | - * @return Account |
|
167 | - */ |
|
168 | - public function getAccount() |
|
169 | - { |
|
170 | - return $this->account; |
|
171 | - } |
|
19 | + use GuidTrait; |
|
20 | + use CreatedUpdatedTrait; |
|
21 | + |
|
22 | + /** |
|
23 | + * @ORM\Id |
|
24 | + * @ORM\Column(type="integer") |
|
25 | + * @ORM\GeneratedValue(strategy="AUTO") |
|
26 | + */ |
|
27 | + protected $id; |
|
28 | + |
|
29 | + /** |
|
30 | + * @ORM\Column(type="string", length=200) |
|
31 | + */ |
|
32 | + protected $token; |
|
33 | + |
|
34 | + /** |
|
35 | + * @ORM\Column(type="datetime", nullable=true) |
|
36 | + */ |
|
37 | + protected $endToken; |
|
38 | + |
|
39 | + /** |
|
40 | + * @ORM\Column(type="string", length=200) |
|
41 | + */ |
|
42 | + protected $userAgent; |
|
43 | + |
|
44 | + /** |
|
45 | + * @ORM\Column(type="string", length=200) |
|
46 | + */ |
|
47 | + protected $ip; |
|
48 | + |
|
49 | + /** |
|
50 | + * @ORM\ManyToOne(targetEntity="Account", inversedBy="tokens") |
|
51 | + * @ORM\JoinColumn(name="account_id", referencedColumnName="id", nullable=false) |
|
52 | + */ |
|
53 | + protected $account; |
|
54 | + |
|
55 | + /** |
|
56 | + * @return mixed |
|
57 | + */ |
|
58 | + public function getId() |
|
59 | + { |
|
60 | + return $this->id; |
|
61 | + } |
|
62 | + |
|
63 | + /** |
|
64 | + * @param mixed $id |
|
65 | + * @return AccountToken |
|
66 | + */ |
|
67 | + public function setId($id) |
|
68 | + { |
|
69 | + $this->id = $id; |
|
70 | + |
|
71 | + return $this; |
|
72 | + } |
|
73 | + |
|
74 | + /** |
|
75 | + * @return mixed |
|
76 | + */ |
|
77 | + public function getToken() |
|
78 | + { |
|
79 | + return $this->token; |
|
80 | + } |
|
81 | + |
|
82 | + /** |
|
83 | + * @param mixed $token |
|
84 | + * @return AccountToken |
|
85 | + */ |
|
86 | + public function setToken($token) |
|
87 | + { |
|
88 | + $this->token = $token; |
|
89 | + |
|
90 | + return $this; |
|
91 | + } |
|
92 | + |
|
93 | + /** |
|
94 | + * @return mixed |
|
95 | + */ |
|
96 | + public function getEndToken() |
|
97 | + { |
|
98 | + return $this->endToken; |
|
99 | + } |
|
100 | + |
|
101 | + /** |
|
102 | + * @param mixed $endToken |
|
103 | + * @return AccountToken |
|
104 | + */ |
|
105 | + public function setEndToken($endToken) |
|
106 | + { |
|
107 | + $this->endToken = $endToken; |
|
108 | + |
|
109 | + return $this; |
|
110 | + } |
|
111 | + |
|
112 | + /** |
|
113 | + * @return mixed |
|
114 | + */ |
|
115 | + public function getUserAgent() |
|
116 | + { |
|
117 | + return $this->userAgent; |
|
118 | + } |
|
119 | + |
|
120 | + /** |
|
121 | + * @param mixed $userAgent |
|
122 | + * @return AccountToken |
|
123 | + */ |
|
124 | + public function setUserAgent($userAgent) |
|
125 | + { |
|
126 | + $this->userAgent = $userAgent; |
|
127 | + |
|
128 | + return $this; |
|
129 | + } |
|
130 | + |
|
131 | + /** |
|
132 | + * @return mixed |
|
133 | + */ |
|
134 | + public function getIp() |
|
135 | + { |
|
136 | + return $this->ip; |
|
137 | + } |
|
138 | + |
|
139 | + /** |
|
140 | + * @param mixed $ip |
|
141 | + * @return AccountToken |
|
142 | + */ |
|
143 | + public function setIp($ip) |
|
144 | + { |
|
145 | + $this->ip = $ip; |
|
146 | + |
|
147 | + return $this; |
|
148 | + } |
|
149 | + |
|
150 | + /** |
|
151 | + * Set Account entity (many to one). |
|
152 | + * |
|
153 | + * @param Account $account |
|
154 | + * @return AccountToken |
|
155 | + */ |
|
156 | + public function setAccount(Account $account = null) |
|
157 | + { |
|
158 | + $this->account = $account; |
|
159 | + |
|
160 | + return $this; |
|
161 | + } |
|
162 | + |
|
163 | + /** |
|
164 | + * Get Account entity (many to one). |
|
165 | + * |
|
166 | + * @return Account |
|
167 | + */ |
|
168 | + public function getAccount() |
|
169 | + { |
|
170 | + return $this->account; |
|
171 | + } |
|
172 | 172 | } |
@@ -12,8 +12,8 @@ discard block |
||
12 | 12 | */ |
13 | 13 | class Account implements UserInterface, \Serializable |
14 | 14 | { |
15 | - use GuidTrait; |
|
16 | - use CreatedUpdatedTrait; |
|
15 | + use GuidTrait; |
|
16 | + use CreatedUpdatedTrait; |
|
17 | 17 | |
18 | 18 | /** |
19 | 19 | * @ORM\Id |
@@ -47,16 +47,16 @@ discard block |
||
47 | 47 | */ |
48 | 48 | private $isActive; |
49 | 49 | |
50 | - /** |
|
51 | - * @ORM\Column(type="datetime", nullable=true) |
|
52 | - */ |
|
53 | - protected $last_connection; |
|
50 | + /** |
|
51 | + * @ORM\Column(type="datetime", nullable=true) |
|
52 | + */ |
|
53 | + protected $last_connection; |
|
54 | 54 | |
55 | - /** |
|
56 | - * @ORM\OneToMany(targetEntity="AccountToken", mappedBy="account") |
|
57 | - * @ORM\JoinColumn(name="id", referencedColumnName="account_id", nullable=false) |
|
58 | - */ |
|
59 | - protected $tokens; |
|
55 | + /** |
|
56 | + * @ORM\OneToMany(targetEntity="AccountToken", mappedBy="account") |
|
57 | + * @ORM\JoinColumn(name="id", referencedColumnName="account_id", nullable=false) |
|
58 | + */ |
|
59 | + protected $tokens; |
|
60 | 60 | |
61 | 61 | /** |
62 | 62 | * @var User |
@@ -187,43 +187,43 @@ discard block |
||
187 | 187 | $this->user = $user; |
188 | 188 | } |
189 | 189 | |
190 | - /** |
|
191 | - * @return mixed |
|
192 | - */ |
|
193 | - public function getLastConnection() |
|
194 | - { |
|
195 | - return $this->last_connection; |
|
196 | - } |
|
190 | + /** |
|
191 | + * @return mixed |
|
192 | + */ |
|
193 | + public function getLastConnection() |
|
194 | + { |
|
195 | + return $this->last_connection; |
|
196 | + } |
|
197 | 197 | |
198 | - /** |
|
199 | - * @param mixed $last_connection |
|
200 | - * @return Account |
|
201 | - */ |
|
202 | - public function setLastConnection($last_connection) |
|
203 | - { |
|
204 | - $this->last_connection = $last_connection; |
|
198 | + /** |
|
199 | + * @param mixed $last_connection |
|
200 | + * @return Account |
|
201 | + */ |
|
202 | + public function setLastConnection($last_connection) |
|
203 | + { |
|
204 | + $this->last_connection = $last_connection; |
|
205 | 205 | |
206 | - return $this; |
|
207 | - } |
|
206 | + return $this; |
|
207 | + } |
|
208 | 208 | |
209 | - /** |
|
210 | - * @return mixed |
|
211 | - */ |
|
212 | - public function getTokens() |
|
213 | - { |
|
214 | - return $this->tokens; |
|
215 | - } |
|
209 | + /** |
|
210 | + * @return mixed |
|
211 | + */ |
|
212 | + public function getTokens() |
|
213 | + { |
|
214 | + return $this->tokens; |
|
215 | + } |
|
216 | 216 | |
217 | - /** |
|
218 | - * @param mixed $tokens |
|
219 | - * @return Account |
|
220 | - */ |
|
221 | - public function setTokens($tokens) |
|
222 | - { |
|
223 | - $this->tokens = $tokens; |
|
217 | + /** |
|
218 | + * @param mixed $tokens |
|
219 | + * @return Account |
|
220 | + */ |
|
221 | + public function setTokens($tokens) |
|
222 | + { |
|
223 | + $this->tokens = $tokens; |
|
224 | 224 | |
225 | - return $this; |
|
226 | - } |
|
225 | + return $this; |
|
226 | + } |
|
227 | 227 | |
228 | 228 | /** |
229 | 229 | * Returns the roles granted to the user. |
@@ -14,297 +14,297 @@ |
||
14 | 14 | */ |
15 | 15 | class Module |
16 | 16 | { |
17 | - use GuidTrait; |
|
18 | - use CreatedUpdatedTrait; |
|
19 | - |
|
20 | - /** |
|
21 | - * @var integer |
|
22 | - * |
|
23 | - * @ORM\Column(name="id", type="integer", nullable=false, options={"unsigned"=true}) |
|
24 | - * @ORM\Id |
|
25 | - * @ORM\GeneratedValue(strategy="IDENTITY") |
|
26 | - */ |
|
27 | - private $id; |
|
28 | - |
|
29 | - /** |
|
30 | - * @var string |
|
31 | - * |
|
32 | - * @ORM\Column(name="package_name", type="string", length=255, nullable=false) |
|
33 | - */ |
|
34 | - private $packageName; |
|
35 | - |
|
36 | - /** |
|
37 | - * @var string |
|
38 | - * |
|
39 | - * @ORM\Column(name="title_tag", type="string", length=70, nullable=true) |
|
40 | - */ |
|
41 | - private $titleTag; |
|
42 | - |
|
43 | - /** |
|
44 | - * @var string |
|
45 | - * |
|
46 | - * @ORM\Column(name="description_tag", type="string", length=160, nullable=true) |
|
47 | - */ |
|
48 | - private $descriptionTag; |
|
49 | - |
|
50 | - /** |
|
51 | - * @var string |
|
52 | - * |
|
53 | - * @ORM\Column(name="title", type="string", length=255, nullable=false) |
|
54 | - */ |
|
55 | - private $title; |
|
56 | - |
|
57 | - /** |
|
58 | - * @var string |
|
59 | - * |
|
60 | - * @ORM\Column(name="template", type="string", length=255, nullable=true) |
|
61 | - */ |
|
62 | - private $template; |
|
63 | - |
|
64 | - /** |
|
65 | - * @var string |
|
66 | - * |
|
67 | - * @ORM\Column(name="url", type="string", length=255, nullable=true) |
|
68 | - */ |
|
69 | - private $url; |
|
70 | - |
|
71 | - /** |
|
72 | - * @var string |
|
73 | - * |
|
74 | - * @ORM\Column(name="url_admin", type="string", length=255, nullable=true) |
|
75 | - */ |
|
76 | - private $urlAdmin; |
|
77 | - |
|
78 | - /** |
|
79 | - * @var boolean |
|
80 | - * |
|
81 | - * @ORM\Column(name="active", type="boolean", nullable=false) |
|
82 | - */ |
|
83 | - private $active; |
|
84 | - |
|
85 | - /** |
|
86 | - * @var integer |
|
87 | - * |
|
88 | - * @ORM\Column(name="`order`", type="integer", nullable=true) |
|
89 | - */ |
|
90 | - private $order; |
|
91 | - |
|
92 | - /** |
|
93 | - * @var boolean |
|
94 | - * |
|
95 | - * @ORM\Column(name="displayed", type="boolean", nullable=false) |
|
96 | - */ |
|
97 | - private $displayed; |
|
98 | - |
|
99 | - /** |
|
100 | - * @var boolean |
|
101 | - * |
|
102 | - * @ORM\Column(name="dev_mode", type="boolean", nullable=false) |
|
103 | - */ |
|
104 | - private $devMode = false; |
|
105 | - |
|
106 | - /** |
|
107 | - * @return int |
|
108 | - */ |
|
109 | - public function getId(): int |
|
110 | - { |
|
111 | - return $this->id; |
|
112 | - } |
|
113 | - |
|
114 | - /** |
|
115 | - * @param int $id |
|
116 | - */ |
|
117 | - public function setId(int $id) |
|
118 | - { |
|
119 | - $this->id = $id; |
|
120 | - } |
|
121 | - |
|
122 | - /** |
|
123 | - * @return string |
|
124 | - */ |
|
125 | - public function getPackageName(): ?string |
|
126 | - { |
|
127 | - return $this->packageName; |
|
128 | - } |
|
129 | - |
|
130 | - /** |
|
131 | - * @param string $package_name |
|
132 | - */ |
|
133 | - public function setPackageName(string $package_name) |
|
134 | - { |
|
135 | - $this->packageName = $package_name; |
|
136 | - } |
|
137 | - |
|
138 | - /** |
|
139 | - * @return string |
|
140 | - */ |
|
141 | - public function getTitleTag(): ?string |
|
142 | - { |
|
143 | - return $this->titleTag; |
|
144 | - } |
|
145 | - |
|
146 | - /** |
|
147 | - * @param string $titleTag |
|
148 | - */ |
|
149 | - public function setTitleTag(string $titleTag) |
|
150 | - { |
|
151 | - $this->titleTag = $titleTag; |
|
152 | - } |
|
153 | - |
|
154 | - /** |
|
155 | - * @return string |
|
156 | - */ |
|
157 | - public function getDescriptionTag(): ?string |
|
158 | - { |
|
159 | - return $this->descriptionTag; |
|
160 | - } |
|
161 | - |
|
162 | - /** |
|
163 | - * @param string $descriptionTag |
|
164 | - */ |
|
165 | - public function setDescriptionTag(string $descriptionTag) |
|
166 | - { |
|
167 | - $this->descriptionTag = $descriptionTag; |
|
168 | - } |
|
169 | - |
|
170 | - /** |
|
171 | - * @return string |
|
172 | - */ |
|
173 | - public function getTitle(): ?string |
|
174 | - { |
|
175 | - return $this->title; |
|
176 | - } |
|
177 | - |
|
178 | - /** |
|
179 | - * @param string $title |
|
180 | - */ |
|
181 | - public function setTitle(string $title) |
|
182 | - { |
|
183 | - $this->title = $title; |
|
184 | - } |
|
185 | - |
|
186 | - /** |
|
187 | - * @return string |
|
188 | - */ |
|
189 | - public function getTemplate(): ?string |
|
190 | - { |
|
191 | - return $this->template; |
|
192 | - } |
|
193 | - |
|
194 | - /** |
|
195 | - * @param string $template |
|
196 | - */ |
|
197 | - public function setTemplate(string $template) |
|
198 | - { |
|
199 | - $this->template = $template; |
|
200 | - } |
|
201 | - |
|
202 | - /** |
|
203 | - * @return string |
|
204 | - */ |
|
205 | - public function getUrl(): ?string |
|
206 | - { |
|
207 | - return $this->url; |
|
208 | - } |
|
209 | - |
|
210 | - /** |
|
211 | - * @param string $url |
|
212 | - */ |
|
213 | - public function setUrl(string $url) |
|
214 | - { |
|
215 | - $this->url = $url; |
|
216 | - } |
|
217 | - |
|
218 | - /** |
|
219 | - * @return string |
|
220 | - */ |
|
221 | - public function getUrlAdmin(): ?string |
|
222 | - { |
|
223 | - return $this->urlAdmin; |
|
224 | - } |
|
225 | - |
|
226 | - /** |
|
227 | - * @param string $urlAdmin |
|
228 | - */ |
|
229 | - public function setUrlAdmin(string $urlAdmin) |
|
230 | - { |
|
231 | - $this->urlAdmin = $urlAdmin; |
|
232 | - } |
|
233 | - |
|
234 | - /** |
|
235 | - * @return boolean |
|
236 | - */ |
|
237 | - public function getActive(): ?bool |
|
238 | - { |
|
239 | - return $this->active; |
|
240 | - } |
|
241 | - |
|
242 | - /** |
|
243 | - * @param bool $active |
|
244 | - */ |
|
245 | - public function setActive(bool $active) |
|
246 | - { |
|
247 | - $this->active = $active; |
|
248 | - } |
|
249 | - |
|
250 | - /** |
|
251 | - * @return int |
|
252 | - */ |
|
253 | - public function getOrder(): ?int |
|
254 | - { |
|
255 | - return $this->order; |
|
256 | - } |
|
257 | - |
|
258 | - /** |
|
259 | - * @param int $order |
|
260 | - */ |
|
261 | - public function setOrder(int $order) |
|
262 | - { |
|
263 | - $this->order = $order; |
|
264 | - } |
|
265 | - |
|
266 | - /** |
|
267 | - * @return bool |
|
268 | - */ |
|
269 | - public function getDisplayed(): ?bool |
|
270 | - { |
|
271 | - return $this->displayed; |
|
272 | - } |
|
273 | - |
|
274 | - /** |
|
275 | - * @param bool $displayed |
|
276 | - */ |
|
277 | - public function setDisplayed(bool $displayed) |
|
278 | - { |
|
279 | - $this->displayed = $displayed; |
|
280 | - } |
|
281 | - |
|
282 | - /** |
|
283 | - * @return bool |
|
284 | - */ |
|
285 | - public function getDevMode(): bool |
|
286 | - { |
|
287 | - return $this->devMode; |
|
288 | - } |
|
289 | - |
|
290 | - /** |
|
291 | - * @param bool $devMode |
|
292 | - * @return Module |
|
293 | - */ |
|
294 | - public function setDevMode(bool $devMode): Module |
|
295 | - { |
|
296 | - $this->devMode = $devMode; |
|
297 | - |
|
298 | - return $this; |
|
299 | - } |
|
300 | - |
|
301 | - public function getFormattedActive() |
|
302 | - { |
|
303 | - return $this->getActive() ? "Oui" : "Non"; |
|
304 | - } |
|
305 | - |
|
306 | - public function getFormattedDisplayed() |
|
307 | - { |
|
308 | - return $this->getDisplayed() ? "Oui" : "Non"; |
|
309 | - } |
|
17 | + use GuidTrait; |
|
18 | + use CreatedUpdatedTrait; |
|
19 | + |
|
20 | + /** |
|
21 | + * @var integer |
|
22 | + * |
|
23 | + * @ORM\Column(name="id", type="integer", nullable=false, options={"unsigned"=true}) |
|
24 | + * @ORM\Id |
|
25 | + * @ORM\GeneratedValue(strategy="IDENTITY") |
|
26 | + */ |
|
27 | + private $id; |
|
28 | + |
|
29 | + /** |
|
30 | + * @var string |
|
31 | + * |
|
32 | + * @ORM\Column(name="package_name", type="string", length=255, nullable=false) |
|
33 | + */ |
|
34 | + private $packageName; |
|
35 | + |
|
36 | + /** |
|
37 | + * @var string |
|
38 | + * |
|
39 | + * @ORM\Column(name="title_tag", type="string", length=70, nullable=true) |
|
40 | + */ |
|
41 | + private $titleTag; |
|
42 | + |
|
43 | + /** |
|
44 | + * @var string |
|
45 | + * |
|
46 | + * @ORM\Column(name="description_tag", type="string", length=160, nullable=true) |
|
47 | + */ |
|
48 | + private $descriptionTag; |
|
49 | + |
|
50 | + /** |
|
51 | + * @var string |
|
52 | + * |
|
53 | + * @ORM\Column(name="title", type="string", length=255, nullable=false) |
|
54 | + */ |
|
55 | + private $title; |
|
56 | + |
|
57 | + /** |
|
58 | + * @var string |
|
59 | + * |
|
60 | + * @ORM\Column(name="template", type="string", length=255, nullable=true) |
|
61 | + */ |
|
62 | + private $template; |
|
63 | + |
|
64 | + /** |
|
65 | + * @var string |
|
66 | + * |
|
67 | + * @ORM\Column(name="url", type="string", length=255, nullable=true) |
|
68 | + */ |
|
69 | + private $url; |
|
70 | + |
|
71 | + /** |
|
72 | + * @var string |
|
73 | + * |
|
74 | + * @ORM\Column(name="url_admin", type="string", length=255, nullable=true) |
|
75 | + */ |
|
76 | + private $urlAdmin; |
|
77 | + |
|
78 | + /** |
|
79 | + * @var boolean |
|
80 | + * |
|
81 | + * @ORM\Column(name="active", type="boolean", nullable=false) |
|
82 | + */ |
|
83 | + private $active; |
|
84 | + |
|
85 | + /** |
|
86 | + * @var integer |
|
87 | + * |
|
88 | + * @ORM\Column(name="`order`", type="integer", nullable=true) |
|
89 | + */ |
|
90 | + private $order; |
|
91 | + |
|
92 | + /** |
|
93 | + * @var boolean |
|
94 | + * |
|
95 | + * @ORM\Column(name="displayed", type="boolean", nullable=false) |
|
96 | + */ |
|
97 | + private $displayed; |
|
98 | + |
|
99 | + /** |
|
100 | + * @var boolean |
|
101 | + * |
|
102 | + * @ORM\Column(name="dev_mode", type="boolean", nullable=false) |
|
103 | + */ |
|
104 | + private $devMode = false; |
|
105 | + |
|
106 | + /** |
|
107 | + * @return int |
|
108 | + */ |
|
109 | + public function getId(): int |
|
110 | + { |
|
111 | + return $this->id; |
|
112 | + } |
|
113 | + |
|
114 | + /** |
|
115 | + * @param int $id |
|
116 | + */ |
|
117 | + public function setId(int $id) |
|
118 | + { |
|
119 | + $this->id = $id; |
|
120 | + } |
|
121 | + |
|
122 | + /** |
|
123 | + * @return string |
|
124 | + */ |
|
125 | + public function getPackageName(): ?string |
|
126 | + { |
|
127 | + return $this->packageName; |
|
128 | + } |
|
129 | + |
|
130 | + /** |
|
131 | + * @param string $package_name |
|
132 | + */ |
|
133 | + public function setPackageName(string $package_name) |
|
134 | + { |
|
135 | + $this->packageName = $package_name; |
|
136 | + } |
|
137 | + |
|
138 | + /** |
|
139 | + * @return string |
|
140 | + */ |
|
141 | + public function getTitleTag(): ?string |
|
142 | + { |
|
143 | + return $this->titleTag; |
|
144 | + } |
|
145 | + |
|
146 | + /** |
|
147 | + * @param string $titleTag |
|
148 | + */ |
|
149 | + public function setTitleTag(string $titleTag) |
|
150 | + { |
|
151 | + $this->titleTag = $titleTag; |
|
152 | + } |
|
153 | + |
|
154 | + /** |
|
155 | + * @return string |
|
156 | + */ |
|
157 | + public function getDescriptionTag(): ?string |
|
158 | + { |
|
159 | + return $this->descriptionTag; |
|
160 | + } |
|
161 | + |
|
162 | + /** |
|
163 | + * @param string $descriptionTag |
|
164 | + */ |
|
165 | + public function setDescriptionTag(string $descriptionTag) |
|
166 | + { |
|
167 | + $this->descriptionTag = $descriptionTag; |
|
168 | + } |
|
169 | + |
|
170 | + /** |
|
171 | + * @return string |
|
172 | + */ |
|
173 | + public function getTitle(): ?string |
|
174 | + { |
|
175 | + return $this->title; |
|
176 | + } |
|
177 | + |
|
178 | + /** |
|
179 | + * @param string $title |
|
180 | + */ |
|
181 | + public function setTitle(string $title) |
|
182 | + { |
|
183 | + $this->title = $title; |
|
184 | + } |
|
185 | + |
|
186 | + /** |
|
187 | + * @return string |
|
188 | + */ |
|
189 | + public function getTemplate(): ?string |
|
190 | + { |
|
191 | + return $this->template; |
|
192 | + } |
|
193 | + |
|
194 | + /** |
|
195 | + * @param string $template |
|
196 | + */ |
|
197 | + public function setTemplate(string $template) |
|
198 | + { |
|
199 | + $this->template = $template; |
|
200 | + } |
|
201 | + |
|
202 | + /** |
|
203 | + * @return string |
|
204 | + */ |
|
205 | + public function getUrl(): ?string |
|
206 | + { |
|
207 | + return $this->url; |
|
208 | + } |
|
209 | + |
|
210 | + /** |
|
211 | + * @param string $url |
|
212 | + */ |
|
213 | + public function setUrl(string $url) |
|
214 | + { |
|
215 | + $this->url = $url; |
|
216 | + } |
|
217 | + |
|
218 | + /** |
|
219 | + * @return string |
|
220 | + */ |
|
221 | + public function getUrlAdmin(): ?string |
|
222 | + { |
|
223 | + return $this->urlAdmin; |
|
224 | + } |
|
225 | + |
|
226 | + /** |
|
227 | + * @param string $urlAdmin |
|
228 | + */ |
|
229 | + public function setUrlAdmin(string $urlAdmin) |
|
230 | + { |
|
231 | + $this->urlAdmin = $urlAdmin; |
|
232 | + } |
|
233 | + |
|
234 | + /** |
|
235 | + * @return boolean |
|
236 | + */ |
|
237 | + public function getActive(): ?bool |
|
238 | + { |
|
239 | + return $this->active; |
|
240 | + } |
|
241 | + |
|
242 | + /** |
|
243 | + * @param bool $active |
|
244 | + */ |
|
245 | + public function setActive(bool $active) |
|
246 | + { |
|
247 | + $this->active = $active; |
|
248 | + } |
|
249 | + |
|
250 | + /** |
|
251 | + * @return int |
|
252 | + */ |
|
253 | + public function getOrder(): ?int |
|
254 | + { |
|
255 | + return $this->order; |
|
256 | + } |
|
257 | + |
|
258 | + /** |
|
259 | + * @param int $order |
|
260 | + */ |
|
261 | + public function setOrder(int $order) |
|
262 | + { |
|
263 | + $this->order = $order; |
|
264 | + } |
|
265 | + |
|
266 | + /** |
|
267 | + * @return bool |
|
268 | + */ |
|
269 | + public function getDisplayed(): ?bool |
|
270 | + { |
|
271 | + return $this->displayed; |
|
272 | + } |
|
273 | + |
|
274 | + /** |
|
275 | + * @param bool $displayed |
|
276 | + */ |
|
277 | + public function setDisplayed(bool $displayed) |
|
278 | + { |
|
279 | + $this->displayed = $displayed; |
|
280 | + } |
|
281 | + |
|
282 | + /** |
|
283 | + * @return bool |
|
284 | + */ |
|
285 | + public function getDevMode(): bool |
|
286 | + { |
|
287 | + return $this->devMode; |
|
288 | + } |
|
289 | + |
|
290 | + /** |
|
291 | + * @param bool $devMode |
|
292 | + * @return Module |
|
293 | + */ |
|
294 | + public function setDevMode(bool $devMode): Module |
|
295 | + { |
|
296 | + $this->devMode = $devMode; |
|
297 | + |
|
298 | + return $this; |
|
299 | + } |
|
300 | + |
|
301 | + public function getFormattedActive() |
|
302 | + { |
|
303 | + return $this->getActive() ? "Oui" : "Non"; |
|
304 | + } |
|
305 | + |
|
306 | + public function getFormattedDisplayed() |
|
307 | + { |
|
308 | + return $this->getDisplayed() ? "Oui" : "Non"; |
|
309 | + } |
|
310 | 310 | } |
@@ -14,45 +14,45 @@ discard block |
||
14 | 14 | */ |
15 | 15 | class Page |
16 | 16 | { |
17 | - use GuidTrait; |
|
18 | - use CreatedUpdatedTrait; |
|
17 | + use GuidTrait; |
|
18 | + use CreatedUpdatedTrait; |
|
19 | 19 | |
20 | - /** |
|
21 | - * @var integer |
|
22 | - * |
|
23 | - * @ORM\Column(name="id", type="integer", nullable=false, options={"unsigned"=true}) |
|
24 | - * @ORM\Id |
|
25 | - * @ORM\GeneratedValue(strategy="IDENTITY") |
|
26 | - */ |
|
27 | - private $id; |
|
20 | + /** |
|
21 | + * @var integer |
|
22 | + * |
|
23 | + * @ORM\Column(name="id", type="integer", nullable=false, options={"unsigned"=true}) |
|
24 | + * @ORM\Id |
|
25 | + * @ORM\GeneratedValue(strategy="IDENTITY") |
|
26 | + */ |
|
27 | + private $id; |
|
28 | 28 | |
29 | - /** |
|
30 | - * @var string |
|
31 | - * |
|
32 | - * @ORM\Column(name="title_tag", type="string", length=70, nullable=true) |
|
33 | - */ |
|
34 | - private $titleTag; |
|
29 | + /** |
|
30 | + * @var string |
|
31 | + * |
|
32 | + * @ORM\Column(name="title_tag", type="string", length=70, nullable=true) |
|
33 | + */ |
|
34 | + private $titleTag; |
|
35 | 35 | |
36 | - /** |
|
37 | - * @var string |
|
38 | - * |
|
39 | - * @ORM\Column(name="description_tag", type="string", length=160, nullable=true) |
|
40 | - */ |
|
41 | - private $descriptionTag; |
|
36 | + /** |
|
37 | + * @var string |
|
38 | + * |
|
39 | + * @ORM\Column(name="description_tag", type="string", length=160, nullable=true) |
|
40 | + */ |
|
41 | + private $descriptionTag; |
|
42 | 42 | |
43 | - /** |
|
44 | - * @var string |
|
45 | - * |
|
46 | - * @ORM\Column(name="title", type="string", length=255, nullable=false) |
|
47 | - */ |
|
48 | - private $title; |
|
43 | + /** |
|
44 | + * @var string |
|
45 | + * |
|
46 | + * @ORM\Column(name="title", type="string", length=255, nullable=false) |
|
47 | + */ |
|
48 | + private $title; |
|
49 | 49 | |
50 | 50 | /** |
51 | 51 | * @var string |
52 | 52 | * |
53 | 53 | * @ORM\Column(name="template", type="string", length=255, nullable=false) |
54 | 54 | */ |
55 | - private $template; |
|
55 | + private $template; |
|
56 | 56 | |
57 | 57 | /** |
58 | 58 | * @var string |
@@ -61,107 +61,107 @@ discard block |
||
61 | 61 | */ |
62 | 62 | private $url; |
63 | 63 | |
64 | - /** |
|
65 | - * @var string |
|
66 | - * |
|
67 | - * @ORM\Column(name="content", type="text", nullable=true) |
|
68 | - */ |
|
69 | - private $content; |
|
64 | + /** |
|
65 | + * @var string |
|
66 | + * |
|
67 | + * @ORM\Column(name="content", type="text", nullable=true) |
|
68 | + */ |
|
69 | + private $content; |
|
70 | 70 | |
71 | - /** |
|
72 | - * @var integer |
|
73 | - * |
|
74 | - * @ORM\Column(name="active", type="integer", nullable=false) |
|
75 | - */ |
|
76 | - private $active; |
|
71 | + /** |
|
72 | + * @var integer |
|
73 | + * |
|
74 | + * @ORM\Column(name="active", type="integer", nullable=false) |
|
75 | + */ |
|
76 | + private $active; |
|
77 | 77 | |
78 | - /** |
|
79 | - * @var integer |
|
80 | - * |
|
81 | - * @ORM\Column(name="order", type="integer", nullable=false) |
|
82 | - */ |
|
83 | - private $order; |
|
78 | + /** |
|
79 | + * @var integer |
|
80 | + * |
|
81 | + * @ORM\Column(name="order", type="integer", nullable=false) |
|
82 | + */ |
|
83 | + private $order; |
|
84 | 84 | |
85 | - /** |
|
86 | - * @var integer |
|
87 | - * |
|
88 | - * @ORM\Column(name="displayed", type="integer", nullable=false) |
|
89 | - */ |
|
90 | - private $displayed; |
|
85 | + /** |
|
86 | + * @var integer |
|
87 | + * |
|
88 | + * @ORM\Column(name="displayed", type="integer", nullable=false) |
|
89 | + */ |
|
90 | + private $displayed; |
|
91 | 91 | |
92 | - /** |
|
93 | - * @var \Page |
|
94 | - * |
|
95 | - * @ORM\ManyToOne(targetEntity="Page") |
|
96 | - * @ORM\JoinColumns({ |
|
97 | - * @ORM\JoinColumn(name="parent", referencedColumnName="id") |
|
98 | - * }) |
|
99 | - */ |
|
100 | - private $parent; |
|
92 | + /** |
|
93 | + * @var \Page |
|
94 | + * |
|
95 | + * @ORM\ManyToOne(targetEntity="Page") |
|
96 | + * @ORM\JoinColumns({ |
|
97 | + * @ORM\JoinColumn(name="parent", referencedColumnName="id") |
|
98 | + * }) |
|
99 | + */ |
|
100 | + private $parent; |
|
101 | 101 | |
102 | - /** |
|
103 | - * @return int |
|
104 | - */ |
|
105 | - public function getId() |
|
106 | - { |
|
107 | - return $this->id; |
|
108 | - } |
|
102 | + /** |
|
103 | + * @return int |
|
104 | + */ |
|
105 | + public function getId() |
|
106 | + { |
|
107 | + return $this->id; |
|
108 | + } |
|
109 | 109 | |
110 | - /** |
|
111 | - * @param int $id |
|
112 | - */ |
|
113 | - public function setId($id) |
|
114 | - { |
|
115 | - $this->id = $id; |
|
116 | - } |
|
110 | + /** |
|
111 | + * @param int $id |
|
112 | + */ |
|
113 | + public function setId($id) |
|
114 | + { |
|
115 | + $this->id = $id; |
|
116 | + } |
|
117 | 117 | |
118 | - /** |
|
119 | - * @return string |
|
120 | - */ |
|
121 | - public function getTitleTag() |
|
122 | - { |
|
123 | - return $this->titleTag; |
|
124 | - } |
|
118 | + /** |
|
119 | + * @return string |
|
120 | + */ |
|
121 | + public function getTitleTag() |
|
122 | + { |
|
123 | + return $this->titleTag; |
|
124 | + } |
|
125 | 125 | |
126 | - /** |
|
127 | - * @param string $titleTag |
|
128 | - */ |
|
129 | - public function setTitleTag($titleTag) |
|
130 | - { |
|
131 | - $this->titleTag = $titleTag; |
|
132 | - } |
|
126 | + /** |
|
127 | + * @param string $titleTag |
|
128 | + */ |
|
129 | + public function setTitleTag($titleTag) |
|
130 | + { |
|
131 | + $this->titleTag = $titleTag; |
|
132 | + } |
|
133 | 133 | |
134 | - /** |
|
135 | - * @return string |
|
136 | - */ |
|
137 | - public function getDescriptionTag() |
|
138 | - { |
|
139 | - return $this->descriptionTag; |
|
140 | - } |
|
134 | + /** |
|
135 | + * @return string |
|
136 | + */ |
|
137 | + public function getDescriptionTag() |
|
138 | + { |
|
139 | + return $this->descriptionTag; |
|
140 | + } |
|
141 | 141 | |
142 | - /** |
|
143 | - * @param string $descriptionTag |
|
144 | - */ |
|
145 | - public function setDescriptionTag($descriptionTag) |
|
146 | - { |
|
147 | - $this->descriptionTag = $descriptionTag; |
|
148 | - } |
|
142 | + /** |
|
143 | + * @param string $descriptionTag |
|
144 | + */ |
|
145 | + public function setDescriptionTag($descriptionTag) |
|
146 | + { |
|
147 | + $this->descriptionTag = $descriptionTag; |
|
148 | + } |
|
149 | 149 | |
150 | - /** |
|
151 | - * @return string |
|
152 | - */ |
|
153 | - public function getTitle() |
|
154 | - { |
|
155 | - return $this->title; |
|
156 | - } |
|
150 | + /** |
|
151 | + * @return string |
|
152 | + */ |
|
153 | + public function getTitle() |
|
154 | + { |
|
155 | + return $this->title; |
|
156 | + } |
|
157 | 157 | |
158 | - /** |
|
159 | - * @param string $title |
|
160 | - */ |
|
161 | - public function setTitle($title) |
|
162 | - { |
|
163 | - $this->title = $title; |
|
164 | - } |
|
158 | + /** |
|
159 | + * @param string $title |
|
160 | + */ |
|
161 | + public function setTitle($title) |
|
162 | + { |
|
163 | + $this->title = $title; |
|
164 | + } |
|
165 | 165 | |
166 | 166 | /** |
167 | 167 | * @return string |
@@ -195,84 +195,84 @@ discard block |
||
195 | 195 | $this->url = $url; |
196 | 196 | } |
197 | 197 | |
198 | - /** |
|
199 | - * @return string |
|
200 | - */ |
|
201 | - public function getContent() |
|
202 | - { |
|
203 | - return $this->content; |
|
204 | - } |
|
198 | + /** |
|
199 | + * @return string |
|
200 | + */ |
|
201 | + public function getContent() |
|
202 | + { |
|
203 | + return $this->content; |
|
204 | + } |
|
205 | 205 | |
206 | - /** |
|
207 | - * @param string $content |
|
208 | - */ |
|
209 | - public function setContent($content) |
|
210 | - { |
|
211 | - $this->content = $content; |
|
212 | - } |
|
206 | + /** |
|
207 | + * @param string $content |
|
208 | + */ |
|
209 | + public function setContent($content) |
|
210 | + { |
|
211 | + $this->content = $content; |
|
212 | + } |
|
213 | 213 | |
214 | - /** |
|
215 | - * @return int |
|
216 | - */ |
|
217 | - public function getActive() |
|
218 | - { |
|
219 | - return $this->active; |
|
220 | - } |
|
214 | + /** |
|
215 | + * @return int |
|
216 | + */ |
|
217 | + public function getActive() |
|
218 | + { |
|
219 | + return $this->active; |
|
220 | + } |
|
221 | 221 | |
222 | - /** |
|
223 | - * @param int $active |
|
224 | - */ |
|
225 | - public function setActive($active) |
|
226 | - { |
|
227 | - $this->active = $active; |
|
228 | - } |
|
222 | + /** |
|
223 | + * @param int $active |
|
224 | + */ |
|
225 | + public function setActive($active) |
|
226 | + { |
|
227 | + $this->active = $active; |
|
228 | + } |
|
229 | 229 | |
230 | - /** |
|
231 | - * @return int |
|
232 | - */ |
|
233 | - public function getOrder() |
|
234 | - { |
|
235 | - return $this->order; |
|
236 | - } |
|
230 | + /** |
|
231 | + * @return int |
|
232 | + */ |
|
233 | + public function getOrder() |
|
234 | + { |
|
235 | + return $this->order; |
|
236 | + } |
|
237 | 237 | |
238 | - /** |
|
239 | - * @param int $order |
|
240 | - */ |
|
241 | - public function setOrder($order) |
|
242 | - { |
|
243 | - $this->order = $order; |
|
244 | - } |
|
238 | + /** |
|
239 | + * @param int $order |
|
240 | + */ |
|
241 | + public function setOrder($order) |
|
242 | + { |
|
243 | + $this->order = $order; |
|
244 | + } |
|
245 | 245 | |
246 | - /** |
|
247 | - * @return int |
|
248 | - */ |
|
249 | - public function getDisplayed() |
|
250 | - { |
|
251 | - return $this->displayed; |
|
252 | - } |
|
246 | + /** |
|
247 | + * @return int |
|
248 | + */ |
|
249 | + public function getDisplayed() |
|
250 | + { |
|
251 | + return $this->displayed; |
|
252 | + } |
|
253 | 253 | |
254 | - /** |
|
255 | - * @param int $displayed |
|
256 | - */ |
|
257 | - public function setDisplayed($displayed) |
|
258 | - { |
|
259 | - $this->displayed = $displayed; |
|
260 | - } |
|
254 | + /** |
|
255 | + * @param int $displayed |
|
256 | + */ |
|
257 | + public function setDisplayed($displayed) |
|
258 | + { |
|
259 | + $this->displayed = $displayed; |
|
260 | + } |
|
261 | 261 | |
262 | - /** |
|
263 | - * @return \Page |
|
264 | - */ |
|
265 | - public function getParent() |
|
266 | - { |
|
267 | - return $this->parent; |
|
268 | - } |
|
262 | + /** |
|
263 | + * @return \Page |
|
264 | + */ |
|
265 | + public function getParent() |
|
266 | + { |
|
267 | + return $this->parent; |
|
268 | + } |
|
269 | 269 | |
270 | - /** |
|
271 | - * @param \Page $parent |
|
272 | - */ |
|
273 | - public function setParent($parent) |
|
274 | - { |
|
275 | - $this->parent = $parent; |
|
276 | - } |
|
270 | + /** |
|
271 | + * @param \Page $parent |
|
272 | + */ |
|
273 | + public function setParent($parent) |
|
274 | + { |
|
275 | + $this->parent = $parent; |
|
276 | + } |
|
277 | 277 | } |
278 | 278 |
@@ -13,130 +13,130 @@ |
||
13 | 13 | */ |
14 | 14 | class UserLogs |
15 | 15 | { |
16 | - use GuidTrait; |
|
17 | - use CreatedUpdatedTrait; |
|
18 | - |
|
19 | - /** |
|
20 | - * @var integer |
|
21 | - * |
|
22 | - * @ORM\Column(name="id", type="integer", nullable=false) |
|
23 | - * @ORM\Id |
|
24 | - * @ORM\GeneratedValue(strategy="IDENTITY") |
|
25 | - */ |
|
26 | - private $id; |
|
27 | - |
|
28 | - /** |
|
29 | - * @ORM\ManyToOne(targetEntity="PiouPiou\RibsAdminBundle\Entity\User") |
|
30 | - * @ORM\JoinColumn(name="user_id", referencedColumnName="id", nullable=false) |
|
31 | - */ |
|
32 | - private $user; |
|
33 | - |
|
34 | - /** |
|
35 | - * @var string |
|
36 | - * |
|
37 | - * @ORM\Column(name="method", type="string", length=255, nullable=false) |
|
38 | - */ |
|
39 | - private $method; |
|
40 | - |
|
41 | - /** |
|
42 | - * @var string |
|
43 | - * |
|
44 | - * @ORM\Column(name="url", type="string", length=255, nullable=false) |
|
45 | - */ |
|
46 | - private $url; |
|
47 | - |
|
48 | - /** |
|
49 | - * @var string |
|
50 | - * |
|
51 | - * @ORM\Column(name="equest_parameters", type="json", nullable=true) |
|
52 | - */ |
|
53 | - private $request_parameters; |
|
54 | - |
|
55 | - /** |
|
56 | - * @return int |
|
57 | - */ |
|
58 | - public function getId() |
|
59 | - { |
|
60 | - return $this->id; |
|
61 | - } |
|
62 | - |
|
63 | - /** |
|
64 | - * @param int $id |
|
65 | - */ |
|
66 | - public function setId($id) |
|
67 | - { |
|
68 | - $this->id = $id; |
|
69 | - } |
|
70 | - |
|
71 | - /** |
|
72 | - * @return User |
|
73 | - */ |
|
74 | - public function getUser(): User |
|
75 | - { |
|
76 | - return $this->user; |
|
77 | - } |
|
78 | - |
|
79 | - /** |
|
80 | - * @param \User $user |
|
81 | - */ |
|
82 | - public function setUser($user) |
|
83 | - { |
|
84 | - $this->user = $user; |
|
85 | - } |
|
86 | - |
|
87 | - /** |
|
88 | - * @return string |
|
89 | - */ |
|
90 | - public function getMethod(): string |
|
91 | - { |
|
92 | - return $this->method; |
|
93 | - } |
|
94 | - |
|
95 | - /** |
|
96 | - * @param string $method |
|
97 | - * @return UserLogs |
|
98 | - */ |
|
99 | - public function setMethod(string $method): UserLogs |
|
100 | - { |
|
101 | - $this->method = $method; |
|
102 | - |
|
103 | - return $this; |
|
104 | - } |
|
105 | - |
|
106 | - /** |
|
107 | - * @return string |
|
108 | - */ |
|
109 | - public function getUrl(): string |
|
110 | - { |
|
111 | - return $this->url; |
|
112 | - } |
|
113 | - |
|
114 | - /** |
|
115 | - * @param string $url |
|
116 | - * @return UserLogs |
|
117 | - */ |
|
118 | - public function setUrl(string $url): UserLogs |
|
119 | - { |
|
120 | - $this->url = $url; |
|
121 | - |
|
122 | - return $this; |
|
123 | - } |
|
124 | - |
|
125 | - |
|
126 | - public function getRequestParameters() |
|
127 | - { |
|
128 | - return $this->request_parameters; |
|
129 | - } |
|
130 | - |
|
131 | - /** |
|
132 | - * @param $request_parameters |
|
133 | - * @return UserLogs |
|
134 | - */ |
|
135 | - public function setRequestParameters($request_parameters): UserLogs |
|
136 | - { |
|
137 | - $this->request_parameters = $request_parameters; |
|
138 | - |
|
139 | - return $this; |
|
140 | - } |
|
16 | + use GuidTrait; |
|
17 | + use CreatedUpdatedTrait; |
|
18 | + |
|
19 | + /** |
|
20 | + * @var integer |
|
21 | + * |
|
22 | + * @ORM\Column(name="id", type="integer", nullable=false) |
|
23 | + * @ORM\Id |
|
24 | + * @ORM\GeneratedValue(strategy="IDENTITY") |
|
25 | + */ |
|
26 | + private $id; |
|
27 | + |
|
28 | + /** |
|
29 | + * @ORM\ManyToOne(targetEntity="PiouPiou\RibsAdminBundle\Entity\User") |
|
30 | + * @ORM\JoinColumn(name="user_id", referencedColumnName="id", nullable=false) |
|
31 | + */ |
|
32 | + private $user; |
|
33 | + |
|
34 | + /** |
|
35 | + * @var string |
|
36 | + * |
|
37 | + * @ORM\Column(name="method", type="string", length=255, nullable=false) |
|
38 | + */ |
|
39 | + private $method; |
|
40 | + |
|
41 | + /** |
|
42 | + * @var string |
|
43 | + * |
|
44 | + * @ORM\Column(name="url", type="string", length=255, nullable=false) |
|
45 | + */ |
|
46 | + private $url; |
|
47 | + |
|
48 | + /** |
|
49 | + * @var string |
|
50 | + * |
|
51 | + * @ORM\Column(name="equest_parameters", type="json", nullable=true) |
|
52 | + */ |
|
53 | + private $request_parameters; |
|
54 | + |
|
55 | + /** |
|
56 | + * @return int |
|
57 | + */ |
|
58 | + public function getId() |
|
59 | + { |
|
60 | + return $this->id; |
|
61 | + } |
|
62 | + |
|
63 | + /** |
|
64 | + * @param int $id |
|
65 | + */ |
|
66 | + public function setId($id) |
|
67 | + { |
|
68 | + $this->id = $id; |
|
69 | + } |
|
70 | + |
|
71 | + /** |
|
72 | + * @return User |
|
73 | + */ |
|
74 | + public function getUser(): User |
|
75 | + { |
|
76 | + return $this->user; |
|
77 | + } |
|
78 | + |
|
79 | + /** |
|
80 | + * @param \User $user |
|
81 | + */ |
|
82 | + public function setUser($user) |
|
83 | + { |
|
84 | + $this->user = $user; |
|
85 | + } |
|
86 | + |
|
87 | + /** |
|
88 | + * @return string |
|
89 | + */ |
|
90 | + public function getMethod(): string |
|
91 | + { |
|
92 | + return $this->method; |
|
93 | + } |
|
94 | + |
|
95 | + /** |
|
96 | + * @param string $method |
|
97 | + * @return UserLogs |
|
98 | + */ |
|
99 | + public function setMethod(string $method): UserLogs |
|
100 | + { |
|
101 | + $this->method = $method; |
|
102 | + |
|
103 | + return $this; |
|
104 | + } |
|
105 | + |
|
106 | + /** |
|
107 | + * @return string |
|
108 | + */ |
|
109 | + public function getUrl(): string |
|
110 | + { |
|
111 | + return $this->url; |
|
112 | + } |
|
113 | + |
|
114 | + /** |
|
115 | + * @param string $url |
|
116 | + * @return UserLogs |
|
117 | + */ |
|
118 | + public function setUrl(string $url): UserLogs |
|
119 | + { |
|
120 | + $this->url = $url; |
|
121 | + |
|
122 | + return $this; |
|
123 | + } |
|
124 | + |
|
125 | + |
|
126 | + public function getRequestParameters() |
|
127 | + { |
|
128 | + return $this->request_parameters; |
|
129 | + } |
|
130 | + |
|
131 | + /** |
|
132 | + * @param $request_parameters |
|
133 | + * @return UserLogs |
|
134 | + */ |
|
135 | + public function setRequestParameters($request_parameters): UserLogs |
|
136 | + { |
|
137 | + $this->request_parameters = $request_parameters; |
|
138 | + |
|
139 | + return $this; |
|
140 | + } |
|
141 | 141 | } |
142 | 142 |
@@ -14,8 +14,8 @@ |
||
14 | 14 | */ |
15 | 15 | class Navigation |
16 | 16 | { |
17 | - use GuidTrait; |
|
18 | - use CreatedUpdatedTrait; |
|
17 | + use GuidTrait; |
|
18 | + use CreatedUpdatedTrait; |
|
19 | 19 | |
20 | 20 | /** |
21 | 21 | * @var integer |