update:
1. fix log module
This commit is contained in:
@@ -6,6 +6,7 @@ export default {
|
||||
searchMenuSpan: 6,
|
||||
border: true,
|
||||
index: true,
|
||||
menu: false,
|
||||
viewBtn: true,
|
||||
delBtn: false,
|
||||
addBtn: false,
|
||||
@@ -49,18 +50,21 @@ export default {
|
||||
label: '业务类型',
|
||||
prop: 'sourceType',
|
||||
type: 'input',
|
||||
hide: true,
|
||||
},
|
||||
{
|
||||
label: '来源id',
|
||||
prop: 'sourceId',
|
||||
type: 'input',
|
||||
overHidden: true,
|
||||
hide: true,
|
||||
},
|
||||
{
|
||||
label: '来源详情',
|
||||
prop: 'sourceDetail',
|
||||
type: 'input',
|
||||
overHidden: true,
|
||||
hide: true,
|
||||
},
|
||||
{
|
||||
label: '收入/支出',
|
||||
|
||||
@@ -11,6 +11,7 @@ export default {
|
||||
addBtn: false,
|
||||
editBtn: false,
|
||||
selection: false,
|
||||
menu: false,
|
||||
dialogClickModal: false,
|
||||
column: [
|
||||
{
|
||||
@@ -56,18 +57,21 @@ export default {
|
||||
label: '业务类型',
|
||||
prop: 'sourceType',
|
||||
type: 'input',
|
||||
hide: true,
|
||||
},
|
||||
{
|
||||
label: '来源id',
|
||||
prop: 'sourceId',
|
||||
type: 'input',
|
||||
overHidden: true,
|
||||
hide: true,
|
||||
},
|
||||
{
|
||||
label: '来源详情',
|
||||
prop: 'sourceDetail',
|
||||
type: 'input',
|
||||
overHidden: true,
|
||||
hide: true,
|
||||
},
|
||||
{
|
||||
label: '收入/支出',
|
||||
|
||||
@@ -6,6 +6,7 @@ export default {
|
||||
searchMenuSpan: 6,
|
||||
border: true,
|
||||
index: true,
|
||||
menu: false,
|
||||
viewBtn: true,
|
||||
delBtn: false,
|
||||
addBtn: false,
|
||||
@@ -49,6 +50,7 @@ export default {
|
||||
label: '业务类型',
|
||||
prop: 'sourceType',
|
||||
type: 'input',
|
||||
hide: true,
|
||||
},
|
||||
|
||||
{
|
||||
@@ -56,12 +58,14 @@ export default {
|
||||
prop: 'sourceId',
|
||||
type: 'input',
|
||||
overHidden: true,
|
||||
hide: true,
|
||||
},
|
||||
{
|
||||
label: '来源详情',
|
||||
prop: 'sourceDetail',
|
||||
type: 'input',
|
||||
overHidden: true,
|
||||
hide: true,
|
||||
},
|
||||
{
|
||||
label: '收入/支出',
|
||||
|
||||
@@ -56,18 +56,21 @@ export default {
|
||||
label: '业务类型',
|
||||
prop: 'sourceType',
|
||||
type: 'input',
|
||||
hide: true,
|
||||
},
|
||||
{
|
||||
label: '来源id',
|
||||
prop: 'sourceId',
|
||||
type: 'input',
|
||||
overHidden: true,
|
||||
hide: true,
|
||||
},
|
||||
{
|
||||
label: '来源详情',
|
||||
prop: 'sourceDetail',
|
||||
type: 'input',
|
||||
overHidden: true,
|
||||
hide: true,
|
||||
},
|
||||
{
|
||||
label: '收入/支出',
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
<template>
|
||||
<basic-container>
|
||||
<avue-crud
|
||||
:option="option"
|
||||
v-model:search="search"
|
||||
v-model:page="page"
|
||||
v-model="form"
|
||||
:table-loading="loading"
|
||||
:data="data"
|
||||
:permission="permissionList"
|
||||
:before-open="beforeOpen"
|
||||
ref="crud"
|
||||
@row-update="rowUpdate"
|
||||
@row-save="rowSave"
|
||||
@row-del="rowDel"
|
||||
@search-change="searchChange"
|
||||
@search-reset="searchReset"
|
||||
@selection-change="selectionChange"
|
||||
@current-change="currentChange"
|
||||
@size-change="sizeChange"
|
||||
@refresh-change="refreshChange"
|
||||
@on-load="onLoad"
|
||||
:option="option"
|
||||
v-model:search="search"
|
||||
v-model:page="page"
|
||||
v-model="form"
|
||||
:table-loading="loading"
|
||||
:data="data"
|
||||
:permission="permissionList"
|
||||
:before-open="beforeOpen"
|
||||
ref="crud"
|
||||
@row-update="rowUpdate"
|
||||
@row-save="rowSave"
|
||||
@row-del="rowDel"
|
||||
@search-change="searchChange"
|
||||
@search-reset="searchReset"
|
||||
@selection-change="selectionChange"
|
||||
@current-change="currentChange"
|
||||
@size-change="sizeChange"
|
||||
@refresh-change="refreshChange"
|
||||
@on-load="onLoad"
|
||||
>
|
||||
<template #menu-left>
|
||||
<!-- <el-button type="danger"-->
|
||||
@@ -45,11 +45,11 @@
|
||||
|
||||
<el-dialog :title="`导出用户积分流水`" append-to-body v-model="exportFlowBox" width="1000px">
|
||||
<avue-form
|
||||
:option="exportFlowOption"
|
||||
:data="exportFlowData"
|
||||
v-model="exportFlowFrom"
|
||||
@submit="exportFlowSubmit"
|
||||
ref="stateCrud"
|
||||
:option="exportFlowOption"
|
||||
:data="exportFlowData"
|
||||
v-model="exportFlowFrom"
|
||||
@submit="exportFlowSubmit"
|
||||
ref="stateCrud"
|
||||
/>
|
||||
</el-dialog>
|
||||
|
||||
@@ -57,13 +57,13 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { getList, getDetail, add, update, remove } from '@/api/common/commonUserPointLog';
|
||||
import {getList, getDetail, add, update, remove} from '@/api/common/commonUserPointLog';
|
||||
import option from '@/option/common/commonUserPointLog';
|
||||
import { mapGetters } from 'vuex';
|
||||
import { exportBlob } from '@/api/common';
|
||||
import { getToken } from '@/utils/auth';
|
||||
import { downloadXls } from '@/utils/util';
|
||||
import { dateNow } from '@/utils/date';
|
||||
import {mapGetters} from 'vuex';
|
||||
import {exportBlob} from '@/api/common';
|
||||
import {getToken} from '@/utils/auth';
|
||||
import {downloadXls} from '@/utils/util';
|
||||
import {dateNow} from '@/utils/date';
|
||||
import NProgress from 'nprogress';
|
||||
import 'nprogress/nprogress.css';
|
||||
|
||||
@@ -91,14 +91,6 @@ export default {
|
||||
menu: false,
|
||||
labelWidth: 200,
|
||||
column: [
|
||||
{
|
||||
label: '账号',
|
||||
prop: 'account',
|
||||
type: 'input',
|
||||
rules: [
|
||||
{ required: true, message: "账号不能为空", trigger: "blur" }
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "时间范围",
|
||||
prop: "searchDateRange", // 关键点:这个prop将绑定一个数组
|
||||
@@ -107,9 +99,15 @@ export default {
|
||||
valueFormat: 'YYYY-MM-DD hh:mm:ss',
|
||||
searchRange: true,
|
||||
rules: [
|
||||
{ required: true, message: "时间范围不能为空", trigger: "blur" }
|
||||
{required: true, message: "时间范围不能为空", trigger: "blur"}
|
||||
],
|
||||
|
||||
span: 24
|
||||
},
|
||||
{
|
||||
label: '账号',
|
||||
prop: 'account',
|
||||
type: 'input',
|
||||
span: 24
|
||||
},
|
||||
],
|
||||
},
|
||||
@@ -139,34 +137,34 @@ export default {
|
||||
methods: {
|
||||
rowSave(row, done, loading) {
|
||||
add(row).then(
|
||||
() => {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
});
|
||||
done();
|
||||
},
|
||||
error => {
|
||||
loading();
|
||||
window.console.log(error);
|
||||
}
|
||||
() => {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
});
|
||||
done();
|
||||
},
|
||||
error => {
|
||||
loading();
|
||||
window.console.log(error);
|
||||
}
|
||||
);
|
||||
},
|
||||
rowUpdate(row, index, done, loading) {
|
||||
update(row).then(
|
||||
() => {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
});
|
||||
done();
|
||||
},
|
||||
error => {
|
||||
loading();
|
||||
console.log(error);
|
||||
}
|
||||
() => {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
});
|
||||
done();
|
||||
},
|
||||
error => {
|
||||
loading();
|
||||
console.log(error);
|
||||
}
|
||||
);
|
||||
},
|
||||
rowDel(row) {
|
||||
@@ -175,16 +173,16 @@ export default {
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
})
|
||||
.then(() => {
|
||||
return remove(row.id);
|
||||
})
|
||||
.then(() => {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
.then(() => {
|
||||
return remove(row.id);
|
||||
})
|
||||
.then(() => {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
});
|
||||
});
|
||||
});
|
||||
},
|
||||
handleDelete() {
|
||||
if (this.selectionList.length === 0) {
|
||||
@@ -196,21 +194,21 @@ export default {
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
})
|
||||
.then(() => {
|
||||
return remove(this.ids);
|
||||
})
|
||||
.then(() => {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
.then(() => {
|
||||
return remove(this.ids);
|
||||
})
|
||||
.then(() => {
|
||||
this.onLoad(this.page);
|
||||
this.$message({
|
||||
type: 'success',
|
||||
message: '操作成功!',
|
||||
});
|
||||
this.$refs.crud.toggleSelection();
|
||||
});
|
||||
this.$refs.crud.toggleSelection();
|
||||
});
|
||||
},
|
||||
handleExport() {
|
||||
let downloadUrl = `//common/user-point-log/commonUserPointLog/export-commonUserPointLog?${
|
||||
this.website.tokenHeader
|
||||
let downloadUrl = `/common/user-point-log/commonUserPointLog/export-commonUserPointLog?${
|
||||
this.website.tokenHeader
|
||||
}=${getToken()}`;
|
||||
const {} = this.query;
|
||||
let values = {};
|
||||
@@ -278,16 +276,16 @@ export default {
|
||||
});
|
||||
},
|
||||
|
||||
openExportBox(){
|
||||
openExportBox() {
|
||||
this.exportFlowBox = true;
|
||||
},
|
||||
|
||||
exportFlowSubmit(form, done){
|
||||
exportFlowSubmit(form, done) {
|
||||
NProgress.start();
|
||||
exportBlob(
|
||||
`/common/user-point-log/exportFlowToExcel?${
|
||||
this.website.tokenHeader
|
||||
}=${getToken()}&account=${form.account}&searchDateRange=${form.searchDateRange}`
|
||||
`/common/user-point-log/export?${
|
||||
this.website.tokenHeader
|
||||
}=${getToken()}&account=${form.account}&searchDateRange=${form.searchDateRange}`
|
||||
).then(res => {
|
||||
downloadXls(res.data, `用户积分流水表${this.$dayjs().format('YYYY-MM-DD')}.xlsx`);
|
||||
NProgress.done();
|
||||
|
||||
@@ -91,14 +91,6 @@ export default {
|
||||
menu: false,
|
||||
labelWidth: 200,
|
||||
column: [
|
||||
{
|
||||
label: '账号',
|
||||
prop: 'account',
|
||||
type: 'input',
|
||||
rules: [
|
||||
{ required: true, message: "账号不能为空", trigger: "blur" }
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "时间范围",
|
||||
prop: "searchDateRange", // 关键点:这个prop将绑定一个数组
|
||||
@@ -109,7 +101,13 @@ export default {
|
||||
rules: [
|
||||
{ required: true, message: "时间范围不能为空", trigger: "blur" }
|
||||
],
|
||||
|
||||
span: 24
|
||||
},
|
||||
{
|
||||
label: '账号',
|
||||
prop: 'account',
|
||||
type: 'input',
|
||||
span: 24
|
||||
},
|
||||
],
|
||||
},
|
||||
@@ -285,7 +283,7 @@ export default {
|
||||
exportFlowSubmit(form, done){
|
||||
NProgress.start();
|
||||
exportBlob(
|
||||
`/market/benefit-point-log/exportFlowToExcel?${
|
||||
`/market/benefit-point-log/export?${
|
||||
this.website.tokenHeader
|
||||
}=${getToken()}&account=${form.account}&searchDateRange=${form.searchDateRange}`
|
||||
).then(res => {
|
||||
|
||||
@@ -90,14 +90,6 @@ export default {
|
||||
menu: false,
|
||||
labelWidth: 200,
|
||||
column: [
|
||||
{
|
||||
label: '账户',
|
||||
prop: 'account',
|
||||
type: 'input',
|
||||
rules: [
|
||||
{ required: true, message: "账号不能为空", trigger: "blur" }
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "时间范围",
|
||||
prop: "searchDateRange", // 关键点:这个prop将绑定一个数组
|
||||
@@ -106,9 +98,15 @@ export default {
|
||||
valueFormat: 'YYYY-MM-DD hh:mm:ss',
|
||||
searchRange: true,
|
||||
rules: [
|
||||
{ required: true, message: "时间范围不能为空", trigger: "blur" }
|
||||
{required: true, message: "时间范围不能为空", trigger: "blur"}
|
||||
],
|
||||
|
||||
span: 24
|
||||
},
|
||||
{
|
||||
label: '账号',
|
||||
prop: 'account',
|
||||
type: 'input',
|
||||
span: 24
|
||||
},
|
||||
],
|
||||
},
|
||||
@@ -208,7 +206,7 @@ export default {
|
||||
});
|
||||
},
|
||||
handleExport() {
|
||||
let downloadUrl = `//common/cash-coupon-log/commonCashCouponLog/export-commonCashCouponLog?${
|
||||
let downloadUrl = `/common/cash-coupon-log/commonCashCouponLog/export?${
|
||||
this.website.tokenHeader
|
||||
}=${getToken()}`;
|
||||
const {} = this.query;
|
||||
@@ -285,7 +283,7 @@ export default {
|
||||
|
||||
NProgress.start();
|
||||
exportBlob(
|
||||
`/market/cash-coupon-log/exportFlowToExcel?${
|
||||
`/market/cash-coupon-log/export?${
|
||||
this.website.tokenHeader
|
||||
}=${getToken()}&account=${form.account}&searchDateRange=${form.searchDateRange}`
|
||||
).then(res => {
|
||||
|
||||
@@ -91,14 +91,6 @@ export default {
|
||||
menu: false,
|
||||
labelWidth: 200,
|
||||
column: [
|
||||
{
|
||||
label: '账号',
|
||||
prop: 'account',
|
||||
type: 'input',
|
||||
rules: [
|
||||
{ required: true, message: "账号不能为空", trigger: "blur" }
|
||||
],
|
||||
},
|
||||
{
|
||||
label: "时间范围",
|
||||
prop: "searchDateRange", // 关键点:这个prop将绑定一个数组
|
||||
@@ -107,9 +99,15 @@ export default {
|
||||
valueFormat: 'YYYY-MM-DD hh:mm:ss',
|
||||
searchRange: true,
|
||||
rules: [
|
||||
{ required: true, message: "时间范围不能为空", trigger: "blur" }
|
||||
{required: true, message: "时间范围不能为空", trigger: "blur"}
|
||||
],
|
||||
|
||||
span: 24
|
||||
},
|
||||
{
|
||||
label: '账号',
|
||||
prop: 'account',
|
||||
type: 'input',
|
||||
span: 24
|
||||
},
|
||||
],
|
||||
},
|
||||
@@ -285,7 +283,7 @@ export default {
|
||||
exportFlowSubmit(form, done){
|
||||
NProgress.start();
|
||||
exportBlob(
|
||||
`/market/benefit-commission-log/exportFlowToExcel?${
|
||||
`/market/benefit-commission-log/export?${
|
||||
this.website.tokenHeader
|
||||
}=${getToken()}&account=${form.account}&searchDateRange=${form.searchDateRange}`
|
||||
).then(res => {
|
||||
|
||||
Reference in New Issue
Block a user