Group tasks ui picked (#7996)

* Added initial group tasks ui

* Changed group compnent directory

* Added group task checklist support

* Added checklist support to ui

* Fixed delete tags route

* Added checklist routes to support new group tasks

* Added assign user tag input

* Added new group members autocomplete directive

* Linked assign ui to api

* Added styles

* Limited tag use

* Fixed line endings

* Updated to new file structure

* Fixed failing task tests

* Updatd with new checklist logic and fixed columns

* Added purchased info to group and prevented non purchased group from seeing new group tasks

* Updated add task function

* Added userid check back to tag routes

* Marked tag tests as pending

* Added comments to pending tests

* Added back routes accidently deleted

* Added locale strings

* Other clarity fixes

* Moved common task function to task service

* Removed files from manifest

* Fixed naming collision and remove logic

* Removed group get tasks until live

* Fixed test to check update task. Removed extra removeTask call. Synced updated checklists. Added purchased to noset

* Fixed delete group task
This commit is contained in:
Keith Holliday
2016-10-03 13:12:20 -07:00
committed by Matteo Pagliazzi
parent 6a82206f81
commit 285041cdee
30 changed files with 1325 additions and 370 deletions

View File

@@ -159,11 +159,11 @@ window.habitrpg = angular.module('habitrpg',
url: '/:gid',
templateUrl: 'partials/options.social.guilds.detail.html',
title: env.t('titleGuilds'),
controller: ['$scope', 'Groups', 'Chat', '$stateParams', 'Members', 'Challenges',
function($scope, Groups, Chat, $stateParams, Members, Challenges){
controller: ['$scope', 'Groups', 'Chat', '$stateParams', 'Members', 'Challenges', 'Tasks',
function($scope, Groups, Chat, $stateParams, Members, Challenges, Tasks) {
Groups.Group.get($stateParams.gid)
.then(function (response) {
$scope.group = response.data.data;
$scope.obj = $scope.group = response.data.data;
Chat.markChatSeen($scope.group._id);
Members.getGroupMembers($scope.group._id)
.then(function (response) {
@@ -177,7 +177,16 @@ window.habitrpg = angular.module('habitrpg',
.then(function (response) {
$scope.group.challenges = response.data.data;
});
});
//@TODO: Add this back when group tasks go live
// return Tasks.getGroupTasks($scope.group._id);
})
// .then(function (response) {
// var tasks = response.data.data;
// tasks.forEach(function (element, index, array) {
// if (!$scope.group[element.type + 's']) $scope.group[element.type + 's'] = [];
// $scope.group[element.type + 's'].push(element);
// })
// });
}]
})