Skip to Content
Menu
Dette spørgsmål er blevet anmeldt
1 Svar
5853 Visninger

how can i hide or invisible sale order lines on basis of condition I want to invisible more than 1 line in sale order line if user create three lines i want to show only first line

Avatar
Kassér
Bedste svar

Hi,


Just define a new Boolean field called "active" in "sale.order.line" model. In Odoo, this "active" field toggle the visibility of a record.


As per your requirement, if you need to hide the order lines based on condition, you can create a compute function in sale order which fetch all the orderline in the corresponding order and check the len(order.order_line) , if it is greater than 1 , you can just assign active = False for all the lines except the first one


Hope it helps​

Avatar
Kassér
Related Posts Besvarelser Visninger Aktivitet
1
maj 25
3118
4
jan. 24
14167
1
jan. 25
3225
2
aug. 24
5748
6
dec. 22
8629