Odoo Help


This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Modify what gets posted to the General Ledger from a Sales Order

Petre Chitashvili
on 4/10/13, 3:36 PM 1,218 views


I have made some modifications to the sales order form and would like to modify what gets posted to the GL by changing the underlying template(s).

Specifically, I want to split accounting entries to reflect partial payments by the customers.

Please suggest whether this can be done via configuration or where to search for it in code.

Thanks. Petre

OpenERP supports partial payments. What exactly do you want? (Is it already supported?)

Bista Solutions US, Ray Carnes
on 4/10/13, 3:49 PM

Here's the scenario: customer buys the product from the shop using a bank loan - bank's desk is in the shop; customer is required to pay 10% of the sale amount in cash immediately to the shop; the remaining 90% will be wire-transferred to the shop's account from the bank.

Thus, I need to split the accounting entries to reflect that 10% has been accrued to the customer and 90% is the receivable from the bank.

DIGY LLC, Petre Chitashvili
on 4/11/13, 4:54 AM

Ray Carnes

--Ray Carnes--
| 9 7 9
Greater Los Angeles, United States
--Ray Carnes--

Senior Odoo Analyst

OpenERP 6.1, 7.0 and Odoo 8.0, 9.0 (Since 2012)

Completed Functional and Technical Training.

Major Skills:

  • Needs Discovery and Requirements Analysis;

  • Function and Technical Specifications;

  • Project Planning;

  • Prototyping and Proof of concepts;

  • Data migration;

  • Configuration & Customization (UI and modules);

  • Integration - data, business logic and service levels;

  • Training and Knowledge transfer;

  • Go Live support;

  • Help desk;

  • Version Migration.

I have over 20 years of experience empowering and enabling users with enterprise information systems that make a real and measurable difference in their ability to proactively manage their businesses and organizations. 

Ray Carnes
On 4/11/13, 9:40 PM

Supported out of the box:

When you Invoice the Sales Order, the full amount of the sale is debited to AR as soon as the Invoice is validated.

When you record a payment for 10% of the amount, AR is credited by this amount, leaving the remaining 90%.

OpenERP is already posting the correct entries to the GL - I am missing the need for you to customize.

Thanks for you answer Ray.

Nevertheless, can you point out where is the configuration or code piece that controls what gets posted to the GL from sales?

DIGY LLC, Petre Chitashvili
on 4/12/13, 6:02 AM

When you create an Invoice from a Sales Order by clicking Create Invoice, the code executed after you click Create Invoice on the popup wizard is 'action_invoice_create' in addons/sale/sale.py. This setups what WILL be posted to the GL, but it doesn't happen until you Validate the invoice. This is when you get a debit to AR and a credit to SALES.

Bista Solutions US, Ray Carnes
on 4/12/13, 5:35 PM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)


Asked: 4/10/13, 3:36 PM
Seen: 1218 times
Last updated: 3/16/15, 8:10 AM