1
votes

When clicking on project kanban card it opens project.task kanban view instead of opening project form view.

What i want is when clicking the project kanban view it opens related project form view instead of tasks kanban.

I had a look to project.js file :

KanbanRecord.include({

    on_card_clicked: function () {

        if (this.model === 'project.project') {

            this.$('.o_project_kanban_boxes a').first().click();

        } else {

            this._super.apply(this, arguments);

        }

    },

What i need to change in this function to achieve my need ?

1

1 Answers

1
votes

If you want to do so, Just replace 'o_project_kanban_boxes' with 'o_kanban_card_manage_section'. It will give you project kanban view click into project form view in odoo.

Final Code look like below:

on_card_clicked: function () {
        if (this.model === 'project.project') {
            this.$('.o_kanban_card_manage_section a').first().click();
        } else {
            this._super.apply(this, arguments);
        }
    },

Hope it will help you.