Odoo Help

Welcome!

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.

0

What's the difference between sale_order and sale_order_line?

By
Kit Sunde
on 8/22/14, 5:09 PM 1,444 views

In sale/sale.py there's two models sale_order and sale_order_line, what's the distinction between these?

Yes,

Abhishek H Menon
on 8/23/14, 3:24 AM
3

Janeesh

--Janeesh--
1641
| 4 3 4
Cochin, India
--Janeesh--

Odoo Developer

Janeesh
On 8/23/14, 1:08 AM

Sales Order (sale_order) is the master record for sales where we store Reference, Customer, Address, Date and any relevant data regarding sales. In Sale Order Line (sale_order_line) we specifies the products, qty, unit price etc..The total value of all these sale order line items are shown in sale order.

0
kalmenchia
On 8/22/14, 8:40 PM

Hi Kit ,

Sale_order is the Master / Header object for the Sales / CRM module 

and Sale_order_line , is the Individual line items in a Sales order , i.e. the product and services

with price and quantity you add in to a sales order. 

Hope this help !

0
klacus
On 8/22/14, 11:17 PM

Hi.

The Sale_order is the base order, model 'sale.order'

The 'sale.order.line' is a joined model (table) what is contain the order relevant items. (product ids, quas, and so on)

You can see the sale_order() columns definition, the sale.order.line is a one2many field of sale_order that is a connection betwwen the two table.

'order_line': fields.one2many('sale.order.line', 'order_id', 'Order Lines', readonly=True, states={'draft': [('readonly', False)]}),

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

2 follower(s)

Stats

Asked: 8/22/14, 5:09 PM
Seen: 1444 times
Last updated: 3/16/15, 8:10 AM