Commit 0fad9fec authored by hangjun83's avatar hangjun83

zkh

parent 6d62f81c
......@@ -180,6 +180,8 @@ class ZhenkhApiService extends PlatformAbstractService
{
try{
if($this->checkPlatformStatus()){
SimpleLogs::writeLog('zkh api params => '.$orderId,__CLASS__.':sendDeliveryOrder');
$response = $this->clientRequest('get',
$this->getPlatformApiUrl().'/openPoApi/v1/purchaseOrder/getDeliveryOrderPart?purchaseOrderId='.$orderId,
[
......@@ -208,6 +210,7 @@ class ZhenkhApiService extends PlatformAbstractService
{
try{
if($this->checkPlatformStatus()){
SimpleLogs::writeLog('zkh api params => '.$deliveryOrder,__CLASS__.':ackDeliveryOrder');
$response = $this->getPostClient($this->getPlatformApiUrl().'/openPoApi/v1/purchaseOrder/ackDeliveryOrderPart',
$deliveryOrder,null,
[
......@@ -235,12 +238,15 @@ class ZhenkhApiService extends PlatformAbstractService
}
try{
if($this->checkPlatformStatus()){
$params = [
'customPrice' => $params['price'],
'priceUnit' => $params['price_unit'],
'zkhSku' => $params['sku']
];
SimpleLogs::writeLog('zkh api params => '.$params,__CLASS__.':updateReportProductPrice');
$response = $this->getPostClient($this->getPlatformApiUrl().'/openApi/v1/common/report/price',
[[
'customPrice' => $params['price'],
'priceUnit' => $params['price_unit'],
'zkhSku' => $params['sku']
]],null,
[$params],null,
[
'honeycombToken' => $token,
'Content-Type' => 'application/json;charset=UTF-8'
......@@ -267,13 +273,16 @@ class ZhenkhApiService extends PlatformAbstractService
}
try{
if($this->checkPlatformStatus()){
$params = [
'supplierWarehouseName' => $params['warehouse'],
'warehouseNameList' => $params['address'],
'qty' => intval($params['qty']),
'zkhSku' => $params['sku']
];
SimpleLogs::writeLog('zkh api params => '.$params,__CLASS__.':updateReportProductStock');
$response = $this->getPostClient($this->getPlatformApiUrl().'/openApi/v2/common/report/stock',
[[
'supplierWarehouseName' => $params['warehouse'],
'warehouseNameList' => $params['address'],
'qty' => intval($params['qty']),
'zkhSku' => $params['sku']
]],null,
[$params],null,
[
'honeycombToken' => $token,
'Content-Type' => 'application/json;charset=UTF-8'
......@@ -330,6 +339,8 @@ class ZhenkhApiService extends PlatformAbstractService
if($this->checkPlatformStatus()){
$params = [];
$params['purchaseOrderId'] = $orderNo;
SimpleLogs::writeLog('zkh api params => '.$params,__CLASS__.':orderConfirm');
$response = $this->getPostClient($this->getPlatformApiUrl().'/openPoApi/v1/purchaseOrder/confirm',
$params,null,
[
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment