diff --git a/addons/account/__openerp__.py b/addons/account/__openerp__.py
index 1a222b2f83c..59d86351cd6 100644
--- a/addons/account/__openerp__.py
+++ b/addons/account/__openerp__.py
@@ -49,7 +49,7 @@ for a particular financial year and for preparation of vouchers there is a modul
""",
'website': 'http://www.openerp.com',
'images' : ['images/accounts.jpeg','images/bank_statement.jpeg','images/cash_register.jpeg','images/chart_of_accounts.jpeg','images/customer_invoice.jpeg','images/journal_entries.jpeg'],
- 'depends' : ['base_setup', 'product', 'analytic', 'process', 'board', 'edi', 'report'],
+ 'depends' : ['base_setup', 'product', 'analytic', 'board', 'edi', 'report'],
'data': [
'security/account_security.xml',
'security/ir.model.access.csv',
@@ -114,17 +114,12 @@ for a particular financial year and for preparation of vouchers there is a modul
'partner_view.xml',
'product_view.xml',
'account_assert_test.xml',
- 'process/statement_process.xml',
- 'process/customer_invoice_process.xml',
- 'process/supplier_invoice_process.xml',
'ir_sequence_view.xml',
'company_view.xml',
- 'board_account_view.xml',
'edi/invoice_action_data.xml',
'account_bank_view.xml',
'res_config_view.xml',
'account_pre_install.yml',
-
'views/report_vat.xml',
'views/report_invoice.xml',
'views/report_trialbalance.xml',
@@ -144,20 +139,12 @@ for a particular financial year and for preparation of vouchers there is a modul
'project/views/report_analyticcostledgerquantity.xml',
'project/views/report_analyticcostledger.xml',
'project/views/report_invertedanalyticbalance.xml',
- ],
- 'js': [
- 'static/src/js/account_move_reconciliation.js',
- 'static/src/js/account_move_line_quickadd.js',
+ 'views/account.xml',
],
'qweb' : [
"static/src/xml/account_move_reconciliation.xml",
"static/src/xml/account_move_line_quickadd.xml",
],
- 'css':[
- 'static/src/css/account_move_reconciliation.css',
- 'static/src/css/account_move_line_quickadd.css',
- 'static/src/css/account_bank_and_cash.css',
- ],
'demo': [
'demo/account_demo.xml',
'project/project_demo.xml',
diff --git a/addons/account/account.py b/addons/account/account.py
index 3537c4f4c55..aa5d507b3d2 100644
--- a/addons/account/account.py
+++ b/addons/account/account.py
@@ -840,16 +840,11 @@ class account_journal(osv.osv):
def name_search(self, cr, user, name, args=None, operator='ilike', context=None, limit=100):
if not args:
args = []
- if context is None:
- context = {}
- ids = []
- if context.get('journal_type', False):
- args += [('type','=',context.get('journal_type'))]
- if name:
- ids = self.search(cr, user, [('code', 'ilike', name)]+ args, limit=limit, context=context)
- if not ids:
- ids = self.search(cr, user, [('name', 'ilike', name)]+ args, limit=limit, context=context)#fix it ilike should be replace with operator
-
+ if operator in expression.NEGATIVE_TERM_OPERATORS:
+ domain = [('code', operator, name), ('name', operator, name)]
+ else:
+ domain = ['|', ('code', operator, name), ('name', operator, name)]
+ ids = self.search(cr, user, expression.AND([domain, args]), limit=limit, context=context)
return self.name_get(cr, user, ids, context=context)
@@ -938,13 +933,11 @@ class account_fiscalyear(osv.osv):
def name_search(self, cr, user, name, args=None, operator='ilike', context=None, limit=80):
if args is None:
args = []
- if context is None:
- context = {}
- ids = []
- if name:
- ids = self.search(cr, user, [('code', 'ilike', name)]+ args, limit=limit)
- if not ids:
- ids = self.search(cr, user, [('name', operator, name)]+ args, limit=limit)
+ if operator in expression.NEGATIVE_TERM_OPERATORS:
+ domain = [('code', operator, name), ('name', operator, name)]
+ else:
+ domain = ['|', ('code', operator, name), ('name', operator, name)]
+ ids = self.search(cr, user, expression.AND([domain, args]), limit=limit, context=context)
return self.name_get(cr, user, ids, context=context)
@@ -1040,19 +1033,11 @@ class account_period(osv.osv):
def name_search(self, cr, user, name, args=None, operator='ilike', context=None, limit=100):
if args is None:
args = []
- if context is None:
- context = {}
- ids = []
- if name:
- ids = self.search(cr, user,
- [('code', 'ilike', name)] + args,
- limit=limit,
- context=context)
- if not ids:
- ids = self.search(cr, user,
- [('name', operator, name)] + args,
- limit=limit,
- context=context)
+ if operator in expression.NEGATIVE_TERM_OPERATORS:
+ domain = [('code', operator, name), ('name', operator, name)]
+ else:
+ domain = ['|', ('code', operator, name), ('name', operator, name)]
+ ids = self.search(cr, user, expression.AND([domain, args]), limit=limit, context=context)
return self.name_get(cr, user, ids, context=context)
def write(self, cr, uid, ids, vals, context=None):
@@ -1187,36 +1172,6 @@ class account_move(osv.osv):
'company_id': company_id,
}
- def name_search(self, cr, user, name, args=None, operator='ilike', context=None, limit=80):
- """
- Returns a list of tupples containing id, name, as internally it is called {def name_get}
- result format: {[(id, name), (id, name), ...]}
-
- @param cr: A database cursor
- @param user: ID of the user currently logged in
- @param name: name to search
- @param args: other arguments
- @param operator: default operator is 'ilike', it can be changed
- @param context: context arguments, like lang, time zone
- @param limit: Returns first 'n' ids of complete result, default is 80.
-
- @return: Returns a list of tuples containing id and name
- """
-
- if not args:
- args = []
- ids = []
- if name:
- ids += self.search(cr, user, [('name','ilike',name)]+args, limit=limit, context=context)
-
- if not ids and name and type(name) == int:
- ids += self.search(cr, user, [('id','=',name)]+args, limit=limit, context=context)
-
- if not ids:
- ids += self.search(cr, user, args, limit=limit, context=context)
-
- return self.name_get(cr, user, ids, context=context)
-
def name_get(self, cursor, user, ids, context=None):
if isinstance(ids, (int, long)):
ids = [ids]
@@ -1842,10 +1797,12 @@ class account_tax_code(osv.osv):
def name_search(self, cr, user, name, args=None, operator='ilike', context=None, limit=80):
if not args:
args = []
- if context is None:
- context = {}
- ids = self.search(cr, user, ['|',('name',operator,name),('code',operator,name)] + args, limit=limit, context=context)
- return self.name_get(cr, user, ids, context)
+ if operator in expression.NEGATIVE_TERM_OPERATORS:
+ domain = [('code', operator, name), ('name', operator, name)]
+ else:
+ domain = ['|', ('code', operator, name), ('name', operator, name)]
+ ids = self.search(cr, user, expression.AND([domain, args]), limit=limit, context=context)
+ return self.name_get(cr, user, ids, context=context)
def name_get(self, cr, uid, ids, context=None):
if isinstance(ids, (int, long)):
@@ -1974,15 +1931,11 @@ class account_tax(osv.osv):
"""
if not args:
args = []
- if context is None:
- context = {}
- ids = []
- if name:
- ids = self.search(cr, user, [('description', '=', name)] + args, limit=limit, context=context)
- if not ids:
- ids = self.search(cr, user, [('name', operator, name)] + args, limit=limit, context=context)
+ if operator in expression.NEGATIVE_TERM_OPERATORS:
+ domain = [('description', operator, name), ('name', operator, name)]
else:
- ids = self.search(cr, user, args, limit=limit, context=context or {})
+ domain = ['|', ('description', operator, name), ('name', operator, name)]
+ ids = self.search(cr, user, expression.AND([domain, args]), limit=limit, context=context)
return self.name_get(cr, user, ids, context=context)
def write(self, cr, uid, ids, vals, context=None):
@@ -1991,15 +1944,17 @@ class account_tax(osv.osv):
return super(account_tax, self).write(cr, uid, ids, vals, context=context)
def search(self, cr, uid, args, offset=0, limit=None, order=None, context=None, count=False):
+ if context is None:
+ context = {}
journal_pool = self.pool.get('account.journal')
- if context and context.has_key('type'):
+ if context.get('type'):
if context.get('type') in ('out_invoice','out_refund'):
args += [('type_tax_use','in',['sale','all'])]
elif context.get('type') in ('in_invoice','in_refund'):
args += [('type_tax_use','in',['purchase','all'])]
- if context and context.has_key('journal_id'):
+ if context.get('journal_id'):
journal = journal_pool.browse(cr, uid, context.get('journal_id'))
if journal.type in ('sale', 'purchase'):
args += [('type_tax_use','in',[journal.type,'all'])]
diff --git a/addons/account/account_invoice.py b/addons/account/account_invoice.py
index eb7d9926bbf..1b4795f02a8 100644
--- a/addons/account/account_invoice.py
+++ b/addons/account/account_invoice.py
@@ -409,9 +409,7 @@ class account_invoice(osv.osv):
'''
assert len(ids) == 1, 'This option should only be used for a single id at a time.'
self.write(cr, uid, ids, {'sent': True}, context=context)
- context2 = context.copy()
- context2['active_ids'] = ids
- return self.pool['report'].get_action(cr, uid, [], 'account.report_invoice', context=context2)
+ return self.pool['report'].get_action(cr, uid, [], 'account.report_invoice', context=context)
def action_invoice_sent(self, cr, uid, ids, context=None):
'''
@@ -672,25 +670,14 @@ class account_invoice(osv.osv):
self.create_workflow(cr, uid, ids)
return True
- # ----------------------------------------
- # Mail related methods
- # ----------------------------------------
-
- def _get_formview_action(self, cr, uid, id, context=None):
+ def get_formview_id(self, cr, uid, id, context=None):
""" Update form view id of action to open the invoice """
- action = super(account_invoice, self)._get_formview_action(cr, uid, id, context=context)
obj = self.browse(cr, uid, id, context=context)
if obj.type == 'in_invoice':
model, view_id = self.pool.get('ir.model.data').get_object_reference(cr, uid, 'account', 'invoice_supplier_form')
- action.update({
- 'views': [(view_id, 'form')],
- })
else:
model, view_id = self.pool.get('ir.model.data').get_object_reference(cr, uid, 'account', 'invoice_form')
- action.update({
- 'views': [(view_id, 'form')],
- })
- return action
+ return view_id
# Workflow stuff
#################
@@ -1793,7 +1780,7 @@ class res_partner(osv.osv):
""" Inherits partner and adds invoice information in the partner form """
_inherit = 'res.partner'
_columns = {
- 'invoice_ids': fields.one2many('account.invoice.line', 'partner_id', 'Invoices', readonly=True),
+ 'invoice_ids': fields.one2many('account.invoice', 'partner_id', 'Invoices', readonly=True),
}
def _find_accounting_partner(self, partner):
diff --git a/addons/account/account_invoice_view.xml b/addons/account/account_invoice_view.xml
index b521f3ff48c..61c397364b9 100644
--- a/addons/account/account_invoice_view.xml
+++ b/addons/account/account_invoice_view.xml
@@ -457,7 +457,7 @@
\n" +"Kliknij aby utworzyć okres rozliczeniowy.\n" +"
\n" +"Typowo, rozliczeniowym okresem księgowym jest miesiąc lub kwartał.\n" +"On odpowiada okresom rozliczeń podatkowych.\n" +"
\n" +" " #. module: account #: model:ir.actions.act_window,name:account.action_view_created_invoice_dashboard @@ -718,6 +725,8 @@ msgid "" "Invoice_${(object.number or '').replace('/','_')}_${object.state == 'draft' " "and 'draft' or ''}" msgstr "" +"Faktura_${(object.number or '').replace('/','_')}_${object.state == 'draft' " +"and 'draft' or ''}" #. module: account #: view:account.period:0 @@ -1793,7 +1802,7 @@ msgstr "Konto podatku dla korekt" #. module: account #: model:ir.model,name:account.model_ir_sequence msgid "ir.sequence" -msgstr "" +msgstr "ir.sequence" #. module: account #: view:account.bank.statement:0 @@ -2356,7 +2365,7 @@ msgstr "Dobra robota!" #. module: account #: field:account.config.settings,module_account_asset:0 msgid "Assets management" -msgstr "Środku trwałe" +msgstr "Środki trwałe" #. module: account #: view:account.account:0 @@ -7563,7 +7572,7 @@ msgstr "" #. module: account #: field:account.invoice,paypal_url:0 msgid "Paypal Url" -msgstr "" +msgstr "Paypal Url" #. module: account #: field:account.config.settings,module_account_voucher:0 @@ -8352,7 +8361,7 @@ msgstr "" #. module: account #: model:ir.model,name:account.model_cash_box_in msgid "cash.box.in" -msgstr "" +msgstr "cash.box.in" #. module: account #: help:account.invoice,move_id:0 @@ -8362,7 +8371,7 @@ msgstr "Połącz z automatycznie generowanymi pozycjami zapisów" #. module: account #: model:ir.model,name:account.model_account_config_settings msgid "account.config.settings" -msgstr "" +msgstr "account.config.settings" #. module: account #: selection:account.config.settings,period:0 @@ -8677,7 +8686,7 @@ msgstr "Brak roku podatkowego dla firmy" #. module: account #: view:account.invoice:0 msgid "Proforma" -msgstr "" +msgstr "Proforma" #. module: account #: report:account.analytic.account.cost_ledger:0 @@ -8951,7 +8960,7 @@ msgstr "Typy kont" #. module: account #: model:email.template,subject:account.email_template_edi_invoice msgid "${object.company_id.name} Invoice (Ref ${object.number or 'n/a'})" -msgstr "" +msgstr "${object.company_id.name} Faktura (Odn. ${object.number or 'n/a'})" #. module: account #: code:addons/account/account_move_line.py:1210 diff --git a/addons/account/i18n/pt.po b/addons/account/i18n/pt.po index 8f34ed52a9b..6c105060cc0 100644 --- a/addons/account/i18n/pt.po +++ b/addons/account/i18n/pt.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:16+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:40+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/pt_BR.po b/addons/account/i18n/pt_BR.po index 84fc5c316d4..5909d4c18cc 100644 --- a/addons/account/i18n/pt_BR.po +++ b/addons/account/i18n/pt_BR.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:21+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:45+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/ro.po b/addons/account/i18n/ro.po index a0f638217fd..5dd5c99a645 100644 --- a/addons/account/i18n/ro.po +++ b/addons/account/i18n/ro.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:17+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:40+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/ru.po b/addons/account/i18n/ru.po index eedfb74caae..2505f8b230a 100644 --- a/addons/account/i18n/ru.po +++ b/addons/account/i18n/ru.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:17+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:40+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/si.po b/addons/account/i18n/si.po index 8b312968ba7..50b19d36013 100644 --- a/addons/account/i18n/si.po +++ b/addons/account/i18n/si.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:18+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:41+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/sk.po b/addons/account/i18n/sk.po index 6c71b8ddd5d..48e792929e9 100644 --- a/addons/account/i18n/sk.po +++ b/addons/account/i18n/sk.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:18+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:41+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/sl.po b/addons/account/i18n/sl.po index 8bab68e8cdb..abd78d568c9 100644 --- a/addons/account/i18n/sl.po +++ b/addons/account/i18n/sl.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:18+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:42+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/sq.po b/addons/account/i18n/sq.po index d0b25675a32..7061cb15df7 100644 --- a/addons/account/i18n/sq.po +++ b/addons/account/i18n/sq.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:08+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:29+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/sr.po b/addons/account/i18n/sr.po index 46c4d823146..7bd5e8f0040 100644 --- a/addons/account/i18n/sr.po +++ b/addons/account/i18n/sr.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:17+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:41+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/sr@latin.po b/addons/account/i18n/sr@latin.po index 58deee7c77c..d6af6941e03 100644 --- a/addons/account/i18n/sr@latin.po +++ b/addons/account/i18n/sr@latin.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:25+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:49+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/sv.po b/addons/account/i18n/sv.po index 0baacb4dd14..d82cabf2eb2 100644 --- a/addons/account/i18n/sv.po +++ b/addons/account/i18n/sv.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:19+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:42+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/ta.po b/addons/account/i18n/ta.po index 48169490d35..0062c3d72af 100644 --- a/addons/account/i18n/ta.po +++ b/addons/account/i18n/ta.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:19+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:42+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/te.po b/addons/account/i18n/te.po index fedaef8aa59..e20f9e37d39 100644 --- a/addons/account/i18n/te.po +++ b/addons/account/i18n/te.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:19+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:43+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/th.po b/addons/account/i18n/th.po index ff668c74f51..8216eb4200a 100644 --- a/addons/account/i18n/th.po +++ b/addons/account/i18n/th.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:19+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:43+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/tlh.po b/addons/account/i18n/tlh.po index fa0b7bb3b48..4fc0a064d01 100644 --- a/addons/account/i18n/tlh.po +++ b/addons/account/i18n/tlh.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:19+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:43+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/tr.po b/addons/account/i18n/tr.po index 6fc63463540..a1c1aad8d97 100644 --- a/addons/account/i18n/tr.po +++ b/addons/account/i18n/tr.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:20+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:43+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/ug.po b/addons/account/i18n/ug.po index 6357f169643..c4773a2e24d 100644 --- a/addons/account/i18n/ug.po +++ b/addons/account/i18n/ug.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:20+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:43+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/uk.po b/addons/account/i18n/uk.po index 6a7aa037973..9711a8508bd 100644 --- a/addons/account/i18n/uk.po +++ b/addons/account/i18n/uk.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:20+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:44+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/ur.po b/addons/account/i18n/ur.po index 673dac3ed9f..011a53785cb 100644 --- a/addons/account/i18n/ur.po +++ b/addons/account/i18n/ur.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:20+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:44+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/vi.po b/addons/account/i18n/vi.po index e17bd17a828..2ac00bb9ed4 100644 --- a/addons/account/i18n/vi.po +++ b/addons/account/i18n/vi.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:21+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:44+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/zh_CN.po b/addons/account/i18n/zh_CN.po index 7fbca3c5deb..e70ff7c5c37 100644 --- a/addons/account/i18n/zh_CN.po +++ b/addons/account/i18n/zh_CN.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:24+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:47+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/zh_HK.po b/addons/account/i18n/zh_HK.po index eac1e5b3a35..d35aab730bc 100644 --- a/addons/account/i18n/zh_HK.po +++ b/addons/account/i18n/zh_HK.po @@ -14,8 +14,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:21+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:44+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/i18n/zh_TW.po b/addons/account/i18n/zh_TW.po index a39f9c464be..46aad2f7e14 100644 --- a/addons/account/i18n/zh_TW.po +++ b/addons/account/i18n/zh_TW.po @@ -13,8 +13,8 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2014-04-12 07:23+0000\n" -"X-Generator: Launchpad (build 16976)\n" +"X-Launchpad-Export-Date: 2014-04-22 06:47+0000\n" +"X-Generator: Launchpad (build 16985)\n" #. module: account #: model:process.transition,name:account.process_transition_supplierreconcilepaid0 diff --git a/addons/account/partner.py b/addons/account/partner.py index f24ffcf55b4..df4c1ec4888 100644 --- a/addons/account/partner.py +++ b/addons/account/partner.py @@ -162,6 +162,29 @@ class res_partner(osv.osv): def _debit_search(self, cr, uid, obj, name, args, context=None): return self._asset_difference_search(cr, uid, obj, name, 'payable', args, context=context) + def _invoice_total(self, cr, uid, ids, field_name, arg, context=None): + result = {} + account_invoice_report = self.pool.get('account.invoice.report') + for partner in self.browse(cr, uid, ids, context=context): + invoice_ids = account_invoice_report.search(cr, uid, [('partner_id','child_of',partner.id)], context=context) + invoices = account_invoice_report.browse(cr, uid, invoice_ids, context=context) + result[partner.id] = sum(inv.user_currency_price_total for inv in invoices) + return result + + def _journal_item_count(self, cr, uid, ids, field_name, arg, context=None): + res = dict(map(lambda x: (x,{'journal_item_count': 0, 'contracts_count': 0 }), ids)) + + # the user may not have access rights + try: + for partner in self.browse(cr, uid, ids, context=context): + res[partner.id] = { + 'journal_item_count': len(partner.journal_item_ids), + 'contracts_count': len(partner.contract_ids) + } + except: + pass + return res + def has_something_to_reconcile(self, cr, uid, partner_id, context=None): ''' at least a debit, a credit and a line older than the last reconciliation date of the partner @@ -190,6 +213,10 @@ class res_partner(osv.osv): fnct_search=_credit_search, string='Total Receivable', multi='dc', help="Total amount this customer owes you."), 'debit': fields.function(_credit_debit_get, fnct_search=_debit_search, string='Total Payable', multi='dc', help="Total amount you have to pay to this supplier."), 'debit_limit': fields.float('Payable Limit'), + 'total_invoiced': fields.function(_invoice_total, string="Total Invoiced", type='float'), + 'contracts_count': fields.function(_journal_item_count, string="Contracts", type='integer', multi="invoice_journal"), + 'journal_item_ids': fields.one2many('account.move.line', 'partner_id', 'Journal Items'), + 'journal_item_count': fields.function(_journal_item_count, string="Journal Items", type="integer", multi="invoice_journal"), 'property_account_payable': fields.property( type='many2one', relation='account.account', diff --git a/addons/account/partner_view.xml b/addons/account/partner_view.xml index 6a58bc7f77e..0fa21444a09 100644 --- a/addons/account/partner_view.xml +++ b/addons/account/partner_view.xml @@ -64,12 +64,21 @@Accounting-related settings are managed on
Import your bank statements and reconcile them in just a few clicks. Prepare payment orders based on your supplier invoices and payment terms.
-Automatically create invoices from sales orders, delivery orders or base them on time and material. Re-invoice expenses on projects to your customer in just a few clicks.
- +Integrate your analytic accounting operations with timesheets, projects, invoices, expenses, etc. No need to record transactions, all analytic entries are posted automatically following your business rules.
- +Manage your assets, track expenses, control budgets, multi-level analytic accounting; OpenERP has all the features you need to sustain all your business activities.
@@ -143,34 +143,21 @@ Manage your assets, track expenses, control budgets, multi-level analytic accounOpenERP supports multiple currencies, multiple users with different access rights, multiple companies with real time consolidation and unlimited analytic plans.
--Get direct access to key information with dynamic and customizable dashboards. Analyse your financial activities with the drill-up, drill-down, drill-across and filter features. -
-