فهرست منبع

修改提现记录

silent 4 سال پیش
والد
کامیت
ca507b08ec
3فایلهای تغییر یافته به همراه105 افزوده شده و 5 حذف شده
  1. 103 3
      src/views/ldt_bills/bills.vue
  2. 1 1
      src/views/ldt_bills/platformbills.vue
  3. 1 1
      src/views/ldt_bills/withdrawrec.vue

+ 103 - 3
src/views/ldt_bills/bills.vue

@@ -18,6 +18,34 @@
                @size-change="sizeChange"
                @refresh-change="refreshChange"
                @on-load="onLoad">
+      <template slot-scope="{type,size}" slot="createTimeSearch">
+        <el-radio-group v-model="query.createTime" :size="size" style="float: left">
+          <el-radio-button @click="searchStateChange" :label="-1">全部</el-radio-button>
+          <el-radio-button @click="searchStateChange" :label="1">今天</el-radio-button>
+          <el-radio-button @click="searchStateChange" :label="2">昨天</el-radio-button>
+          <el-radio-button @click="searchStateChange" :label="3">最近七天</el-radio-button>
+          <el-radio-button @click="searchStateChange" :label="4">最近30天</el-radio-button>
+          <el-radio-button @click="searchStateChange" :label="5">本月</el-radio-button>
+          <el-radio-button @click="searchStateChange" :label="6">本年</el-radio-button>
+        </el-radio-group>
+        <avue-date v-model="query.createTimeRange" type="datetimerange" format="yyyy年MM月dd日 hh:mm:ss"
+                   value-format="yyyy-MM-dd hh:mm:ss" placeholder="请选择日期"
+                   :size="size"
+                   @change="searchStateChange"
+                   style="width: 280px;margin-left:5px;float: left"
+                   range-separator="-"
+                   start-placeholder="开始日期"
+                   end-placeholder="结束日期"></avue-date>
+      </template>
+      <template slot-scope="{type,size}" slot="keySearch">
+        <el-input type="text" placeholder="订单ID" v-model="query.key" :size="size"
+                  style="width: 300px;margin: 1px 5px 1px 0;">
+          <el-button type="primary" :size="size" icon="el-icon-search" slot="append"
+                     @click="searchStateChange"></el-button>
+        </el-input>
+        <el-button type="primary" :size="size" icon="el-icon-top" @click="generateListAndDownload">生成列表</el-button>
+        <!--        <el-button type="primary" :size="size">导出已生成列表</el-button>-->
+      </template>
       <template slot="menuLeft">
         <span style="font-family: '宋体'">
           用户付款总额:
@@ -54,12 +82,17 @@
 <script>
   import {getList, censusPrice, getDetail, add, update, remove} from "@/api/ldt_bills/bills";
   import {mapGetters} from "vuex";
+  import moment from "_moment@2.29.1@moment";
+  import FileUtil from "@/util/fileUtil";
 
   export default {
     data() {
       return {
         form: {},
-        query: {},
+        query: {
+          createTime: -1,
+          createTimeRange: [],
+        },
         loading: true,
         censusPrice:{},
         page: {
@@ -81,6 +114,8 @@
           editBtn:false,
           viewBtn: true,
           selection: true,
+          searchBtn: false,
+          emptyBtn: false,
           dialogClickModal: false,
           column: [
             {
@@ -167,7 +202,6 @@
             },
             {
               label: "交易类型",
-              search: true,
               prop: "type",
               type: "select",
               dicData:[{
@@ -220,7 +254,6 @@
             },
             {
               label: "支付状态",
-              search: true,
               prop: "payStatus",
               type: "select",
               dicData:[{
@@ -347,12 +380,25 @@
               addDisplay: false,
               editDisplay: false,
               search: true,
+              searchSpan: 24,
+              searchOrder: 0,
+              searchslot: true,
               rules: [{
                 required: true,
                 message: "请输入通知时间",
                 trigger: "blur"
               }]
             },
+            {
+              label: "关键字",
+              prop: "key",
+              hide: true,
+              search: true,
+              searchslot: true,
+              searchOrder: 1,
+              searchSpan: 24,
+              editDisplay: false,
+            },
           ]
         },
         data: []
@@ -376,6 +422,60 @@
         return ids.join(",");
       }
     },
+    watch: {
+      //监听创建时间变化
+      "query.createTime": {
+        handler(value) {
+          //防止重复调用
+          if (value !== undefined) {
+            this.query.createTimeRange = [];
+            switch (value) {
+              case -1:
+                this.query.createTimeStart = undefined;
+                this.query.createTimeEnd = undefined;
+                break;
+              case 1: //今天
+                this.query.createTimeStart = moment().format("yyyy-MM-DD 00:00:00");
+                this.query.createTimeEnd = moment().format("yyyy-MM-DD HH:mm:ss");
+                break;
+              case 2: //昨天
+                this.query.createTimeStart = moment().subtract(1, 'days').format("yyyy-MM-DD 00:00:00");
+                this.query.createTimeEnd = moment().subtract(1, 'days').format("yyyy-MM-DD 23:59:59");
+                break;
+              case 3: //近7天
+                this.query.createTimeStart = moment().subtract(7, 'days').format("yyyy-MM-DD HH:mm:ss");
+                this.query.createTimeEnd = moment().format("yyyy-MM-DD HH:mm:ss");
+                break;
+              case 4: //近30天
+                this.query.createTimeStart = moment().subtract(30, 'days').format("yyyy-MM-DD HH:mm:ss");
+                this.query.createTimeEnd = moment().format("yyyy-MM-DD HH:mm:ss");
+                break;
+              case 5: //本月
+                this.query.createTimeStart = moment().format("yyyy-MM-01 00:00:00");
+                this.query.createTimeEnd = moment().format(`yyyy-MM-DD HH:mm:ss`);
+                break;
+              case 6: //本年
+                this.query.createTimeStart = moment().format("yyyy-01-01 00:00:00");
+                this.query.createTimeEnd = moment().format(`yyyy-MM-DD HH:mm:ss`);
+                break;
+              default:
+                break;
+            }
+          }
+        }
+      },
+      //监听创建时间变化
+      "query.createTimeRange": {
+        handler(value) {
+          //防止重复调用
+          if (value.length === 2) {
+            this.query.createTimeStart = value[0];
+            this.query.createTimeEnd = value[1];
+            this.query.createTime = undefined;
+          }
+        }
+      },
+    },
     created() {
       this.getCensusPrice();
     },

+ 1 - 1
src/views/ldt_bills/platformbills.vue

@@ -75,7 +75,7 @@
   import {getList, generateList, censusPrice, getDetail, add, update, remove} from "@/api/ldt_bills/platformbills";
   import {mapGetters} from "vuex";
   import moment from "_moment@2.29.1@moment";
-  import FileUtil from "@/util/fileUtil"
+  import FileUtil from "@/util/fileUtil";
 
   export default {
     data() {

+ 1 - 1
src/views/ldt_bills/withdrawrec.vue

@@ -93,7 +93,7 @@
 import moment from "moment";
 import {add, censusPrice, generateList, getDetail, getList, remove, update} from "@/api/ldt_bills/withdrawrec";
 import {mapGetters} from "vuex";
-import FileUtil from "@/util/fileUtil"
+import FileUtil from "@/util/fileUtil";
 
 export default {
   data() {