Hi,
I want to create CurrentInvoice,this is my code. there is only the product number in the CurrentInvoiceLine,But why could not add the product in CurrentInvoiceLine, thanks
$cino = array("Number" => $number);
$newCurrentInvoiceHandle = $client->CurrentInvoice_Create(
array(
'debtorHandle' => $cino
)
)->CurrentInvoice_CreateResult;
$client->CurrentInvoice_SetOtherReference(
array(
'currentInvoiceHandle' => $newCurrentInvoiceHandle,
'value' => $order_number
)
);
$newCurrentInvoiceLineHandle = $client->CurrentInvoiceLine_Create(
array(
'invoiceHandle' => $newCurrentInvoiceHandle
)
)->CurrentInvoiceLine_CreateResult;
$productHandles = $client->product_GetAll()->Product_GetAllResult->ProductHandle;
$firstProduct = $productHandles[0];
$client->CurrentInvoiceLine_SetProduct(
array(
'currentInvoiceLineHandle' => $newCurrentInvoiceLineHandle,
'valueHandle' => $firstProduct
)
);

