ymy 1 vuosi sitten
vanhempi
säilyke
0088509fad

+ 1 - 1
src/benyun/components/byInput/byInput.vue

@@ -34,7 +34,7 @@ config:{
     min:0 //最小值
     max:''  //最大值
     step:'' //间隔
-    onceEdit: true/false  //只能编辑一次
+    onceEdit: true/false  //保存后不能修改
     prefixIcon:''  //头部图标
     suffixIcon:''  //尾部图标
   }

+ 6 - 0
src/components/skuModal/productModal.vue

@@ -17,6 +17,7 @@
 
 <script lang="ts">
 import { Component, Prop, Vue, Watch } from "vue-property-decorator";
+import wmsStatue from './wmsStatus.vue'
 @Component
 export default class ProductModal extends Vue {
   value=false
@@ -95,6 +96,11 @@ export default class ProductModal extends Vue {
         field:'skuTitle',
         ellipsis:true,
         // width:150
+      },{
+        width: '80px',
+        title: '是否已同步WMS',
+        field: 'isSynchronousWMS',
+        component: wmsStatue
       },{
         title:'规格',
         field:'materialSpec',

+ 16 - 0
src/components/skuModal/wmsStatus.vue

@@ -0,0 +1,16 @@
+<template>
+	<div>
+		<el-tag size='mini' :type="propValue===0?'success':'warning'" disable-transitions effect="dark">{{propValue===0?'是':'否'}}</el-tag>
+	</div>
+</template>
+<script lang="ts">
+	import { Component, Prop, Vue, Watch, Mixins } from "vue-property-decorator";
+	@Component
+	export default class yesno extends Vue {
+		@Prop()
+		propValue : any
+	}
+</script>
+
+<style>
+</style>

+ 1 - 0
src/views/audit/sku/index.vue

@@ -236,6 +236,7 @@
 				{
 					// width: '90px',
 					title: '体积/cm³',
+					width:90,
 					field: 'volume',
 				},
 			]

+ 27 - 4
src/views/oms/B2BOrder/components/deliveryDetail.vue

@@ -102,6 +102,9 @@
           <div class="s-col">WMS取消订单的备注:{{ value.wmsRemark }}</div>
         </div>
       </div>
+      <div class="deli-footer">
+        <div class="send-btn" @click="cancelB2CDelivery">取消发货</div>
+      </div>
     </div>
   </el-drawer>
 </template>
@@ -109,7 +112,7 @@
 <script lang="ts">
 import { Component, Prop, Vue, Watch } from "vue-property-decorator";
 import DeliveryGoodsInfo from "./deliveryGoodsInfo.vue";
-import { queryOrderByOrderId,cancleSendOrder } from  '@/api/delivery'
+import { queryOrderByOrderId,cancleSendOrder,cancleWmsTradeOrder } from  '@/api/delivery'
 import api from '@/api/currency'
 @Component({components:{DeliveryGoodsInfo}})
 export default class DeliveryDetail extends Vue {
@@ -182,6 +185,26 @@ export default class DeliveryDetail extends Vue {
     }
     return n;
   }
+  cancelB2CDelivery() {
+    this.$confirm('此操作将导致该订单的发货被取消,是否继续?', '提示', {
+      confirmButtonText: '继续',
+      cancelButtonText: '取消',
+      type: 'warning'
+    }).then(() => {
+      this.load = true;
+      cancleWmsTradeOrder({saleOrderCode:this.value.wmsSaleorderCode}).then((res:any) => {
+        this.drawer = false;
+        this.load =false;
+        this.$message({
+          message:'该订单的发货已被取消!',
+          type:'success'
+        })
+        this.$emit('handleSuccess');
+      }).catch(() => {
+        this.load = false;
+      })
+    }).catch(() => {});
+  }
   setData(v:any){
     if(!v) {
       this.$message('缺少订单id');
@@ -192,8 +215,8 @@ export default class DeliveryDetail extends Vue {
       omsOrderId:v
     }).then((res:any) => {
       this.load = false;
-      this.value = res.data;
-      if(this.value) {
+      if(res.data) {
+        this.value = res.data;
         this.loadWarehouse();
         if(res.data.subItemList){
           this.value.subItem=[];
@@ -224,7 +247,7 @@ export default class DeliveryDetail extends Vue {
           }
         })
       }else{
-        this.drawer = false;
+        // this.drawer = false;
         this.$message('未找到发货明细数据!')
       }
     }).catch(() => {

+ 2 - 1
src/views/oms/B2BOrder/components/logisticsInfo.vue

@@ -6,7 +6,7 @@
     :direction="direction"
     size="30%">
     <div class="order-logistcs">
-      <el-timeline :reverse="true">
+      <el-timeline :reverse="true" v-if="data && data.length > 0">
         <el-timeline-item v-for="(item,index) of data" :key="index" :timestamp="item.tmsStatus + ' ' +item.createTime" placement="top">
           <el-card>
             <!-- <h4>{{item.tmsStatus}}</h4> -->
@@ -18,6 +18,7 @@
           </el-card>
         </el-timeline-item>
       </el-timeline>
+      <el-empty v-else description="暂无数据"></el-empty>
     </div>
       
   </el-drawer>

+ 3 - 3
src/views/oms/B2COrder/components/deliveryDetail.vue

@@ -150,8 +150,8 @@ export default class DeliveryDetail extends Vue {
       omsOrderId:v
     }).then((res:any) => {
       this.load = false;
-      this.value = res.data;
-      if(this.value) {
+      if(res.data) {
+        this.value = res.data;
         this.loadWarehouse();
         if(res.data.subItemList){
           this.value.subItem=[];
@@ -181,7 +181,7 @@ export default class DeliveryDetail extends Vue {
           }
         })
       }else{
-        this.drawer = false;
+        // this.drawer = false;
         this.$message('未找到发货明细数据!')
       }
     }).catch(() => {

+ 2 - 1
src/views/oms/B2COrder/components/logisticsInfo.vue

@@ -6,7 +6,7 @@
     :direction="direction"
     size="30%">
     <div class="order-logistcs">
-      <el-timeline :reverse="true">
+      <el-timeline :reverse="true" v-if="data && data.length > 0">
         <el-timeline-item v-for="(item,index) of data" :key="index" :timestamp="item.tmsStatus + ' ' +item.createTime" placement="top">
           <el-card>
             <!-- <h4>{{item.tmsStatus}}</h4> -->
@@ -18,6 +18,7 @@
           </el-card>
         </el-timeline-item>
       </el-timeline>
+      <el-empty v-else description="暂无数据"></el-empty>
     </div>
       
   </el-drawer>

+ 1 - 1
src/views/oms/B2COrder/index.vue

@@ -639,7 +639,7 @@ export default class Order extends Vue {
       ids = ids ? ids + ',' + item.id : item.id;
       idsArr.push(item.id)
     }
-    this.$confirm('归档后数据无法恢复,您确定将订单“'+ ids +'”归档?', '提示', {
+    this.$confirm('归档后数据无法恢复,您确定将所选订单归档?', '提示', {
       confirmButtonText: '确定',
       cancelButtonText: '取消',
       type: 'warning'

+ 31 - 27
src/views/oms/order/components/deliveryDetail.vue

@@ -145,36 +145,40 @@ export default class DeliveryDetail extends Vue {
     queryOrderByOrderId({
       omsOrderId:v
     }).then((res:any) => {
-      this.value = res.data;
-      if(res.data.subItemList){
-        this.value.subItem=[];
-        for(const item of this.value.subItemList){
-          this.value.subItem.push({
-            tmsGoodsCode:item.tmsGoodsCode,
-            name:item.tmsGoodsName,
-            tmsGoodsTotalPrice:item.tmsGoodsTotalPrice,
-            price:item.tmsGoodsPrice,
-            weight:item.tmsWeight,
-            tmsQuantity:item.tmsQuantity
-          })
+      if(res.data){
+        this.value = res.data;
+        if(res.data.subItemList){
+          this.value.subItem=[];
+          for(const item of this.value.subItemList){
+            this.value.subItem.push({
+              tmsGoodsCode:item.tmsGoodsCode,
+              name:item.tmsGoodsName,
+              tmsGoodsTotalPrice:item.tmsGoodsTotalPrice,
+              price:item.tmsGoodsPrice,
+              weight:item.tmsWeight,
+              tmsQuantity:item.tmsQuantity
+            })
+          }
         }
-      }
-      this.load = false;
-      if(res.data.pricePlan){
-        try{
-          this.priceData = JSON.parse(res.data.pricePlan);
-        }catch(e){
-          this.priceData = [];
-          console.error('价格列表数据转换错误!')
+        this.load = false;
+        if(res.data.pricePlan){
+          try{
+            this.priceData = JSON.parse(res.data.pricePlan);
+          }catch(e){
+            this.priceData = [];
+            console.error('价格列表数据转换错误!')
+          }
+          
         }
-        
+        setTimeout(()=>{
+          if(this.$refs.info){
+            (this.$refs.info as any).setValue(this.value)
+          }
+        },1000)
+      }else{
+        this.drawer = false;
+        this.$message('未找到发货明细数据!')
       }
-      setTimeout(()=>{
-        if(this.$refs.info){
-          (this.$refs.info as any).setValue(this.value)
-        }
-      },1000)
-      
     }).catch(() => {
       this.load = false;
     })

+ 2 - 1
src/views/oms/order/components/logisticsInfo.vue

@@ -6,7 +6,7 @@
     :direction="direction"
     size="30%">
     <div class="order-logistcs">
-      <el-timeline :reverse="true">
+      <el-timeline :reverse="true" v-if="data && data.length > 0">
         <el-timeline-item v-for="(item,index) of data" :key="index" :timestamp="item.tmsStatus + ' ' +item.createTime" placement="top">
           <el-card>
             <!-- <h4>{{item.tmsStatus}}</h4> -->
@@ -18,6 +18,7 @@
           </el-card>
         </el-timeline-item>
       </el-timeline>
+      <el-empty v-else description="暂无数据"></el-empty>
     </div>
       
   </el-drawer>