3
0
Fork 0

[IMP] : Improve doc

9.0
Adil Houmadi 2015-03-03 11:05:26 +01:00
parent dcb212c58c
commit 1a9a99ff57
3 changed files with 7 additions and 11 deletions

View File

@ -1,8 +1,8 @@
=========================== ===========================
OpenERP web_widget_color module Odoo web_widget_color module
=========================== ===========================
This module aims to add a color picker to openERP/Odoo. This module aims to add a color picker to Odoo.
It's a `jsColor <http://jscolor.com/>`_ lib integration. It's a `jsColor <http://jscolor.com/>`_ lib integration.
@ -37,13 +37,11 @@ This module has been ported to 8.0
Usage Usage
===== =====
It adds a new data type ``color``. To apply it, simply change the field You need to declare a char field of at least size 7::
declaration as following::
_columns = { _columns = {
'color': fields.char( 'color': fields.char(
u"Couleur", u"Couleur",
size=7,
help=u"Toutes couleur valid css, exemple blue ou #f57900" help=u"Toutes couleur valid css, exemple blue ou #f57900"
), ),
} }
@ -52,13 +50,11 @@ declaration as following::
color = fields.Char( color = fields.Char(
string="Color", string="Color",
size=7,
help="Choose your color" help="Choose your color"
) )
In the view declaration there is nothing especial to do, In the view declaration, put widget='color' attribute in the field tag::
add the field as any other one. Here is a part of tree view example::
... ...
<field name="arch" type="xml"> <field name="arch" type="xml">

View File

@ -1,7 +1,7 @@
# -*- encoding: utf-8 -*- # -*- encoding: utf-8 -*-
############################################################################ ############################################################################
# #
# OpenERP, Open Source Web Color # Odoo, Open Source Web Color
# Copyright (C) 2012 Savoir-faire Linux (<http://www.savoirfairelinux.com>). # Copyright (C) 2012 Savoir-faire Linux (<http://www.savoirfairelinux.com>).
# Copyright (C) 2014 Anybox <http://anybox.fr> # Copyright (C) 2014 Anybox <http://anybox.fr>
# Copyright (C) 2015 Taktik SA <http://taktik.be> # Copyright (C) 2015 Taktik SA <http://taktik.be>

View File

@ -1,7 +1,7 @@
# -*- encoding: utf-8 -*- # -*- encoding: utf-8 -*-
############################################################################ ############################################################################
# #
# OpenERP, Open Source Web Widget Color # Odoo, Open Source Web Widget Color
# Copyright (C) 2012 Savoir-faire Linux (<http://www.savoirfairelinux.com>). # Copyright (C) 2012 Savoir-faire Linux (<http://www.savoirfairelinux.com>).
# Copyright (C) 2014 Anybox <http://anybox.fr> # Copyright (C) 2014 Anybox <http://anybox.fr>
# Copyright (C) 2015 Taktik SA <http://taktik.be> # Copyright (C) 2015 Taktik SA <http://taktik.be>
@ -27,7 +27,7 @@
'name': "Web Widget Color", 'name': "Web Widget Color",
'category': "web", 'category': "web",
'description': """ 'description': """
This module aims to add a color picker to openERP/Odoo. This module aims to add a color picker to Odoo.
""", """,
'version': "1.0", 'version': "1.0",
'depends': ['base', 'web'], 'depends': ['base', 'web'],