This commit is contained in:
ivan deng
2018-10-03 22:44:19 +08:00
parent efa2cda811
commit a1432367eb
5 changed files with 32 additions and 6 deletions

View File

@@ -1,7 +1,2 @@
# -*- coding: utf-8 -*-
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
from . import models

View File

@@ -47,6 +47,7 @@
'images': ['static/description/banner.png'],
'data': [
'views/product_views.xml',
'views/temp.xml',
],
'demo': [
],

View File

@@ -0,0 +1,2 @@
from . import product

View File

@@ -0,0 +1,13 @@
# Author: Damien Crier
# Copyright 2017 Camptocamp SA
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from odoo import fields, models
class ProductTemplate(models.Model):
_inherit = 'product.template'
colorpicker = fields.Char(
string="Color Picker",
)

View File

@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record id="product_template_subcontracted_service_view_form" model="ir.ui.view">
<field name="name">product_template_subcontracted_service_view_form</field>
<field name="model">product.template</field>
<field name="inherit_id" ref="product.product_template_form_view"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='type']" position="after">
<field name="colorpicker" widget="colorpicker" attr1="test"/>
</xpath>
</field>
</record>
</odoo>