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
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- 客户关系管理
- e-Commerce
- 会计
- 库存
- PoS
- Project
- MRP
此问题已终结
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
相关帖文 | 回复 | 查看 | 活动 | |
---|---|---|---|---|
|
1
5月 25
|
3072 | ||
|
4
1月 24
|
14133 | ||
|
1
1月 25
|
3176 | ||
|
2
8月 24
|
5728 | ||
|
6
12月 22
|
8594 |