[IMP] Improved project and opportunities kanban view. Use KanbanRecord#on_card_clicked

bzr revid: fme@openerp.com-20120524160752-rl0by5v4g1n22syl
This commit is contained in:
Fabien Meghazi 2012-05-24 18:07:52 +02:00
parent b70dd5534f
commit c78ca8dd35
3 changed files with 13 additions and 3 deletions

View File

@ -264,13 +264,13 @@
<li><ul class="oe_kanban_colorpicker" data-field="color"/></li>
</ul>
<div class="oe_kanban_content">
<a type="edit"><h3>
<h3>
<field name="partner_id"/>
<t t-if="record.planned_revenue.raw_value">
- <t t-esc="Math.round(record.planned_revenue.value)"/>
<field name="company_currency"/>
</t>
</h3></a>
</h3>
<div>
<b> <field name="partner_address_name"/> </b>
</div>

View File

@ -196,7 +196,7 @@
<li><ul class="oe_kanban_colorpicker" data-field="color"/></li>
</ul>
<div class="oe_kanban_content">
<a type="edit"><h3 class="oe_kanban_ellipsis"><field name="name"/></h3></a>
<h3 class="oe_kanban_ellipsis"><field name="name"/></h3>
<div class="oe_kanban_project_list">
<a t-if="record.use_tasks.raw_value"

View File

@ -23,4 +23,14 @@ openerp.project = function(openerp) {
}
}
});
openerp.web_kanban.KanbanRecord.include({
on_card_clicked: function() {
if (this.view.dataset.model === 'project.project') {
this.$('.oe_kanban_project_list a').first().click();
} else {
this._super.apply(this, arguments);
}
}
});
};