Parcourir la source

装箱单-成衣-批量删除

jbb il y a 2 ans
Parent
commit
1746210303
1 fichiers modifiés avec 14 ajouts et 1 suppressions
  1. 14 1
      src/views/packing-list/clothes-list.vue

+ 14 - 1
src/views/packing-list/clothes-list.vue

@@ -133,6 +133,7 @@
         <a-upload  name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader" :action="importExcelUrl"  @change="handleImportExcel" :customRequest="uploadFlie">
           <a-button type="primary" icon="import">导入-来源预装箱单</a-button>
         </a-upload>
+        <a-button type="primary" icon="download" @click="majorityDelet">批量删除</a-button>
       </div>
 
       <!-- table  rowKey="id"-->
@@ -284,7 +285,7 @@ import ReferencePrePacklist from '@views/packing-list/packinglist-clothes/refere
 import clothesAddDrawer from '@views/packing-list/packinglist-clothes/clothesAddDrawer.vue'
 import detailsClothesDrawer from '@views/packing-list/packinglist-clothes/detailsClothesDrawer.vue'
 import editClothesDrawer from '@views/packing-list/packinglist-clothes/editClothesDrawer.vue'
-import { spltList,deleteSpltList,spltListId,SubmitList,cancelSubmitList,bitchSubmitList,bitchCancelSubmitList,fileDetail,upload,pushOrderData} from '@api/document/packing-list/packinglist-clothes'
+import { spltList,deleteSpltList,spltListId,SubmitList,cancelSubmitList,bitchSubmitList,bitchCancelSubmitList,fileDetail,upload,pushOrderData,batchDelete} from '@api/document/packing-list/packinglist-clothes'
 
 
 export default {
@@ -705,6 +706,18 @@ export default {
      })
 
     },
+    majorityDelet(){
+      var ids = this.selectedRowKeys.toString()
+      batchDelete({ ids: ids }).then(res => {
+          if (res.success) {
+            this.$message.success('批量删除成功');
+            this.getSpltList()
+          }else {
+            this.$message.error(res.message);
+          }
+        })
+        this.selectedRowKeys = []
+    },
     pushU8(record){
       pushOrderData({ids : record.id}).then(res =>{
         if (res.success) {