Jelajahi Sumber

修改样式

YY 2 tahun lalu
induk
melakukan
294cc5df00

+ 4 - 12
src/views/platSettings/banner/detail.vue

@@ -84,12 +84,8 @@ export default {
     async search() {
       if (this.id) {
         let res = await this.fetch(this.id);
-        if (this.$checkRes(res)) {
-          this.$set(this, `form`, res.data);
-        }
-      } else {
-        this.$set(this, `form`, { status: '0' });
-      }
+        if (this.$checkRes(res)) this.$set(this, `form`, res.data);
+      } else this.$set(this, `form`, { status: '0' });
       this.loadings = false;
     },
     // 提交
@@ -107,14 +103,10 @@ export default {
       let res;
       // 类型
       res = await this.dictQuery({ code: 'banner_type' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `typeList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `typeList`, res.data);
       // 是否使用
       res = await this.dictQuery({ code: 'status' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `statusList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `statusList`, res.data);
     },
     // 返回
     toBack() {

+ 2 - 6
src/views/platSettings/banner/index.vue

@@ -130,14 +130,10 @@ export default {
       let res;
       // 类型
       res = await this.dictQuery({ code: 'banner_type' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `typeList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `typeList`, res.data);
       // 是否使用
       res = await this.dictQuery({ code: 'status' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `statusList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `statusList`, res.data);
     },
   },
   computed: {

+ 3 - 1
src/views/platmanag/goodsTags/index.vue

@@ -13,18 +13,20 @@
             <el-col :span="2">
               <el-button size="mini" type="primary" @click="backLevel()">返回</el-button>
             </el-col>
+            <!-- 面包屑 -->
             <el-col :span="20">
               <el-breadcrumb separator-class="el-icon-arrow-right">
                 <el-breadcrumb-item v-for="(item, index) in data" :key="index">{{ item.label }}({{ item.code }})</el-breadcrumb-item>
               </el-breadcrumb>
             </el-col>
           </el-col>
-
+          <!-- 查询 -->
           <data-search :fields="searchFields" v-model="searchInfo" @query="search">
             <template #status>
               <el-option v-for="i in statusList" :key="i.model" :label="i.label" :value="i.value"></el-option>
             </template>
           </data-search>
+          <!-- 添加 -->
           <data-btn :fields="btnFields" @add="toAdd" />
           <data-table ref="dataTable" :fields="fields" :opera="opera" :data="list" :total="total" @edit="toEdit" @delete="toDelete" @query="search">
             <template #code="{ row, item }">

+ 6 - 16
src/views/platmanag/sales/detail.vue

@@ -197,10 +197,8 @@ export default {
         if (status) res.data.zhStatus = status.label;
         this.$set(this, `info`, res.data);
         this.$set(this, `shop`, res.data.shop);
-        if (res.data.type == '4' || res.data.type == '5') {
-          // 商品
-          this.$set(this, `list`, res.data.order_detail.goods);
-        } else if (res.data.type == '1' || res.data.type == '2' || res.data.type == '3') {
+        if (res.data.type == '4' || res.data.type == '5') this.$set(this, `list`, res.data.order_detail.goods); // 商品
+        else if (res.data.type == '1' || res.data.type == '2' || res.data.type == '3') {
           if (res.data.transport) this.$set(this, `transport`, res.data.transport);
           // 图片
           this.$set(this, `file`, res.data.goods.goods.file[0].url);
@@ -228,9 +226,7 @@ export default {
         else if (res.data.status == '!5') this.$set(this, `active`, 5);
         else if (res.data.status == '-5') this.$set(this, `active`, 4);
         // 查询物流
-        if (res.data.transport) {
-          this.toLog(res.data.transport);
-        }
+        if (res.data.transport) this.toLog(res.data.transport);
         this.loading = false;
       }
     },
@@ -333,9 +329,7 @@ export default {
     // 远程查询快递公司
     async querySearch(value) {
       let res = await this.dictQuery({ code: 'transport_company', label: value });
-      if (this.$checkRes(res)) {
-        this.$set(this, 'shop_transport_typeList', res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, 'shop_transport_typeList', res.data);
     },
     // 买家快递填写保存
     async customerSubmit(val) {
@@ -378,13 +372,9 @@ export default {
       let res;
       // 类型
       res = await this.dictQuery({ code: 'afterSale_type' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `typeList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `typeList`, res.data);
       res = await this.dictQuery({ code: 'afterSale_status' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `statusList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `statusList`, res.data);
     },
     // 返回
     toBack() {

+ 2 - 6
src/views/platmanag/sales/index.vue

@@ -105,14 +105,10 @@ export default {
       let res;
       // 类型
       res = await this.dictQuery({ code: 'afterSale_type' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `typeList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `typeList`, res.data);
       // 售后状态
       res = await this.dictQuery({ code: 'afterSale_status' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `statusList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `statusList`, res.data);
     },
   },
   computed: {

+ 3 - 9
src/views/platmanag/storeAcc/detail.vue

@@ -77,9 +77,7 @@ export default {
         { label: '角色', model: 'role', type: 'select' },
         { label: '邮箱', model: 'email' },
       ],
-      rules: {
-        // password: [{ required: true, message: '请输入密码', trigger: 'blur' }],
-      },
+      rules: {},
       form: {},
       roleList: [],
     };
@@ -120,9 +118,7 @@ export default {
         let data = res.data;
         this.$set(this, `form`, data);
         this.view = 'info';
-      } else {
-        this.$message.error('未找到指定数据');
-      }
+      } else this.$message.error('未找到指定数据');
     },
     // 重置密码
     async toReset({ data }) {
@@ -159,9 +155,7 @@ export default {
     // 查询其他信息
     async searchOthers() {
       let res = await this.roleQuery();
-      if (this.$checkRes(res)) {
-        this.$set(this, `roleList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `roleList`, res.data);
     },
     // 返回
     toBack() {

+ 2 - 6
src/views/platmanag/storeAcc/index.vue

@@ -119,9 +119,7 @@ export default {
         let data = res.data;
         this.$set(this, `form`, data);
         this.view = 'info';
-      } else {
-        this.$message.error('未找到指定数据');
-      }
+      } else this.$message.error('未找到指定数据');
     },
     // 删除
     async toDel({ data }) {
@@ -146,9 +144,7 @@ export default {
     async searchOthers() {
       let res;
       res = await this.getDict({ code: 'shop_status' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `statusList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `statusList`, res.data);
     },
     toBackList() {
       this.view = 'list';

+ 2 - 6
src/views/platmanag/user/index.vue

@@ -143,14 +143,10 @@ export default {
       let res;
       // 性别
       res = await this.dictQuery({ code: 'gender' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `genderList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `genderList`, res.data);
       // 用户状态
       res = await this.dictQuery({ code: 'user_status' });
-      if (this.$checkRes(res)) {
-        this.$set(this, `useList`, res.data);
-      }
+      if (this.$checkRes(res)) this.$set(this, `useList`, res.data);
     },
   },
   computed: {