Commit a74ab47d authored by xiangzj's avatar xiangzj

创意酒接口调整

parent 42f7f494
......@@ -35,7 +35,7 @@
</view>
<view class="text-block">
<text class="middle-date middle-date-select">收货方名称</text>
<text class="middle-date-des middle-date-des-select">{{orderDetail.INFO.ZZFLD00008T}}</text>
<text class="middle-date-des middle-date-des-select">{{orderDetail.INFO.ZZFLD00008T_DSCR}}</text>
</view>
<view class="text-block">
<text class="middle-date middle-date-select">联系人</text>
......@@ -51,7 +51,7 @@
</view>
<view class="text-block">
<text class="middle-date middle-date-select">经销商名称</text>
<text class="middle-date-des middle-date-des-select">{{orderDetail.INFO.GRPNAME}}</text>
<text class="middle-date-des middle-date-des-select">{{orderDetail.INFO.CUST_NAME}}</text>
</view>
<view class="text-block text-block-last">
<text class="middle-date middle-date-select">外箱喷码内容</text>
......@@ -72,7 +72,8 @@
apiGetCategory,
apiGetCategoryDetail,
apiGetCategoryDetailById,
apiSaveCustom
apiSaveCustom,
apiSubmitCustom
} from '@/servers/diyWine.js'
import md5 from "@/uview-ui/libs/function/md5.js";
......@@ -278,20 +279,56 @@
"Sign": md5.hex_md5(`Action=guanying.adapter.works.savecustom&Info=${JSON.stringify(this.activeTemplateItemDetail)}&OutsideGoodsID=${this.orderDetail.ITEM[0].ORDERED_PROD}&TemplateID=${this.activeTemplateItem.TemplateID}&SecretKey=8B72E5CB394E3CABB56DC8E04AC4DE7F`)
}
const res = await apiSaveCustom(params)
if(res.Status !== 'Success'){
uni.showToast({
title: res.ErrMsg,
duration: 2000,
icon: 'none'
});
return
}
const goodsInfo = {
"OutsideGoodsID": this.orderDetail.ITEM[0].ORDERED_PROD,
"GoodsCount": this.orderDetail.ITEM[0].QUANTITY,
"GoodsName": this.orderDetail.ITEM[0].DESCRIPTION,
"PackingUnit": this.orderDetail.ITEM[0].ZZFLD00002T,
"OutsideWorksID": res.Data.WorksID,
}
const params2 = {
'Action': "guanying.adapter.crmorder.down",
'Address': this.orderDetail.INFO.ZZFLD00002N,
'BoxCode': this.orderDetail.INFO.ZZFLD000098,
// 'CallbackUrlList': JSON.stringify({WorksbackUrl:''}),
'City': this.orderDetail.INFO.ZZFLD000003_TEXT,
// County: this.orderDetail.INFO.,
'MobileNumber': this.orderDetail.INFO.ZZFLD00002M,
// OrderAmount: "",
'OrderGoods': JSON.stringify(goodsInfo),
'OutsideCoreOrderID': this.orderDetail.INFO.OBJECT_ID,
'Province': this.orderDetail.INFO.ZZFLD000002_TEXT,
'RealName': this.orderDetail.INFO.ZZFLD00002L,
"SecretKey": "8B72E5CB394E3CABB56DC8E04AC4DE7F",
'StoreCompanyName': this.orderDetail.INFO.CUST_NAME,
'StoreName': this.orderDetail.INFO.CUST_NAME,
"Sign": md5.hex_md5(`Action=guanying.adapter.crmorder.down&Address=${this.orderDetail.INFO.ZZFLD00002N}&BoxCode=${this.orderDetail.INFO.ZZFLD000098}&City=${this.orderDetail.INFO.ZZFLD000003_TEXT}&MobileNumber=${this.orderDetail.INFO.ZZFLD00002M}&OrderGoods=${JSON.stringify(goodsInfo)}&OutsideCoreOrderID=${this.orderDetail.INFO.OBJECT_ID}&Province=${this.orderDetail.INFO.ZZFLD000002_TEXT}&RealName=${this.orderDetail.INFO.ZZFLD00002L}&StoreCompanyName=${this.orderDetail.INFO.CUST_NAME}&StoreName=${this.orderDetail.INFO.CUST_NAME}&SecretKey=8B72E5CB394E3CABB56DC8E04AC4DE7F`)
}
const res2 = await apiSubmitCustom(params2)
if(res2.Status !== 'Success'){
uni.showToast({
title: res2.ErrMsg,
duration: 2000,
icon: 'none'
});
return
}
this.isEdit = false
this.goodsBottleImage =
res
.Data.ShowImagePath
// const res2 = {
// Data: {
// "WorksID": "1512",
// "ShowImagePath": "http://att.c0331.dev.guanyingyun.com/attachment/works/works/2020/08/12/15972225215710.png",
// "FinalImagePath": "http://att.c0331.dev.guanyingyun.com/attachment/works/works/2020/08/12/15972225215291.png"
// },
// ErrCode: "0",
// ErrMsg: "",
// Status: "Success"
// }
this.goodsBottleImage = res.Data.ShowImagePath
uni.showToast({
title: `制单成功,平台唯一定制服务单编号:(`+res2.Data.CoreOrderID+`),平台唯一定制服务单编号:(`+res2.Data.WorksID+`)`,
duration: 2000,
icon: 'none'
});
}
}
}
......
......@@ -43,17 +43,17 @@
<view class="block-detal">
<view class="block-detal-item">
<text class="detal-item-label">品牌</text>
<text class="detal-item-value">{{ele.brandBqTextView}}</text>
<text class="detal-item-value">{{ele.brandTextView}}</text>
</view>
<view class="block-detal-item">
<text class="detal-item-label">产品</text>
<text class="detal-item-value">{{ele.productDesc}}</text>
<text class="detal-item-value detal-item-value3">{{ele.productDesc}}</text>
</view>
<view class="block-detal-item">
<text class="detal-item-label">未发货件数</text>
<text class="detal-item-value">{{ele.undeliveredQuantity}}</text>
</view>
<view class="block-detal-item">
<!-- <view class="block-detal-item">
<text class="detal-item-label">传统当月计划量</text>
<text class="detal-item-value">{{ele.applyNum}}</text>
</view>
......@@ -64,7 +64,7 @@
<view class="block-detal-item">
<text class="detal-item-label">传统当年剩余量</text>
<text class="detal-item-value">{{ele.annualLeftQty}}</text>
</view>
</view> -->
<view class="block-detal-item block-detal-item-last">
<text class="detal-item-label">本次要货件数</text>
<text class="detal-item-value">{{ele.wantQuantity}}</text>
......@@ -406,7 +406,7 @@
font-size: 24rpx;
width: 200%;
flex: 2;
text-align: left;
text-align: right;
}
.receive-info {
position: relative;
......
......@@ -38,4 +38,13 @@ export async function apiGetCategoryDetailById(params) {
export async function apiSaveCustom(params) {
const res = await apiHelper.post('/adapter/v2/views', params)
return res
}
/**
* 提交定制图
* @param name 账户名
* @returns {Promise<AxiosResponse<T>>}
*/
export async function apiSubmitCustom(params) {
const res = await apiHelper.post('/adapter/v1/views', params)
return res
}
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