mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-17 22:57:21 +01:00
Refactoring & Feature: edit/delete controls of tasks (#11357)
* Refactoring & Feature: edit/delete group and challenge tasks - Remove showOption from tasks props - Pass all needed data to task for understand in mapGetter function which controls we should show - Improve current solution with edit and delete logic * Fix: this in template * Fix & Test: extend tests, fix can Edit/Delete functions
This commit is contained in:
committed by
Matteo Pagliazzi
parent
c6281b6f17
commit
70b6501135
@@ -45,10 +45,10 @@
|
||||
v-for="task in taskList",
|
||||
:key="task.id", :task="task",
|
||||
:isUser="isUser",
|
||||
:showOptions="showOptions"
|
||||
@editTask="editTask",
|
||||
@moveTo="moveTo",
|
||||
:group='group',
|
||||
:challenge="challenge"
|
||||
v-on:taskDestroyed='taskDestroyed'
|
||||
)
|
||||
template(v-if="hasRewardsList")
|
||||
@@ -312,10 +312,7 @@ export default {
|
||||
selectedTags: {},
|
||||
taskListOverride: {},
|
||||
group: {},
|
||||
showOptions: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
challenge: {},
|
||||
}, // @TODO: maybe we should store the group on state?
|
||||
data () {
|
||||
const icons = Object.freeze({
|
||||
|
||||
Reference in New Issue
Block a user