FIX wrong paramters name in the usecreditnote method
Rename 'creditnoteid' with 'discountid' in the URI Rename 'creditId' with 'discountid' in the method
This commit is contained in:
parent
fbabacf19a
commit
9a1c684870
@ -701,7 +701,7 @@ class Invoices extends DolibarrApi
|
|||||||
* @param int $id Id of invoice
|
* @param int $id Id of invoice
|
||||||
* @param int $discountid Id of a discount coming from a credit note
|
* @param int $discountid Id of a discount coming from a credit note
|
||||||
*
|
*
|
||||||
* @url POST {id}/usecreditnote/{creditnoteid}
|
* @url POST {id}/usecreditnote/{discountid}
|
||||||
*
|
*
|
||||||
* @return int
|
* @return int
|
||||||
* @throws 400
|
* @throws 400
|
||||||
@ -719,7 +719,7 @@ class Invoices extends DolibarrApi
|
|||||||
if(empty($id)) {
|
if(empty($id)) {
|
||||||
throw new RestException(400, 'Invoice ID is mandatory');
|
throw new RestException(400, 'Invoice ID is mandatory');
|
||||||
}
|
}
|
||||||
if(empty($creditId)) {
|
if(empty($discountid)) {
|
||||||
throw new RestException(400, 'Credit ID is mandatory');
|
throw new RestException(400, 'Credit ID is mandatory');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user