Hi,
When creating invoices through the Rest API, the original Sales Order is not getting marked Completed and the per_billed on both the Sales Order and the Sales Order Items isn’t changing from 0%.
I’ve looked through all similar topics I could find but haven’t come up with a solution.
Here’s my post when creating the invoice:
{
"title":"INV-2544",
"customer":"customer name",
"sales_order":"SO-00656",
"po_no":"PO1234",
"docstatus":1,
"posting_date":"2019-01-01",
"set_posting_time":true,
"due_date":"2019-01-31T00:00:00",
"payment_terms_template":"Net 30",
"items":[
{
"name":"5a0827916a",
"qty":6.0,
"delivered_qty":6.0,
"item_code":"ITEM1234",
"item_name":"My new item",
"rate":42.5,
"sales_order":"SO-00656",
"uom":"Unit",
"warehouse":"Finished Goods - Company",
"description":"My new item",
"conversion_factor":1.0
}
],
"taxes":[
{
"charge_type":"Actual",
"account_head":"Cost of Goods Sold - Company",
"cost_center":"Main - Company",
"description":"Free Shipping",
"tax_amount":0.0
}
]
}