@@ -82,7 +82,7 @@ |
||
| 82 | 82 | |
| 83 | 83 | $this->headers['Content-Description'] = ['File Transfer']; |
| 84 | 84 | $this->headers['Content-Type'] = [$mimetype]; |
| 85 | - $this->headers['Content-Disposition'] = ['attachment; filename="' . $filename . '"']; |
|
| 85 | + $this->headers['Content-Disposition'] = ['attachment; filename="' . $filename . '"']; |
|
| 86 | 86 | $this->headers['Expires'] = ['0']; |
| 87 | 87 | $this->headers['Cache-Control'] = ['must-revalidate']; |
| 88 | 88 | $this->headers['Pragma'] = ['public']; |
@@ -135,8 +135,8 @@ |
||
| 135 | 135 | { |
| 136 | 136 | $id = (int) $request->getAttribute('id'); |
| 137 | 137 | $role = $this->roleRepository |
| 138 | - ->with('permissions') |
|
| 139 | - ->find($id); |
|
| 138 | + ->with('permissions') |
|
| 139 | + ->find($id); |
|
| 140 | 140 | if (!$role) { |
| 141 | 141 | $this->flash->setError($this->lang->tr('Can not find the role')); |
| 142 | 142 | $this->logger->warning('Can not find role with id {id}', ['id' => $id]); |
@@ -135,8 +135,8 @@ |
||
| 135 | 135 | { |
| 136 | 136 | $id = (int) $request->getAttribute('id'); |
| 137 | 137 | $user = $this->userRepository |
| 138 | - ->with('roles') |
|
| 139 | - ->find($id); |
|
| 138 | + ->with('roles') |
|
| 139 | + ->find($id); |
|
| 140 | 140 | if (!$user) { |
| 141 | 141 | $this->flash->setError($this->lang->tr('Can not find the user')); |
| 142 | 142 | $this->logger->warning('Can not find user with id {id}', ['id' => $id]); |
@@ -126,16 +126,16 @@ |
||
| 126 | 126 | |
| 127 | 127 | $currentPage = (int)$param->get('page', 1); |
| 128 | 128 | $this->pagination->setTotalItems($totalItems) |
| 129 | - ->setCurrentPage($currentPage); |
|
| 129 | + ->setCurrentPage($currentPage); |
|
| 130 | 130 | $limit = $this->pagination->getItemsPerPage(); |
| 131 | 131 | $offset = $this->pagination->getOffset(); |
| 132 | 132 | ////////// END PAGINATION ////////////////// |
| 133 | 133 | |
| 134 | 134 | $users = $this->userRepository |
| 135 | - ->limit($offset, $limit) |
|
| 136 | - ->orderBy(['lastname', 'firstname']) |
|
| 137 | - ->filters($filters) |
|
| 138 | - ->all(); |
|
| 135 | + ->limit($offset, $limit) |
|
| 136 | + ->orderBy(['lastname', 'firstname']) |
|
| 137 | + ->filters($filters) |
|
| 138 | + ->all(); |
|
| 139 | 139 | |
| 140 | 140 | $statusList = [ |
| 141 | 141 | 'D' => 'Deactive', |
@@ -124,7 +124,7 @@ |
||
| 124 | 124 | ->filter($filters) |
| 125 | 125 | ->count('id'); |
| 126 | 126 | |
| 127 | - $currentPage = (int)$param->get('page', 1); |
|
| 127 | + $currentPage = (int) $param->get('page', 1); |
|
| 128 | 128 | $this->pagination->setTotalItems($totalItems) |
| 129 | 129 | ->setCurrentPage($currentPage); |
| 130 | 130 | $limit = $this->pagination->getItemsPerPage(); |
@@ -94,18 +94,18 @@ |
||
| 94 | 94 | public function setValidationRules(): void |
| 95 | 95 | { |
| 96 | 96 | $this->addRules('code', [ |
| 97 | - new NotEmpty(), |
|
| 98 | - new MinLength(2), |
|
| 99 | - new AlphaNumericDash() |
|
| 97 | + new NotEmpty(), |
|
| 98 | + new MinLength(2), |
|
| 99 | + new AlphaNumericDash() |
|
| 100 | 100 | ]); |
| 101 | 101 | |
| 102 | 102 | $this->addRules('description', [ |
| 103 | - new NotEmpty(), |
|
| 104 | - new MinLength(3) |
|
| 103 | + new NotEmpty(), |
|
| 104 | + new MinLength(3) |
|
| 105 | 105 | ]); |
| 106 | 106 | |
| 107 | 107 | $this->addRules('depend', [ |
| 108 | - new MinLength(2) |
|
| 108 | + new MinLength(2) |
|
| 109 | 109 | ]); |
| 110 | 110 | } |
| 111 | 111 | } |