|
@@ -92,7 +92,7 @@
|
|
|
</div>
|
|
</div>
|
|
|
<el-button type="primary" slot="reference">本店送</el-button>
|
|
<el-button type="primary" slot="reference">本店送</el-button>
|
|
|
</el-popover>
|
|
</el-popover>
|
|
|
- <el-button style="margin-left: 20px" @click="fillFormFn" type="primary" >发货</el-button>
|
|
|
|
|
|
|
+ <el-button style="margin-left: 20px" @click="fillFormFn" type="primary" >发快递</el-button>
|
|
|
|
|
|
|
|
</div>
|
|
</div>
|
|
|
</template>
|
|
</template>
|
|
@@ -141,7 +141,7 @@
|
|
|
</div>
|
|
</div>
|
|
|
</el-drawer>
|
|
</el-drawer>
|
|
|
<!-- 填单 -->
|
|
<!-- 填单 -->
|
|
|
- <el-dialog title="填单" :visible.sync="orderDialog" :close-on-click-modal="false" width="30%">
|
|
|
|
|
|
|
+ <el-dialog title="确认客户地址" :visible.sync="orderDialog" :close-on-click-modal="false" width="30%">
|
|
|
<div class="order-modal-content">
|
|
<div class="order-modal-content">
|
|
|
<el-form
|
|
<el-form
|
|
|
:model="orderForm"
|
|
:model="orderForm"
|
|
@@ -153,19 +153,27 @@
|
|
|
<div class="form-wrap">
|
|
<div class="form-wrap">
|
|
|
<!-- 左侧 -->
|
|
<!-- 左侧 -->
|
|
|
<div class="form-left-wrap">
|
|
<div class="form-left-wrap">
|
|
|
- <el-form-item label="配送方" prop="sendSide">
|
|
|
|
|
- <el-select v-model="orderForm.sendSide" placeholder="请选择" size="small" @change="selectSendSide" style="width: 100%">
|
|
|
|
|
- <el-option
|
|
|
|
|
- v-for="item in sendSideOpt"
|
|
|
|
|
- :key="item.value"
|
|
|
|
|
- :label="item.label"
|
|
|
|
|
- :value="item.value"
|
|
|
|
|
- ></el-option>
|
|
|
|
|
- </el-select>
|
|
|
|
|
- </el-form-item>
|
|
|
|
|
- <el-form-item label="配送城市" prop="receiveMobile" style="margin-bottom: 8px;">
|
|
|
|
|
- <el-input v-model="orderForm.receiveCity" :disabled="true" placeholder="配送城市" size="mini"></el-input>
|
|
|
|
|
|
|
+ <el-form-item label="配送方" prop="sendSide">
|
|
|
|
|
+ <el-select v-model="orderForm.sendSide" placeholder="请选择" size="small" @change="selectSendSide" style="width: 100%">
|
|
|
|
|
+ <el-option
|
|
|
|
|
+ v-for="item in sendSideOpt"
|
|
|
|
|
+ :key="item.value"
|
|
|
|
|
+ :label="item.label"
|
|
|
|
|
+ :value="item.value"
|
|
|
|
|
+ ></el-option>
|
|
|
|
|
+ </el-select>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
|
|
+ <el-form-item label="城市" prop="receiveMobile" style="margin-bottom: 8px;">
|
|
|
|
|
+ <el-input v-model="orderForm.receiveCity" :disabled="true" placeholder="城市" size="mini"></el-input>
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+
|
|
|
|
|
+ <el-form-item label="客户名称" prop="customName" style="margin-bottom: 8px;">
|
|
|
|
|
+ <el-input v-model="orderForm.customName" placeholder="请填写" size="mini"></el-input>
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+ <el-form-item label="客户手机" prop="customMobile" style="margin-bottom: 8px;">
|
|
|
|
|
+ <el-input v-model="orderForm.customMobile" placeholder="请填写" size="mini"></el-input>
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+
|
|
|
<el-form-item label="详细地址" prop="receiveAddress" style="margin-bottom: 8px;">
|
|
<el-form-item label="详细地址" prop="receiveAddress" style="margin-bottom: 8px;">
|
|
|
<el-autocomplete
|
|
<el-autocomplete
|
|
|
v-model="orderForm.receiveAddress"
|
|
v-model="orderForm.receiveAddress"
|
|
@@ -185,10 +193,11 @@
|
|
|
<el-input v-model="orderForm.receiveFloor" placeholder="楼号门牌号(选填)" size="mini"></el-input>
|
|
<el-input v-model="orderForm.receiveFloor" placeholder="楼号门牌号(选填)" size="mini"></el-input>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
<el-form-item label="配送时间" prop="reachTime" style="margin-bottom: 8px;">
|
|
<el-form-item label="配送时间" prop="reachTime" style="margin-bottom: 8px;">
|
|
|
- <el-time-picker format='HH:mm' value-format="HH:mm" v-model="orderForm.reachTime" @change="freight" placeholder="任意时间点" style="width: 100%" size="mini"></el-time-picker>
|
|
|
|
|
|
|
+ <el-time-picker format='HH:mm' value-format="HH:mm" v-model="orderForm.reachTime" @change="freight" placeholder="任意时间点" style="width: 100%" size="mini">
|
|
|
|
|
+ </el-time-picker>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
<el-form-item label="运费" prop="remark" style="margin-bottom: 8px;">
|
|
<el-form-item label="运费" prop="remark" style="margin-bottom: 8px;">
|
|
|
- <el-input v-model="orderForm.sedCost" :disabled="true" placeholder="留空表示免运费" size="mini"></el-input>
|
|
|
|
|
|
|
+ <el-input v-model="orderForm.sedCost" :disabled="true" placeholder="" size="mini"></el-input>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
@@ -360,20 +369,22 @@ export default {
|
|
|
relateData: {},
|
|
relateData: {},
|
|
|
confirmSendVisit: false,
|
|
confirmSendVisit: false,
|
|
|
orderDialog: false,
|
|
orderDialog: false,
|
|
|
- freightInfo:{
|
|
|
|
|
- id: '',
|
|
|
|
|
- floor:'',
|
|
|
|
|
- province: '',
|
|
|
|
|
- city: '',
|
|
|
|
|
- address: '',
|
|
|
|
|
- expressId: '',
|
|
|
|
|
- long: '',
|
|
|
|
|
- lat: '',
|
|
|
|
|
- sendTime: '',
|
|
|
|
|
- },
|
|
|
|
|
|
|
+ freightInfo:{
|
|
|
|
|
+ id: '',
|
|
|
|
|
+ floor:'',
|
|
|
|
|
+ province: '',
|
|
|
|
|
+ city: '',
|
|
|
|
|
+ address: '',
|
|
|
|
|
+ expressId: '',
|
|
|
|
|
+ long: '',
|
|
|
|
|
+ lat: '',
|
|
|
|
|
+ customName:'',
|
|
|
|
|
+ customMobile:'',
|
|
|
|
|
+ sendTime: '',
|
|
|
|
|
+ },
|
|
|
orderForm: {
|
|
orderForm: {
|
|
|
- sendSide:'',//配送方
|
|
|
|
|
- sedCost:'',//运费
|
|
|
|
|
|
|
+ sendSide:'',//配送方
|
|
|
|
|
+ sedCost:'',//运费
|
|
|
receiveUserName: '', // 收花人姓名;到店自提的姓名
|
|
receiveUserName: '', // 收花人姓名;到店自提的姓名
|
|
|
receiveMobile: '', // 收花人手机;到店自提的电话;
|
|
receiveMobile: '', // 收花人手机;到店自提的电话;
|
|
|
receiveProvince: '', // 收花人省份
|
|
receiveProvince: '', // 收花人省份
|
|
@@ -381,7 +392,6 @@ export default {
|
|
|
receiveAddress: '', // 收花人地址
|
|
receiveAddress: '', // 收花人地址
|
|
|
receiveFloor: '', // 收花人门楼号和牌号
|
|
receiveFloor: '', // 收花人门楼号和牌号
|
|
|
receiveFullAddress: '', // 收花人完整地址,从腾讯地图接口获取
|
|
receiveFullAddress: '', // 收花人完整地址,从腾讯地图接口获取
|
|
|
- // bookName: '', // 订花人姓名
|
|
|
|
|
bookMobile: '', // 订花人手机号
|
|
bookMobile: '', // 订花人手机号
|
|
|
reachTime: '', // 配送时间
|
|
reachTime: '', // 配送时间
|
|
|
reachPeriod: '0', // 配送时段,0上午1下午2晚上
|
|
reachPeriod: '0', // 配送时段,0上午1下午2晚上
|
|
@@ -510,27 +520,26 @@ export default {
|
|
|
this.orderForm.longitude = item.location.lng;
|
|
this.orderForm.longitude = item.location.lng;
|
|
|
this.orderForm.receiveAddress = item.title;
|
|
this.orderForm.receiveAddress = item.title;
|
|
|
this.orderForm.receiveFullAddress = item.address;
|
|
this.orderForm.receiveFullAddress = item.address;
|
|
|
-
|
|
|
|
|
- this.freightInfo.address = item.address;
|
|
|
|
|
- this.freightInfo.long = item.location.lng;
|
|
|
|
|
- this.freightInfo.lat = item.location.lat;
|
|
|
|
|
- this.freight()
|
|
|
|
|
|
|
+ this.freightInfo.address = item.address;
|
|
|
|
|
+ this.freightInfo.long = item.location.lng;
|
|
|
|
|
+ this.freightInfo.lat = item.location.lat;
|
|
|
|
|
+ this.freight()
|
|
|
},
|
|
},
|
|
|
submitOrderFn() {
|
|
submitOrderFn() {
|
|
|
- if(this.$util.isEmpty(this.freightInfo.expressId)){this.$message({message: '请选择配送方',type: 'warning'});return};
|
|
|
|
|
- if(this.$util.isEmpty(this.orderForm.reachTime)){this.$message({message: '请选择配时间',type: 'warning'});return};
|
|
|
|
|
- let parameter = {
|
|
|
|
|
- id:this.id,
|
|
|
|
|
- sendCost:this.orderForm.sedCost,
|
|
|
|
|
- expressId:this.freightInfo.expressId,
|
|
|
|
|
- sendTime:this.orderForm.reachTime,
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ if(this.$util.isEmpty(this.freightInfo.expressId)){this.$message({message: '请选择配送方',type: 'warning'});return};
|
|
|
|
|
+ if(this.$util.isEmpty(this.orderForm.reachTime)){this.$message({message: '请选择配时间',type: 'warning'});return};
|
|
|
|
|
+ let parameter = {
|
|
|
|
|
+ id:this.id,
|
|
|
|
|
+ sendCost:this.orderForm.sedCost,
|
|
|
|
|
+ expressId:this.freightInfo.expressId,
|
|
|
|
|
+ sendTime:this.orderForm.reachTime,
|
|
|
|
|
+ }
|
|
|
this.$service.order.sendExpressage(parameter)
|
|
this.$service.order.sendExpressage(parameter)
|
|
|
- .then(res => {
|
|
|
|
|
- this.init();
|
|
|
|
|
- // this.getDet();
|
|
|
|
|
- this.resetForm();
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ .then(res => {
|
|
|
|
|
+ this.init();
|
|
|
|
|
+ // this.getDet();
|
|
|
|
|
+ this.resetForm();
|
|
|
|
|
+ });
|
|
|
},
|
|
},
|
|
|
handleChange(value) {
|
|
handleChange(value) {
|
|
|
console.log('value', value);
|
|
console.log('value', value);
|
|
@@ -581,20 +590,21 @@ export default {
|
|
|
this.printOrder();
|
|
this.printOrder();
|
|
|
});
|
|
});
|
|
|
},
|
|
},
|
|
|
- // 填单
|
|
|
|
|
|
|
+ //发快递
|
|
|
fillFormFn() {
|
|
fillFormFn() {
|
|
|
this.orderDialog = true;
|
|
this.orderDialog = true;
|
|
|
- this.freightInfo.id = this.id;
|
|
|
|
|
- this.$service.custom.clientInfo({ id: this.orderData.customId}).then(res => {
|
|
|
|
|
- this.orderForm.receiveCity = `${res.province}-${res.city}`
|
|
|
|
|
- this.orderForm.receiveAddress = `${res.address}`
|
|
|
|
|
-
|
|
|
|
|
- this.freightInfo.province = res.province;
|
|
|
|
|
- this.freightInfo.city = res.city;
|
|
|
|
|
- this.freightInfo.address = res.address;
|
|
|
|
|
- this.freightInfo.long = res.long;
|
|
|
|
|
- this.freightInfo.lat = res.lat;
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ this.freightInfo.id = this.id;
|
|
|
|
|
+ this.$service.custom.clientInfo({ id: this.orderData.customId}).then(res => {
|
|
|
|
|
+ this.orderForm.receiveCity = `${res.province}-${res.city}`
|
|
|
|
|
+ this.orderForm.receiveAddress = `${res.address}`
|
|
|
|
|
+ this.orderForm.customName = `${res.name}`
|
|
|
|
|
+ this.orderForm.customMobile = `${res.mobile}`
|
|
|
|
|
+ this.freightInfo.province = res.province;
|
|
|
|
|
+ this.freightInfo.city = res.city;
|
|
|
|
|
+ this.freightInfo.address = res.address;
|
|
|
|
|
+ this.freightInfo.long = res.long;
|
|
|
|
|
+ this.freightInfo.lat = res.lat;
|
|
|
|
|
+ })
|
|
|
},
|
|
},
|
|
|
freight(){
|
|
freight(){
|
|
|
this.freightInfo.floor = this.orderForm.receiveFloor;
|
|
this.freightInfo.floor = this.orderForm.receiveFloor;
|