From b7f74340de27a3427d8afb8750724b788c8a780c Mon Sep 17 00:00:00 2001
From: MrShi <1878285526@qq.com>
Date: 星期四, 06 二月 2025 18:17:19 +0800
Subject: [PATCH] 改bug

---
 admin/src/views/stock/components/AssetSel.vue |   14 ++++++++++----
 1 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/admin/src/views/stock/components/AssetSel.vue b/admin/src/views/stock/components/AssetSel.vue
index a315d02..d4bb919 100644
--- a/admin/src/views/stock/components/AssetSel.vue
+++ b/admin/src/views/stock/components/AssetSel.vue
@@ -1,5 +1,5 @@
 <template>
-  <GlobalWindow title="閫夋嫨鐗╂枡" :visible.sync="isShowModal" :confirm-working="isLoading" width="900px" @close="close"
+  <GlobalWindow title="閫夋嫨鐗╂枡" :visible.sync="isShowModal" :confirm-working="isLoading" width="1000px" @close="close"
     @confirm="confirm">
     <el-form ref="searchForm" :model="searchForm" label-width="100px" inline>
       <el-form-item prop="code" label="鐗╂枡淇℃伅">
@@ -10,7 +10,8 @@
           :options="cateList" :props="{
             label: 'name',
             value: 'id',
-            children: 'childCategoryList'
+            children: 'childCategoryList',
+            checkStrictly: true
           }"></el-cascader>
       </el-form-item>
       <span>
@@ -54,6 +55,7 @@
         total: 0
       },
       isOut: false,
+      warehouseId: false,
       list: [],
       selList: [],
       cateList: [],
@@ -78,7 +80,7 @@
       this.selList = val
     },
     getList(page) {
-      const { pagination, searchForm, isOut } = this
+      const { pagination, searchForm, isOut, warehouseId } = this
       this.listLoading = true
       if(page){pagination.page = page}
       console.log('isOut', isOut);
@@ -87,7 +89,7 @@
       fn({
         capacity: pagination.pageSize,
         page: pagination.page,
-        model: {...searchForm}
+        model: {...searchForm,status: 0, warehouseId}
       }).then((res) => {
         this.listLoading = false
         this.list = res.records
@@ -120,6 +122,10 @@
     changeSel(e) {
       if (e && e.length == 2) {
         this.$set(this.searchForm, 'cateId', e[1])
+        this.$set(this.searchForm, 'parentCateId', '')
+      }else if((e && e.length == 1)){
+        this.$set(this.searchForm, 'parentCateId', e[0])
+        this.$set(this.searchForm, 'cateId', '')
       } else {
         this.$set(this.searchForm, 'cateId', '')
       }

--
Gitblit v1.9.3