Group plans reorder tasks (#8358)

* Added move route for group tasks

* Added group task reorder to front end

* Added syncing with group task order

* Fixed linting issues

* Added missing exec and abstracted move code

* Added unit test for moveTask
This commit is contained in:
Keith Holliday
2017-01-11 11:16:20 -07:00
committed by Matteo Pagliazzi
parent 2690caed35
commit 1590d955cd
9 changed files with 191 additions and 21 deletions

View File

@@ -158,6 +158,13 @@ angular.module('habitrpg')
});
};
function moveGroupTask (taskId, position) {
return $http({
method: 'POST',
url: '/api/v3/group-tasks/' + taskId + '/move/to/' + position,
});
};
function addChecklistItem (taskId, checkListItem) {
return $http({
method: 'POST',
@@ -408,5 +415,6 @@ angular.module('habitrpg')
getGroupApprovals: getGroupApprovals,
approve: approve,
moveGroupTask: moveGroupTask,
};
}]);