diff --git a/addons/account/account.py b/addons/account/account.py index 1520c4f0646..8ef5004df04 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -1215,7 +1215,8 @@ class account_move(osv.osv): # # TODO: Check if period is closed ! # - def create(self, cr, uid, vals, context={}): + def create(self, cr, uid, vals, context=None): + context = context or {} if 'line_id' in vals and context.get('copy'): for l in vals['line_id']: if not l[0]: @@ -1256,6 +1257,7 @@ class account_move(osv.osv): return result def copy(self, cr, uid, id, default={}, context={}): + context = context or {} default.update({ 'state':'draft', 'name':'/', @@ -1265,7 +1267,8 @@ class account_move(osv.osv): }) return super(account_move, self).copy(cr, uid, id, default, context) - def unlink(self, cr, uid, ids, context={}, check=True): + def unlink(self, cr, uid, ids, context=None, check=True): + context = context or {} toremove = [] obj_move_line = self.pool.get('account.move.line') for move in self.browse(cr, uid, ids, context): @@ -1605,7 +1608,7 @@ class account_tax_code(osv.osv): if isinstance(ids, (int, long)): ids = [ids] reads = self.read(cr, uid, ids, ['name','code'], context, load='_classic_write') - return [(x['id'], (x['code'] and x['code'] + ' - ' or '') + x['name']) \ + return [(x['id'], (x['code'] and (x['code'] + ' - ') or '') + x['name']) \ for x in reads] def _default_company(self, cr, uid, context={}): @@ -2019,7 +2022,7 @@ class account_model(osv.osv): } _defaults = { - 'legend': lambda self, cr, uid, context:_('You can specify year, month and date in the name of the model using the following labels:\n\n%(year)s : To Specify Year \n%(month)s : To Specify Month \n%(date)s : Current Date\n\ne.g. My model on %(date)s'), + 'legend': lambda self, cr, uid, context:_('You can specify year, month and date in the name of the model using the following labels:\n\n%(year)s: To Specify Year \n%(month)s: To Specify Month \n%(date)s: Current Date\n\ne.g. My model on %(date)s'), } def generate(self, cr, uid, ids, datas={}, context=None): move_ids = [] @@ -2221,7 +2224,7 @@ class account_subscription_line(osv.osv): account_subscription_line() # --------------------------------------------------------------- -# Account Templates : Account, Tax, Tax Code and chart. + Wizard +# Account Templates: Account, Tax, Tax Code and chart. + Wizard # --------------------------------------------------------------- class account_tax_template(osv.osv): @@ -2394,7 +2397,7 @@ class account_chart_template(osv.osv): 'property_account_income_categ': fields.many2one('account.account.template','Income Category Account'), 'property_account_expense': fields.many2one('account.account.template','Expense Account on Product Template'), 'property_account_income': fields.many2one('account.account.template','Income Account on Product Template'), - 'property_reserve_and_surplus_account': fields.many2one('account.account.template', 'Reserve and Profit/Loss Account', domain=[('type', '=', 'payable')], help='This Account is used for transferring Profit/Loss(If It is Profit : Amount will be added, Loss : Amount will be deducted.), Which is calculated from Profilt & Loss Report'), + 'property_reserve_and_surplus_account': fields.many2one('account.account.template', 'Reserve and Profit/Loss Account', domain=[('type', '=', 'payable')], help='This Account is used for transferring Profit/Loss(If It is Profit: Amount will be added, Loss: Amount will be deducted.), Which is calculated from Profilt & Loss Report'), } account_chart_template() @@ -2544,9 +2547,17 @@ class wizard_multi_charts_accounts(osv.osv_memory): if ids: return ids[0] return False + + def _get_default_accounts(self, cr, uid, context=None): + accounts = [{'acc_name':'Current','account_type':'bank'}, + {'acc_name':'Deposit','account_type':'bank'}, + {'acc_name':'Cash','account_type':'cash'}] + return accounts + _defaults = { 'company_id': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr, uid, [uid], c)[0].company_id.id, 'chart_template_id': _get_chart, + 'bank_accounts_id': _get_default_accounts, 'code_digits': 6, 'seq_journal': True } diff --git a/addons/account/account_analytic_line.py b/addons/account/account_analytic_line.py index a982ca51182..f3c2b71122f 100644 --- a/addons/account/account_analytic_line.py +++ b/addons/account/account_analytic_line.py @@ -24,8 +24,6 @@ import time from osv import fields from osv import osv from tools.translate import _ -import tools -from tools import config class account_analytic_line(osv.osv): _inherit = 'account.analytic.line' @@ -82,12 +80,13 @@ class account_analytic_line(osv.osv): return {} product_obj = self.pool.get('product.product') analytic_journal_obj =self.pool.get('account.analytic.journal') + company_obj = self.pool.get('res.company') + product_price_type_obj = self.pool.get('product.price.type') j_id = analytic_journal_obj.browse(cr, uid, journal_id, context=context) prod = product_obj.browse(cr, uid, prod_id) if not company_id: company_id = j_id.company_id.id result = 0.0 - is_purchase = False if j_id.type <> 'sale': a = prod.product_tmpl_id.property_account_expense.id @@ -99,8 +98,6 @@ class account_analytic_line(osv.osv): 'for this product: "%s" (id:%d)') % \ (prod.name, prod.id,)) amount_unit = prod.price_get('standard_price', context)[prod.id] - is_purchase = True - else: a = prod.product_tmpl_id.property_account_income.id if not a: @@ -128,9 +125,8 @@ class account_analytic_line(osv.osv): if pricetype.field == 'list_price': flag = True amount_unit = prod.price_get(pricetype.field, context)[prod.id] - amount = amount_unit*unit_amount or 1.0 prec = self.pool.get('decimal.precision').precision_get(cr, uid, 'Account') - amount = amount_unit*unit_amount or 1.0 + amount = amount_unit*unit or 1.0 result = round(amount, prec) if not flag: result *= -1 diff --git a/addons/account/account_bank_statement.py b/addons/account/account_bank_statement.py index 0b240663943..cf50a1ab62e 100644 --- a/addons/account/account_bank_statement.py +++ b/addons/account/account_bank_statement.py @@ -378,7 +378,7 @@ class account_bank_statement(osv.osv): self.create_move_from_st_line(cr, uid, st_line.id, company_currency_id, st_line_number, context) self.write(cr, uid, [st.id], {'name': st_number}, context=context) - self.log(cr, uid, st.id, 'Statement %s is confirmed and entries are created.' % st_number) + self.log(cr, uid, st.id, _('Statement %s is confirmed, journal items are created.') % (st_number,)) done.append(st.id) return self.write(cr, uid, ids, {'state':'confirm'}, context=context) @@ -501,4 +501,4 @@ class account_bank_statement_line(osv.osv): account_bank_statement_line() -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: \ No newline at end of file +# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/account/account_invoice_view.xml b/addons/account/account_invoice_view.xml index 18484a7d1c8..28d2f5a06a6 100644 --- a/addons/account/account_invoice_view.xml +++ b/addons/account/account_invoice_view.xml @@ -430,7 +430,7 @@ [('type','=','out_invoice')] {'type':'out_invoice', 'journal_type': 'sale'} - Most of customer invoices are automatically generated in draft mode by OpenERP flows, following a purchase order for instance. Review, confirm or cancel, pay or refund your customers' invoices here. A manual invoice can be created here. + Customer Invoices allows you create and manage invoices issued to your customers. OpenERP generates draft of invoices automatically so that you only have to confirm them before sending them to your customers. @@ -458,7 +458,7 @@ [('type','=','in_invoice')] {'type':'in_invoice', 'journal_type': 'purchase'} - Proposal for supplier invoices are usually automatically generate by OpenERP, following a procurement order or a production order for instance. To consult and to check for, or to manually create a customer invoice, use this menu. You can review, confirm or cancel, pay or refund an invoice from the view from of the invoices. + Supplier Invoices allows you to enter and manage invoices issued by your suppliers. OpenERP generates draft of supplier invoices automatically so that you can control what you received from your supplier according to what you purchased or received. @@ -471,7 +471,7 @@ [('type','=','out_refund')] {'type':'out_refund', 'journal_type': 'sale_refund'} - A customer refund is a credit note to your customer that cancel invoice or a part of it. + Customer Refunds helps you manage the credit notes issued/to be issued for your customers. A refund invoice is a document that cancels an invoice or a part of it. You can easily generate refunds and reconcile them from the invoice form. @@ -510,22 +510,5 @@ res_model="account.invoice" src_model="account.journal"/> - - - - diff --git a/addons/account/account_move_line.py b/addons/account/account_move_line.py index ca662fbd88f..530128c82f6 100644 --- a/addons/account/account_move_line.py +++ b/addons/account/account_move_line.py @@ -26,6 +26,7 @@ from osv import fields, osv from tools.translate import _ import decimal_precision as dp import tools +from operator import itemgetter class account_move_line(osv.osv): _name = "account.move.line" @@ -863,9 +864,8 @@ class account_move_line(osv.osv): result['toolbar']['action'] = [] #Restrict the list of journal view in search view - if view_type == 'search': - journal_list = journal_pool.name_search(cr, uid, '', [], context=context) - result['fields']['journal_id']['selection'] = journal_list + if view_type == 'search' and result['fields'].get('journal_id', False): + result['fields']['journal_id']['selection'] = journal_pool.name_search(cr, uid, '', [], context=context) return result if context.get('view_mode', False): @@ -887,19 +887,20 @@ class account_move_line(osv.osv): for field in journal.view_id.columns_id: if not field.field in fields: fields[field.field] = [journal.id] - fld.append((field.field, field.sequence)) + fld.append((field.field, field.sequence, field.name)) flds.append(field.field) common_fields[field.field] = 1 else: fields.get(field.field).append(journal.id) common_fields[field.field] = common_fields[field.field] + 1 - fld.append(('period_id', 3)) - fld.append(('journal_id', 10)) + + fld.append(('period_id', 3, 'Period')) + fld.append(('journal_id', 10, 'Journal')) flds.append('period_id') flds.append('journal_id') fields['period_id'] = all_journal fields['journal_id'] = all_journal - from operator import itemgetter + fld = sorted(fld, key=itemgetter(1)) widths = { @@ -952,6 +953,7 @@ class account_move_line(osv.osv): if field in widths: attrs.append('width="'+str(widths[field])+'"') + attrs.append('string="'+field_it[2]+'"') attrs.append("invisible=\"context.get('visible_id') not in %s\"" % (fields.get(field))) xml += '''\n''' % (field,' '.join(attrs)) diff --git a/addons/account/account_view.xml b/addons/account/account_view.xml index bfafe166fda..6e42836c21e 100644 --- a/addons/account/account_view.xml +++ b/addons/account/account_view.xml @@ -23,8 +23,8 @@
- - + + @@ -59,7 +59,7 @@ - + @@ -237,16 +237,16 @@ - account.treasory.graph - account.account - graph - - - - - + account.treasory.graph + account.account + graph + + + + + - + Accounts account.account @@ -314,13 +314,33 @@ + + account.journal.view.search + account.journal.view + search + + + + + + + + account.journal.view.tree + account.journal.view + tree + + + + + + account.journal.view.form account.journal.view form - + @@ -330,7 +350,9 @@ account.journal.view form tree,form + + + + account.account.type.search + account.account.type + search + + + + + + + + account.account.type.tree account.account.type @@ -703,6 +739,7 @@ account.account.type form tree,form + + + account.tax.code.search + account.tax.code + search + + + + + + + + + account.tax.code.tree account.tax.code @@ -775,10 +825,10 @@
- - - - + + + + @@ -801,6 +851,7 @@ form tree,form + @@ -832,7 +883,6 @@ - @@ -843,9 +893,9 @@ - - - + + + @@ -879,8 +929,8 @@ - - + + @@ -904,7 +954,7 @@ [('parent_id','=',False)] tree - Chart of Taxes is a tree view reflecting the structure of the Tax Cases (or tax codes) and shows the current tax situation. The tax chart represents the amount of each area of the tax declaration for your country. It’s presented in a hierarchical structure, which can be modified to fit your needs. + The chart of taxes is used to generate your periodic tax statement. You will see here the taxes with codes related to your legal statement according to your country. + + account.fiscal.position.template.search + account.fiscal.position.template + search + + + + + + + account.fiscal.position.template.form account.fiscal.position.template form - + @@ -2445,6 +2522,7 @@ account.fiscal.position.template form tree,form + [('journal_id.type', '=', 'cash')] {'journal_type':'cash'} + Cash Register allows you to manage cash entries in your cash journals. diff --git a/addons/account/board_account_view.xml b/addons/account/board_account_view.xml index 89767eb1507..ade29ef6f83 100644 --- a/addons/account/board_account_view.xml +++ b/addons/account/board_account_view.xml @@ -44,7 +44,7 @@ - + @@ -68,6 +68,6 @@ - + diff --git a/addons/account/company.py b/addons/account/company.py index 8e14fe53c3a..0a3cc15663a 100644 --- a/addons/account/company.py +++ b/addons/account/company.py @@ -33,7 +33,7 @@ class res_company(osv.osv): method=True, view_load=True, domain="[('type', '=', 'payable')]", - help="This Account is used for transferring Profit/Loss(If It is Profit : Amount will be added, Loss : Amount will be deducted.), Which is calculated from Profit & Loss Report"), + help="This Account is used for transferring Profit/Loss(If It is Profit: Amount will be added, Loss : Amount will be deducted.), Which is calculated from Profit & Loss Report"), } _defaults = { diff --git a/addons/account/data/account_data2.xml b/addons/account/data/account_data2.xml index 870500db057..38bdd4b2b2c 100644 --- a/addons/account/data/account_data2.xml +++ b/addons/account/data/account_data2.xml @@ -2,6 +2,11 @@ + + Sales + sale + + @@ -465,13 +470,42 @@ SAJ/%(year)s/ + + Sales Credit Note Journal + account.journal + + SCNJ/%(year)s/ + Purchase Journal account.journal EXJ/%(year)s/ - + + Expenses Credit Notes Journal + account.journal + + ECNJ/%(year)s/ + + + Bank Journal + account.journal + + BNK/%(year)s/ + + + Checks Journal + account.journal + + CHK/%(year)s/ + + + Cash Journal + account.journal + + CSH/%(year)s/ + diff --git a/addons/account/demo/account_minimal.xml b/addons/account/demo/account_minimal.xml index 764420e6689..87c8a37254d 100644 --- a/addons/account/demo/account_minimal.xml +++ b/addons/account/demo/account_minimal.xml @@ -357,7 +357,7 @@ sale_refund - + @@ -381,7 +381,7 @@ purchase_refund - + @@ -393,7 +393,7 @@ BNK bank - + @@ -404,7 +404,7 @@ CHK bank - + @@ -415,7 +415,7 @@ CSH cash - + diff --git a/addons/account/i18n/hr.po b/addons/account/i18n/hr.po index a34f7c100c0..c4109588ca0 100644 --- a/addons/account/i18n/hr.po +++ b/addons/account/i18n/hr.po @@ -7,13 +7,13 @@ msgstr "" "Project-Id-Version: OpenERP Server 6.0dev\n" "Report-Msgid-Bugs-To: support@openerp.com\n" "POT-Creation-Date: 2009-08-28 16:01+0000\n" -"PO-Revision-Date: 2010-10-13 15:51+0000\n" -"Last-Translator: zmmaj \n" +"PO-Revision-Date: 2010-10-14 07:28+0000\n" +"Last-Translator: OpenERP Administrators \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2010-10-14 04:45+0000\n" +"X-Launchpad-Export-Date: 2010-10-15 04:42+0000\n" "X-Generator: Launchpad (build Unknown)\n" #. module: account diff --git a/addons/account/i18n/mn.po b/addons/account/i18n/mn.po index a2e5ce8ef6b..ea1d2cfeba4 100644 --- a/addons/account/i18n/mn.po +++ b/addons/account/i18n/mn.po @@ -8,13 +8,13 @@ msgstr "" "Project-Id-Version: openobject-addons\n" "Report-Msgid-Bugs-To: FULL NAME \n" "POT-Creation-Date: 2009-08-28 16:01+0000\n" -"PO-Revision-Date: 2010-10-12 07:43+0000\n" +"PO-Revision-Date: 2010-10-17 07:44+0000\n" "Last-Translator: OpenERP Administrators \n" "Language-Team: Mongolian \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2010-10-13 04:58+0000\n" +"X-Launchpad-Export-Date: 2010-10-18 04:55+0000\n" "X-Generator: Launchpad (build Unknown)\n" #. module: account @@ -647,7 +647,7 @@ msgstr "Харилцагчийн төлбөрийн нөхцөл" #. module: account #: view:account.move.reconcile:0 msgid "Account Entry Reconcile" -msgstr "Дансны бичилт гүйцээлт" +msgstr "Дансны бичилт бууралт" #. module: account #: wizard_button:account.move.bank.reconcile,init,open:0 @@ -706,7 +706,7 @@ msgstr "Нэмэлт мэдээлэл" #. module: account #: selection:account.invoice,type:0 msgid "Customer Refund" -msgstr "Худалдан авагчийн буцаалт" +msgstr "Үйлчлүүлэгчийн буцаалт" #. module: account #: wizard_view:account.analytic.account.chart,init:0 @@ -724,7 +724,7 @@ msgstr "Татварын ангилалын тэмдэг" #. module: account #: help:res.partner,credit:0 msgid "Total amount this customer owes you." -msgstr "Энэ худалдан авагчаас авах нийт авлагын дүн." +msgstr "Энэ үйлчлүүлэгчээс авах нийт авлагын дүн." #. module: account #: view:account.move.line:0 @@ -1067,7 +1067,7 @@ msgstr "Төлсөн дүн" #: model:process.transition,name:account.process_transition_customerinvoice0 #: model:process.transition,name:account.process_transition_suppliercustomerinvoice0 msgid "Customer Invoice" -msgstr "Худалдан авагчийн нэхэмжлэл" +msgstr "Үйлчлүүлэгчийн нэхэмжлэл" #. module: account #: wizard_view:account.open_closed_fiscalyear,init:0 @@ -1401,7 +1401,7 @@ msgstr "Электроник файл" #. module: account #: view:res.partner:0 msgid "Customer Credit" -msgstr "Худалдан авагчийн кредит" +msgstr "Үйлчлүүлэгчийн кредит" #. module: account #: field:account.invoice,tax_line:0 @@ -1881,7 +1881,7 @@ msgstr "Эхлэх огноо" #. module: account #: model:account.journal,name:account.refund_expenses_journal msgid "x Expenses Credit Notes Journal" -msgstr "" +msgstr "Зардлыг кредитийн журналд тэмдэглэх" #. module: account #: field:account.analytic.journal,type:0 @@ -1930,7 +1930,7 @@ msgstr "" #: model:ir.actions.act_window,name:account.action_invoice_tree5 #: model:ir.ui.menu,name:account.menu_invoice_draft msgid "Draft Customer Invoices" -msgstr "Худалдан авагчийн ноорог нэхэмжлэл" +msgstr "Үйлчлүүлэгчийн ноорог нэхэмжлэл" #. module: account #: model:ir.model,name:account.model_account_subscription_line @@ -2020,7 +2020,7 @@ msgstr "Аналитик журналын тайлан" #: model:ir.actions.act_window,name:account.action_invoice_tree3 #: model:ir.ui.menu,name:account.menu_action_invoice_tree3 msgid "Customer Refunds" -msgstr "Худалдан авагчийн буцаалт" +msgstr "Үйлчлүүлэгчийн буцаалт" #. module: account #: rml:account.vat.declaration:0 @@ -2096,7 +2096,7 @@ msgstr "Өгөгдлүүд" #. module: account #: model:process.process,name:account.process_process_invoiceprocess0 msgid "Customer Invoice Process" -msgstr "Худалдан авагчийн нэхэмжлэлийн явц" +msgstr "Үйлчлүүлэгчийн нэхэмжлэлийн явц" #. module: account #: rml:account.invoice:0 @@ -2476,7 +2476,7 @@ msgstr "Журнал нээх" #. module: account #: rml:account.analytic.account.journal:0 msgid "KI" -msgstr "" +msgstr "KI" #. module: account #: model:ir.actions.wizard,name:account.action_account_analytic_line @@ -2732,7 +2732,7 @@ msgstr "-" #. module: account #: rml:account.analytic.account.journal:0 msgid "asgfas" -msgstr "" +msgstr "asgfas" #. module: account #: model:ir.actions.act_window,name:account.action_account_analytic_account_tree2 @@ -2859,7 +2859,7 @@ msgstr "Зарлага төвлөрөл" #. module: account #: rml:account.overdue:0 msgid "Customer Ref:" -msgstr "Худалдан авагчийн дугаар" +msgstr "Үйлчлүүлэгчийн дугаар" #. module: account #: xsl:account.transfer:0 @@ -2882,7 +2882,7 @@ msgstr "Нийт кредит" #: model:ir.actions.act_window,name:account.action_invoice_tree1_new #: model:ir.ui.menu,name:account.menu_action_invoice_tree1_new msgid "New Customer Invoice" -msgstr "Шинэ худалдан авагчийн нэхэмжлэл" +msgstr "Шинэ үйлчлүүлэгчийн нэхэмжлэл" #. module: account #: field:account.account,reconcile:0 @@ -2965,7 +2965,7 @@ msgstr "Дансны хуулга" #. module: account #: rml:account.overdue:0 msgid "Document: Customer account statement" -msgstr "Баримт: Худалдан авагчийн дансны хуулга" +msgstr "Баримт: Үйлчлүүлэгчийн дансны хуулга" #. module: account #: view:product.product:0 @@ -3042,7 +3042,7 @@ msgstr "Гаралтын валютын ханш" #: model:ir.actions.act_window,name:account.action_invoice_tree10 #: model:ir.ui.menu,name:account.menu_action_invoice_tree10 msgid "Draft Customer Refunds" -msgstr "Худалдан авагчийн ноорог буцаалт" +msgstr "Үйлчлүүлэгчийн ноорог буцаалт" #. module: account #: field:account.journal.column,readonly:0 @@ -3119,7 +3119,7 @@ msgstr "Аналитик Журнал" #. module: account #: rml:account.general.ledger:0 msgid "Entry Label" -msgstr "Бичлэгийн нэр" +msgstr "Гүйлгээний нэр" #. module: account #: model:process.transition,note:account.process_transition_paymentreconcile0 @@ -3498,7 +3498,9 @@ msgstr "Өдрийн огноо" msgid "" "The amount expressed in an optional other currency if it is a multi-currency " "entry." -msgstr "Өөр валютаар илэрхийлсэн дүн байна" +msgstr "" +"Хэрэв энэ гүйлгээ гадаад валютаар хийгдсэн бол гүйлгээний дүнг гадаад " +"валютаар илэрхийлнэ." #. module: account #: field:account.tax,parent_id:0 @@ -3599,7 +3601,7 @@ msgstr "Шинэ нийлүүлэгчийн буцаалт" #. module: account #: view:account.model:0 msgid "Entry Model" -msgstr "Гүйлгээний модель" +msgstr "Гүйлгээний загвар" #. module: account #: wizard_field:account.general.ledger.report,checktype,amount_currency:0 @@ -3764,7 +3766,7 @@ msgstr "Биелэх огноо" #. module: account #: view:account.subscription:0 msgid "Entry Subscription" -msgstr "захиалгын бичилт" +msgstr "Гүйлгээний тэмдэглэл" #. module: account #: selection:account.print.journal.report,init,sort_selection:0 @@ -3840,7 +3842,7 @@ msgstr "" " Харилцагчийн данс бүртгэл\n" " Татварын менежмент\n" " Төсөв\n" -" Харилцагчийн нэхэмжлэл\n" +" Үйлчлүүлэгчийн нэхэмжлэл\n" " Банкны ажил гүйлгэ\n" " " @@ -4001,7 +4003,7 @@ msgstr "Нэмэлт Талбарууд" #. module: account #: view:res.partner:0 msgid "Customer Accounting Properties" -msgstr "Худалдан авагчийн санхүү бүртгэл" +msgstr "Үйлчлүүлэгчийн санхүү бүртгэл" #. module: account #: view:account.bank.statement:0 @@ -4126,12 +4128,14 @@ msgid "" "You can check this box to mark the entry line as a litigation with the " "associated partner" msgstr "" +"Журналын бичилт нь холбогдох харилцагчийн хувьд маргаантай гэж үзвэл энэ " +"нүдийг сонгох хэрэгтэй" #. module: account #: model:ir.actions.act_window,name:account.action_invoice_tree1 #: model:ir.ui.menu,name:account.menu_action_invoice_tree1 msgid "Customer Invoices" -msgstr "Худалдан авагчийн нэхэмжлэл" +msgstr "Үйлчлүүлэгчийн нэхэмжлэл" #. module: account #: field:res.partner,debit_limit:0 @@ -4315,7 +4319,7 @@ msgstr "Татварууд:" #: model:ir.actions.act_window,name:account.action_invoice_tree7 #: model:ir.ui.menu,name:account.menu_action_invoice_tree7 msgid "Unpaid Customer Invoices" -msgstr "Худалдан авагчийн төлөгдөөгүй нэхэмжлэл" +msgstr "Үйлчлүүлэгчийн төлөгдөөгүй нэхэмжлэл" #. module: account #: model:ir.actions.act_window,name:account.action_invoice_tree2 @@ -4478,7 +4482,7 @@ msgstr "Санхүүгийн жилийн дарааллууд" #. module: account #: view:account.model.line:0 msgid "Entry Model Line" -msgstr "Бүртгэл загвар шугам" +msgstr "Гүйлгээний загварын мөр" #. module: account #: view:account.tax.template:0 @@ -4503,12 +4507,12 @@ msgstr "Балансын удирдлагын эхлэл төгсгөлийг т #. module: account #: wizard_view:account.wizard_paid_open,init:0 msgid "Are you sure you want to open this invoice ?" -msgstr "" +msgstr "Энэ нэхэмжлэлийг нээхдээ та итгэлтэй байна уу?" #. module: account #: model:ir.actions.report.xml,name:account.account_3rdparty_ledger_other msgid "Partner Other Ledger" -msgstr "" +msgstr "Бусад харилцагчийн тооцооны дэвтэр" #. module: account #: view:res.partner:0 @@ -4542,7 +4546,7 @@ msgstr "Дансны бичилт" #. module: account #: model:ir.actions.act_window,name:account.act_account_partner_account_move_unreconciled msgid "Receivables & Payables" -msgstr "Авлагын данс болон төлбөр" +msgstr "Авлага & Өглөг" #. module: account #: rml:account.general.ledger:0 @@ -4625,7 +4629,7 @@ msgstr "Нийлүүлэгчийн санхүү бүртгэл" #. module: account #: view:account.analytic.account:0 msgid "Analytic Account Statistics" -msgstr "" +msgstr "Аналитик санхүүгийн статистик" #. module: account #: view:wizard.multi.charts.accounts:0 @@ -4652,12 +4656,12 @@ msgstr "Ажил гүйлгээнүүд" #. module: account #: wizard_view:account.analytic.account.chart,init:0 msgid "Analytic Account Charts" -msgstr "" +msgstr "Аналитик дансны мод" #. module: account #: wizard_field:account.aged.trial.balance,init,result_selection:0 msgid "Filter on Partners" -msgstr "" +msgstr "Харилцагч дээр шүүлт хийх" #. module: account #: field:account.tax,price_include:0 @@ -4674,7 +4678,7 @@ msgstr "Аналитик бичилтүүд журналаар" #: model:process.transition,note:account.process_transition_suppliervalidentries0 #: model:process.transition,note:account.process_transition_validentries0 msgid "Valid entries from invoice" -msgstr "" +msgstr "Нэхэмжлэлийн хүчинтэй бичилт" #. module: account #: field:account.account,company_id:0 @@ -4704,7 +4708,7 @@ msgstr "Орлого" #. module: account #: selection:account.subscription,state:0 msgid "Running" -msgstr "" +msgstr "Байнгын" #. module: account #: help:account.tax,include_base_amount:0 @@ -4728,7 +4732,7 @@ msgstr "Журналын нэр" #. module: account #: model:process.transition,note:account.process_transition_invoiceimport0 msgid "Import invoice from statement" -msgstr "" +msgstr "Мэдэгдлээс нэхэмжлэл оруулж ирэх" #. module: account #: selection:account.automatic.reconcile,init,power:0 @@ -4745,13 +4749,13 @@ msgstr "Санхүүгийн жил" #. module: account #: model:process.node,note:account.process_node_importinvoice0 msgid "Import from invoices or payments" -msgstr "" +msgstr "Нэхэмжлэл буюу төлөлтөөс оруулах" #. module: account #: model:ir.actions.wizard,name:account.wizard_reconcile_select #: model:ir.ui.menu,name:account.menu_reconcile_select msgid "Reconcile entries" -msgstr "" +msgstr "Тулгах бичилт" #. module: account #: xsl:account.transfer:0 @@ -4837,7 +4841,7 @@ msgstr "А/к дугаар" #: model:ir.actions.act_window,name:account.report_account_analytic_journal_tree_month #: model:ir.ui.menu,name:account.report_account_analytic_journal_print_month msgid "Account cost and revenue by journal (This Month)" -msgstr "" +msgstr "Дансны өртөг, орлого журналаар" #. module: account #: selection:account.partner.balance.report,init,result_selection:0 @@ -4921,7 +4925,7 @@ msgstr "Борлуулалтын татварууд" #. module: account #: model:ir.model,name:account.model_account_move_reconcile msgid "Account Reconciliation" -msgstr "" +msgstr "Дансны тулгалт" #. module: account #: view:account.bank.statement:0 @@ -4953,12 +4957,12 @@ msgstr "" #: field:account.bank.statement.reconcile,total_amount:0 #: field:account.bank.statement.reconcile,total_second_amount:0 msgid "Payment amount" -msgstr "" +msgstr "Төлөлтийн хэмжээ" #. module: account #: view:account.analytic.account:0 msgid "Analytic account" -msgstr "" +msgstr "Аналитик данс" #. module: account #: rml:account.invoice:0 @@ -4995,17 +4999,17 @@ msgstr "Дебит" #. module: account #: model:ir.ui.menu,name:account.next_id_42 msgid "All Months" -msgstr "" +msgstr "Бүх сарууд" #. module: account #: wizard_field:account.invoice.refund,init,date:0 msgid "Operation date" -msgstr "" +msgstr "Ашиглалтын огноо" #. module: account #: field:account.invoice,invoice_line:0 msgid "Invoice Lines" -msgstr "" +msgstr "Нэхэмжлэлийн мөр" #. module: account #: field:account.period,date_start:0 @@ -5020,7 +5024,7 @@ msgstr "Шинэ гүйлгээний нэр" #. module: account #: wizard_button:account_use_models,init_form,create:0 msgid "Create Entries" -msgstr "" +msgstr "Бичилт үүсгэх" #. module: account #: field:account.tax,ref_tax_code_id:0 @@ -5031,17 +5035,17 @@ msgstr "Буцаалтын татварын ангилал" #. module: account #: field:account.invoice.tax,name:0 msgid "Tax Description" -msgstr "" +msgstr "Татварын тайлбар" #. module: account #: help:account.invoice,move_id:0 msgid "Link to the automatically generated account moves." -msgstr "" +msgstr "Дансны автомат үүссэн шилжилтүүд рүү холбох" #. module: account #: wizard_field:account.automatic.reconcile,reconcile,reconciled:0 msgid "Reconciled transactions" -msgstr "" +msgstr "Тулгагдсан гүйлгээнүүд" #. module: account #: model:ir.ui.menu,name:account.menu_finance_reporting @@ -5052,23 +5056,23 @@ msgstr "Тайлан" #: rml:account.third_party_ledger:0 #: rml:account.third_party_ledger_other:0 msgid "/" -msgstr "" +msgstr "/" #. module: account #: model:process.node,note:account.process_node_invoiceinvoice0 #: model:process.node,note:account.process_node_supplierinvoiceinvoice0 msgid "Have a number and entries are generated" -msgstr "" +msgstr "Үүсгэгдсэн тоо болон бичлэгүүдийг агуулж байна" #. module: account #: rml:account.analytic.account.analytic.check:0 msgid "Analytic Check -" -msgstr "" +msgstr "Аналитик шалгалт-" #. module: account #: rml:account.account.balance:0 msgid "Account Balance -" -msgstr "" +msgstr "Дансны тэнцэл-" #. module: account #: field:account.journal,group_invoice_lines:0 @@ -5084,7 +5088,7 @@ msgstr "Тохиргоо" #: view:account.analytic.line:0 #: view:account.invoice:0 msgid "Total amount" -msgstr "" +msgstr "Нийт хэмжээ" #. module: account #: view:account.journal:0 @@ -5094,7 +5098,7 @@ msgstr "Журналын бүтэц" #. module: account #: view:account.subscription.line:0 msgid "Subscription lines" -msgstr "" +msgstr "Бүртгэлийн мөрүүд" #. module: account #: field:account.chart.template,property_account_income:0 @@ -5111,7 +5115,7 @@ msgstr "Уг дансны гүйлгээг хөрвүүлж хадгалах в #: wizard_button:populate_statement_from_inv,go,end:0 #: wizard_button:populate_statement_from_inv,init,end:0 msgid "_Cancel" -msgstr "" +msgstr "Цуцлах" #. module: account #: wizard_view:account.general.ledger.report,checktype:0 @@ -5129,7 +5133,7 @@ msgstr "Тонгоруулсан аналитик баланс-" #: model:process.node,name:account.process_node_paidinvoice0 #: model:process.node,name:account.process_node_supplierpaidinvoice0 msgid "Paid invoice" -msgstr "" +msgstr "Нэхэмжлэл төлөх" #. module: account #: view:account.tax:0 @@ -5147,7 +5151,7 @@ msgstr "Татварын групп" #: model:ir.actions.act_window,name:account.action_invoice_tree3_new #: model:ir.ui.menu,name:account.menu_action_invoice_tree3_new msgid "New Customer Refund" -msgstr "Шинэ худалдан авагчийн буцаалт" +msgstr "Шинэ Үйлчлүүлэгчийн буцаалт" #. module: account #: help:wizard.multi.charts.accounts,seq_journal:0 @@ -5161,7 +5165,7 @@ msgstr "" #. module: account #: model:ir.actions.wizard,name:account.wizard_populate_statement_from_inv msgid "Import invoices" -msgstr "" +msgstr "Нэхэмжлэл оруулж ирэх" #. module: account #: wizard_view:account.move.line.unreconcile,init:0 @@ -5195,7 +5199,7 @@ msgstr "Дансны өгөгдөл" #. module: account #: view:account.tax.code.template:0 msgid "Account Tax Code Template" -msgstr "" +msgstr "Дансны татварын кодны загвар" #. module: account #: view:account.subscription:0 @@ -5205,7 +5209,7 @@ msgstr "" #. module: account #: model:process.node,name:account.process_node_manually0 msgid "Manually" -msgstr "" +msgstr "Гараар" #. module: account #: view:account.invoice:0 @@ -5235,22 +5239,22 @@ msgstr "Нэхэмжлэлийн гүйлгээ" #. module: account #: wizard_field:account.invoice.pay,addendum,writeoff_journal_id:0 msgid "Write-Off journal" -msgstr "" +msgstr "Журналаас хасалт хийх" #. module: account #: wizard_button:account.invoice.pay,init,writeoff_check:0 msgid "Full Payment" -msgstr "" +msgstr "Бүтэн төлөлт" #. module: account #: selection:account.move,type:0 msgid "Journal Purchase" -msgstr "" +msgstr "Худалдан авалтын журнал" #. module: account #: selection:account.move,type:0 msgid "Cash Receipt" -msgstr "" +msgstr "Кассын баримт" #. module: account #: field:account.fiscal.position.tax,tax_dest_id:0 @@ -5276,9 +5280,7 @@ msgstr "Томьёолол" #. module: account #: help:account.move.line,currency_id:0 msgid "The optional other currency if it is a multi-currency entry." -msgstr "" -"Тухайн дансны валютаас өөр валютаар бичилт хийх үед хэрэглэгдэх валютын " -"төрөл." +msgstr "Гадаад валютын гүйлгээ бол валютыг сонгоно." #. module: account #: view:account.invoice:0 @@ -5295,7 +5297,7 @@ msgstr "" #. module: account #: wizard_view:account_use_models,create:0 msgid "Use Model" -msgstr "" +msgstr "Модел ашиглах" #. module: account #: wizard_button:account.wizard_paid_open,init,end:0 @@ -5305,7 +5307,7 @@ msgstr "Үгүй" #. module: account #: model:ir.actions.act_window,name:account.act_account_partner_account_move msgid "All account entries" -msgstr "" +msgstr "Бүх дансны бичилт" #. module: account #: help:account.invoice.tax,tax_code_id:0 @@ -5323,7 +5325,7 @@ msgstr "Огноо шүүлт" #. module: account #: wizard_view:populate_statement_from_inv,init:0 msgid "Choose Journal and Payment Date" -msgstr "" +msgstr "Журнал болон төлөлтийн огноо сонгох" #. module: account #: selection:account.analytic.account,state:0 @@ -5347,7 +5349,7 @@ msgstr "Төлсөн" #: model:ir.actions.act_window,name:account.action_invoice_tree11 #: model:ir.ui.menu,name:account.menu_action_invoice_tree11 msgid "Unpaid Customer Refunds" -msgstr "Худалдан авагчийн төлөгдөөгүй буцаалтууд" +msgstr "Үйлчлүүлэгчийн төлөгдөөгүй буцаалтууд" #. module: account #: help:account.invoice,residual:0 @@ -5357,18 +5359,18 @@ msgstr "" #. module: account #: wizard_view:account.period.close,init:0 msgid "Are you sure ?" -msgstr "" +msgstr "Та итгэлтэй байна уу?" #. module: account #: rml:account.invoice:0 #: view:account.invoice:0 msgid "PRO-FORMA" -msgstr "" +msgstr "PRO-FORMA" #. module: account #: field:account.move.reconcile,line_partial_ids:0 msgid "Partial Entry lines" -msgstr "" +msgstr "Хэсэгчилсэн журналын бичилт" #. module: account #: help:account.move.line,statement_id:0 @@ -5378,7 +5380,7 @@ msgstr "Банкны гүйлгээ тулгалтанд хэрэглэгдэх #. module: account #: view:account.fiscalyear:0 msgid "Fiscalyear" -msgstr "" +msgstr "Санхүүгийн жил" #. module: account #: wizard_button:account.analytic.line,init,open:0 @@ -5389,12 +5391,12 @@ msgstr "" #: selection:account.analytic.account,type:0 #: selection:account.move.line,centralisation:0 msgid "Normal" -msgstr "" +msgstr "Хэвийн" #. module: account #: model:process.process,name:account.process_process_supplierinvoiceprocess0 msgid "Supplier Invoice Process" -msgstr "" +msgstr "Нийлүүлэгч нэхэмжлэх процесс" #. module: account #: rml:account.account.balance:0 @@ -5408,7 +5410,7 @@ msgstr "" #: rml:account.third_party_ledger_other:0 #: rml:account.vat.declaration:0 msgid "Page" -msgstr "" +msgstr "Хуудас" #. module: account #: view:account.move:0 @@ -5420,23 +5422,23 @@ msgstr "Туслах мэдээлэл" #: model:ir.actions.act_window,name:account.action_payment_term_form #: model:ir.ui.menu,name:account.menu_action_payment_term_form msgid "Payment Terms" -msgstr "" +msgstr "Төлөлтийн нөхцөл" #. module: account #: selection:account.aged.trial.balance,init,result_selection:0 msgid "Receivable and Payable" -msgstr "" +msgstr "Авлага болон өглөг" #. module: account #: rml:account.account.balance:0 #: rml:account.general.journal:0 msgid ":" -msgstr "" +msgstr ":" #. module: account #: field:account.bank.statement.line,reconcile_amount:0 msgid "Amount reconciled" -msgstr "" +msgstr "Тулгагдсан хэмжээ" #. module: account #: selection:account.account,currency_mode:0 @@ -5474,7 +5476,7 @@ msgstr "Татварын хэрэглээ" #: model:ir.actions.act_window,name:account.action_subscription_form #: model:ir.ui.menu,name:account.menu_action_subscription_form msgid "Subscription Entries" -msgstr "" +msgstr "Баримтын бичилт" #. module: account #: model:ir.actions.act_window,name:account.action_invoice_tree6 @@ -5502,7 +5504,7 @@ msgstr "Мөчлөгийн төгсгөл" #: view:account.move:0 #: model:ir.model,name:account.model_account_move msgid "Account Entry" -msgstr "" +msgstr "Дансны бичилт" #. module: account #: rml:account.general.journal:0 @@ -5528,7 +5530,7 @@ msgstr "Ерөнхий журнал" #: rml:account.third_party_ledger:0 #: rml:account.third_party_ledger_other:0 msgid "Balance" -msgstr "Тэнцэл" +msgstr "Баланс" #. module: account #: rml:account.invoice:0 @@ -5538,7 +5540,7 @@ msgstr "Буцааж төлөх" #. module: account #: model:ir.model,name:account.model_account_invoice_tax msgid "Invoice Tax" -msgstr "" +msgstr "Татварын нэхэмжлэл" #. module: account #: model:ir.actions.act_window,name:account.action_account_analytic_journal_form @@ -5664,7 +5666,7 @@ msgstr "" #. module: account #: field:account.model.line,date:0 msgid "Current Date" -msgstr "" +msgstr "Одоогийн огноо" #. module: account #: selection:account.move,type:0 @@ -5785,7 +5787,7 @@ msgstr "Мөчлөг нээж хаах" #. module: account #: rml:account.analytic.account.balance:0 msgid "Analytic Balance -" -msgstr "" +msgstr "Аналитик тэнцэл" #. module: account #: wizard_field:account_use_models,init_form,model:0 @@ -5802,7 +5804,7 @@ msgstr "Нэхэмжлэлийн мөр" #. module: account #: selection:account.bank.statement.line,type:0 msgid "Customer" -msgstr "Худалдан авагч" +msgstr "Үйлчлүүлэгчийн" #. module: account #: field:account.subscription,period_type:0 @@ -5812,7 +5814,7 @@ msgstr "Мөчлөгийн төрөл" #. module: account #: view:product.category:0 msgid "Accounting Properties" -msgstr "" +msgstr "Санхүүгийн бүрэлдэхүүн хэсгүүд" #. module: account #: model:ir.model,name:account.model_account_sequence_fiscalyear @@ -5858,7 +5860,7 @@ msgstr "Солих данс" #. module: account #: rml:account.overdue:0 msgid "Maturity" -msgstr "" +msgstr "Хугацаа" #. module: account #: field:account.fiscalyear,name:0 @@ -5894,12 +5896,12 @@ msgstr "Нийлүүлэгчийн буцаалт" #: model:process.transition,note:account.process_transition_entriesreconcile0 #: model:process.transition,note:account.process_transition_supplierentriesreconcile0 msgid "Reconcile Entries." -msgstr "" +msgstr "Бичилт тулгах" #. module: account #: field:account.subscription.line,move_id:0 msgid "Entry" -msgstr "Бичилт" +msgstr "Ажил гүйлгээ" #. module: account #: model:process.node,note:account.process_node_paidinvoice0 @@ -5918,7 +5920,7 @@ msgstr "" #. module: account #: model:ir.module.module,shortdesc:account.module_meta_information msgid "Accounting and financial management" -msgstr "" +msgstr "Санхүү эдийн засгийн удирдлага" #. module: account #: view:account.fiscal.position.template:0 @@ -6044,7 +6046,7 @@ msgstr "Хэрэглэгч уг дансны гүйлгээг банкны ху #. module: account #: wizard_button:account.subscription.generate,init,generate:0 msgid "Compute Entry Dates" -msgstr "" +msgstr "Гүйлгээний огноо тооцоолол" #. module: account #: view:board.board:0 @@ -6060,7 +6062,7 @@ msgstr "Ноорог нэхэмжлэл" #: model:ir.actions.act_window,name:account.open_board_account #: model:ir.ui.menu,name:account.menu_board_account msgid "Accounting Dashboard" -msgstr "" +msgstr "Санхүүгийн хянах самбар" #. module: account #: view:board.board:0 @@ -6077,7 +6079,7 @@ msgstr "Үнийн нэхэмжлэл" #. module: account #: view:board.board:0 msgid "Aged receivables" -msgstr "Насжилтын авлагын данс" +msgstr "Авлагын насжилт" #. module: account #: model:ir.module.module,shortdesc:account.module_meta_information @@ -6097,12 +6099,12 @@ msgstr "Эдийн засгийн үзүүлэлт" #. module: account #: view:board.board:0 msgid "Account Board" -msgstr "" +msgstr "Дансны самбар" #. module: account #: view:board.board:0 msgid "Aged income" -msgstr "" +msgstr "Насжилтын орлого" #. module: account #: wizard_field:account.balance.account.balance.report,init,show_columns:0 @@ -6164,7 +6166,7 @@ msgstr "" #. module: account #: model:ir.actions.wizard,name:account.wizard_account_balance_report msgid "Account balance-Compare Years" -msgstr "" +msgstr "Дансны тэнцлийг жилээр нь харьцуулах" #. module: account #: model:ir.module.module,description:account.module_meta_information @@ -6296,7 +6298,7 @@ msgstr "" #. module: account #: wizard_view:account.balance.account.balance.report,init:0 msgid "Customize Report" -msgstr "" +msgstr "Хувийн тайлан" #. module: account #: field:report.aged.receivable,name:0 @@ -6326,7 +6328,7 @@ msgstr "Дансны төрлөөр" #. module: account #: model:ir.model,name:report_account.model_report_aged_receivable msgid "Aged Receivable Till Today" -msgstr "" +msgstr "Өнөөдрийг хүртэлх авлагын насжилт" #. module: account #: model:ir.model,name:report_account.model_report_account_receivable @@ -6352,7 +6354,7 @@ msgstr "Санхүүгийн тайлан-Тайлан" #: model:ir.actions.act_window,name:report_account.action_account_receivable_graph #: model:ir.ui.menu,name:report_account.menu_account_receivable_graph msgid "Balance by Type of Account" -msgstr "" +msgstr "Дансны төрлийн тэнцэл" #. module: account #: field:report.account.receivable,name:0 @@ -6368,7 +6370,7 @@ msgstr "Үүсгэх огноо" #: model:ir.actions.act_window,name:report_account.action_aged_receivable_graph #: view:report.aged.receivable:0 msgid "Aged Receivable" -msgstr "Насжилтын авлага" +msgstr "Авлагын насжилт" #. module: account #: view:report.invoice.created:0 diff --git a/addons/account/i18n/sr.po b/addons/account/i18n/sr.po index d171553ea85..7efd4a0b1be 100644 --- a/addons/account/i18n/sr.po +++ b/addons/account/i18n/sr.po @@ -8,13 +8,13 @@ msgstr "" "Project-Id-Version: openobject-addons\n" "Report-Msgid-Bugs-To: FULL NAME \n" "POT-Creation-Date: 2009-08-28 16:01+0000\n" -"PO-Revision-Date: 2010-10-13 16:24+0000\n" -"Last-Translator: zmmaj \n" +"PO-Revision-Date: 2010-10-14 07:29+0000\n" +"Last-Translator: OpenERP Administrators \n" "Language-Team: Serbian \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Launchpad-Export-Date: 2010-10-14 04:45+0000\n" +"X-Launchpad-Export-Date: 2010-10-15 04:42+0000\n" "X-Generator: Launchpad (build Unknown)\n" #. module: account diff --git a/addons/account/installer.py b/addons/account/installer.py index 60251a673ae..b689697d7a8 100644 --- a/addons/account/installer.py +++ b/addons/account/installer.py @@ -256,7 +256,7 @@ class account_installer(osv.osv_memory): vals_seq = { 'name': _('Bank Journal '), 'code': 'account.journal', - 'prefix': 'BAN/', + 'prefix': 'BNK/%(year)s/', 'padding': 5 } seq_id = obj_sequence.create(cr,uid,vals_seq) @@ -280,17 +280,13 @@ class account_installer(osv.osv_memory): obj_journal.create(cr,uid,vals_journal) for val in record.bank_accounts_id: - seq_prefix = None seq_padding = 5 if val.account_type == 'cash': type = cash_type_id - seq_prefix = "CSH/" elif val.account_type == 'bank': type = bank_type_id - seq_prefix = "BAN/" elif val.account_type == 'check': type = check_type_id - seq_prefix = "CHK/" else: type = check_type_id seq_padding = None @@ -304,9 +300,9 @@ class account_installer(osv.osv_memory): 'company_id': company_id.id } child_bnk_acc = obj_acc.create(cr, uid, vals_bnk) vals_seq_child = { - 'name': _(vals_bnk['name']), + 'name': _(vals_bnk['name'] + ' ' + 'Journal'), 'code': 'account.journal', - 'prefix': seq_prefix, + 'prefix': _((vals_bnk['name'][:3].upper()) + '/%(year)s/'), 'padding': seq_padding } seq_id = obj_sequence.create(cr, uid, vals_seq_child) @@ -314,7 +310,7 @@ class account_installer(osv.osv_memory): #create the bank journal vals_journal = {} vals_journal['name']= vals_bnk['name'] + ' Journal' - vals_journal['code']= _(vals_bnk['name'][:3]) + vals_journal['code']= _(vals_bnk['name'][:3]).upper() vals_journal['sequence_id'] = seq_id vals_journal['type'] = 'cash' if vals.get('currency_id', False): @@ -328,7 +324,6 @@ class account_installer(osv.osv_memory): obj_journal.create(cr,uid,vals_journal) code_cnt += 1 - #reactivate the parent_store functionality on account_account self.pool._init = False self.pool.get('account.account')._parent_store_compute(cr) @@ -352,20 +347,36 @@ class account_installer(osv.osv_memory): seq_sale = { 'name': 'Sale Journal', 'code': 'account.journal', - 'prefix': '%(year)s/', + 'prefix': 'SAJ/%(year)s/', 'padding': 3 } seq_id_sale = obj_sequence.create(cr, uid, seq_sale) seq_purchase = { 'name': 'Purchase Journal', 'code': 'account.journal', - 'prefix': '%(year)s/', + 'prefix': 'EXJ/%(year)s/', 'padding': 3 } seq_id_purchase = obj_sequence.create(cr, uid, seq_purchase) + seq_refund_sale = { + 'name': 'Sales Refund Journal', + 'code': 'account.journal', + 'prefix': 'SCNJ/%(year)s/', + 'padding': 3 + } + seq_id_sale_refund = obj_sequence.create(cr, uid, seq_refund_sale) + seq_refund_purchase = { + 'name': 'Purchase Refund Journal', + 'code': 'account.journal', + 'prefix': 'ECNJ/%(year)s/', + 'padding': 3 + } + seq_id_purchase_refund = obj_sequence.create(cr, uid, seq_refund_purchase) else: seq_id_sale = seq_id seq_id_purchase = seq_id + seq_id_sale_refund = seq_id + seq_id_purchase_refund = seq_id vals_journal['view_id'] = view_id @@ -408,9 +419,6 @@ class account_installer(osv.osv_memory): data = mod_obj.browse(cr, uid, data_id[0]) view_id = data.res_id - seq_id_sale_refund = seq_id_sale - seq_id_purchase_refund = seq_id_purchase - vals_journal['view_id'] = view_id #Sales Refund Journal @@ -596,8 +604,7 @@ class account_installer(osv.osv_memory): new_paid_tax_code = self.pool.get('account.tax.code').create(cr, uid, vals_paid_tax_code) sales_tax = obj_tax.create(cr, uid, - {'name':'TAX%s%%'%(s_tax*100), - 'description':'TAX%s%%'%(s_tax*100), + {'name':'TAX %s%%'%(s_tax*100), 'amount':s_tax, 'base_code_id':new_tax_code, 'tax_code_id':new_paid_tax_code, @@ -632,8 +639,7 @@ class account_installer(osv.osv_memory): new_paid_tax_code = self.pool.get('account.tax.code').create(cr, uid, vals_paid_tax_code) purchase_tax = obj_tax.create(cr, uid, - {'name':'TAX%s%%'%(p_tax*100), - 'description':'TAX%s%%'%(p_tax*100), + {'name':'TAX %s%%'%(p_tax*100), 'amount':p_tax, 'base_code_id':new_tax_code, 'tax_code_id':new_paid_tax_code, diff --git a/addons/account/invoice.py b/addons/account/invoice.py index 4cdaeab9a49..23978296367 100644 --- a/addons/account/invoice.py +++ b/addons/account/invoice.py @@ -351,7 +351,7 @@ class account_invoice(osv.osv): if view_type == 'tree': doc = etree.XML(res['arch']) nodes = doc.xpath("//field[@name='partner_id']") - partner_string = 'Customer' + partner_string = _('Customer') if context.get('type', 'out_invoice') in ('in_invoice', 'in_refund'): partner_string = _('Supplier') for node in nodes: @@ -363,7 +363,7 @@ class account_invoice(osv.osv): try: res = super(account_invoice, self).create(cr, uid, vals, context) for inv_id, name in self.name_get(cr, uid, [res], context=context): - message = _('Invoice ') + " '" + name + "' "+ _("is waiting for validation.") + message = _("Invoice '%s' is waiting for validation.") % name self.log(cr, uid, inv_id, message) return res except Exception, e: @@ -375,6 +375,9 @@ class account_invoice(osv.osv): def confirm_paid(self, cr, uid, ids, context=None): self.write(cr, uid, ids, {'state':'paid'}, context=context) + for inv_id, name in self.name_get(cr, uid, ids, context=context): + message = _("Invoice '%s' is paid.") % name + self.log(cr, uid, inv_id, message) return True def unlink(self, cr, uid, ids, context=None): @@ -674,7 +677,7 @@ class account_invoice(osv.osv): return (ref or '').replace('/','') def _get_analytic_lines(self, cr, uid, id): - inv = self.browse(cr, uid, [id])[0] + inv = self.browse(cr, uid, id) cur_obj = self.pool.get('res.currency') company_currency = inv.company_id.currency_id.id @@ -690,6 +693,8 @@ class account_invoice(osv.osv): ref = inv.reference else: ref = self._convert_ref(cr, uid, inv.number) + if not inv.journal_id.analytic_journal_id: + raise osv.except_osv(_('No Analytic Journal !'),_("You have to define an analytic journal on the '%s' journal!") % (inv.journal_id.name,)) il['analytic_lines'] = [(0,0, { 'name': il['name'], 'date': inv['date_invoice'], @@ -699,7 +704,7 @@ class account_invoice(osv.osv): 'product_id': il['product_id'], 'product_uom_id': il['uos_id'], 'general_account_id': il['account_id'], - 'journal_id': self._get_journal_analytic(cr, uid, inv.type), + 'journal_id': inv.journal_id.analytic_journal_id.id, 'ref': ref, })] return iml @@ -1218,12 +1223,13 @@ class account_invoice(osv.osv): inv_id, name = self.name_get(cr, uid, [invoice.id], context=context)[0] if (not round(total,self.pool.get('decimal.precision').precision_get(cr, uid, 'Account'))) or writeoff_acc_id: - self.log(cr, uid, inv_id, _('Invoice ') + " '" + name + "' "+ _("is totally paid.")) self.pool.get('account.move.line').reconcile(cr, uid, line_ids, 'manual', writeoff_acc_id, writeoff_period_id, writeoff_journal_id, context) else: code = invoice.currency_id.code - amt = str(pay_amount) + code + ' on ' + str(invoice.amount_total) + code + ' (' + str(total) + code + ' remaining)' - self.log(cr, uid, inv_id, _('Invoice ') + " '" + name + "' "+ _("is paid partially: ") + amt) + # TODO: use currency's formatting function + msg = _("Invoice '%s' is paid partially: %s%s of %s%s (%s%s remaining)") % \ + (name, pay_amount, code, invoice.amount_total, code, total, code) + self.log(cr, uid, inv_id, msg) self.pool.get('account.move.line').reconcile_partial(cr, uid, line_ids, 'manual', context) # Update the stored value (fields.function), so we write to trigger recompute @@ -1289,14 +1295,6 @@ class account_invoice_line(osv.osv): 'price_unit': _price_unit_default, } - def product_id_change_unit_price_inv(self, cr, uid, tax_id, price_unit, qty, address_invoice_id, product, partner_id, context=None): - tax_obj = self.pool.get('account.tax') - if price_unit: - taxes = tax_obj.browse(cr, uid, tax_id) - for tax in tax_obj.compute_inv(cr, uid, taxes, price_unit, qty, address_invoice_id, product, partner_id): - price_unit = price_unit - tax['amount'] - return {'price_unit': price_unit,'invoice_line_tax_id': tax_id} - def product_id_change(self, cr, uid, ids, product, uom, qty=0, name='', type='out_invoice', partner_id=False, fposition_id=False, price_unit=False, address_invoice_id=False, currency_id=False, context=None): if context is None: context = {} @@ -1361,7 +1359,7 @@ class account_invoice_line(osv.osv): else: app_acc_in = in_acc_cate app_acc_exp = ex_acc_cate - if app_acc_in.company_id.id != company_id and app_acc_exp.company_id.id != company_id: + if app_acc_in and app_acc_in.company_id.id != company_id and app_acc_exp and app_acc_exp.company_id.id != company_id: in_res_id = account_obj.search(cr, uid, [('name','=',app_acc_in.name),('company_id','=',company_id)]) exp_res_id = account_obj.search(cr, uid, [('name','=',app_acc_exp.name),('company_id','=',company_id)]) if not in_res_id and not exp_res_id: @@ -1396,8 +1394,7 @@ class account_invoice_line(osv.osv): taxes = res.supplier_taxes_id and res.supplier_taxes_id or (a and self.pool.get('account.account').browse(cr, uid, a).tax_ids or False) tax_id = fpos_obj.map_tax(cr, uid, fpos, taxes) if type in ('in_invoice', 'in_refund'): - to_update = self.product_id_change_unit_price_inv(cr, uid, tax_id, price_unit or res.standard_price, qty, address_invoice_id, product, partner_id, context=context) - result.update(to_update) + result.update( {'price_unit': price_unit or res.standard_price,'invoice_line_tax_id': tax_id} ) else: result.update({'price_unit': res.list_price, 'invoice_line_tax_id': tax_id}) diff --git a/addons/account/project/project.py b/addons/account/project/project.py index f082672310e..5a58eca97a4 100644 --- a/addons/account/project/project.py +++ b/addons/account/project/project.py @@ -28,11 +28,11 @@ from osv import osv class account_analytic_journal(osv.osv): _name = 'account.analytic.journal' _columns = { - 'name' : fields.char('Journal Name', size=64, required=True), - 'code' : fields.char('Journal Code', size=8), - 'active' : fields.boolean('Active', help="If the active field is set to true, it will allow you to hide the analytic journal without removing it."), + 'name': fields.char('Journal Name', size=64, required=True), + 'code': fields.char('Journal Code', size=8), + 'active': fields.boolean('Active', help="If the active field is set to true, it will allow you to hide the analytic journal without removing it."), 'type': fields.selection([('sale','Sale'), ('purchase','Purchase'), ('cash','Cash'), ('general','General'), ('situation','Situation')], 'Type', size=32, required=True, help="Gives the type of the analytic journal. When it needs for a document (eg: an invoice) to create analytic entries, OpenERP will look for a matching journal of the same type."), - 'line_ids' : fields.one2many('account.analytic.line', 'journal_id', 'Lines'), + 'line_ids': fields.one2many('account.analytic.line', 'journal_id', 'Lines'), 'company_id': fields.many2one('res.company', 'Company', required=True), } _defaults = { diff --git a/addons/account/project/project_view.xml b/addons/account/project/project_view.xml index 809f69673fe..9a482155b4f 100644 --- a/addons/account/project/project_view.xml +++ b/addons/account/project/project_view.xml @@ -14,6 +14,8 @@ + + @@ -127,7 +129,7 @@ tree [('parent_id','=',False)] - Analytic Charts of Accounts allows you to access to reports by analytic accounts (or cost accounts) . From this menu you can access to analytic balance, a report that relates the analytic accounts to the general accounts. It is useful for analyzing the profitability of projects, giving you the profitability of a project for the different operations that you used to carry out the project. + The normal chart of accounts has a structure defined by the legal requirement of the country. The analytic chart of account structure should reflect your own business needs in term of costs/revenues reporting. They are usually structured by contracts, projects, products or departements. Most of the OpenERP operations (invoices, timesheets, expenses, etc) generate analytic entries on the related account. diff --git a/addons/account/project/wizard/account_analytic_cost_ledger_for_journal_report_view.xml b/addons/account/project/wizard/account_analytic_cost_ledger_for_journal_report_view.xml index 82796a75b4f..3bf5d54e8a6 100644 --- a/addons/account/project/wizard/account_analytic_cost_ledger_for_journal_report_view.xml +++ b/addons/account/project/wizard/account_analytic_cost_ledger_for_journal_report_view.xml @@ -8,18 +8,16 @@ form - - - - - - - - -