<view><text class="red">*</text>申请退货需将原设备寄回</view> | <view><text class="red">*</text>申请退货需将原设备寄回</view> | ||||
<view>寄回信息:</view> | <view>寄回信息:</view> | ||||
<view>收件人:ETC售后 联系电话:18798751224(此电话仅用于ETC售后收取快递,如需咨询业务请致电4008008787)</view> | <view>收件人:ETC售后 联系电话:18798751224(此电话仅用于ETC售后收取快递,如需咨询业务请致电4008008787)</view> | ||||
<view>寄回地址:贵州省贵阳市云岩区普天广场11楼</view> | |||||
<view>寄回地址:{{config.address}}</view> | |||||
</view> | </view> | ||||
<view class="subBtn"> | <view class="subBtn"> | ||||
<submit-button :title="config ? config.submitName : '提交'" form-type="submit" | <submit-button :title="config ? config.submitName : '提交'" form-type="submit" |
"enablePullDownRefresh": false | "enablePullDownRefresh": false | ||||
} | } | ||||
}, | }, | ||||
{ | |||||
"path": "pin-code-deblocking/select-car", | |||||
"style": { | |||||
"navigationBarTitleText": "卡pin码解锁", | |||||
"enablePullDownRefresh": false | |||||
} | |||||
}, | |||||
{ | { | ||||
"path": "pin-code-deblocking/pin-code-confirm", | "path": "pin-code-deblocking/pin-code-confirm", | ||||
"style": { | "style": { | ||||
"enablePullDownRefresh": false | "enablePullDownRefresh": false | ||||
} | } | ||||
}, | }, | ||||
{ | |||||
"path": "to-bookkeeping-card/select-car", | |||||
"style": { | |||||
"navigationBarTitleText": "储值卡转记账卡-选择车辆", | |||||
"enablePullDownRefresh": false | |||||
} | |||||
}, | |||||
{ | { | ||||
"path": "to-bookkeeping-card/confirm", | "path": "to-bookkeeping-card/confirm", | ||||
"style": { | "style": { |
import { deviceType } from "@/utils/network/difference"; | import { deviceType } from "@/utils/network/difference"; | ||||
const state = reactive({ | const state = reactive({ | ||||
list: [], | list: [], | ||||
type: "",//1 OBU重新激活 2 卡签注销 3 更换设备 4卡签续期 5挂失解挂 6增补设备 | |||||
type: "",//1 OBU重新激活 2 卡签注销 3 更换设备 4卡签续期 5挂失解挂 6增补设备 | |||||
// 30 储值卡转记账卡 31卡pin码解锁 | |||||
}); | }); | ||||
onLoad((options) => { | onLoad((options) => { | ||||
console.log("options", options) | console.log("options", options) | ||||
uni.setNavigationBarTitle({ | uni.setNavigationBarTitle({ | ||||
title: '增补设备-选择车辆' | title: '增补设备-选择车辆' | ||||
}); | }); | ||||
}else if (options.type == "30") { | |||||
uni.setNavigationBarTitle({ | |||||
title: '储值卡转记账卡-选择车辆' | |||||
}); | |||||
}else if (options.type == "31") { | |||||
uni.setNavigationBarTitle({ | |||||
title: '卡pin码解锁-选择车辆' | |||||
}); | |||||
} | } | ||||
quanCheckActionTrue().then((item : any) => { | quanCheckActionTrue().then((item : any) => { | ||||
state.list = item.data; | state.list = item.data; | ||||
console.log(item); | console.log(item); | ||||
if (item.deviceType == deviceType) { | if (item.deviceType == deviceType) { | ||||
// OBU重新激活跳转 | // OBU重新激活跳转 | ||||
const params = encodeURIComponent(JSON.stringify(item)) | const params = encodeURIComponent(JSON.stringify(item)) | ||||
if(state.type=="5"){ | |||||
} | |||||
jump(state.type, params) | jump(state.type, params) | ||||
} else { | } else { | ||||
if (state.type == "1") { | if (state.type == "1") { | ||||
navTo(`/subpackage/after-sale/card-loss-reporting/cardloss-confirm?id=${item.id}`) | navTo(`/subpackage/after-sale/card-loss-reporting/cardloss-confirm?id=${item.id}`) | ||||
}else if (state.type == "6") { | }else if (state.type == "6") { | ||||
navTo(`/subpackage/after-sale/additional-equipment/additional-equipment-confirm?id=${item.id}`) | navTo(`/subpackage/after-sale/additional-equipment/additional-equipment-confirm?id=${item.id}`) | ||||
}else if (state.type == "30") { | |||||
navTo(`/subpackage/after-sale/to-bookkeeping-card/confirm?id=${item.id}`) | |||||
}else if (state.type == "31") { | |||||
navTo(`/subpackage/after-sale/pin-code-deblocking/pin-code-confirm?id=${item.id}`); | |||||
} | } | ||||
} | } | ||||
import { stringToJson } from "@/utils/network/encryption"; | import { stringToJson } from "@/utils/network/encryption"; | ||||
import { request } from "@/utils/network/request"; | import { request } from "@/utils/network/request"; | ||||
import { searchVehicleInfo } from "@/utils/network/api.js"; | |||||
import { searchVehicleInfo,getMailingAddressApi } from "@/utils/network/api.js"; | |||||
// 154接口获取车辆信息 | // 154接口获取车辆信息 | ||||
export const searchVehicleInfoQuery = (vehicleId,random) => { | export const searchVehicleInfoQuery = (vehicleId,random) => { | ||||
const options = { | const options = { | ||||
}).catch((error) => { | }).catch((error) => { | ||||
reject(error); | reject(error); | ||||
}); | }); | ||||
} | |||||
export const getMailingAddress = (orderId) => { | |||||
var data = { | |||||
orderId: orderId, | |||||
}; | |||||
const options = { | |||||
type: 2, | |||||
data: data, | |||||
method: "POST", | |||||
showLoading: true, | |||||
}; | |||||
return new Promise(async (resolve, reject) => { | |||||
const res = await request(getMailingAddressApi, options); | |||||
const data = stringToJson(res.bizContent).address; | |||||
console.log("获取邮寄地址", data) | |||||
resolve(data); | |||||
}).catch((error) => { | |||||
reject(error); | |||||
}); | |||||
} | } |
<template> | |||||
<view class="selectCar-box"> | |||||
<view v-if="state.list.length > 0" @click="choose(i, item)" class="item" v-for="(item, i) in state.list" | |||||
:key="i"> | |||||
<view class="iten-left"> | |||||
<image :src="`${$imgUrl}che.png`" mode="aspectFill"></image> | |||||
<text>{{ item.vehiclePlate }}</text> | |||||
</view> | |||||
<view class="choose-item"> | |||||
<view class="active" v-if="flag == i"> </view> | |||||
</view> | |||||
</view> | |||||
<view v-else class="flex"> 暂无车辆订单信息 </view> | |||||
</view> | |||||
</template> | |||||
<script lang="ts" setup> | |||||
import { reactive, ref } from "vue"; | |||||
import { navTo } from "@/utils/utils"; | |||||
import { onLoad, onShow } from "@dcloudio/uni-app"; | |||||
import { orderList } from "@/utils/network/api.js"; | |||||
import { request } from "@/utils/network/request.js"; | |||||
import { msg } from "@/utils/utils"; | |||||
import { getItem, StorageKeys, setItem } from "@/utils/storage"; | |||||
import { stringToJson } from "@/utils/network/encryption"; | |||||
const state = reactive({ | |||||
list: [], | |||||
}); | |||||
onLoad(() => { | |||||
quanCheckActionTrue().then((item : any) => { | |||||
state.list = item.data; | |||||
console.log(item); | |||||
}); | |||||
}); | |||||
const quanCheckActionTrue = () => { | |||||
let source = "" | |||||
// #ifdef MP-ALIPAY | |||||
source = "ALI" | |||||
// #endif | |||||
// #ifdef MP-WEIXIN | |||||
source = "WECHAT" | |||||
// #endif | |||||
var data = { | |||||
opId: getItem(StorageKeys.OpenId), | |||||
source: source, | |||||
tabIndex: "0", | |||||
orderStep: "11", | |||||
isValueCard: "", | |||||
orderStatus: "1", | |||||
isAfter: true, | |||||
}; | |||||
const options = { | |||||
type: 2, | |||||
data: data, | |||||
method: "POST", | |||||
showLoading: true, | |||||
}; | |||||
return new Promise(async (resolve, reject) => { | |||||
const res = await request(orderList, options); | |||||
const data = stringToJson(res.bizContent); | |||||
resolve(data); | |||||
}).catch((error) => { | |||||
reject(error); | |||||
}); | |||||
}; | |||||
const flag = ref("0"); | |||||
const choose = (i, item) => { | |||||
console.log(item.cardId); | |||||
navTo( | |||||
`/subpackage/after-sale/pin-code-deblocking/pin-code-confirm?id=${item.id}` | |||||
); | |||||
}; | |||||
</script> | |||||
<style> | |||||
page { | |||||
width: 100%; | |||||
height: 100%; | |||||
background-color: #eef7f7; | |||||
} | |||||
</style> | |||||
<style lang="scss" scoped> | |||||
.flex { | |||||
display: flex; | |||||
justify-content: center; | |||||
} | |||||
.selectCar-box { | |||||
// width: 100%; | |||||
height: 100%; | |||||
padding: 30rpx; | |||||
.item { | |||||
padding: 20rpx; | |||||
display: flex; | |||||
justify-content: space-between; | |||||
align-items: center; | |||||
height: 130rpx; | |||||
background: #ffffff; | |||||
box-shadow: 0rpx 2rpx 6rpx 0rpx rgba(223, 223, 223, 0.8); | |||||
border-radius: 20rpx; | |||||
margin-bottom: 30rpx; | |||||
.iten-left { | |||||
display: flex; | |||||
align-items: center; | |||||
image { | |||||
width: 150rpx; | |||||
height: 90rpx; | |||||
} | |||||
text { | |||||
margin-left: 20rpx; | |||||
font-size: 32rpx; | |||||
font-family: Noto Sans S Chinese; | |||||
font-weight: 400; | |||||
color: #333333; | |||||
} | |||||
} | |||||
.choose-item { | |||||
width: 44rpx; | |||||
height: 44rpx; | |||||
background: #ffffff; | |||||
border: 2rpx solid #00b38b; | |||||
border-radius: 50%; | |||||
margin-right: 20rpx; | |||||
display: flex; | |||||
justify-content: center; | |||||
align-items: center; | |||||
box-sizing: content-box; | |||||
} | |||||
.active { | |||||
width: 34rpx; | |||||
height: 34rpx; | |||||
background: #00b38b; | |||||
border-radius: 50%; | |||||
} | |||||
} | |||||
} | |||||
</style> |
<!-- <view><text>是否逾期:</text><text>{{state.params['over']?'逾期':"未逾期"}}</text></view> --> | <!-- <view><text>是否逾期:</text><text>{{state.params['over']?'逾期':"未逾期"}}</text></view> --> | ||||
<view><text>状态:</text><text>{{state.params['statusC']}}</text></view> | <view><text>状态:</text><text>{{state.params['statusC']}}</text></view> | ||||
<view v-if="state.params['reason']"><text>原因:</text><text>{{state.params['reason']}}</text></view> | <view v-if="state.params['reason']"><text>原因:</text><text>{{state.params['reason']}}</text></view> | ||||
<view><text>申请时间:</text><text>{{state.params['insertTime']}}</text> | |||||
<view><text>申请时间:</text><text>{{state.params['insertTime']}}</text></view> | |||||
<view v-if="state.params['address']"><text>邮寄地址:</text><text>{{state.params['address']}}</text> | |||||
</view> | </view> | ||||
</view> | </view> | ||||
</view> | </view> |
addressQuery, | addressQuery, | ||||
changeCardInfo, | changeCardInfo, | ||||
changeCardQueryCancle, | changeCardQueryCancle, | ||||
getMailingAddressApi | |||||
// getMailingAddressApi | |||||
} from "@/utils/network/api.js"; | } from "@/utils/network/api.js"; | ||||
import { | import { | ||||
stringToJson | stringToJson | ||||
getItem, | getItem, | ||||
StorageKeys | StorageKeys | ||||
} from "@/utils/storage"; | } from "@/utils/storage"; | ||||
import { | |||||
getMailingAddress | |||||
} from "@/subpackage/after-sale/js/publicRequest"; | |||||
import { | import { | ||||
wechatPayConfigId, | wechatPayConfigId, | ||||
console.log("radiolist1.value", radiolist1.value) | console.log("radiolist1.value", radiolist1.value) | ||||
getexpresslist(); | getexpresslist(); | ||||
getAddressList(); | getAddressList(); | ||||
getMailingAddress(option.orderId) | |||||
getMailingAddress(option.orderId).then((address) => { | |||||
console.log("address",address) | |||||
form.goodsAddress=address | |||||
}) | |||||
}); | }); | ||||
const getMailingAddress = (orderId) => { | |||||
var data = { | |||||
orderId: orderId, | |||||
}; | |||||
const options = { | |||||
type: 2, | |||||
data: data, | |||||
method: "POST", | |||||
showLoading: true, | |||||
}; | |||||
request(getMailingAddressApi, options).then((res) => { | |||||
const data = stringToJson(res.bizContent); | |||||
form.goodsAddress=data.address | |||||
console.log("获取邮寄地址", data) | |||||
}); | |||||
}; | |||||
const goToAddAddress = () => { | const goToAddAddress = () => { | ||||
uni.navigateTo({ | uni.navigateTo({ | ||||
url: "/subpackage/orders/addAddress", | url: "/subpackage/orders/addAddress", | ||||
applyRes: form.applyRes, | applyRes: form.applyRes, | ||||
cardExpire: params.cardExpire, | cardExpire: params.cardExpire, | ||||
obuExpire: params.obuExpire, | obuExpire: params.obuExpire, | ||||
goodsAddress:"" | |||||
goodsAddress:form.goodsAddress | |||||
}; | }; | ||||
const options = { | const options = { | ||||
type: 2, | type: 2, |
<template> | |||||
<view class="selectCar-box"> | |||||
<view v-if="state.list&&state.list.length>0" @click="choose(i,item)" class="item" v-for="(item,i) in state.list" | |||||
:key="i"> | |||||
<view class="iten-left"> | |||||
<image :src="`${$imgUrl}che.png`" mode="aspectFill"></image> | |||||
<text>{{item.vehiclePlate}}</text> | |||||
</view> | |||||
<view class="choose-item"> | |||||
<view class="active" v-if="flag==i"> | |||||
</view> | |||||
</view> | |||||
</view> | |||||
<view v-else> | |||||
<empty title='暂无找到相关车辆信息' /> | |||||
</view> | |||||
</view> | |||||
</template> | |||||
<script lang="ts" setup> | |||||
import empty from "@/components/empty/empty.vue"; | |||||
import { | |||||
reactive, | |||||
ref | |||||
} from "vue" | |||||
import { | |||||
navTo | |||||
} from "@/utils/utils" | |||||
import { | |||||
onLoad, | |||||
} from "@dcloudio/uni-app"; | |||||
import { | |||||
orderList | |||||
} from "@/utils/network/api.js"; | |||||
import { | |||||
request | |||||
} from "@/utils/network/request.js"; | |||||
import { | |||||
getItem, | |||||
StorageKeys, | |||||
} from "@/utils/storage"; | |||||
import { | |||||
stringToJson | |||||
} from "@/utils/network/encryption"; | |||||
const state = reactive({ | |||||
list: [] //车辆list | |||||
}); | |||||
const flag = ref('0') //默认选择0 | |||||
onLoad(() => { | |||||
quanCheckActionTrue().then((item: any) => { | |||||
state.list = item.data | |||||
}) | |||||
}); | |||||
const quanCheckActionTrue = () => { | |||||
let source = "" | |||||
// #ifdef MP-ALIPAY | |||||
source ="ALI" | |||||
// #endif | |||||
// #ifdef MP-WEIXIN | |||||
source ="WECHAT" | |||||
// #endif | |||||
var data = { | |||||
opId: getItem(StorageKeys.OpenId), | |||||
source: source, //渠道为小程序 | |||||
tabIndex: '0', //0全部 | |||||
orderStep: '11', //11 为已完成” | |||||
isValueCard: '1', | |||||
title:'1', | |||||
isAfter: true, | |||||
}; | |||||
const options = { | |||||
type: 2, | |||||
data: data, | |||||
method: "POST", | |||||
showLoading: true, | |||||
}; | |||||
return new Promise(async (resolve, reject) => { | |||||
const res = await request(orderList, options); | |||||
const data = stringToJson(res.bizContent); | |||||
resolve(data); | |||||
}).catch((error) => { | |||||
reject(error); | |||||
}); | |||||
} | |||||
const choose = (i, item) => { | |||||
flag.value = i | |||||
navTo(`/subpackage/after-sale/to-bookkeeping-card/confirm?id=${item.id}`) | |||||
} | |||||
</script> | |||||
<style> | |||||
page { | |||||
width: 100%; | |||||
height: 100%; | |||||
background-color: #EEF7F7; | |||||
} | |||||
</style> | |||||
<style lang="scss" scoped> | |||||
.flex { | |||||
display: flex; | |||||
justify-content: center; | |||||
} | |||||
.selectCar-box { | |||||
// width: 100%; | |||||
height: 100%; | |||||
padding: 30rpx; | |||||
.item { | |||||
padding: 20rpx; | |||||
display: flex; | |||||
justify-content: space-between; | |||||
align-items: center; | |||||
height: 130rpx; | |||||
background: #FFFFFF; | |||||
box-shadow: 0rpx 2rpx 6rpx 0rpx rgba(223, 223, 223, 0.8); | |||||
border-radius: 20rpx; | |||||
margin-bottom: 30rpx; | |||||
.iten-left { | |||||
display: flex; | |||||
align-items: center; | |||||
image { | |||||
width: 150rpx; | |||||
height: 90rpx; | |||||
} | |||||
text { | |||||
margin-left: 20rpx; | |||||
font-size: 32rpx; | |||||
font-family: Noto Sans S Chinese; | |||||
font-weight: 400; | |||||
color: #333333; | |||||
} | |||||
} | |||||
.choose-item { | |||||
width: 44rpx; | |||||
height: 44rpx; | |||||
background: #FFFFFF; | |||||
border: 2rpx solid #00B38B; | |||||
border-radius: 50%; | |||||
margin-right: 20rpx; | |||||
display: flex; | |||||
justify-content: center; | |||||
align-items: center; | |||||
box-sizing: content-box; | |||||
} | |||||
.active { | |||||
width: 34rpx; | |||||
height: 34rpx; | |||||
background: #00B38B; | |||||
border-radius: 50%; | |||||
} | |||||
} | |||||
} | |||||
</style> |
<template> | <template> | ||||
<view class="oderPage"> | <view class="oderPage"> | ||||
<u-form :model="form" ref="myForm" :error-type="errorType"> | |||||
<u-form :model="form" :error-type="errorType"> | |||||
<view class="from"> | <view class="from"> | ||||
<u-form-item prop="applyType"> | <u-form-item prop="applyType"> | ||||
<view><text class="red">*</text>设备更换需将原设备寄回</view> | <view><text class="red">*</text>设备更换需将原设备寄回</view> | ||||
<view>寄回信息:</view> | <view>寄回信息:</view> | ||||
<view>收件人:ETC售后 联系电话:18798751224(此电话仅用于ETC售后收取快递,如需咨询业务请致电4008008787)</view> | <view>收件人:ETC售后 联系电话:18798751224(此电话仅用于ETC售后收取快递,如需咨询业务请致电4008008787)</view> | ||||
<view>寄回地址:贵州省贵阳市云岩区普天广场11楼</view> | |||||
<view>寄回地址:{{state.address}}</view> | |||||
</view> | </view> | ||||
<button class="submit" @click="submit">下一步</button> | <button class="submit" @click="submit">下一步</button> | ||||
<!-- 自提网点弹窗 --> | <!-- 自提网点弹窗 --> | ||||
import { | import { | ||||
onLoad | onLoad | ||||
} from "@dcloudio/uni-app"; | } from "@dcloudio/uni-app"; | ||||
import { | |||||
getMailingAddress | |||||
} from "@/subpackage/orders/js/publicRequest"; | |||||
// 表单数据 | // 表单数据 | ||||
const form = reactive({ | const form = reactive({ | ||||
orderId: '', | orderId: '', | ||||
applyType: '', | applyType: '', | ||||
operation: '' | operation: '' | ||||
}) | |||||
const state = reactive({ | |||||
address: '', | |||||
}) | }) | ||||
//接受通过该id查询订单详情 | //接受通过该id查询订单详情 | ||||
const oldId = ref('') | const oldId = ref('') | ||||
// 设置验证规则 | // 设置验证规则 | ||||
const myForm = ref(null) | const myForm = ref(null) | ||||
onReady(() => { | onReady(() => { | ||||
myForm.value.setRules(rules) | |||||
// myForm.value.setRules(rules) | |||||
}) | }) | ||||
let show = ref(false) | let show = ref(false) | ||||
const submit = () => { | const submit = () => { | ||||
if (form.applyType) { | if (form.applyType) { | ||||
console.log('验证通过', form); | console.log('验证通过', form); | ||||
navTo(`/subpackage/orders/apply-ex-goods?orderId=${oldId.value}`) //测试用 | |||||
navTo(`/subpackage/orders/apply-ex-goods?orderId=${oldId.value}&address=${state.address}`) //测试用 | |||||
} else { | } else { | ||||
uni.showToast({ | uni.showToast({ | ||||
title: "请选择申请类型", | title: "请选择申请类型", | ||||
form.orderId = option.orderId | form.orderId = option.orderId | ||||
oldId.value = option.id | oldId.value = option.id | ||||
console.log(form); | console.log(form); | ||||
getMailingAddress(option.orderId).then((address) => { | |||||
console.log("address",address) | |||||
state.address=address | |||||
}) | |||||
}); | }); | ||||
</script> | </script> | ||||
}; | }; | ||||
const state = reactive({ | const state = reactive({ | ||||
address:"", | |||||
//订单信息 | //订单信息 | ||||
orderInfo: {} as any, | orderInfo: {} as any, | ||||
//网点信息 | //网点信息 | ||||
address: e.address, | address: e.address, | ||||
postalCode: e.postalCode, | postalCode: e.postalCode, | ||||
opId: getItem(StorageKeys.OpenId), | opId: getItem(StorageKeys.OpenId), | ||||
goodsAddress:state.address | |||||
}, | }, | ||||
method: "POST", | method: "POST", | ||||
showLoading: true, | showLoading: true, | ||||
getOrderDetails(option.orderId); | getOrderDetails(option.orderId); | ||||
getLogisticsList(); | getLogisticsList(); | ||||
getOutletList(); | getOutletList(); | ||||
state.address=option.address | |||||
}); | }); | ||||
</script> | </script> | ||||
import { getLogistics, orderReturn, outletList } from "@/utils/network/api"; | import { getLogistics, orderReturn, outletList } from "@/utils/network/api"; | ||||
import { stringToJson } from "@/utils/network/encryption"; | import { stringToJson } from "@/utils/network/encryption"; | ||||
import { getItem, StorageKeys } from "@/utils/storage"; | import { getItem, StorageKeys } from "@/utils/storage"; | ||||
import { | |||||
getMailingAddress | |||||
} from "@/subpackage/orders/js/publicRequest"; | |||||
const config = { | const config = { | ||||
submitName: "申请退货", | submitName: "申请退货", | ||||
titleWidth: 160, | titleWidth: 160, | ||||
divider: true, | divider: true, | ||||
address:"" | |||||
}; | }; | ||||
const state = reactive({ | const state = reactive({ | ||||
returnLogisticsNumber: e.returnLogisticsNumber, | returnLogisticsNumber: e.returnLogisticsNumber, | ||||
returnReason: e.returnReason, | returnReason: e.returnReason, | ||||
opId: getItem(StorageKeys.OpenId), | opId: getItem(StorageKeys.OpenId), | ||||
address:config.address | |||||
}, | }, | ||||
method: "POST", | method: "POST", | ||||
showLoading: true, | showLoading: true, | ||||
}; | }; | ||||
request(orderReturn, options).then((res) => { | request(orderReturn, options).then((res) => { | ||||
confirm( | confirm( | ||||
"您申办的ETC订单已申请退货,待审核,请到【查询服务】的【业务审核查询】查看进度", | "您申办的ETC订单已申请退货,待审核,请到【查询服务】的【业务审核查询】查看进度", | ||||
//获取退货网点 | //获取退货网点 | ||||
getOutletList(); | getOutletList(); | ||||
getMailingAddress(state.orderInfo.orderId).then((address) => { | |||||
console.log("address",address) | |||||
config.address=address | |||||
}) | |||||
}); | }); | ||||
</script> | </script> | ||||
import { stringToJson } from "@/utils/network/encryption"; | |||||
import { request } from "@/utils/network/request"; | |||||
import {getMailingAddressApi } from "@/utils/network/api.js"; | |||||
export const getMailingAddress = (orderId) => { | |||||
var data = { | |||||
orderId: orderId, | |||||
}; | |||||
const options = { | |||||
type: 2, | |||||
data: data, | |||||
method: "POST", | |||||
showLoading: true, | |||||
}; | |||||
return new Promise(async (resolve, reject) => { | |||||
const res = await request(getMailingAddressApi, options); | |||||
const data = stringToJson(res.bizContent).address; | |||||
console.log("获取邮寄地址", data) | |||||
resolve(data); | |||||
}).catch((error) => { | |||||
reject(error); | |||||
}); | |||||
} |