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

 in a quotation if i want to put the quantity for a product zero , and i do not want this product to appear in customer preview or while printing the quotation ,i need this for some tracking processes.

How can i do this?

Imagine profil
Abandonează
Cel mai bun răspuns

Why would you want to add a product with quantity zero? I don't see how this can help you tracking something as Odoo will not make a stock move line for this SO line. Is there maybe a better solution? If you share more details of the use case, we can think along with you.

If you really want to add a SO line with quantity 0 you could think about editing the sales order report with Odoo Studio. You can hide a line on the report when the quantity is 0.

Imagine profil
Abandonează
Cel mai bun răspuns

You could modify the QWeb report to only display the sales order line when the quantity is not zero. You would do this in the view report_saleorder_document. Somewhere around here

<tr t-att-class="'bg-200 font-weight-bold o_line_section' if line.display_type == 'line_section' else 'font-italic o_line_note' if line.display_type == 'line_note' else ''">
<t t-if="not line.display_type">
<td name="td_name"><span t-field="line.name"/></td>
Imagine profil
Abandonează

however, i think a custom field in the sale order or the sale order line would be even better... but maybe more difficult to implement ... just saying ...