summaryrefslogtreecommitdiff
path: root/doc/reference/guidelines.rst
diff options
context:
space:
mode:
authorChristophe Simonis <chs@odoo.com>2016-04-25 14:43:44 +0200
committerChristophe Simonis <chs@odoo.com>2016-04-25 14:43:44 +0200
commitbb8f0f1fc3d0f5574938019ca69cc917a55e7962 (patch)
treea6662094bb9c307981461fdb9872195032f2da06 /doc/reference/guidelines.rst
parent9ad6a9df6e5e5654bc98c4c655848404b4e946b2 (diff)
parent4d337f72ed59d1e5260fa2bb4f3d238e6ed11415 (diff)
[MERGE] forward port of branch saas-9 up to 4d337f7
Diffstat (limited to 'doc/reference/guidelines.rst')
-rw-r--r--doc/reference/guidelines.rst6
1 files changed, 3 insertions, 3 deletions
diff --git a/doc/reference/guidelines.rst b/doc/reference/guidelines.rst
index 17e50fe89ae..e4cfe1255ec 100644
--- a/doc/reference/guidelines.rst
+++ b/doc/reference/guidelines.rst
@@ -16,7 +16,7 @@ Module structure
Directories
-----------
-A module is organised in a few directory :
+A module is organised in a few directories :
- *data/* : demo and data xml
- *models/* : models definition
@@ -129,7 +129,7 @@ When declaring a record in XML,
<field name="arch" type="xml">
<tree>
<field name="my_field_1"/>
- <field name="my_field_2" string="My Label" widget="statusbar" statusbar_visible="draft,sent,progress,done" statusbar_colors='{"invoice_except":"red","waiting_date":"blue"}' />
+ <field name="my_field_2" string="My Label" widget="statusbar" statusbar_visible="draft,sent,progress,done" />
</tree>
</field>
</record>
@@ -266,7 +266,7 @@ Inside these 3 groups, the imported lines are alphabetically sorted.
Idioms
------
-- Prefer ``%`` over ``.format()``, prefer ``%(varname)`` instead of position (This is better for translation)
+- Prefer ``%`` over ``.format()``, prefer ``%(varname)`` instead of position (This is better for translations)
- Try to avoid generators and decorators
- Always favor *Readability* over *conciseness* or using the language features or idioms.
- Use list comprehension, dict comprehension, and basic manipulation using ``map``, ``filter``, ``sum``, ... They make the code easier to read.