Accounting mailing list archives
accounting@odoo-community.org
Browse archives
Re: Account.voucher in v9/v10
by
Bringsvor Consulting AS, Torvald Bringsvor
Here's some code for the account.payment if you wish:
payment_obj = self.env['account.payment']
paymentinfo = {'partner_type': partner_type,
'partner_id': invoice.partner_id.id,
'amount': paid_amount,
'communication': t1,
'payment_date': fields.Date.to_string(s_datetime),
'name': t1,
'currency_id': self.currency_id and self.currency_id.id,
'journal_id': self.journal_id and self.journal_id.id,
'payment_type': payment_type,
'payment_method_id': self.payment_method_id and self.payment_method_id.id,
'payment_difference_handling': 'open',
'payment_reference': payment_reference,
'invoice_ids': [(6, 0, [invoice.id])],
}
payment = payment_obj.create(paymentinfo)
_logger.info('Created payment %s for invoice %s', payment,
invoice.number)
payment.post()
paymentinfo = {'partner_type': partner_type,
'partner_id': invoice.partner_id.id,
'amount': paid_amount,
'communication': t1,
'payment_date': fields.Date.to_string(s_datetime),
'name': t1,
'currency_id': self.currency_id and self.currency_id.id,
'journal_id': self.journal_id and self.journal_id.id,
'payment_type': payment_type,
'payment_method_id': self.payment_method_id and self.payment_method_id.id,
'payment_difference_handling': 'open',
'payment_reference': payment_reference,
'invoice_ids': [(6, 0, [invoice.id])],
}
payment = payment_obj.create(paymentinfo)
_logger.info('Created payment %s for invoice %s', payment,
invoice.number)
payment.post()
-Torvald
Torvald Baade Bringsvor
Bringsvor Consulting AS - Odoo (formerly OpenERP) implementation partner
Skogveien 13b, 1406 Ski. Tel (+47) 4548 2848
2016-10-10 18:08 GMT+02:00 Pedro M. Baeza (Tecnativa) <pedro.baeza@tecnativa.com>:
You have the new model account.payment for that.Regards.2016-10-05 23:23 GMT+02:00 Quentin Lavallée-Bourdeau <quentin.lavallee@savoirfairelinux.com >:Hi,
Is there a new feature in v9/v10 which allows to reconcile invoice & refund in order to do a single payment like the v8 view model=account.voucher?The model is no longer available.Thank you in advance,
Quentin Lavallée-Bourdeau
Consultant fonctionnel
Savoir-faire Linux
Tel: +1 514-276-5468 #331
www.savoirfairelinux.com______________________________
_________________
Mailing-List: http://odoo-community.org/groups/accounting-28
Post to: mailto:accounting@odoo-community.org
Unsubscribe: http://odoo-community.org/groups?unsubscribe ______________________________
_________________
Mailing-List: http://odoo-community.org/groups/accounting-28
Post to: mailto:accounting@odoo-community.org
Unsubscribe: http://odoo-community.org/groups?unsubscribe
Reference
-
Account.voucher in v9/v10
by Quentin Lavallée-Bourdeau <quentin.lavallee@savoirfairelinux.com> - 05/10/2016 23:14:55 - 0-
Re: Account.voucher in v9/v10
byBringsvor Consulting AS, Torvald Bringsvor
-