mirror of
https://github.com/OCA/manufacture.git
synced 2025-01-28 16:37:15 +02:00
[MIG] mrp_tag: Migation to 15.0
This commit is contained in:
committed by
Miquel Raïch
parent
f46f8d515a
commit
88adcb03bd
@@ -5,7 +5,7 @@
|
||||
{
|
||||
"name": "MRP Tags",
|
||||
"summary": "Allows to add multiple tags to Manufacturing Orders",
|
||||
"version": "14.0.1.0.0",
|
||||
"version": "15.0.1.0.0",
|
||||
"author": "ForgeFlow, Odoo Community Association (OCA)",
|
||||
"website": "https://github.com/OCA/manufacture",
|
||||
"category": "Purchases",
|
||||
|
||||
@@ -9,13 +9,13 @@ from odoo import fields, models
|
||||
|
||||
class MrpTag(models.Model):
|
||||
_name = "mrp.tag"
|
||||
_description = "mrp Tag"
|
||||
_description = "MRP Tag"
|
||||
|
||||
def _get_default_color(self):
|
||||
return randint(1, 11)
|
||||
|
||||
name = fields.Char("Tag Name", required=True, translate=True)
|
||||
color = fields.Integer("Color", default=_get_default_color)
|
||||
color = fields.Integer("Tag Color", default=_get_default_color)
|
||||
|
||||
_sql_constraints = [
|
||||
("tag_name_uniq", "unique (name)", "Tag name already exists !"),
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
<field name="name">mrp.tag.view.tree</field>
|
||||
<field name="model">mrp.tag</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Tags" editable="bottom">
|
||||
<tree name="Tags" editable="bottom">
|
||||
<field name="name" />
|
||||
<field name="color" widget="color_picker" />
|
||||
</tree>
|
||||
|
||||
Reference in New Issue
Block a user