Files
habitica/website/views/shared/tasks/task-list.jade
T
Keith Holliday 30954fe7c5 Added support for grouping tasks by challenge (#8469)
* Added support for grouping tasks by chllenge

* Fixed tests and updated default challenge model name

* Fixed broken member test

* Updated setting string

* Changed to shortName

* Began abstracting task grouping

* Added initial task directive code

* Added new directives to help with grouping of tasks

* Removed random console.log
2017-02-27 11:34:03 -07:00

22 lines
814 B
Plaintext

script(id='templates/task-list.html', type="text/ng-template")
ul(ng-init='setObj(obj)', class='{{::list.type}}s main-list',
ng-show='obj[list.type+"s"].length > 0',
hrpg-sort-tasks,
ng-if='showNormalList()')
task
div(ng-init='setObj(obj); console.log(obj)')
div(
ng-repeat="(key, taskList) in groupedList[list.type]",
ng-if='user.preferences.tasks.groupByChallenge && !$state.includes("options.social.challenges")')
h3 {{key}}
ul(class='{{::list.type}}s main-list',
ng-show='taskList.length > 0', hrpg-sort-tasks)
task
//Loads the non-sortable lists for challenges
ul(ng-init='setObj(obj)', class='{{::list.type}}s main-list',
ng-show='obj[list.type + "s"].length > 0',
ng-if='showChallengeList()')
task