Zory пре 3 недеља
родитељ
комит
dbcf41f50c

+ 5 - 2
src/views/manage/general/brand/index.vue

@@ -6,7 +6,7 @@
                 <el-button type="default" icon="el-icon-plus" @click="table_add()">新增衣物品牌</el-button>
             </div>
         </div>
-        <el-main>
+        <el-main v-loading="isLoading">
             <div v-if="list.length == 0">
                 <el-empty description="暂无数据" :image-size="100"></el-empty>
             </div>
@@ -39,7 +39,8 @@ export default {
     data(){
         return {
             list: [],
-            maxNum:0
+            maxNum:0,
+            isLoading:false
         }
     },
     created(){
@@ -66,7 +67,9 @@ export default {
             this.getList()
         },
         async getList(){
+            this.isLoading = true;
             var resp = await this.$API.cloth.color.get({"type":"brand"});
+            this.isLoading = false;
             if (resp.code == 0) {
                 return this.$message.warning(resp.msg)
             }

+ 5 - 2
src/views/manage/general/color/index.vue

@@ -6,7 +6,7 @@
                 <el-button type="default" icon="el-icon-plus" @click="table_add()">新增颜色</el-button>
             </div>
         </div>
-        <el-main>
+        <el-main v-loading="isLoading">
             <div v-if="list.length == 0">
                 <el-empty description="暂无数据" :image-size="100"></el-empty>
             </div>
@@ -50,7 +50,8 @@ export default {
     data(){
         return {
             list: [],
-            maxNum:0
+            maxNum:0,
+            isLoading:false
         }
     },
     created(){
@@ -77,7 +78,9 @@ export default {
             this.getList()
         },
         async getList(){
+            this.isLoading = true;
             var resp = await this.$API.cloth.color.get({"type":"color"});
+            this.isLoading = false;
             if (resp.code == 0) {
                 return this.$message.warning(resp.msg)
             }

+ 5 - 2
src/views/manage/general/defect/index.vue

@@ -6,7 +6,7 @@
                 <el-button type="default" icon="el-icon-plus" @click="table_add()">新增瑕疵说明</el-button>
             </div>
         </div>
-        <el-main>
+        <el-main v-loading="isLoading">
             <div v-if="list.length == 0">
                 <el-empty description="暂无数据" :image-size="100"></el-empty>
             </div>
@@ -37,7 +37,8 @@ export default {
     data(){
         return {
             list: [],
-            maxNum:0
+            maxNum:0,
+            isLoading:false
         }
     },
     created(){
@@ -64,7 +65,9 @@ export default {
             this.getList()
         },
         async getList(){
+            this.isLoading = true;
             var resp = await this.$API.cloth.color.get({"type":"defect"});
+            this.isLoading = false;
             if (resp.code == 0) {
                 return this.$message.warning(resp.msg)
             }

+ 5 - 2
src/views/manage/general/ornament/index.vue

@@ -6,7 +6,7 @@
                 <el-button type="default" icon="el-icon-plus" @click="table_add()">新增配饰/附件</el-button>
             </div>
         </div>
-        <el-main>
+        <el-main v-loading="isLoading">
             <div v-if="list.length == 0">
                 <el-empty description="暂无数据" :image-size="100"></el-empty>
             </div>
@@ -37,7 +37,8 @@ export default {
     data(){
         return {
             list: [],
-            maxNum:0
+            maxNum:0,
+            isLoading:false
         }
     },
     created(){
@@ -64,7 +65,9 @@ export default {
             this.getList()
         },
         async getList(){
+            this.isLoading = true;
             var resp = await this.$API.cloth.color.get({"type":"ornament"});
+            this.isLoading = false;
             if (resp.code == 0) {
                 return this.$message.warning(resp.msg)
             }

+ 5 - 2
src/views/manage/general/risk/index.vue

@@ -6,7 +6,7 @@
                 <el-button type="default" icon="el-icon-plus" @click="table_add()">新增洗涤风险项</el-button>
             </div>
         </div>
-        <el-main>
+        <el-main v-loading="isLoading">
             <div v-if="list.length == 0">
                 <el-empty description="暂无数据" :image-size="100"></el-empty>
             </div>
@@ -37,7 +37,8 @@ export default {
     data(){
         return {
             list: [],
-            maxNum:0
+            maxNum:0,
+            isLoading:false
         }
     },
     created(){
@@ -64,7 +65,9 @@ export default {
             this.getList()
         },
         async getList(){
+            this.isLoading = true;
             var resp = await this.$API.cloth.color.get({"type":"risk"});
+            this.isLoading = false;
             if (resp.code == 0) {
                 return this.$message.warning(resp.msg)
             }