Apply column restrictions to the board
This commit is contained in:
@@ -28,11 +28,21 @@ class BoardAjaxController extends BaseController
|
||||
}
|
||||
|
||||
$values = $this->request->getJson();
|
||||
$canMoveTask = $this->columnMoveRestrictionModel->isAllowed(
|
||||
$project_id,
|
||||
$this->helper->user->getProjectUserRole($project_id),
|
||||
$values['src_column_id'],
|
||||
$values['dst_column_id']
|
||||
);
|
||||
|
||||
if (! $canMoveTask) {
|
||||
throw new AccessForbiddenException("You don't have the permission to move this task");
|
||||
}
|
||||
|
||||
$result =$this->taskPositionModel->movePosition(
|
||||
$project_id,
|
||||
$values['task_id'],
|
||||
$values['column_id'],
|
||||
$values['dst_column_id'],
|
||||
$values['position'],
|
||||
$values['swimlane_id']
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user