Trần Thanh Chương
New Member
Mình có gửi đầy đủ các properties trong docs swagger của misa crm, nhưng api chỉ update được các properties của đơn hàng, không update được
sale_order_product_mappings.
Kiểm tra giúp mình nhé, mình gửi JSON
sale_order_product_mappings.
Kiểm tra giúp mình nhé, mình gửi JSON
JSON:
[
{
"owner_id": 4,
"owner_id_text": "xxx",
"form_layout_id": 37,
"form_layout_id_text": "Mẫu tiêu chuẩn",
"sale_order_no": "DH0001034",
"sale_order_name": "Đơn hàng bán cho Test",
"sale_order_date": "2023-09-24T00:00:00.000+07:00",
"book_date": "2023-09-24T00:00:00.000+07:00",
"account_id": 266,
"account_name": "Test",
"contact_id": 0,
"sale_order_amount": 455425,
"due_date": "2023-09-24T00:00:00.000+07:00",
"sale_order_type": "Bán mới",
"revenue_status_id": 1,
"revenue_status": "Bản nháp",
"recorded_sale": 0,
"status": "Chưa thực hiện",
"description": "",
"is_use_currency": false,
"currency_type": "VND",
"exchange_rate": 1,
"total_receipted_amount": 0,
"balance_receipt_amount": 455425,
"is_invoiced": false,
"invoiced_amount": 0,
"un_invoiced_amount": 455425,
"un_subcrible": false,
"billing_country": "",
"billing_province": "",
"billing_district": "",
"billing_ward": "",
"billing_address": "Hcm",
"phone": "xxx",
"shipping_country": "",
"shipping_province": "",
"shipping_district": "",
"shipping_ward": "",
"shipping_street": "",
"shipping_address": "Hcm",
"organization_unit_id": 1,
"organization_unit_name": "xxx",
"created_by": "Developer",
"modified_by": "Developer",
"is_public": false,
"is_deleted": false,
"total_summary": 455425,
"tax_summary": 33735.19,
"discount_summary": 0,
"to_currency_summary": 421689.85000000003,
"billing_account_id": 266,
"billing_account": "Test",
"is_sent_bill": false,
"shipping_contact_name": "Test",
"pay_status": "Chưa thanh toán",
"shipping_amount_summary": 0,
"sale_order_process_cost": 0,
"amount_summary": 0,
"liquidate_amount": 455425,
"to_currency_summary_oc": 421689.85000000003,
"discount_summary_oc": 0,
"tax_summary_oc": 33735.19,
"total_summary_oc": 455425,
"liquidate_amount_oc": 455425,
"sale_order_amount_oc": 455425,
"total_receipted_amount_oc": 0,
"balance_receipt_amount_oc": 455425,
"invoiced_amount_oc": 0,
"async_id": "a3875eaf-9cf1-45c8-bb50-91b0e51c362e",
"sale_order_product_mappings": [
{
"product_id": 15814,
"unit": "Thùng",
"price": 26454.63,
"amount": 15,
"to_currency": 396819.45,
"discount": 0,
"tax": 31745.56,
"total": 428565.01,
"product_name": "TP00689",
"product_code": "TP00689",
"tax_percent": "0.08%",
"discount_percent": 0,
"shipping_amount": 0,
"usage_unit": "Thùng",
"ratio": 1,
"usage_unit_price": 26454.63,
"usage_unit_amount": 15,
"operator": "Nhân",
"stock_id": "1",
"stock_name": "KHO TP",
"description": "xxx",
"to_currency_oc": 396819.45,
"discount_oc": 0,
"tax_oc": 31745.56,
"total_oc": 428565.01,
"is_discount_directly": false,
"price_after_tax": 0,
"sort_order": 1,
"async_id": "c2698812-4d35-4d75-829b-1c84b18a0490"
}
]
}
]
Học thêm kiến thức tại: AMIS Blog | MISA Academy