| @@ 184-190 (lines=7) @@ | ||
| 181 | ||
| 182 | } |
|
| 183 | ||
| 184 | public function delete($id) { |
|
| 185 | $this->permissionService->checkPermission($this->boardMapper, $id, Acl::PERMISSION_READ); |
|
| 186 | $board = $this->find($id); |
|
| 187 | $board->setDeletedAt(time()); |
|
| 188 | $this->boardMapper->update($board); |
|
| 189 | return $board; |
|
| 190 | } |
|
| 191 | ||
| 192 | public function deleteUndo($id) { |
|
| 193 | $this->permissionService->checkPermission($this->boardMapper, $id, Acl::PERMISSION_READ); |
|
| @@ 192-197 (lines=6) @@ | ||
| 189 | return $board; |
|
| 190 | } |
|
| 191 | ||
| 192 | public function deleteUndo($id) { |
|
| 193 | $this->permissionService->checkPermission($this->boardMapper, $id, Acl::PERMISSION_READ); |
|
| 194 | $board = $this->find($id); |
|
| 195 | $board->setDeletedAt(0); |
|
| 196 | return $this->boardMapper->update($board); |
|
| 197 | } |
|
| 198 | ||
| 199 | public function deleteForce($id) { |
|
| 200 | $this->permissionService->checkPermission($this->boardMapper, $id, Acl::PERMISSION_READ); |
|
| @@ 83-90 (lines=8) @@ | ||
| 80 | $card->setAttachmentCount($this->attachmentService->count($cardId)); |
|
| 81 | } |
|
| 82 | ||
| 83 | public function fetchDeleted($boardId) { |
|
| 84 | $this->permissionService->checkPermission($this->boardMapper, $boardId, Acl::PERMISSION_READ); |
|
| 85 | $cards = $this->cardMapper->findDeleted($boardId); |
|
| 86 | foreach ($cards as $card) { |
|
| 87 | $this->enrich($card); |
|
| 88 | } |
|
| 89 | return $cards; |
|
| 90 | } |
|
| 91 | ||
| 92 | public function find($cardId) { |
|
| 93 | $this->permissionService->checkPermission($this->cardMapper, $cardId, Acl::PERMISSION_READ); |
|