|
|
@@ -321,7 +321,7 @@
|
|
|
|
|
|
|
|
|
<el-dialog :title="erpDialog.title" :visible.sync="erpDialog.open" width="600px" append-to-body>
|
|
|
- <div v-if="order!=null&&order.extendOrderId!=null&&order.status==1" v-hasPermi="['live:liveOrder:updateExpress']" >
|
|
|
+ <div v-if="item!=null&&item.extendOrderId!=null&&item.status==1" v-hasPermi="['live:liveOrder:updateExpress']" >
|
|
|
<el-button size="mini" @click="updateExpress()" >同步物流发货</el-button>
|
|
|
</div>
|
|
|
<div class="table-layout" v-if="erpOrder!=null">
|
|
|
@@ -384,8 +384,8 @@
|
|
|
<el-option key="YD" label="韵达" value="YD" />
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
- <el-form-item label="物流单号" prop="deliverySn" >
|
|
|
- <el-input v-model="editDyForm.deliverySn" placeholder="请输入物流单号" />
|
|
|
+ <el-form-item label="物流单号" prop="deliveryId" >
|
|
|
+ <el-input v-model="editDyForm.deliveryId" placeholder="请输入物流单号" />
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
@@ -470,9 +470,10 @@ export default {
|
|
|
followDoctorId:null,
|
|
|
},
|
|
|
editDyForm:{
|
|
|
- orderId:null,
|
|
|
- deliveryId:null,
|
|
|
- deliveryCode:null,
|
|
|
+ id: null,
|
|
|
+ orderId: null,
|
|
|
+ deliveryId: null,
|
|
|
+ deliveryCode: null,
|
|
|
},
|
|
|
showList:true,
|
|
|
edit:{
|
|
|
@@ -534,7 +535,7 @@ export default {
|
|
|
remark:"",
|
|
|
},
|
|
|
editDyRules:{
|
|
|
- deliverySn: [
|
|
|
+ deliveryId: [
|
|
|
{ required: true, message: "物流单号不能为空", trigger: "blur" }
|
|
|
],
|
|
|
deliveryCode: [
|
|
|
@@ -668,10 +669,18 @@ export default {
|
|
|
fmt(val) {
|
|
|
return val != null ? Number(val).toFixed(2) : '0.00'
|
|
|
},
|
|
|
- editDelivery(){
|
|
|
+ editDelivery(scope){
|
|
|
this.editDy.open = true;
|
|
|
this.editDyForm.orderId = this.item.orderId;
|
|
|
-
|
|
|
+ if (scope && scope.row) {
|
|
|
+ this.editDyForm.id = scope.row.id;
|
|
|
+ this.editDyForm.deliveryCode = scope.row.deliverSn;
|
|
|
+ this.editDyForm.deliveryId = scope.row.deliverId;
|
|
|
+ } else {
|
|
|
+ this.editDyForm.id = null;
|
|
|
+ this.editDyForm.deliveryCode = null;
|
|
|
+ this.editDyForm.deliveryId = '';
|
|
|
+ }
|
|
|
},
|
|
|
showListD(){
|
|
|
if(this.showList){
|
|
|
@@ -1047,9 +1056,16 @@ export default {
|
|
|
submitEditDyForm(){
|
|
|
this.$refs["editDyForm"].validate(valid => {
|
|
|
if (valid) {
|
|
|
- editDeliveryId({orderId: this.editDyForm.orderId,
|
|
|
+ const params = {
|
|
|
+ orderId: this.editDyForm.orderId,
|
|
|
deliverSn: this.editDyForm.deliveryCode,
|
|
|
- deliverId: this.editDyForm.deliverySn,type: 1}).then(response => {
|
|
|
+ deliverId: this.editDyForm.deliveryId,
|
|
|
+ type: 1
|
|
|
+ };
|
|
|
+ if (this.editDyForm.id != null) {
|
|
|
+ params.id = this.editDyForm.id;
|
|
|
+ }
|
|
|
+ editDeliveryId(params).then(response => {
|
|
|
if (response.code === 200) {
|
|
|
this.msgSuccess("操作成功");
|
|
|
this.editDy.open = false;
|
|
|
@@ -1057,6 +1073,9 @@ export default {
|
|
|
this.item = response.data;
|
|
|
this.$parent.$parent.getList();
|
|
|
});
|
|
|
+ getOrderExpress(this.item.orderId).then(response => {
|
|
|
+ this.deliverList = response.data || [];
|
|
|
+ });
|
|
|
}
|
|
|
})
|
|
|
}
|