Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
1266 Zobrazení

I try to import a sales order from an online shop. Because of different tax calculations, that leads to rounding errors, the total price of the order can differ by multiple cents.


For odoo itself there is the option with a B2C pricelist: https://www.odoo.com/documentation/17.0/applications/finance/accounting/taxes/B2B_B2C.html


But I create the Odoo 17 sale order via the XML-API with the following data:

{
  "carrier_id": 3,
  "client_order_ref": "13725",
  "company_id": 1,
  "name": "Order 13725",
  "note": "thanks :-)",
  "order_line": [
    [
      0,
      0,
      {
        "product_id": 101,
        "display_name": "Demo Product #1",
        "name": "Demo Product #1",
        "product_uom_qty": 1,
        "price_unit": 1,
        "price_tax": 0.07,
        "tax_id": [
          [
            6,
            0,
            [
              76
            ]
          ]
        ]
      }
    ]
  ],
  "partner_id": 13895
}

How can I use gross prices (taxes included) via API when the `sale.order.line` field `price_total` is read-only.

Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
0
bře 19
3379
1
říj 16
3673
2
čvc 16
18747
1
kvě 15
9232
1
bře 15
5425