[FIX] project: correctly delete the personal stage group in kanban view
Before this commit, when the user removes a personal stage in Project app and this personal stage has some tasks, the kanban model will reload the data instead of delete the group. However, since the `default_group_by` is personal stages then the group deleted stays visible in the UI even if it is deleted for the backend side. This commit flags the group deleted to avoid readd the empty group when the reload is done to correctly remove the group in the UI. task-2968326 closes odoo/odoo#105801 X-original-commit: ad5a569b6ee50cc2c643975b52f23b9df385b753 Related: odoo/enterprise#33967 Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com> Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
This commit is contained in:
@@ -12,9 +12,10 @@ export class ProjectTaskKanbanGroup extends KanbanModel.Group {
|
||||
|
||||
async delete() {
|
||||
if (this.isPersonalStageGroup) {
|
||||
this.deleted = true;
|
||||
return await this.model.orm.call(this.resModel, 'remove_personal_stage', [this.resId]);
|
||||
} else {
|
||||
return super.delete();
|
||||
return await super.delete();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user