mirror of
https://github.com/OCA/contract.git
synced 2025-02-13 17:57:24 +02:00
[13.0][IMP] contract : show tags with colors in the contract
This commit is contained in:
@@ -13,3 +13,4 @@ class ContractTag(models.Model):
|
||||
company_id = fields.Many2one(
|
||||
"res.company", string="Company", default=lambda self: self.env.company.id,
|
||||
)
|
||||
color = fields.Integer("Color Index", default=0)
|
||||
|
||||
@@ -139,7 +139,11 @@
|
||||
required="1"
|
||||
attrs="{'readonly': [('is_terminated','=',True)]}"
|
||||
/>
|
||||
<field name="tag_ids" widget="many2many_tags" />
|
||||
<field
|
||||
name="tag_ids"
|
||||
widget="many2many_tags"
|
||||
options="{'color_field': 'color'}"
|
||||
/>
|
||||
</group>
|
||||
</group>
|
||||
<group name="recurring_invoices">
|
||||
@@ -527,6 +531,11 @@
|
||||
<field name="code" />
|
||||
<field name="journal_id" groups="account.group_account_user" />
|
||||
<field name="partner_id" />
|
||||
<field
|
||||
name="tag_ids"
|
||||
widget="many2many_tags"
|
||||
options="{'color_field': 'color'}"
|
||||
/>
|
||||
<field name="active" invisible="1" />
|
||||
<field name="company_id" groups="base.group_multi_company" />
|
||||
</tree>
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
<form>
|
||||
<group>
|
||||
<field name="name" />
|
||||
<field name="color" />
|
||||
<field
|
||||
name="company_id"
|
||||
options="{'no_create': True}"
|
||||
|
||||
Reference in New Issue
Block a user