Fix flake8

This commit is contained in:
Cédric Krier committed 2013-02-17 00:35:14 +01:00
1 parent 73737cb8d0
commit 0b2dd7a878
2 files changed
+20 -20

No files matched your search

+16 -16
View File
@@ -168,19 +168,20 @@ class Template:
states={
'invisible': (~Eval('context', {}).get('company')
| Eval('account_category')),
}, help='This account will be used instead of the one defined'\
' on the category.', depends=['account_category']))
},
help='This account will be used instead of the one defined'
' on the category.', depends=['account_category']))
account_revenue = fields.Property(fields.Many2One('account.account',
'Account Revenue', domain=[
('kind', '=', 'revenue'),
('company', '=', Eval('context', {}).get('company', 0)),
], on_change=['account_category', 'account_revenue'],
states={
'invisible': (~Eval('context', {}).get('company')
| Eval('account_category')),
},
help='This account will be used instead of the one defined'\
' on the category.', depends=['account_category']))
'Account Revenue', domain=[
('kind', '=', 'revenue'),
('company', '=', Eval('context', {}).get('company', 0)),
], on_change=['account_category', 'account_revenue'],
states={
'invisible': (~Eval('context', {}).get('company')
| Eval('account_category')),
},
help='This account will be used instead of the one defined'
' on the category.', depends=['account_category']))
account_expense_used = fields.Function(fields.Many2One('account.account',
'Account Expense Used'), 'get_account')
account_revenue_used = fields.Function(fields.Many2One('account.account',
@@ -216,10 +217,9 @@ class Template:
def __setup__(cls):
super(Template, cls).__setup__()
cls._error_messages.update({
'missing_account': 'There is no account ' \
'expense/revenue defined on the product ' \
'%s (%d)',
})
'missing_account': ('There is no account '
'expense/revenue defined on the product %s (%d)'),
})
cls.category.states['required'] = Or(
cls.category.states.get('required', False),
Eval('account_category', False) | Eval('taxes_category', False))
+4 -4
View File
@@ -36,16 +36,16 @@ setup(name='trytond_account_product',
long_description=read('README'),
author='Tryton',
url='http://www.tryton.org/',
download_url="http://downloads.tryton.org/" + \
info.get('version', '0.0.1').rsplit('.', 1)[0] + '/',
download_url=("http://downloads.tryton.org/" +
info.get('version', '0.0.1').rsplit('.', 1)[0] + '/'),
package_dir={'trytond.modules.account_product': '.'},
packages=[
'trytond.modules.account_product',
'trytond.modules.account_product.tests',
],
package_data={
'trytond.modules.account_product': info.get('xml', []) \
+ ['tryton.cfg', 'locale/*.po'],
'trytond.modules.account_product': (info.get('xml', [])
+ ['tryton.cfg', 'locale/*.po']),
},
classifiers=[
'Development Status :: 5 - Production/Stable',