labelService->find($this->request->getParam('labelId')); return new DataResponse($label, HTTP::STATUS_OK); } /** * Create a new label */ #[NoAdminRequired] #[NoCSRFRequired] #[CORS] public function create(string $title, string $color): DataResponse { $label = $this->labelService->create($title, $color, $this->request->getParam('boardId')); return new DataResponse($label, HTTP::STATUS_OK); } /** * Update a specific label */ #[NoAdminRequired] #[NoCSRFRequired] #[CORS] public function update(string $title, string $color): DataResponse { $label = $this->labelService->update($this->request->getParam('labelId'), $title, $color); return new DataResponse($label, HTTP::STATUS_OK); } /** * Delete a specific label */ #[NoAdminRequired] #[NoCSRFRequired] #[CORS] public function delete(): DataResponse { $label = $this->labelService->delete($this->request->getParam('labelId')); return new DataResponse($label, HTTP::STATUS_OK); } }