Przeglądaj źródła

时间充值活动

lex-xin 4 lat temu
rodzic
commit
bcf4eb81d2

+ 3 - 1
src/router/notKeepAliveList.js

@@ -45,5 +45,7 @@ export default [
   '/insideSetting/editionList', // 版本控制
   '/insideSetting/adapayManager', // 汇仁账号管理
   '/insideSetting/adapayOperation', //
-  '/operateManager/stuRecodeManager'
+  '/operateManager/stuRecodeManager',
+  '/insideSetting/entryActivities', // 时间充值活动
+  '/insideSetting/entryOperation',
 ]

+ 14 - 6
src/views/app/entryActivities.vue

@@ -7,8 +7,9 @@
       <div @click="onChargeOperation('create')"
            v-permission="'/entryOperation'"
            class='newBand'>添加</div>
-      <el-form :inline="true"
-               :model="searchForm">
+      <save-form :inline="true"
+               :model="searchForm"
+               @submit="search">
         <!-- <el-form-item>
           <el-select placeholder="请选择适用范围">
             <el-option value="NEW" label="新用户"></el-option>
@@ -26,10 +27,9 @@
           </el-select>
         </el-form-item>
         <el-form-item>
-          <el-button type="danger"
-                     @click="getList">搜索</el-button>
+          <el-button type="danger" native-type="submit">搜索</el-button>
         </el-form-item>
-      </el-form>
+      </save-form>
       <div class="tableWrap">
         <el-table :data="dataList"
                   :header-cell-style="{background:'#EDEEF0',color:'#444'}">
@@ -89,7 +89,7 @@
             </template>
           </el-table-column>
         </el-table>
-        <pagination :total="pageInfo.total"
+        <pagination sync :total.sync="pageInfo.total"
                     :page.sync="pageInfo.page"
                     :limit.sync="pageInfo.limit"
                     :page-sizes="pageInfo.page_size"
@@ -128,6 +128,10 @@ export default {
     this.getList()
   },
   methods: {
+    search() {
+      this.pageInfo.page = 1
+      this.getList()
+    },
     messageTips (title, res) {
       if (res.code == 200) {
         this.$message.success(title + '成功')
@@ -157,6 +161,8 @@ export default {
           query: {
             type: 'create'
           }
+        }, (route) => {
+          route.meta.title = '添加活动充值活动'
         })
       } else if (type == 'look') {
         this.$router.push({
@@ -165,6 +171,8 @@ export default {
             id: row.id,
             type: 'look'
           }
+        }, (route) => {
+          route.meta.title = '查看活动充值活动'
         })
       }
     },

+ 0 - 20
src/views/app/entryOperation.vue

@@ -277,26 +277,6 @@ export default {
   mounted () {
     this.init();
   },
-  activated () {
-    if (this.$route.query.type == "create") {
-      this.form = {
-        name: null,
-        suitableUser: null,
-        date: null,
-        startDate: null,
-        endDate: null,
-        totalPrice: null,
-        discountPrice: null,
-        purchaseMinutes: null,
-        giveMinutes: null,
-        coverImg: null,
-        detail: null
-      }
-      this.$refs["form"].resetFields();
-    }
-    this.pageType = this.$route.query.type;
-    this.init();
-  },
   methods: {
     init () {
       this.getList();