mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-18 23:27:26 +01:00
fix(tasks): manager lock icon, coerce task value to Number
This commit is contained in:
@@ -1046,13 +1046,17 @@ export default {
|
||||
showTaskLockIcon () {
|
||||
if (this.isUser) return false;
|
||||
if (this.isGroupTask) {
|
||||
if (this.teamManagerAccess) return false;
|
||||
if (this.isOpenTask) {
|
||||
if (!this.task.completed) return false;
|
||||
if (this.task.group.completedBy === this.user._id) return false;
|
||||
return true;
|
||||
}
|
||||
if (this.task.group.assignedUsers.indexOf(this.user._id) !== -1) return false;
|
||||
if (
|
||||
this.task.group.assignedUsers.length > 0
|
||||
&& this.task.group.assignedUsers.indexOf(this.user._id) === -1
|
||||
) return true;
|
||||
if (this.teamManagerAccess) return false;
|
||||
}
|
||||
return true;
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user