YY 2 lat temu
rodzic
commit
8e40dcda61

+ 0 - 6
src/layout/data/menu.js

@@ -70,12 +70,6 @@ export const adminMenu = [
         name: '订单管理',
         name: '订单管理',
         index: '3-3',
         index: '3-3',
       },
       },
-      {
-        icon: 'icon-rencai',
-        path: '/selfShop/coupon',
-        name: '优惠券管理',
-        index: '3-4',
-      },
       {
       {
         icon: 'icon-rencai',
         icon: 'icon-rencai',
         path: '/selfShop/sales',
         path: '/selfShop/sales',

+ 0 - 6
src/router/module/selfShop.js

@@ -29,12 +29,6 @@ export default [
     meta: { title: '自营店铺-订单管理-详细信息' },
     meta: { title: '自营店铺-订单管理-详细信息' },
     component: () => import(/* webpackChunkName: "selfShop_order_detail_orderDetail" */ '@/views/selfShop/order/detail_orderDetail.vue'),
     component: () => import(/* webpackChunkName: "selfShop_order_detail_orderDetail" */ '@/views/selfShop/order/detail_orderDetail.vue'),
   },
   },
-  {
-    path: '/selfShop/coupon',
-    name: 'selfShop_coupon',
-    meta: { title: '自营店铺-优惠券管理' },
-    component: () => import(/* webpackChunkName: "selfShop_coupon" */ '@/views/selfShop/coupon/index.vue'),
-  },
   {
   {
     path: '/selfShop/spec/:id',
     path: '/selfShop/spec/:id',
     name: 'selfShop_spec',
     name: 'selfShop_spec',

+ 0 - 27
src/views/selfShop/coupon/index.vue

@@ -1,27 +0,0 @@
-<template>
-  <div id="index">
-    <p>coupon</p>
-  </div>
-</template>
-
-<script>
-import { mapState, createNamespacedHelpers } from 'vuex';
-export default {
-  name: 'index',
-  props: {},
-  components: {},
-  data: function () {
-    return {};
-  },
-  computed: {
-    ...mapState(['user']),
-  },
-  created() {},
-  methods: {},
-  metaInfo() {
-    return { title: this.$route.meta.title };
-  },
-};
-</script>
-
-<style lang="less" scoped></style>

+ 7 - 7
src/views/system/coupon/detail.vue

@@ -205,13 +205,13 @@ export default {
         let res = await this.fetch(this.id);
         let res = await this.fetch(this.id);
         if (this.$checkRes(res)) {
         if (this.$checkRes(res)) {
           let data = res.data;
           let data = res.data;
-          if (data.get_limit_config.max) data.get_limit_max = data.get_limit_config.max;
-          if (data.discount_config.max) data.discount_type_max = data.discount_config.max;
-          if (data.discount_config.limit) data.limit = data.discount_config.limit;
-          if (data.discount_config.min) data.min = data.discount_config.min;
-          if (data.use_limit_config.tags) data.tags = data.use_limit_config.tags;
-          if (data.expire_config.fixed[0]) data.time = data.expire_config.fixed[0];
-          if (data.expire_config.days) data.days = data.expire_config.days;
+          data.get_limit_max = _.get(data, 'get_limit_config.max');
+          data.discount_type_max = _.get(data, 'discount_config.max');
+          data.limit = _.get(data, 'discount_config.limit');
+          data.min = _.get(data, 'discount_config.min');
+          data.tags = _.get(data, 'use_limit_config.tags');
+          data.time = _.get(data, 'expire_config.fixed[0]');
+          data.days = _.get(data, 'expire_config.days');
           if (data.shop) {
           if (data.shop) {
             let res = await this.shopFetch(data.shop);
             let res = await this.shopFetch(data.shop);
             if (this.$checkRes(res)) {
             if (this.$checkRes(res)) {