[FIX] coding_guidelines: fix the alphabetic orders for the import
In odoo, as we suggest everyone to follow an alphebetic order.
The translator(`_`), ASCII is 95 and `a` ASCII value is 97
which '_' < 'a', the translator should be defined first in the
import before the `api` not at the end of the import
This commits adds an example to import static class `Command`
with a Capital alphabet with a ASCII value of `C` as 67
which will be before than the `_`
'C' < '_' < 'a'
This order of import should be followed while the import
closes odoo/documentation#11992
X-original-commit: c7a6b67a87
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
This commit is contained in:
parent
4b9939c579
commit
203bbe60a8
@ -424,7 +424,7 @@ Inside these 3 groups, the imported lines are alphabetically sorted.
|
||||
import time
|
||||
from datetime import datetime
|
||||
# 2 : imports of odoo
|
||||
from odoo import api, fields, models # alphabetically ordered
|
||||
from odoo import Command, _, api, fields, models # alphabetically ordered
|
||||
from odoo.fields import Domain
|
||||
from odoo.tools.safe_eval import safe_eval as eval
|
||||
# 3 : imports from odoo addons
|
||||
|
Loading…
Reference in New Issue
Block a user