2
.. i18n: Developing modules
3
.. i18n: -------------------
10
.. i18n: single: modules development
15
single: modules development
25
.. i18n: Here you will find information about the organisation of the community in
26
.. i18n: OpenERP project. It includes a description of the different tools used, the role
27
.. i18n: of the different actors, and the different process for improvement management.
30
Here you will find information about the organisation of the community in
31
OpenERP project. It includes a description of the different tools used, the role
32
of the different actors, and the different process for improvement management.
34
.. i18n: The whole organisation is managed through our launchpad projects: http://launchpad.net
35
.. i18n: Our projects on launchpad are currently organised like this:
38
The whole organisation is managed through our launchpad projects: http://launchpad.net
39
Our projects on launchpad are currently organised like this:
41
.. i18n: +----------------------------+----------------------------------------------+--------------------------------------------+
42
.. i18n: | **Project name** | **URL** | **Description** |
43
.. i18n: +============================+==============================================+============================================+
45
.. i18n: | **openobject** | https://launchpad.net/openobject | the main super-project (group) where all |
46
.. i18n: | | | bugs, features and faq are managed |
48
.. i18n: +----------------------------+----------------------------------------------+--------------------------------------------+
50
.. i18n: | **openobject-addons** | https://launchpad.net/openobject-addons | the project for core OpenERP modules |
52
.. i18n: +----------------------------+----------------------------------------------+--------------------------------------------+
54
.. i18n: | **openobject-server** | https://launchpad.net/openobject-server | the OpenERP server |
56
.. i18n: +----------------------------+----------------------------------------------+--------------------------------------------+
58
.. i18n: | **openerp-web** | https://launchpad.net/openerp-web | the web client for OpenERP 6.1 and newer |
59
.. i18n: | | | versions |
61
.. i18n: +----------------------------+----------------------------------------------+--------------------------------------------+
63
.. i18n: | **openobject-client** | https://launchpad.net/openobject-client | the native client (gtk) for OpenERP 6.1 |
64
.. i18n: | | | and earlier |
66
.. i18n: +----------------------------+----------------------------------------------+--------------------------------------------+
68
.. i18n: | **openobject-client-web** | https://launchpad.net/openobject-client-web | the web client for OpenERP 6.0 and earlier |
69
.. i18n: | | | versions |
71
.. i18n: +----------------------------+----------------------------------------------+--------------------------------------------+
74
+----------------------------+----------------------------------------------+--------------------------------------------+
75
| **Project name** | **URL** | **Description** |
76
+============================+==============================================+============================================+
78
| **openobject** | https://launchpad.net/openobject | the main super-project (group) where all |
79
| | | bugs, features and faq are managed |
81
+----------------------------+----------------------------------------------+--------------------------------------------+
83
| **openobject-addons** | https://launchpad.net/openobject-addons | the project for core OpenERP modules |
85
+----------------------------+----------------------------------------------+--------------------------------------------+
87
| **openobject-server** | https://launchpad.net/openobject-server | the OpenERP server |
89
+----------------------------+----------------------------------------------+--------------------------------------------+
91
| **openerp-web** | https://launchpad.net/openerp-web | the web client for OpenERP 6.1 and newer |
94
+----------------------------+----------------------------------------------+--------------------------------------------+
96
| **openobject-client** | https://launchpad.net/openobject-client | the native client (gtk) for OpenERP 6.1 |
99
+----------------------------+----------------------------------------------+--------------------------------------------+
101
| **openobject-client-web** | https://launchpad.net/openobject-client-web | the web client for OpenERP 6.0 and earlier |
104
+----------------------------+----------------------------------------------+--------------------------------------------+
106
.. i18n: Getting Sources
107
.. i18n: +++++++++++++++
113
.. i18n: Please refer to :ref:`how-to-get-the-latest-trunk-source-code-link` in the Bazaar section
116
Please refer to :ref:`how-to-get-the-latest-trunk-source-code-link` in the Bazaar section
118
.. i18n: If you don't know the Bazaar version control system, please read the :ref:`documentation on Bazaar <bazaar-link>`
121
If you don't know the Bazaar version control system, please read the :ref:`documentation on Bazaar <bazaar-link>`
123
.. i18n: Community Addons
124
.. i18n: ++++++++++++++++
130
.. i18n: OpenERP modules developed by the community were historically published in a shared source
131
.. i18n: code branch on Launchpad, nicknamed ``extra-addons``: https://code.launchpad.net/~openerp-commiter/openobject-addons/trunk-extra-addons
134
OpenERP modules developed by the community were historically published in a shared source
135
code branch on Launchpad, nicknamed ``extra-addons``: https://code.launchpad.net/~openerp-commiter/openobject-addons/trunk-extra-addons
137
.. i18n: As of 2012 and the release of OpenERP 6.1, this shared branch is being phased out, due to several downsides to this
138
.. i18n: organization, such as:
141
As of 2012 and the release of OpenERP 6.1, this shared branch is being phased out, due to several downsides to this
142
organization, such as:
144
.. i18n: * difficult to enforce access control on the modules (commit right is all or nothing)
145
.. i18n: * difficult to enforce quality (therefore impossible to rely on it for customer projects)
146
.. i18n: * commit history mixes all modules
147
.. i18n: * download/checkout of the branch requires to fetch all modules at once
150
* difficult to enforce access control on the modules (commit right is all or nothing)
151
* difficult to enforce quality (therefore impossible to rely on it for customer projects)
152
* commit history mixes all modules
153
* download/checkout of the branch requires to fetch all modules at once
155
.. i18n: A better organization was discussed on the OpenERP `mailing-lists <https://lists.launchpad.net/openerp-expert-framework/msg00948.html>`_,
156
.. i18n: with the `following goals <https://lists.launchpad.net/openerp-expert-framework/msg00997.html>`_:
159
A better organization was discussed on the OpenERP `mailing-lists <https://lists.launchpad.net/openerp-expert-framework/msg00948.html>`_,
160
with the `following goals <https://lists.launchpad.net/openerp-expert-framework/msg00997.html>`_:
162
.. i18n: * To get rid of the big extra-addons branch
163
.. i18n: * To join efforts on the same topic in order to avoid too many modules for a same feature
164
.. i18n: * To become more aware of the developments that have been done by others
165
.. i18n: * To start working with merge proposal between us
166
.. i18n: * To improve the quality of our code
169
* To get rid of the big extra-addons branch
170
* To join efforts on the same topic in order to avoid too many modules for a same feature
171
* To become more aware of the developments that have been done by others
172
* To start working with merge proposal between us
173
* To improve the quality of our code
175
.. i18n: The community modules have therefore been split into separate Launchpad project and
176
.. i18n: their respective branches. When possible, existing ones were reused. All listed projects
177
.. i18n: provide a short description of the kind of modules you can find/merge into.
180
The community modules have therefore been split into separate Launchpad project and
181
their respective branches. When possible, existing ones were reused. All listed projects
182
provide a short description of the kind of modules you can find/merge into.
184
.. i18n: The community welcomes everyone on board to join efforts! In order to add your own modules in the appropriate project,
185
.. i18n: you should use merge proposals. Depending on the volume, some time might be needed at the beginning to review everything.
186
.. i18n: So thank you all in advance for your patience during this transition period.
189
The community welcomes everyone on board to join efforts! In order to add your own modules in the appropriate project,
190
you should use merge proposals. Depending on the volume, some time might be needed at the beginning to review everything.
191
So thank you all in advance for your patience during this transition period.
193
.. i18n: For all of these projects, the rules we expect you to adhere to and respect are:
196
For all of these projects, the rules we expect you to adhere to and respect are:
198
.. i18n: * No company-related prefix or suffix in the module names (like ``c2c-account-something``);
199
.. i18n: * Always make merge proposal for any bugfix or improvement so that everyone can take note of it and eventually ask for a different approach;
200
.. i18n: * Nobody merge his/her own work into the branch. Another member of the team must do it. Exceptions may be accepted if the merge proposal has been strongly approved by the rest of the team;
201
.. i18n: * If your module doesn’t fit into any of the available projects, or you found no related team, please post a request on the `framework expert mailing list <https://launchpad.net/~openerp-expert-framework>`_ so that we can create a specific one for you;
202
.. i18n: * When at least one of your modules has been approved in the branch, you may ask to be part of the team. If you are not part of the team, you can still contribute to the project through merge proposals;
203
.. i18n: * Use the available teams (see :ref:`community_contrib_teams` section) according to their topics (it means that you always need to attribute a new project to these teams, so as to avoid having hundreds of them).
206
* No company-related prefix or suffix in the module names (like ``c2c-account-something``);
207
* Always make merge proposal for any bugfix or improvement so that everyone can take note of it and eventually ask for a different approach;
208
* Nobody merge his/her own work into the branch. Another member of the team must do it. Exceptions may be accepted if the merge proposal has been strongly approved by the rest of the team;
209
* If your module doesn’t fit into any of the available projects, or you found no related team, please post a request on the `framework expert mailing list <https://launchpad.net/~openerp-expert-framework>`_ so that we can create a specific one for you;
210
* When at least one of your modules has been approved in the branch, you may ask to be part of the team. If you are not part of the team, you can still contribute to the project through merge proposals;
211
* Use the available teams (see :ref:`community_contrib_teams` section) according to their topics (it means that you always need to attribute a new project to these teams, so as to avoid having hundreds of them).
213
.. i18n: Should you have any suggestions related to the above rules, please feel free to post them on the framework expert mailing list.
216
Should you have any suggestions related to the above rules, please feel free to post them on the framework expert mailing list.
218
.. i18n: Community Projects
219
.. i18n: ^^^^^^^^^^^^^^^^^^
220
.. i18n: The list of the official community projects/topics can be found under this project group: https://launchpad.net/openobject,
221
.. i18n: and is summarized below.
226
The list of the official community projects/topics can be found under this project group: https://launchpad.net/openobject,
227
and is summarized below.
229
.. i18n: * Stock and Logistic Barcode: https://launchpad.net/stock-logistic-barcode
230
.. i18n: * Stock and Logistic Warehouse: https://launchpad.net/stock-logistic-warehouse
231
.. i18n: * Stock and Logistic Tracking: https://launchpad.net/stock-logistic-tracking
232
.. i18n: * Stock and Logistic Flows: https://launchpad.net/stock-logistic-flows
233
.. i18n: * Stock and Logistic - Reports: https://launchpad.net/stock-logistic-report
234
.. i18n: * Carriers And Deliveries Management: https://launchpad.net/carriers-deliveries
235
.. i18n: * Banking Addons: https://launchpad.net/banking-addons
236
.. i18n: * Contact and Partner Management: https://launchpad.net/partner-contact-management
237
.. i18n: * Purchase - Workflow and Organization: https://launchpad.net/purchase-wkfl
238
.. i18n: * Purchase - Financial Controlling: https://launchpad.net/purchase-financial
239
.. i18n: * Purchase - Reports: https://launchpad.net/purchase-report
240
.. i18n: * Sales - Financial Controlling: https://launchpad.net/sale-financial
241
.. i18n: * Sales - Workflow and Organization: https://launchpad.net/sale-wkfl
242
.. i18n: * Sales - Reports: https://launchpad.net/sale-reports
243
.. i18n: * Product - Kitting Management: https://launchpad.net/product-kitting
244
.. i18n: * OpenERP Product Attributes : https://launchpad.net/openerp-product-attributes
245
.. i18n: * Account - Financial Report: https://launchpad.net/account-financial-report
246
.. i18n: * Account - Analytic Accounting: https://launchpad.net/account-analytic
247
.. i18n: * Account - Budgeting: https://launchpad.net/account-budgeting
248
.. i18n: * Account - Invoicing Reports: https://launchpad.net/account-invoice-report
249
.. i18n: * Account Payment Addons: https://launchpad.net/account-payment
250
.. i18n: * Account - Closing: https://launchpad.net/account-closing
251
.. i18n: * Account - Consolidation: https://launchpad.net/account-consolidation
252
.. i18n: * Account - Financial Tools: https://launchpad.net/account-financial-tools
253
.. i18n: * Account - Invoicing: https://launchpad.net/account-invoicing
254
.. i18n: * Contract management: https://launchpad.net/contract-management
255
.. i18n: * OpenERP Fiscal Rule: https://launchpad.net/openerp-fiscal-rules
256
.. i18n: * Margin Analysis: https://launchpad.net/margin-analysis
257
.. i18n: * Medical in OpenERP : https://launchpad.net/oemedical
258
.. i18n: * Construction : https://launchpad.net/openerp-construction
259
.. i18n: * Project Management - Invoicing and Reporting: https://launchpad.net/project-reporting
260
.. i18n: * Project Management - Services: https://launchpad.net/project-service
261
.. i18n: * HR - Timesheet Management: https://launchpad.net/hr-timesheet
262
.. i18n: * Hotel Management System on OpenERP : https://launchpad.net/hotel-management-system
263
.. i18n: * Department Management: https://launchpad.net/department-mgmt
264
.. i18n: * Server Environment And Tools: https://launchpad.net/server-env-tools
265
.. i18n: * Webkit Utils: https://launchpad.net/webkit-utils
266
.. i18n: * E-Commerce addons: https://launchpad.net/e-commerce-addons
267
.. i18n: * Report - Printing and Sending: https://launchpad.net/report-print-send
268
.. i18n: * Management Systems : https://launchpad.net/openerp-mgmtsystem
269
.. i18n: * Web-Addons for OpenERP : https://launchpad.net/web-addons
270
.. i18n: * Geospatial Addons for OpenERP : https://launchpad.net/geospatial-addons
273
* Stock and Logistic Barcode: https://launchpad.net/stock-logistic-barcode
274
* Stock and Logistic Warehouse: https://launchpad.net/stock-logistic-warehouse
275
* Stock and Logistic Tracking: https://launchpad.net/stock-logistic-tracking
276
* Stock and Logistic Flows: https://launchpad.net/stock-logistic-flows
277
* Stock and Logistic - Reports: https://launchpad.net/stock-logistic-report
278
* Carriers And Deliveries Management: https://launchpad.net/carriers-deliveries
279
* Banking Addons: https://launchpad.net/banking-addons
280
* Contact and Partner Management: https://launchpad.net/partner-contact-management
281
* Purchase - Workflow and Organization: https://launchpad.net/purchase-wkfl
282
* Purchase - Financial Controlling: https://launchpad.net/purchase-financial
283
* Purchase - Reports: https://launchpad.net/purchase-report
284
* Sales - Financial Controlling: https://launchpad.net/sale-financial
285
* Sales - Workflow and Organization: https://launchpad.net/sale-wkfl
286
* Sales - Reports: https://launchpad.net/sale-reports
287
* Product - Kitting Management: https://launchpad.net/product-kitting
288
* OpenERP Product Attributes : https://launchpad.net/openerp-product-attributes
289
* Account - Financial Report: https://launchpad.net/account-financial-report
290
* Account - Analytic Accounting: https://launchpad.net/account-analytic
291
* Account - Budgeting: https://launchpad.net/account-budgeting
292
* Account - Invoicing Reports: https://launchpad.net/account-invoice-report
293
* Account Payment Addons: https://launchpad.net/account-payment
294
* Account - Closing: https://launchpad.net/account-closing
295
* Account - Consolidation: https://launchpad.net/account-consolidation
296
* Account - Financial Tools: https://launchpad.net/account-financial-tools
297
* Account - Invoicing: https://launchpad.net/account-invoicing
298
* Contract management: https://launchpad.net/contract-management
299
* OpenERP Fiscal Rule: https://launchpad.net/openerp-fiscal-rules
300
* Margin Analysis: https://launchpad.net/margin-analysis
301
* Medical in OpenERP : https://launchpad.net/oemedical
302
* Construction : https://launchpad.net/openerp-construction
303
* Project Management - Invoicing and Reporting: https://launchpad.net/project-reporting
304
* Project Management - Services: https://launchpad.net/project-service
305
* HR - Timesheet Management: https://launchpad.net/hr-timesheet
306
* Hotel Management System on OpenERP : https://launchpad.net/hotel-management-system
307
* Department Management: https://launchpad.net/department-mgmt
308
* Server Environment And Tools: https://launchpad.net/server-env-tools
309
* Webkit Utils: https://launchpad.net/webkit-utils
310
* E-Commerce addons: https://launchpad.net/e-commerce-addons
311
* Report - Printing and Sending: https://launchpad.net/report-print-send
312
* Management Systems : https://launchpad.net/openerp-mgmtsystem
313
* Web-Addons for OpenERP : https://launchpad.net/web-addons
314
* Geospatial Addons for OpenERP : https://launchpad.net/geospatial-addons
316
.. i18n: Some of them are waiting on their owner to bring some modifications so they can fit into other projects (changing team, series,...).
317
.. i18n: Should you be one of these owners, please inform the others on the mailing-list when ready.
318
.. i18n: If some refuse to open the projects to the community, it is always possibel to create another project.
321
Some of them are waiting on their owner to bring some modifications so they can fit into other projects (changing team, series,...).
322
Should you be one of these owners, please inform the others on the mailing-list when ready.
323
If some refuse to open the projects to the community, it is always possibel to create another project.
325
.. i18n: Misc Guidelines
326
.. i18n: +++++++++++++++
339
.. i18n: Organisation of files in modules
340
.. i18n: ################################
343
Organisation of files in modules
344
################################
346
.. i18n: .. === Organisation of files in modules ===
349
.. === Organisation of files in modules ===
351
.. i18n: The structure of a module should be::
353
.. i18n: /module_name/
354
.. i18n: /module_name/__init__.py
355
.. i18n: /module_name/__openerp__.py
356
.. i18n: /module_name/i18n
357
.. i18n: /module_name/i18n/module_name.pot
358
.. i18n: /module_name/images/
359
.. i18n: /module_name/images/screenshot.png
360
.. i18n: /module_name/migrations
361
.. i18n: /module_name/module.py
362
.. i18n: /module_name/module_view.xml
363
.. i18n: /module_name/module_wizard.xml
364
.. i18n: /module_name/module_report.xml
365
.. i18n: /module_name/module_data.xml
366
.. i18n: /module_name/module_demo.xml
367
.. i18n: /module_name/module_security.xml
368
.. i18n: /module_name/wizard/
369
.. i18n: /module_name/wizard/__init__.py
370
.. i18n: /module_name/wizard/wizard_name.py
371
.. i18n: /module_name/wizard/wizard_name_view.xml
372
.. i18n: /module_name/wizard/wizard_name_workflow.xml
373
.. i18n: /module_name/report/
374
.. i18n: /module_name/report/__init__.py
375
.. i18n: /module_name/report/report_name.sxw
376
.. i18n: /module_name/report/report_name.rml
377
.. i18n: /module_name/report/report_name.py
378
.. i18n: /module_name/security
379
.. i18n: /module_name/security/ir.model.access.csv
380
.. i18n: /module_name/static/src/img/icon.png
381
.. i18n: /module_name/tests
384
The structure of a module should be::
387
/module_name/__init__.py
388
/module_name/__openerp__.py
390
/module_name/i18n/module_name.pot
392
/module_name/images/screenshot.png
393
/module_name/migrations
394
/module_name/module.py
395
/module_name/module_view.xml
396
/module_name/module_wizard.xml
397
/module_name/module_report.xml
398
/module_name/module_data.xml
399
/module_name/module_demo.xml
400
/module_name/module_security.xml
402
/module_name/wizard/__init__.py
403
/module_name/wizard/wizard_name.py
404
/module_name/wizard/wizard_name_view.xml
405
/module_name/wizard/wizard_name_workflow.xml
407
/module_name/report/__init__.py
408
/module_name/report/report_name.sxw
409
/module_name/report/report_name.rml
410
/module_name/report/report_name.py
411
/module_name/security
412
/module_name/security/ir.model.access.csv
413
/module_name/static/src/img/icon.png
423
.. i18n: Each object defined in your module must have at least one security rule
424
.. i18n: defined on it to make it accessible.
427
Each object defined in your module must have at least one security rule
428
defined on it to make it accessible.
430
.. i18n: Coding Guidelines
431
.. i18n: #################
437
.. i18n: Follow Python PEP 8: http://www.python.org/dev/peps/pep-0008/
440
Follow Python PEP 8: http://www.python.org/dev/peps/pep-0008/
449
.. i18n: General Style
450
.. i18n: #############
456
.. i18n: * use the Helvetica font everywhere
457
.. i18n: * margins (in millimeters):
460
.. i18n: - bottom: 16
461
.. i18n: - left: between 12 and 13 to allow punching holes without punching in the text area
462
.. i18n: - right: between 12 and 13
465
* use the Helvetica font everywhere
466
* margins (in millimeters):
470
- left: between 12 and 13 to allow punching holes without punching in the text area
471
- right: between 12 and 13
473
.. i18n: .. note:: the line separator between the header and the body can overlap slightly in the left and right margins: up to 9 millimeters on the left and up to 12 millimeters on the right
475
.. i18n: * for Titles use font *Helvetica-Bold* with size *14.5*
477
.. i18n: * put the context on each report: example, for the report account_balance: the context is the fiscal year and periods
479
.. i18n: * for the name of cells: use Capital Letter if the name contains more than one word (ex: Date Ordered)
480
.. i18n: * content and name of cells should have the same indentation
482
.. i18n: * for report, we can define two kinds of arrays:
484
.. i18n: - array with general information, like reference, date..., use:
486
.. i18n: + *Bold-Helvetica* and size=8 for cells name
487
.. i18n: + *Helvetica* size="8" for content
489
.. i18n: - array with detailed information, use:
491
.. i18n: + *Helvetica-Bold* size *9* for cells names
492
.. i18n: + *Helvetica* size *8* for content
495
.. note:: the line separator between the header and the body can overlap slightly in the left and right margins: up to 9 millimeters on the left and up to 12 millimeters on the right
497
* for Titles use font *Helvetica-Bold* with size *14.5*
499
* put the context on each report: example, for the report account_balance: the context is the fiscal year and periods
501
* for the name of cells: use Capital Letter if the name contains more than one word (ex: Date Ordered)
502
* content and name of cells should have the same indentation
504
* for report, we can define two kinds of arrays:
506
- array with general information, like reference, date..., use:
508
+ *Bold-Helvetica* and size=8 for cells name
509
+ *Helvetica* size="8" for content
511
- array with detailed information, use:
513
+ *Helvetica-Bold* size *9* for cells names
514
+ *Helvetica* size *8* for content
516
.. i18n: .. describe:: Headers and footers for internal reports:
518
.. i18n: * Internal report = all accounting reports and other that have only internal use (not sent to customers)
519
.. i18n: * height of headers should be shorter
520
.. i18n: * take off corporate header and footer for internal report (Use a simplified header for internal reports: Company's name, report title, printing date and page number)
524
.. i18n: - company's name: in the middle of each page
525
.. i18n: - report's name: is printed centered after the header
526
.. i18n: - printing date: not in the middle of the report, but on the left in the header
527
.. i18n: - page number: on each page, is printed on the right. This page number should contain the current page number and the total of pages. Ex: page 3/15
530
.. i18n: - to avoid wasting paper, we have taken off the footer
533
.. describe:: Headers and footers for internal reports:
535
* Internal report = all accounting reports and other that have only internal use (not sent to customers)
536
* height of headers should be shorter
537
* take off corporate header and footer for internal report (Use a simplified header for internal reports: Company's name, report title, printing date and page number)
541
- company's name: in the middle of each page
542
- report's name: is printed centered after the header
543
- printing date: not in the middle of the report, but on the left in the header
544
- page number: on each page, is printed on the right. This page number should contain the current page number and the total of pages. Ex: page 3/15
547
- to avoid wasting paper, we have taken off the footer
549
.. i18n: .. describe:: table line separator:
552
.. describe:: table line separator:
554
.. i18n: * it's prettier if each line in a table has a light grey line as separator
555
.. i18n: * use a grey column separator only for array containing general information
558
* it's prettier if each line in a table has a light grey line as separator
559
* use a grey column separator only for array containing general information
561
.. i18n: .. describe:: table breaking
563
.. i18n: * a table header should at least have two data rows (no table header alone at the bottom of the page)
564
.. i18n: * when a big table is broken, the table header is repeated on every page
567
.. describe:: table breaking
569
* a table header should at least have two data rows (no table header alone at the bottom of the page)
570
* when a big table is broken, the table header is repeated on every page
572
.. i18n: .. describe:: how to differentiate parents and children ?
574
.. i18n: * When you have more than one level, use these styles:
576
.. i18n: - for the levels 1 and 2:fontSize="8.0" fontName="Helvetica-Bold"
577
.. i18n: - from the third level, use:fontName="Helvetica" fontSize="8.0" and increase the indentation with 13 (pixels) for each level
578
.. i18n: - underline sums when the element is a parent
581
.. describe:: how to differentiate parents and children ?
583
* When you have more than one level, use these styles:
585
- for the levels 1 and 2:fontSize="8.0" fontName="Helvetica-Bold"
586
- from the third level, use:fontName="Helvetica" fontSize="8.0" and increase the indentation with 13 (pixels) for each level
587
- underline sums when the element is a parent
596
.. i18n: Naming Convention
597
.. i18n: ^^^^^^^^^^^^^^^^^
603
.. i18n: The name of the module are all lowercase, each word separated by underscores.
604
.. i18n: Always start with the most relevant words, which are preferably names of other
605
.. i18n: modules on which it depends.
608
The name of the module are all lowercase, each word separated by underscores.
609
Always start with the most relevant words, which are preferably names of other
610
modules on which it depends.
617
.. i18n: * account_invoice_layout
620
* account_invoice_layout
622
.. i18n: Information Required
623
.. i18n: ^^^^^^^^^^^^^^^^^^^^
629
.. i18n: Each module must contain at least:
632
Each module must contain at least:
635
.. i18n: * description
641
.. i18n: Modules Description
642
.. i18n: ^^^^^^^^^^^^^^^^^^^
648
.. i18n: Dependencies
649
.. i18n: ^^^^^^^^^^^^
655
.. i18n: Each module must contain:
658
Each module must contain:
660
.. i18n: * A list of dependencies amongst others modules: ['account','sale']
662
.. i18n: * Provide only highest requirement level, not need to set ['account','base','product','sale']
665
* A list of dependencies amongst others modules: ['account','sale']
667
* Provide only highest requirement level, not need to set ['account','base','product','sale']
669
.. i18n: Module Content
670
.. i18n: ^^^^^^^^^^^^^^
676
.. i18n: Each module must contain demo data for every object defined in the module.
679
Each module must contain demo data for every object defined in the module.
681
.. i18n: If you implemented workflows in the module, create demo data that passes
682
.. i18n: most branches of your workflow. You can use the module recorder to help you
683
.. i18n: build such demo data.
686
If you implemented workflows in the module, create demo data that passes
687
most branches of your workflow. You can use the module recorder to help you
688
build such demo data.
697
.. i18n: Naming Menus
698
.. i18n: ############
704
.. i18n: * Use plural forms: *Customer Invoice*, should be *Customer Invoices*
705
.. i18n: * Avoid abbreviations in menus if possible. Example: BoMs -> Bills of Materials
708
* Use plural forms: *Customer Invoice*, should be *Customer Invoices*
709
* Avoid abbreviations in menus if possible. Example: BoMs -> Bills of Materials
711
.. i18n: Order of the menus
712
.. i18n: ##################
718
.. i18n: The *Reporting* menu is at the bottom of the list, use a sequence=50.
721
The *Reporting* menu is at the bottom of the list, use a sequence=50.
723
.. i18n: Common Mistakes
724
.. i18n: ###############
730
.. i18n: * Edit Categories -> Categories
731
.. i18n: * List of Categories -> Categories
734
* Edit Categories -> Categories
735
* List of Categories -> Categories
737
.. i18n: Search Criteria
738
.. i18n: #################
744
.. i18n: Search criteria: search available on all columns of the list view
747
Search criteria: search available on all columns of the list view
749
.. i18n: Default Language
750
.. i18n: ^^^^^^^^^^^^^^^^
756
.. i18n: The default language for every development must be U.S. English.
759
The default language for every development must be U.S. English.
761
.. i18n: For menus and fields, use uppercase for all first letters, excluding conjections:
764
For menus and fields, use uppercase for all first letters, excluding conjections:
766
.. i18n: * Chart of Accounts
771
.. i18n: Field Naming Conventions
772
.. i18n: ^^^^^^^^^^^^^^^^^^^^^^^^
775
Field Naming Conventions
776
^^^^^^^^^^^^^^^^^^^^^^^^
778
.. i18n: * many2one fields should respect this regex: '.*_id'
779
.. i18n: * one2many fields should respect this regex: '.*_ids'
780
.. i18n: * one2many relation table should respect this regex: '.*_rel'
781
.. i18n: * many2many fields should respect this regex: '.*_ids'
782
.. i18n: * use underscore to separate words
783
.. i18n: * avoid using uppercase
784
.. i18n: * if a field is composed of several words, start with the most important words
787
* many2one fields should respect this regex: '.*_id'
788
* one2many fields should respect this regex: '.*_ids'
789
* one2many relation table should respect this regex: '.*_rel'
790
* many2many fields should respect this regex: '.*_ids'
791
* use underscore to separate words
792
* avoid using uppercase
793
* if a field is composed of several words, start with the most important words
795
.. i18n: Model Naming Conventions
796
.. i18n: ^^^^^^^^^^^^^^^^^^^^^^^^
799
Model Naming Conventions
800
^^^^^^^^^^^^^^^^^^^^^^^^
802
.. i18n: * All objects must start with the name of the module they are defined in.
803
.. i18n: * If an object is composed of several words, use points to separate words
806
* All objects must start with the name of the module they are defined in.
807
* If an object is composed of several words, use points to separate words
816
.. i18n: * All Tree of resources are called *XXX's Structure*, unless a dedicated term exist for the concept
818
.. i18n: - Good: Location' Structure, Chart of Accounts, Categories' Structure
819
.. i18n: - Bad: Tree of Category, Tree of Bill of Materials
822
* All Tree of resources are called *XXX's Structure*, unless a dedicated term exist for the concept
824
- Good: Location' Structure, Chart of Accounts, Categories' Structure
825
- Bad: Tree of Category, Tree of Bill of Materials