تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
1287 أدوات العرض

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.

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
0
مارس 19
3413
1
أكتوبر 16
3727
2
يوليو 16
18773
1
مايو 15
9288
1
مارس 15
5479