Skip to Content
Meniu
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
Această întrebare a fost marcată
1 Răspunde
5985 Vizualizări

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

Imagine profil
Abandonează
Cel mai bun răspuns

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​

Imagine profil
Abandonează
Related Posts Răspunsuri Vizualizări Activitate
1
mai 25
3262
4
ian. 24
14250
1
ian. 25
3342
2
aug. 24
5821
6
dec. 22
8747