|
|
@@ -92,13 +92,9 @@
|
|
|
<text style="color: #3385FF">¥{{ form.sendCost }}</text>
|
|
|
</tui-list-cell>
|
|
|
|
|
|
- <tui-list-cell class="line-cell" :hover="false" :arrow="true" v-if="form.sendType == 3">
|
|
|
+ <tui-list-cell class="line-cell" :hover="false" v-if="form.sendType == 3">
|
|
|
<view class="tui-title ">配送物流</view>
|
|
|
- <picker mode="selector" :value="form.wlId" :range="wlList" range-key="name" @change="changeWlFn" class="tui-input" >
|
|
|
- <input v-model="form.wlId" name="wlId" type="text" hidden />
|
|
|
- <view v-if="Number(form.wlId)>0">{{ wlSelData.name }}</view>
|
|
|
- <view class="tui-placeholder" v-else>请选择</view>
|
|
|
- </picker>
|
|
|
+ <input type="digit" placeholder="请填写物流" v-model="form.wlName" @focus="form.wlName=''" placeholder-class="tui-placeholder"/>
|
|
|
</tui-list-cell>
|
|
|
|
|
|
<tui-list-cell class="line-cell" :hover="false" v-if="(form.sendType == 2 || form.sendType == 0)&& Number(form.packCost)>0">
|
|
|
@@ -152,7 +148,7 @@ import appFormSend from "@/components/app-form-send";
|
|
|
import appSendTime from "@/components/app-send-time";
|
|
|
const formUtil = require("@/utils/formValidation.js");
|
|
|
import AppDatePicker from "@/components/app-date-picker";
|
|
|
-import { getGhsDataApi,getGhsWl } from "@/api/ghs";
|
|
|
+import { getGhsDataApi } from "@/api/ghs";
|
|
|
import { freight,createOrder } from "@/api/purchase";
|
|
|
import { mapActions, mapGetters } from "vuex";
|
|
|
import { shopHouponHas } from '@/api/coupon'
|
|
|
@@ -203,7 +199,6 @@ export default {
|
|
|
product: "",
|
|
|
hbId: '0',
|
|
|
packCost:0,
|
|
|
- wlId:0,
|
|
|
wlName:''
|
|
|
},
|
|
|
showCustomer: false,
|
|
|
@@ -261,12 +256,6 @@ export default {
|
|
|
},
|
|
|
methods: {
|
|
|
...mapActions(["initMerchantInfo"]),
|
|
|
- changeWlFn(e) {
|
|
|
- let that = this
|
|
|
- this.wlSelData = this.wlList[e.detail.value]
|
|
|
- that.form.wlId = that.wlSelData.id
|
|
|
- that.form.wlName = that.wlSelData.name
|
|
|
- },
|
|
|
changeSendType(num){
|
|
|
this.form.sendType = num
|
|
|
if(num == 2){
|
|
|
@@ -444,25 +433,6 @@ export default {
|
|
|
getGhsDataApi({id:id}).then(res => {
|
|
|
this.ghsInfo = res.data
|
|
|
this.form.packCost = res.data.packCost?parseFloat(res.data.packCost):0
|
|
|
- that.form.wlId = this.ghsInfo.customWlId ? this.ghsInfo.customWlId : 0
|
|
|
- getGhsWl({id:id}).then(res=>{
|
|
|
- if(res.code == 1){
|
|
|
- that.wlList = res.data.list
|
|
|
- if(Number(that.form.wlId)>0){
|
|
|
- let newData = that.wlList.filter(
|
|
|
- e => that.form.wlId == e.id
|
|
|
- )
|
|
|
- if(!this.$util.isEmpty(newData)){
|
|
|
- that.wlSelData = newData[0]
|
|
|
- that.form.wlId = that.wlSelData.id
|
|
|
- that.form.wlName = that.wlSelData.name
|
|
|
- }else{
|
|
|
- that.form.wlId = 0
|
|
|
- that.form.wlName = ''
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
- })
|
|
|
});
|
|
|
},
|
|
|
countAllPrices(e){
|
|
|
@@ -498,8 +468,8 @@ export default {
|
|
|
})
|
|
|
|
|
|
if(this.form.sendType == 3){
|
|
|
- if(Number(this.form.wlId)<=0){
|
|
|
- this.$msg('请选择物流')
|
|
|
+ if (this.$util.isEmpty(this.form.wlName)){
|
|
|
+ this.$msg('请填写物流')
|
|
|
return false
|
|
|
}
|
|
|
}
|
|
|
@@ -522,7 +492,6 @@ export default {
|
|
|
product:JSON.stringify(product),
|
|
|
ghsId:this.ghsInfo.id,
|
|
|
hbId: this.form.hbId,
|
|
|
- wlId:this.form.wlId,
|
|
|
wlName:this.form.wlName,
|
|
|
xj:JSON.stringify(xj)
|
|
|
}
|