hey guys,I set a priority field in product?I want to check all the invoice and its line to find which invoice_line has greater priority of product?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Boekhouding
- Voorraad
- PoS
- Project
- MRP
Deze vraag is gerapporteerd
2
Antwoorden
1295
Weergaven
You can create a compute field in invoice which will display the highest priority from the line.
highest_seq = fields.Integer(compute='_compute_highest_seq')
def _compute_highest_seq(self):
for inv in self:
inv.highest_seq = min([line.product_id.sequence for line in inv.invoice_line_ids])
Now, add this field in Invoice tree view so that you can see which invoice has highest priority of product.
Geniet je van het gesprek? Blijf niet alleen lezen, doe ook mee!
Maak vandaag nog een account aan om te profiteren van exclusieve functies en deel uit te maken van onze geweldige community!
Aanmelden
i get it sir,but i have one more question,i have more than one invoice and want to compare one with other on the basis of priority of product inside the invoice line,how will i do that?