diff --git a/addons/account/account.py b/addons/account/account.py index 9176a2eec64..b0271a4fee1 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -2473,14 +2473,14 @@ class account_tax_template(osv.osv): account_tax_template() -# Fiscal Mapping Templates +# Fiscal Position Templates class account_fiscal_position_template(osv.osv): _name = 'account.fiscal.position.template' - _description = 'Template for Fiscal Mapping' + _description = 'Template for Fiscal Position' _columns = { - 'name': fields.char('Fiscal Mapping Template', size=64, translate=True, required=True), + 'name': fields.char('Fiscal Position Template', size=64, translate=True, required=True), 'chart_template_id': fields.many2one('account.chart.template', 'Chart Template', required=True), 'account_ids': fields.one2many('account.fiscal.position.account.template', 'position_id', 'Account Mapping'), 'tax_ids': fields.one2many('account.fiscal.position.tax.template', 'position_id', 'Tax Mapping') @@ -2490,11 +2490,11 @@ account_fiscal_position_template() class account_fiscal_position_tax_template(osv.osv): _name = 'account.fiscal.position.tax.template' - _description = 'Template Tax Fiscal Mapping' + _description = 'Template Tax Fiscal Position' _rec_name = 'position_id' _columns = { - 'position_id': fields.many2one('account.fiscal.position.template', 'Fiscal Mapping', required=True, ondelete='cascade'), + 'position_id': fields.many2one('account.fiscal.position.template', 'Fiscal Position', required=True, ondelete='cascade'), 'tax_src_id': fields.many2one('account.tax.template', 'Tax Source', required=True), 'tax_dest_id': fields.many2one('account.tax.template', 'Replacement Tax') } @@ -2722,7 +2722,7 @@ class wizard_multi_charts_accounts(osv.osv_memory): # Bank Journals data_id = obj_data.search(cr, uid, [('model','=','account.journal.view'), ('name','=','account_journal_bank_view')]) - data = obj_pool.browse(cr, uid, data_id[0]) + data = obj_data.browse(cr, uid, data_id[0]) view_id_cash = data.res_id data_id = obj_data.search(cr, uid, [('model','=','account.journal.view'), ('name','=','account_journal_bank_view_multi')]) @@ -2860,4 +2860,4 @@ class account_bank_accounts_wizard(osv.osv_memory): account_bank_accounts_wizard() -# 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_installer.xml b/addons/account/account_installer.xml index a3570fae79a..2b736a514c3 100644 --- a/addons/account/account_installer.xml +++ b/addons/account/account_installer.xml @@ -26,7 +26,7 @@ - + @@ -34,24 +34,24 @@ - + + + + +
- + - +
- - - -
diff --git a/addons/account/account_invoice_view.xml b/addons/account/account_invoice_view.xml index 734b99e81f3..e72bd584f9d 100644 --- a/addons/account/account_invoice_view.xml +++ b/addons/account/account_invoice_view.xml @@ -36,11 +36,11 @@ - + - + @@ -55,16 +55,14 @@ - + - + - - + - @@ -85,7 +83,7 @@ - + @@ -100,7 +98,7 @@
- + @@ -148,7 +146,7 @@ form 2 - + @@ -156,7 +154,7 @@ + + + + + account.invoice.supplier.pay + account.invoice + form + + + + + + + + diff --git a/addons/account_voucher/account_voucher_view.xml b/addons/account_voucher/account_voucher_view.xml index b089825da9b..1ad3edd0760 100644 --- a/addons/account_voucher/account_voucher_view.xml +++ b/addons/account_voucher/account_voucher_view.xml @@ -218,14 +218,5 @@ - - diff --git a/addons/account_voucher/i18n/pl.po b/addons/account_voucher/i18n/pl.po index a1ddddebc4d..2bde4729e33 100644 --- a/addons/account_voucher/i18n/pl.po +++ b/addons/account_voucher/i18n/pl.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-07 16:41+0000\n" -"Last-Translator: Grzegorz Grzelak (Cirrus.pl) \n" +"PO-Revision-Date: 2010-10-08 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-08 04:39+0000\n" +"X-Launchpad-Export-Date: 2010-10-09 12:13+0000\n" "X-Generator: Launchpad (build Unknown)\n" #. module: account_voucher diff --git a/addons/account_voucher/invoice.py b/addons/account_voucher/invoice.py new file mode 100644 index 00000000000..a2cf45391fb --- /dev/null +++ b/addons/account_voucher/invoice.py @@ -0,0 +1,52 @@ +# -*- coding: utf-8 -*- +############################################################################## +# +# OpenERP, Open Source Management Solution +# Copyright (C) 2004-2010 Tiny SPRL (). +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +############################################################################## + +import netsvc +from osv import fields, osv +from tools.translate import _ + +class invoice(osv.osv): + _inherit = 'account.invoice' + def invoice_pay_customer(self, cr, uid, ids, context={}): + if not ids: return [] + inv = self.browse(cr, uid, ids[0], context=context) + return { + 'name':_("Pay Invoice"), + 'view_mode': 'form', + 'view_id': False, + 'view_type': 'form', + 'res_model': 'account.voucher', + 'type': 'ir.actions.act_window', + 'nodestroy': True, + 'target': 'new', + 'domain': '[]', + 'context': { + 'default_partner_id': inv.partner_id.id, + 'default_amount': inv.residual, + 'default_name':inv.name, + 'close_after_process': True, + 'invoice_type':inv.type, + 'invoice_id':inv.id, + 'default_type': inv.type in ('out_invoice','out_refund') and 'receipt' or 'payment' + } + } + +invoice() diff --git a/addons/account_voucher/voucher_payment_receipt_view.xml b/addons/account_voucher/voucher_payment_receipt_view.xml index 1e717a07a33..8169cac31e3 100644 --- a/addons/account_voucher/voucher_payment_receipt_view.xml +++ b/addons/account_voucher/voucher_payment_receipt_view.xml @@ -219,7 +219,7 @@