Oct 3 fixes (#9148)

* Only show level after yesterdailies modal

* Fixed zindex

* Added spcial spells to rewards column

* Added single click buy for health and armoire

* Prevented task scoring when casting a spell

* Renamed generic purchase method

* Updated nav for small screen

* Hide checklist while casting
This commit is contained in:
Keith Holliday
2017-10-03 16:33:01 -05:00
committed by GitHub
parent 4fa3046104
commit 0aa16d7021
8 changed files with 246 additions and 191 deletions

View File

@@ -18,6 +18,7 @@
.task-notes.small-text(v-markdown="task.notes")
.checklist(v-if="canViewchecklist")
label.custom-control.custom-checkbox.checklist-item(
v-if='!castingSpell',
v-for="item in task.checklist", :class="{'checklist-item-done': item.completed}",
)
input.custom-control-input(type="checkbox", :checked="item.completed", @change="toggleChecklistItem(item)")
@@ -339,7 +340,10 @@ export default {
};
},
computed: {
...mapState({user: 'user.data'}),
...mapState({
user: 'user.data',
castingSpell: 'spellOptions.castingSpell',
}),
...mapGetters({
getTagsFor: 'tasks:getTagsFor',
getTaskClasses: 'tasks:getTaskClasses',
@@ -390,6 +394,7 @@ export default {
methods: {
...mapActions({scoreChecklistItem: 'tasks:scoreChecklistItem'}),
toggleChecklistItem (item) {
if (this.castingSpell) return;
item.completed = !item.completed;
this.scoreChecklistItem({taskId: this.task._id, itemId: item.id});
},
@@ -407,6 +412,8 @@ export default {
this.$root.$emit('castEnd', task, 'task', e);
},
async score (direction) {
if (this.castingSpell) return;
// TODO move to an action
const Content = this.$store.state.content;
const user = this.user;