Browse Source

详情

main
niefei 11 months ago
parent
commit
0ca552ece7
  1. 485
      src/views/business/commonFeedback/index.vue
  2. 610
      src/views/business/commonInfo/index.vue
  3. 473
      src/views/business/commonNotify/index.vue
  4. 551
      src/views/business/dealCashout/index.vue
  5. 573
      src/views/business/dealPay/index.vue
  6. 541
      src/views/business/dealReceive/index.vue
  7. 553
      src/views/business/dealTransfer/index.vue
  8. 580
      src/views/business/recordTransaction/index.vue
  9. 517
      src/views/business/userAccount/index.vue
  10. 532
      src/views/business/userCard/index.vue
  11. 456
      src/views/business/userFriend/index.vue
  12. 537
      src/views/business/userInfo/index.vue
  13. 496
      src/views/business/userPasswd/index.vue
  14. 524
      src/views/business/userRegister/index.vue

485
src/views/business/commonFeedback/index.vue

@ -2,40 +2,19 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="反馈人" prop="userId">
<el-input
v-model="queryParams.userId"
placeholder="请输入反馈人"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userId" placeholder="请输入反馈人" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="星级" prop="star">
<el-input
v-model="queryParams.star"
placeholder="请输入星级"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.star" placeholder="请输入星级" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="是否正向(0正向,1负向)" prop="isGood">
<el-input
v-model="queryParams.isGood"
placeholder="请输入是否正向(0正向,1负向)"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.isGood" placeholder="请输入是否正向(0正向,1负向)" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -45,53 +24,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:commonFeedback:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:commonFeedback:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:commonFeedback:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:commonFeedback:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:commonFeedback:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:commonFeedback:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:commonFeedback:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:commonFeedback:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="commonFeedbackList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="反馈人" align="center" prop="userId" />
<el-table-column label="反馈内容" align="center" prop="content" />
<el-table-column label="星级" align="center" prop="star" />
@ -102,33 +55,19 @@
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:commonFeedback:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:commonFeedback:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:commonFeedback:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:commonFeedback:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改反馈信息对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -137,7 +76,7 @@
<el-input v-model="form.userId" placeholder="请输入反馈人" />
</el-form-item>
<el-form-item label="反馈内容">
<editor v-model="form.content" :min-height="192"/>
<editor v-model="form.content" :min-height="192" />
</el-form-item>
<el-form-item label="星级" prop="star">
<el-input v-model="form.star" placeholder="请输入星级" />
@ -151,183 +90,223 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 反馈信息详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="反馈人:">
{{form.userId}}
</el-form-item>
<el-form-item label="反馈内容">
<editor v-model="form.content" :min-height="192" />
</el-form-item>
<el-form-item label="星级:">
{{form.star}}
</el-form-item>
<el-form-item label="是否正向(0正向,1负向):">
{{form.isGood}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listCommonFeedback, getCommonFeedback, delCommonFeedback, addCommonFeedback, updateCommonFeedback } from "@/api/business/commonFeedback";
import {
listCommonFeedback,
getCommonFeedback,
delCommonFeedback,
addCommonFeedback,
updateCommonFeedback
} from "@/api/business/commonFeedback";
export default {
name: "CommonFeedback",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
commonFeedbackList: [],
//
title: "",
//
open: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
content: undefined,
star: undefined,
isGood: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
userId: [
{ required: true, message: "反馈人不能为空", trigger: "blur" }
],
content: [
{ required: true, message: "反馈内容不能为空", trigger: "blur" }
],
}
};
},
created() {
this.getList();
},
methods: {
/** 查询反馈信息列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listCommonFeedback(this.queryParams).then(response => {
this.commonFeedbackList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
content: undefined,
star: undefined,
isGood: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "CommonFeedback",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
commonFeedbackList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
content: undefined,
star: undefined,
isGood: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
userId: [{
required: true,
message: "反馈人不能为空",
trigger: "blur"
}],
content: [{
required: true,
message: "反馈内容不能为空",
trigger: "blur"
}],
}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加反馈信息";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getCommonFeedback(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改反馈信息";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateCommonFeedback(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addCommonFeedback(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除反馈信息编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询反馈信息列表 */
getList() {
this.loading = true;
return delCommonFeedback(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listCommonFeedback(this.queryParams).then(response => {
this.commonFeedbackList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
content: undefined,
star: undefined,
isGood: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/commonFeedback/export', {
...this.queryParams
}, `commonFeedback_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加反馈信息";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "反馈信息";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getCommonFeedback(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改反馈信息";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateCommonFeedback(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addCommonFeedback(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除反馈信息编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delCommonFeedback(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/commonFeedback/export', {
...this.queryParams
}, `commonFeedback_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

610
src/views/business/commonInfo/index.vue

@ -2,108 +2,49 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="版本号" prop="version">
<el-input
v-model="queryParams.version"
placeholder="请输入版本号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.version" placeholder="请输入版本号" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="发版日期">
<el-date-picker
v-model="daterangeReleaseDate"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeReleaseDate" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item label="隐私政策" prop="privacyPolicy">
<el-input
v-model="queryParams.privacyPolicy"
placeholder="请输入隐私政策"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.privacyPolicy" placeholder="请输入隐私政策" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="隐私设置" prop="privacySetting">
<el-input
v-model="queryParams.privacySetting"
placeholder="请输入隐私设置"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.privacySetting" placeholder="请输入隐私设置" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="功能说明" prop="featureDesc">
<el-input
v-model="queryParams.featureDesc"
placeholder="请输入功能说明"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.featureDesc" placeholder="请输入功能说明" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="技术说明" prop="techDesc">
<el-input
v-model="queryParams.techDesc"
placeholder="请输入技术说明"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.techDesc" placeholder="请输入技术说明" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="用户协议" prop="userAgreement">
<el-input
v-model="queryParams.userAgreement"
placeholder="请输入用户协议"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userAgreement" placeholder="请输入用户协议" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="免责声明" prop="disclaimer">
<el-input
v-model="queryParams.disclaimer"
placeholder="请输入免责声明"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.disclaimer" placeholder="请输入免责声明" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="关于我们" prop="about">
<el-input
v-model="queryParams.about"
placeholder="请输入关于我们"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.about" placeholder="请输入关于我们" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="个人信息共享清单" prop="shareInfoList">
<el-input
v-model="queryParams.shareInfoList"
placeholder="请输入个人信息共享清单"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.shareInfoList" placeholder="请输入个人信息共享清单" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="个人信息已收集清单" prop="collectInfoList">
<el-input
v-model="queryParams.collectInfoList"
placeholder="请输入个人信息已收集清单"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.collectInfoList" placeholder="请输入个人信息已收集清单" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -113,53 +54,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:commonInfo:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:commonInfo:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:commonInfo:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:commonInfo:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:commonInfo:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:commonInfo:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:commonInfo:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:commonInfo:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="commonInfoList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="版本号" align="center" prop="version" />
<el-table-column label="发版日期" align="center" prop="releaseDate" width="180">
<template slot-scope="scope">
@ -181,33 +96,19 @@
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:commonInfo:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:commonInfo:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:commonInfo:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:commonInfo:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改关于信息对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -216,10 +117,7 @@
<el-input v-model="form.version" placeholder="请输入版本号" />
</el-form-item>
<el-form-item label="发版日期" prop="releaseDate">
<el-date-picker clearable
v-model="form.releaseDate"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
<el-date-picker clearable v-model="form.releaseDate" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择发版日期">
</el-date-picker>
</el-form-item>
@ -256,198 +154,264 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 关于信息详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="版本号:">
{{form.version}}
</el-form-item>
<el-form-item label="发版日期">
<el-date-picker clearable v-model="form.releaseDate" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择发版日期">
</el-date-picker>
</el-form-item>
<el-form-item label="隐私政策:">
{{form.privacyPolicy}}
</el-form-item>
<el-form-item label="隐私设置:">
{{form.privacySetting}}
</el-form-item>
<el-form-item label="功能说明:">
{{form.featureDesc}}
</el-form-item>
<el-form-item label="技术说明:">
{{form.techDesc}}
</el-form-item>
<el-form-item label="用户协议:">
{{form.userAgreement}}
</el-form-item>
<el-form-item label="免责声明:">
{{form.disclaimer}}
</el-form-item>
<el-form-item label="关于我们:">
{{form.about}}
</el-form-item>
<el-form-item label="个人信息共享清单:">
{{form.shareInfoList}}
</el-form-item>
<el-form-item label="个人信息已收集清单:">
{{form.collectInfoList}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listCommonInfo, getCommonInfo, delCommonInfo, addCommonInfo, updateCommonInfo } from "@/api/business/commonInfo";
import {
listCommonInfo,
getCommonInfo,
delCommonInfo,
addCommonInfo,
updateCommonInfo
} from "@/api/business/commonInfo";
export default {
name: "CommonInfo",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
commonInfoList: [],
//
title: "",
//
open: false,
//
daterangeReleaseDate: [],
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
version: undefined,
releaseDate: undefined,
privacyPolicy: undefined,
privacySetting: undefined,
featureDesc: undefined,
techDesc: undefined,
userAgreement: undefined,
disclaimer: undefined,
about: undefined,
shareInfoList: undefined,
collectInfoList: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询关于信息列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeReleaseDate && '' != this.daterangeReleaseDate) {
this.queryParams.params["beginReleaseDate"] = this.daterangeReleaseDate[0];
this.queryParams.params["endReleaseDate"] = this.daterangeReleaseDate[1];
}
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listCommonInfo(this.queryParams).then(response => {
this.commonInfoList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
version: undefined,
releaseDate: undefined,
privacyPolicy: undefined,
privacySetting: undefined,
featureDesc: undefined,
techDesc: undefined,
userAgreement: undefined,
disclaimer: undefined,
about: undefined,
shareInfoList: undefined,
collectInfoList: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "CommonInfo",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
commonInfoList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeReleaseDate: [],
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
version: undefined,
releaseDate: undefined,
privacyPolicy: undefined,
privacySetting: undefined,
featureDesc: undefined,
techDesc: undefined,
userAgreement: undefined,
disclaimer: undefined,
about: undefined,
shareInfoList: undefined,
collectInfoList: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeReleaseDate = [];
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加关于信息";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getCommonInfo(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改关于信息";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateCommonInfo(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addCommonInfo(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除关于信息编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询关于信息列表 */
getList() {
this.loading = true;
return delCommonInfo(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeReleaseDate && '' != this.daterangeReleaseDate) {
this.queryParams.params["beginReleaseDate"] = this.daterangeReleaseDate[0];
this.queryParams.params["endReleaseDate"] = this.daterangeReleaseDate[1];
}
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listCommonInfo(this.queryParams).then(response => {
this.commonInfoList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
version: undefined,
releaseDate: undefined,
privacyPolicy: undefined,
privacySetting: undefined,
featureDesc: undefined,
techDesc: undefined,
userAgreement: undefined,
disclaimer: undefined,
about: undefined,
shareInfoList: undefined,
collectInfoList: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/commonInfo/export', {
...this.queryParams
}, `commonInfo_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeReleaseDate = [];
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加关于信息";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "关于信息";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getCommonInfo(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改关于信息";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateCommonInfo(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addCommonInfo(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除关于信息编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delCommonInfo(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/commonInfo/export', {
...this.queryParams
}, `commonInfo_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

473
src/views/business/commonNotify/index.vue

@ -2,44 +2,20 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="触发事务ID" prop="eventId">
<el-input
v-model="queryParams.eventId"
placeholder="请输入触发事务ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.eventId" placeholder="请输入触发事务ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="消息场景(支付、提现等)" prop="messageScene">
<el-input
v-model="queryParams.messageScene"
placeholder="请输入消息场景(支付、提现等)"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.messageScene" placeholder="请输入消息场景(支付、提现等)" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="发送者" prop="sender">
<el-input
v-model="queryParams.sender"
placeholder="请输入发送者"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.sender" placeholder="请输入发送者" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="接收者" prop="receiver">
<el-input
v-model="queryParams.receiver"
placeholder="请输入接收者"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.receiver" placeholder="请输入接收者" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="标题" prop="title">
<el-input
v-model="queryParams.title"
placeholder="请输入标题"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.title" placeholder="请输入标题" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -49,53 +25,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:commonNotify:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:commonNotify:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:commonNotify:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:commonNotify:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:commonNotify:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:commonNotify:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:commonNotify:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:commonNotify:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="commonNotifyList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="触发事务ID" align="center" prop="eventId" />
<el-table-column label="消息类型(系统、通知、活动等)" align="center" prop="messageType" />
<el-table-column label="消息场景(支付、提现等)" align="center" prop="messageScene" />
@ -105,33 +55,19 @@
<el-table-column label="内容" align="center" prop="content" />
<el-table-column label="内容" align="center" prop="imgUrl" />
<el-table-column label="状态" align="center" prop="status" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:commonNotify:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:commonNotify:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:commonNotify:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:commonNotify:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改消息通知对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -152,10 +88,10 @@
<el-input v-model="form.title" placeholder="请输入标题" />
</el-form-item>
<el-form-item label="内容">
<editor v-model="form.content" :min-height="192"/>
<editor v-model="form.content" :min-height="192" />
</el-form-item>
<el-form-item label="图片地址">
<editor v-model="form.imgUrl" :min-height="192"/>
<editor v-model="form.imgUrl" :min-height="192" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
@ -163,175 +99,216 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 消息通知详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="触发事务ID:">
{{form.eventId}}
</el-form-item>
<el-form-item label="消息场景(支付、提现等):">
{{form.messageScene}}
</el-form-item>
<el-form-item label="发送者:">
{{form.sender}}
</el-form-item>
<el-form-item label="接收者:">
{{form.receiver}}
</el-form-item>
<el-form-item label="标题:">
{{form.title}}
</el-form-item>
<el-form-item label="内容">
<editor v-model="form.content" :min-height="192" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listCommonNotify, getCommonNotify, delCommonNotify, addCommonNotify, updateCommonNotify } from "@/api/business/commonNotify";
import {
listCommonNotify,
getCommonNotify,
delCommonNotify,
addCommonNotify,
updateCommonNotify
} from "@/api/business/commonNotify";
export default {
name: "CommonNotify",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
commonNotifyList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
eventId: undefined,
messageType: undefined,
messageScene: undefined,
sender: undefined,
receiver: undefined,
title: undefined,
content: undefined,
status: undefined,
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询消息通知列表 */
getList() {
this.loading = true;
listCommonNotify(this.queryParams).then(response => {
this.commonNotifyList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
eventId: undefined,
messageType: undefined,
messageScene: undefined,
sender: undefined,
receiver: undefined,
title: undefined,
content: undefined,
imgUrl: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "CommonNotify",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
commonNotifyList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
eventId: undefined,
messageType: undefined,
messageScene: undefined,
sender: undefined,
receiver: undefined,
title: undefined,
content: undefined,
status: undefined,
},
//
form: {},
//
rules: {}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加消息通知";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getCommonNotify(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改消息通知";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateCommonNotify(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addCommonNotify(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除消息通知编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询消息通知列表 */
getList() {
this.loading = true;
return delCommonNotify(ids);
}).then(() => {
this.loading = false;
listCommonNotify(this.queryParams).then(response => {
this.commonNotifyList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
eventId: undefined,
messageType: undefined,
messageScene: undefined,
sender: undefined,
receiver: undefined,
title: undefined,
content: undefined,
imgUrl: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/commonNotify/export', {
...this.queryParams
}, `commonNotify_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加消息通知";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "消息通知";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getCommonNotify(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改消息通知";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateCommonNotify(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addCommonNotify(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除消息通知编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delCommonNotify(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/commonNotify/export', {
...this.queryParams
}, `commonNotify_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

551
src/views/business/dealCashout/index.vue

@ -2,72 +2,30 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="提现ID" prop="userId">
<el-input
v-model="queryParams.userId"
placeholder="请输入提现ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userId" placeholder="请输入提现ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="提现账户" prop="userAccount">
<el-input
v-model="queryParams.userAccount"
placeholder="请输入提现账户"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userAccount" placeholder="请输入提现账户" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="目标ID" prop="toId">
<el-input
v-model="queryParams.toId"
placeholder="请输入目标ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.toId" placeholder="请输入目标ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="目标账户" prop="toAccount">
<el-input
v-model="queryParams.toAccount"
placeholder="请输入目标账户"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.toAccount" placeholder="请输入目标账户" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="账单唯一编号" prop="billCode">
<el-input
v-model="queryParams.billCode"
placeholder="请输入账单唯一编号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.billCode" placeholder="请输入账单唯一编号" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="提现金额" prop="amount">
<el-input
v-model="queryParams.amount"
placeholder="请输入提现金额"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.amount" placeholder="请输入提现金额" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建者" prop="createBy">
<el-input
v-model="queryParams.createBy"
placeholder="请输入创建者"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.createBy" placeholder="请输入创建者" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -77,53 +35,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:dealCashout:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:dealCashout:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:dealCashout:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:dealCashout:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:dealCashout:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:dealCashout:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:dealCashout:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:dealCashout:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="dealCashoutList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="提现ID" align="center" prop="userId" />
<el-table-column label="提现账户" align="center" prop="userAccount" />
<el-table-column label="目标ID" align="center" prop="toId" />
@ -144,33 +76,19 @@
<span>{{ parseTime(scope.row.updateTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:dealCashout:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:dealCashout:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:dealCashout:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:dealCashout:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改提现对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -202,197 +120,250 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 提现详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="提现ID:">
{{form.userId}}
</el-form-item>
<el-form-item label="提现账户:">
{{form.userAccount}}
</el-form-item>
<el-form-item label="目标ID:">
{{form.toId}}
</el-form-item>
<el-form-item label="目标账户:">
{{form.toAccount}}
</el-form-item>
<el-form-item label="账单唯一编号:">
{{form.billCode}}
</el-form-item>
<el-form-item label="提现金额:">
{{form.amount}}
</el-form-item>
<el-form-item label="提现备注:">
{{form.remark}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listDealCashout, getDealCashout, delDealCashout, addDealCashout, updateDealCashout } from "@/api/business/dealCashout";
import {
listDealCashout,
getDealCashout,
delDealCashout,
addDealCashout,
updateDealCashout
} from "@/api/business/dealCashout";
export default {
name: "DealCashout",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
dealCashoutList: [],
//
title: "",
//
open: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
status: undefined,
createBy: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
userId: [
{ required: true, message: "提现ID不能为空", trigger: "blur" }
],
userAccount: [
{ required: true, message: "提现账户不能为空", trigger: "blur" }
],
toId: [
{ required: true, message: "目标ID不能为空", trigger: "blur" }
],
amount: [
{ required: true, message: "提现金额不能为空", trigger: "blur" }
],
}
};
},
created() {
this.getList();
},
methods: {
/** 查询提现列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listDealCashout(this.queryParams).then(response => {
this.dealCashoutList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
remark: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "DealCashout",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
dealCashoutList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
status: undefined,
createBy: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
userId: [{
required: true,
message: "提现ID不能为空",
trigger: "blur"
}],
userAccount: [{
required: true,
message: "提现账户不能为空",
trigger: "blur"
}],
toId: [{
required: true,
message: "目标ID不能为空",
trigger: "blur"
}],
amount: [{
required: true,
message: "提现金额不能为空",
trigger: "blur"
}],
}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加提现";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getDealCashout(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改提现";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateDealCashout(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addDealCashout(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除提现编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询提现列表 */
getList() {
this.loading = true;
return delDealCashout(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listDealCashout(this.queryParams).then(response => {
this.dealCashoutList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
remark: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/dealCashout/export', {
...this.queryParams
}, `dealCashout_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加提现";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "提现";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getDealCashout(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改提现";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateDealCashout(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addDealCashout(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除提现编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delDealCashout(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/dealCashout/export', {
...this.queryParams
}, `dealCashout_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

573
src/views/business/dealPay/index.vue

@ -2,80 +2,33 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="付款ID" prop="userId">
<el-input
v-model="queryParams.userId"
placeholder="请输入付款ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userId" placeholder="请输入付款ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="付款账户" prop="userAccount">
<el-input
v-model="queryParams.userAccount"
placeholder="请输入付款账户"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userAccount" placeholder="请输入付款账户" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="目标ID" prop="toId">
<el-input
v-model="queryParams.toId"
placeholder="请输入目标ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.toId" placeholder="请输入目标ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="目标账户" prop="toAccount">
<el-input
v-model="queryParams.toAccount"
placeholder="请输入目标账户"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.toAccount" placeholder="请输入目标账户" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="账单唯一编号" prop="billCode">
<el-input
v-model="queryParams.billCode"
placeholder="请输入账单唯一编号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.billCode" placeholder="请输入账单唯一编号" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="付款金额" prop="amount">
<el-input
v-model="queryParams.amount"
placeholder="请输入付款金额"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.amount" placeholder="请输入付款金额" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="二维码解析" prop="qrCode">
<el-input
v-model="queryParams.qrCode"
placeholder="请输入二维码解析"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.qrCode" placeholder="请输入二维码解析" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="付款备注" prop="remark">
<el-input
v-model="queryParams.remark"
placeholder="请输入付款备注"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.remark" placeholder="请输入付款备注" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -85,53 +38,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:dealPay:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:dealPay:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:dealPay:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:dealPay:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:dealPay:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:dealPay:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:dealPay:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:dealPay:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="dealPayList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="付款ID" align="center" prop="userId" />
<el-table-column label="付款账户" align="center" prop="userAccount" />
<el-table-column label="目标ID" align="center" prop="toId" />
@ -147,33 +74,19 @@
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:dealPay:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:dealPay:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:dealPay:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:dealPay:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改付款对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -208,202 +121,260 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 付款详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="付款ID:">
{{form.userId}}
</el-form-item>
<el-form-item label="付款账户:">
{{form.userAccount}}
</el-form-item>
<el-form-item label="目标ID:">
{{form.toId}}
</el-form-item>
<el-form-item label="目标账户:">
{{form.toAccount}}
</el-form-item>
<el-form-item label="账单唯一编号:">
{{form.billCode}}
</el-form-item>
<el-form-item label="付款金额:">
{{form.amount}}
</el-form-item>
<el-form-item label="二维码解析:">
{{form.qrCode}}
</el-form-item>
<el-form-item label="付款备注:">
{{form.remark}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listDealPay, getDealPay, delDealPay, addDealPay, updateDealPay } from "@/api/business/dealPay";
import {
listDealPay,
getDealPay,
delDealPay,
addDealPay,
updateDealPay
} from "@/api/business/dealPay";
export default {
name: "DealPay",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
dealPayList: [],
//
title: "",
//
open: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
qrCode: undefined,
remark: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
userId: [
{ required: true, message: "付款ID不能为空", trigger: "blur" }
],
userAccount: [
{ required: true, message: "付款账户不能为空", trigger: "blur" }
],
toId: [
{ required: true, message: "目标ID不能为空", trigger: "blur" }
],
toAccount: [
{ required: true, message: "目标账户不能为空", trigger: "blur" }
],
amount: [
{ required: true, message: "付款金额不能为空", trigger: "blur" }
],
}
};
},
created() {
this.getList();
},
methods: {
/** 查询付款列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listDealPay(this.queryParams).then(response => {
this.dealPayList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
qrCode: undefined,
remark: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "DealPay",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
dealPayList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
qrCode: undefined,
remark: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
userId: [{
required: true,
message: "付款ID不能为空",
trigger: "blur"
}],
userAccount: [{
required: true,
message: "付款账户不能为空",
trigger: "blur"
}],
toId: [{
required: true,
message: "目标ID不能为空",
trigger: "blur"
}],
toAccount: [{
required: true,
message: "目标账户不能为空",
trigger: "blur"
}],
amount: [{
required: true,
message: "付款金额不能为空",
trigger: "blur"
}],
}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加付款";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getDealPay(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改付款";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateDealPay(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addDealPay(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除付款编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询付款列表 */
getList() {
this.loading = true;
return delDealPay(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listDealPay(this.queryParams).then(response => {
this.dealPayList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
qrCode: undefined,
remark: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/dealPay/export', {
...this.queryParams
}, `dealPay_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加付款";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "付款";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getDealPay(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改付款";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateDealPay(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addDealPay(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除付款编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delDealPay(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/dealPay/export', {
...this.queryParams
}, `dealPay_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

541
src/views/business/dealReceive/index.vue

@ -2,74 +2,31 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="收款ID" prop="userId">
<el-input
v-model="queryParams.userId"
placeholder="请输入收款ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userId" placeholder="请输入收款ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="收款账户" prop="userAccount">
<el-input
v-model="queryParams.userAccount"
placeholder="请输入收款账户"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userAccount" placeholder="请输入收款账户" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="目标ID" prop="toId">
<el-input
v-model="queryParams.toId"
placeholder="请输入目标ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.toId" placeholder="请输入目标ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="目标账户" prop="toAccount">
<el-input
v-model="queryParams.toAccount"
placeholder="请输入目标账户"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.toAccount" placeholder="请输入目标账户" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="账单唯一编号" prop="billCode">
<el-input
v-model="queryParams.billCode"
placeholder="请输入账单唯一编号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.billCode" placeholder="请输入账单唯一编号" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="收款金额" prop="amount">
<el-input
v-model="queryParams.amount"
placeholder="请输入收款金额"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.amount" placeholder="请输入收款金额" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="二维码解析" prop="qrCode">
<el-input
v-model="queryParams.qrCode"
placeholder="请输入二维码解析"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.qrCode" placeholder="请输入二维码解析" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="提现备注" prop="remark">
<el-input
v-model="queryParams.remark"
placeholder="请输入提现备注"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.remark" placeholder="请输入提现备注" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间" prop="createTime">
<el-date-picker clearable
v-model="queryParams.createTime"
type="date"
value-format="yyyy-MM-dd"
<el-date-picker clearable v-model="queryParams.createTime" type="date" value-format="yyyy-MM-dd"
placeholder="请选择创建时间">
</el-date-picker>
</el-form-item>
@ -81,53 +38,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:dealReceive:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:dealReceive:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:dealReceive:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:dealReceive:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:dealReceive:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:dealReceive:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:dealReceive:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:dealReceive:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="dealReceiveList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="收款ID" align="center" prop="userId" />
<el-table-column label="收款账户" align="center" prop="userAccount" />
<el-table-column label="目标ID" align="center" prop="toId" />
@ -143,33 +74,19 @@
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:dealReceive:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:dealReceive:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:dealReceive:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:dealReceive:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改收款对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -204,191 +121,247 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 收款详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="收款ID:">
{{form.userId}}
</el-form-item>
<el-form-item label="收款账户:">
{{form.userAccount}}
</el-form-item>
<el-form-item label="目标ID:">
{{form.toId}}
</el-form-item>
<el-form-item label="目标账户:">
{{form.toAccount}}
</el-form-item>
<el-form-item label="账单唯一编号:">
{{form.billCode}}
</el-form-item>
<el-form-item label="收款金额:">
{{form.amount}}
</el-form-item>
<el-form-item label="二维码解析:">
{{form.qrCode}}
</el-form-item>
<el-form-item label="提现备注:">
{{form.remark}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listDealReceive, getDealReceive, delDealReceive, addDealReceive, updateDealReceive } from "@/api/business/dealReceive";
import {
listDealReceive,
getDealReceive,
delDealReceive,
addDealReceive,
updateDealReceive
} from "@/api/business/dealReceive";
export default {
name: "DealReceive",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
dealReceiveList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
qrCode: undefined,
remark: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
userId: [
{ required: true, message: "收款ID不能为空", trigger: "blur" }
],
userAccount: [
{ required: true, message: "收款账户不能为空", trigger: "blur" }
],
toId: [
{ required: true, message: "目标ID不能为空", trigger: "blur" }
],
toAccount: [
{ required: true, message: "目标账户不能为空", trigger: "blur" }
],
}
};
},
created() {
this.getList();
},
methods: {
/** 查询收款列表 */
getList() {
this.loading = true;
listDealReceive(this.queryParams).then(response => {
this.dealReceiveList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
qrCode: undefined,
remark: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "DealReceive",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
dealReceiveList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
qrCode: undefined,
remark: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
userId: [{
required: true,
message: "收款ID不能为空",
trigger: "blur"
}],
userAccount: [{
required: true,
message: "收款账户不能为空",
trigger: "blur"
}],
toId: [{
required: true,
message: "目标ID不能为空",
trigger: "blur"
}],
toAccount: [{
required: true,
message: "目标账户不能为空",
trigger: "blur"
}],
}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加收款";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getDealReceive(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改收款";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateDealReceive(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addDealReceive(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除收款编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询收款列表 */
getList() {
this.loading = true;
return delDealReceive(ids);
}).then(() => {
this.loading = false;
listDealReceive(this.queryParams).then(response => {
this.dealReceiveList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
qrCode: undefined,
remark: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/dealReceive/export', {
...this.queryParams
}, `dealReceive_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加收款";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "收款";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getDealReceive(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改收款";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateDealReceive(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addDealReceive(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除收款编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delDealReceive(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/dealReceive/export', {
...this.queryParams
}, `dealReceive_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

553
src/views/business/dealTransfer/index.vue

@ -2,72 +2,30 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="转账ID" prop="userId">
<el-input
v-model="queryParams.userId"
placeholder="请输入转账ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userId" placeholder="请输入转账ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="转账账户" prop="userAccount">
<el-input
v-model="queryParams.userAccount"
placeholder="请输入转账账户"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userAccount" placeholder="请输入转账账户" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="接收ID" prop="toId">
<el-input
v-model="queryParams.toId"
placeholder="请输入接收ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.toId" placeholder="请输入接收ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="接收账户" prop="toAccount">
<el-input
v-model="queryParams.toAccount"
placeholder="请输入接收账户"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.toAccount" placeholder="请输入接收账户" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="账单唯一编号" prop="billCode">
<el-input
v-model="queryParams.billCode"
placeholder="请输入账单唯一编号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.billCode" placeholder="请输入账单唯一编号" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="转账金额" prop="amount">
<el-input
v-model="queryParams.amount"
placeholder="请输入转账金额"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.amount" placeholder="请输入转账金额" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="转账备注" prop="remark">
<el-input
v-model="queryParams.remark"
placeholder="请输入转账备注"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.remark" placeholder="请输入转账备注" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -77,53 +35,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:dealTransfer:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:dealTransfer:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:dealTransfer:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:dealTransfer:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:dealTransfer:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:dealTransfer:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:dealTransfer:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:dealTransfer:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="dealTransferList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="转账ID" align="center" prop="userId" />
<el-table-column label="转账账户" align="center" prop="userAccount" />
<el-table-column label="接收ID" align="center" prop="toId" />
@ -138,33 +70,19 @@
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:dealTransfer:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:dealTransfer:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:dealTransfer:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:dealTransfer:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改转账对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -196,197 +114,252 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 转账详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="转账ID:">
{{form.userId}}
</el-form-item>
<el-form-item label="转账账户:">
{{form.userAccount}}
</el-form-item>
<el-form-item label="接收ID:">
{{form.toId}}
</el-form-item>
<el-form-item label="接收账户:">
{{form.toAccount}}
</el-form-item>
<el-form-item label="账单唯一编号:">
{{form.billCode}}
</el-form-item>
<el-form-item label="转账金额:">
{{form.amount}}
</el-form-item>
<el-form-item label="转账备注:">
{{form.remark}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listDealTransfer, getDealTransfer, delDealTransfer, addDealTransfer, updateDealTransfer } from "@/api/business/dealTransfer";
import {
listDealTransfer,
getDealTransfer,
delDealTransfer,
addDealTransfer,
updateDealTransfer
} from "@/api/business/dealTransfer";
export default {
name: "DealTransfer",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
dealTransferList: [],
//
title: "",
//
open: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
remark: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
userId: [
{ required: true, message: "转账ID不能为空", trigger: "blur" }
],
userAccount: [
{ required: true, message: "转账账户不能为空", trigger: "blur" }
],
toId: [
{ required: true, message: "接收ID不能为空", trigger: "blur" }
],
toAccount: [
{ required: true, message: "接收账户不能为空", trigger: "blur" }
],
}
};
},
created() {
this.getList();
},
methods: {
/** 查询转账列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listDealTransfer(this.queryParams).then(response => {
this.dealTransferList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
remark: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "DealTransfer",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
dealTransferList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
remark: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
userId: [{
required: true,
message: "转账ID不能为空",
trigger: "blur"
}],
userAccount: [{
required: true,
message: "转账账户不能为空",
trigger: "blur"
}],
toId: [{
required: true,
message: "接收ID不能为空",
trigger: "blur"
}],
toAccount: [{
required: true,
message: "接收账户不能为空",
trigger: "blur"
}],
}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加转账";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getDealTransfer(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改转账";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateDealTransfer(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addDealTransfer(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除转账编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询转账列表 */
getList() {
this.loading = true;
return delDealTransfer(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listDealTransfer(this.queryParams).then(response => {
this.dealTransferList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
userAccount: undefined,
toId: undefined,
toAccount: undefined,
billCode: undefined,
amount: undefined,
transferType: undefined,
remark: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/dealTransfer/export', {
...this.queryParams
}, `dealTransfer_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加转账";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "转账";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getDealTransfer(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改转账";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateDealTransfer(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addDealTransfer(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除转账编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delDealTransfer(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/dealTransfer/export', {
...this.queryParams
}, `dealTransfer_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

580
src/views/business/recordTransaction/index.vue

@ -2,92 +2,44 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="用户ID" prop="senderId">
<el-input
v-model="queryParams.senderId"
placeholder="请输入用户ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.senderId" placeholder="请输入用户ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="账户编号" prop="senderAccount">
<el-input
v-model="queryParams.senderAccount"
placeholder="请输入账户编号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.senderAccount" placeholder="请输入账户编号" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="目标用户ID" prop="receiverId">
<el-input
v-model="queryParams.receiverId"
placeholder="请输入目标用户ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.receiverId" placeholder="请输入目标用户ID" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="目标用户账户编号" prop="receiverAccount">
<el-input
v-model="queryParams.receiverAccount"
placeholder="请输入目标用户账户编号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.receiverAccount" placeholder="请输入目标用户账户编号" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="交易前金额" prop="previousBalance">
<el-input
v-model="queryParams.previousBalance"
placeholder="请输入交易前金额"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.previousBalance" placeholder="请输入交易前金额" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="交易金额" prop="changeBalance">
<el-input
v-model="queryParams.changeBalance"
placeholder="请输入交易金额"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.changeBalance" placeholder="请输入交易金额" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="当前金额" prop="currentBalance">
<el-input
v-model="queryParams.currentBalance"
placeholder="请输入当前金额"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.currentBalance" placeholder="请输入当前金额" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="交易备注" prop="note">
<el-input
v-model="queryParams.note"
placeholder="请输入交易备注"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.note" placeholder="请输入交易备注" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="交易时间">
<el-date-picker
v-model="daterangeTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss" type="daterange"
range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -97,53 +49,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:recordTransaction:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:recordTransaction:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:recordTransaction:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:recordTransaction:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:recordTransaction:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:recordTransaction:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:recordTransaction:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:recordTransaction:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="recordTransactionList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="ID" align="center" prop="id" v-if="true"/>
<el-table-column label="ID" align="center" prop="id" v-if="true" />
<el-table-column label="用户ID" align="center" prop="senderId" />
<el-table-column label="账户编号" align="center" prop="senderAccount" />
<el-table-column label="交易类型" align="center" prop="type" />
@ -164,33 +90,19 @@
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:recordTransaction:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:recordTransaction:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:recordTransaction:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:recordTransaction:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改交易动账记录对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -220,10 +132,7 @@
<el-input v-model="form.note" type="textarea" placeholder="请输入内容" />
</el-form-item>
<el-form-item label="交易时间" prop="time">
<el-date-picker clearable
v-model="form.time"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
<el-date-picker clearable v-model="form.time" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择交易时间">
</el-date-picker>
</el-form-item>
@ -233,196 +142,249 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 交易动账记录详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="用户ID:">
{{form.senderId}}
</el-form-item>
<el-form-item label="账户编号:">
{{form.senderAccount}}
</el-form-item>
<el-form-item label="目标用户ID:">
{{form.receiverId}}
</el-form-item>
<el-form-item label="目标用户账户编号:">
{{form.receiverAccount}}
</el-form-item>
<el-form-item label="交易前金额:">
{{form.previous}}
</el-form-item>
<el-form-item label="交易金额:">
{{form.change}}
</el-form-item>
<el-form-item label="当前金额:">
{{form.current}}
</el-form-item>
<el-form-item label="交易备注:"s>
{{form.note}}
</el-form-item>
<el-form-item label="交易时间" prop="time">
<el-date-picker clearable v-model="form.time" type="datetime" value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择交易时间">
</el-date-picker>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listRecordTransaction, getRecordTransaction, delRecordTransaction, addRecordTransaction, updateRecordTransaction } from "@/api/business/recordTransaction";
import {
listRecordTransaction,
getRecordTransaction,
delRecordTransaction,
addRecordTransaction,
updateRecordTransaction
} from "@/api/business/recordTransaction";
export default {
name: "RecordTransaction",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
recordTransactionList: [],
//
title: "",
//
open: false,
//
daterangeTime: [],
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
senderId: undefined,
senderAccount: undefined,
type: undefined,
receiverId: undefined,
receiverAccount: undefined,
previousBalance: undefined,
changeBalance: undefined,
currentBalance: undefined,
note: undefined,
time: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询交易动账记录列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeTime && '' != this.daterangeTime) {
this.queryParams.params["beginTime"] = this.daterangeTime[0];
this.queryParams.params["endTime"] = this.daterangeTime[1];
}
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listRecordTransaction(this.queryParams).then(response => {
this.recordTransactionList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
senderId: undefined,
senderAccount: undefined,
type: undefined,
receiverId: undefined,
receiverAccount: undefined,
previousBalance: undefined,
changeBalance: undefined,
currentBalance: undefined,
note: undefined,
time: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "RecordTransaction",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
recordTransactionList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeTime: [],
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
senderId: undefined,
senderAccount: undefined,
type: undefined,
receiverId: undefined,
receiverAccount: undefined,
previousBalance: undefined,
changeBalance: undefined,
currentBalance: undefined,
note: undefined,
time: undefined,
status: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeTime = [];
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加交易动账记录";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getRecordTransaction(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改交易动账记录";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateRecordTransaction(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addRecordTransaction(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除交易动账记录编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询交易动账记录列表 */
getList() {
this.loading = true;
return delRecordTransaction(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeTime && '' != this.daterangeTime) {
this.queryParams.params["beginTime"] = this.daterangeTime[0];
this.queryParams.params["endTime"] = this.daterangeTime[1];
}
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listRecordTransaction(this.queryParams).then(response => {
this.recordTransactionList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
senderId: undefined,
senderAccount: undefined,
type: undefined,
receiverId: undefined,
receiverAccount: undefined,
previousBalance: undefined,
changeBalance: undefined,
currentBalance: undefined,
note: undefined,
time: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/recordTransaction/export', {
...this.queryParams
}, `recordTransaction_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeTime = [];
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加交易动账记录";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "交易动账记录";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getRecordTransaction(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改交易动账记录";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateRecordTransaction(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addRecordTransaction(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除交易动账记录编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delRecordTransaction(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/recordTransaction/export', {
...this.queryParams
}, `recordTransaction_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

517
src/views/business/userAccount/index.vue

@ -2,68 +2,31 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="用户id" prop="userId">
<el-input
v-model="queryParams.userId"
placeholder="请输入用户id"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userId" placeholder="请输入用户id" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="账户唯一ID" prop="accountId">
<el-input
v-model="queryParams.accountId"
placeholder="请输入账户唯一ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.accountId" placeholder="请输入账户唯一ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="账户唯一编号" prop="accountCode">
<el-input
v-model="queryParams.accountCode"
placeholder="请输入账户唯一编号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.accountCode" placeholder="请输入账户唯一编号" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="账户名称" prop="accountName">
<el-input
v-model="queryParams.accountName"
placeholder="请输入账户名称"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.accountName" placeholder="请输入账户名称" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="账户余额" prop="accountAmount">
<el-input
v-model="queryParams.accountAmount"
placeholder="请输入账户余额"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.accountAmount" placeholder="请输入账户余额" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item label="更新时间">
<el-date-picker
v-model="daterangeUpdateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeUpdateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -73,53 +36,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:userAccount:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:userAccount:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:userAccount:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:userAccount:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:userAccount:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:userAccount:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:userAccount:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:userAccount:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="userAccountList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="用户id" align="center" prop="userId" />
<el-table-column label="账户唯一ID" align="center" prop="accountId" />
<el-table-column label="账户唯一编号" align="center" prop="accountCode" />
@ -137,33 +74,19 @@
<span>{{ parseTime(scope.row.updateTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:userAccount:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:userAccount:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:userAccount:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:userAccount:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改用户账户对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -189,187 +112,225 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 用户账户详情显示框 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="用户id:">
{{form.userId}}
</el-form-item>
<el-form-item label="账户唯一ID:">
{{form.accountId}}
</el-form-item>
<el-form-item label="账户唯一编号:">
{{form.accountCode}}
</el-form-item>
<el-form-item label="账户名称:">
{{form.accountName}}
</el-form-item>
<el-form-item label="账户余额:">
{{form.accountAmount}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listUserAccount, getUserAccount, delUserAccount, addUserAccount, updateUserAccount } from "@/api/business/userAccount";
import {
listUserAccount,
getUserAccount,
delUserAccount,
addUserAccount,
updateUserAccount
} from "@/api/business/userAccount";
export default {
name: "UserAccount",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userAccountList: [],
//
title: "",
//
open: false,
//
daterangeCreateTime: [],
//
daterangeUpdateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
accountId: undefined,
accountCode: undefined,
accountName: undefined,
accountAmount: undefined,
status: undefined,
createTime: undefined,
updateTime: undefined
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询用户账户列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
if (null != this.daterangeUpdateTime && '' != this.daterangeUpdateTime) {
this.queryParams.params["beginUpdateTime"] = this.daterangeUpdateTime[0];
this.queryParams.params["endUpdateTime"] = this.daterangeUpdateTime[1];
}
listUserAccount(this.queryParams).then(response => {
this.userAccountList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
accountId: undefined,
accountCode: undefined,
accountName: undefined,
accountAmount: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "UserAccount",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userAccountList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeCreateTime: [],
//
daterangeUpdateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
accountId: undefined,
accountCode: undefined,
accountName: undefined,
accountAmount: undefined,
status: undefined,
createTime: undefined,
updateTime: undefined
},
//
form: {},
//
rules: {}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.daterangeUpdateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户账户";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserAccount(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户账户";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserAccount(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserAccount(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户账户编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询用户账户列表 */
getList() {
this.loading = true;
return delUserAccount(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
if (null != this.daterangeUpdateTime && '' != this.daterangeUpdateTime) {
this.queryParams.params["beginUpdateTime"] = this.daterangeUpdateTime[0];
this.queryParams.params["endUpdateTime"] = this.daterangeUpdateTime[1];
}
listUserAccount(this.queryParams).then(response => {
this.userAccountList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
accountId: undefined,
accountCode: undefined,
accountName: undefined,
accountAmount: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userAccount/export', {
...this.queryParams
}, `userAccount_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.daterangeUpdateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户账户";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "用户账户";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserAccount(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户账户";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserAccount(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserAccount(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户账户编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delUserAccount(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userAccount/export', {
...this.queryParams
}, `userAccount_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

532
src/views/business/userCard/index.vue

@ -2,68 +2,29 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="用户ID" prop="userId">
<el-input
v-model="queryParams.userId"
placeholder="请输入用户ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userId" placeholder="请输入用户ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="银行卡号" prop="cardNum">
<el-input
v-model="queryParams.cardNum"
placeholder="请输入银行卡号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.cardNum" placeholder="请输入银行卡号" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="银行卡余额" prop="cardAmount">
<el-input
v-model="queryParams.cardAmount"
placeholder="请输入银行卡余额"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.cardAmount" placeholder="请输入银行卡余额" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="银行名称" prop="bankName">
<el-input
v-model="queryParams.bankName"
placeholder="请输入银行名称"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.bankName" placeholder="请输入银行名称" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="具体分行" prop="deptName">
<el-input
v-model="queryParams.deptName"
placeholder="请输入具体分行"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.deptName" placeholder="请输入具体分行" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item label="更新时间">
<el-date-picker
v-model="daterangeUpdateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeUpdateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -73,53 +34,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:userCard:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:userCard:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:userCard:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:userCard:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:userCard:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:userCard:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:userCard:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:userCard:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="userCardList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="用户ID" align="center" prop="userId" />
<el-table-column label="银行卡号" align="center" prop="cardNum" />
<el-table-column label="银行卡余额" align="center" prop="cardAmount" />
@ -136,33 +71,19 @@
<span>{{ parseTime(scope.row.updateTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:userCard:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:userCard:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:userCard:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:userCard:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改用户银行卡对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -188,193 +109,236 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 用户银行卡详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="用户ID:" >
{{form.userId}}
</el-form-item>
<el-form-item label="银行卡号:">
{{form.cardNum}}
</el-form-item>
<el-form-item label="银行卡余额:">
{{form.cardAmount}}
</el-form-item>
<el-form-item label="银行名称:">
{{form.bankName}}
</el-form-item>
<el-form-item label="具体分行:">
{{form.deptName}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listUserCard, getUserCard, delUserCard, addUserCard, updateUserCard } from "@/api/business/userCard";
import {
listUserCard,
getUserCard,
delUserCard,
addUserCard,
updateUserCard
} from "@/api/business/userCard";
export default {
name: "UserCard",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userCardList: [],
//
title: "",
//
open: false,
//
daterangeCreateTime: [],
//
daterangeUpdateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
cardNum: undefined,
cardAmount: undefined,
bankName: undefined,
deptName: undefined,
status: undefined,
createTime: undefined,
updateTime: undefined
},
//
form: {},
//
rules: {
userId: [
{ required: true, message: "用户ID不能为空", trigger: "blur" }
],
cardNum: [
{ required: true, message: "银行卡号不能为空", trigger: "blur" }
],
}
};
},
created() {
this.getList();
},
methods: {
/** 查询用户银行卡列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
if (null != this.daterangeUpdateTime && '' != this.daterangeUpdateTime) {
this.queryParams.params["beginUpdateTime"] = this.daterangeUpdateTime[0];
this.queryParams.params["endUpdateTime"] = this.daterangeUpdateTime[1];
}
listUserCard(this.queryParams).then(response => {
this.userCardList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
cardNum: undefined,
cardAmount: undefined,
bankName: undefined,
deptName: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "UserCard",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userCardList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeCreateTime: [],
//
daterangeUpdateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
cardNum: undefined,
cardAmount: undefined,
bankName: undefined,
deptName: undefined,
status: undefined,
createTime: undefined,
updateTime: undefined
},
//
form: {},
//
rules: {
userId: [{
required: true,
message: "用户ID不能为空",
trigger: "blur"
}],
cardNum: [{
required: true,
message: "银行卡号不能为空",
trigger: "blur"
}],
}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.daterangeUpdateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户银行卡";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserCard(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户银行卡";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserCard(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserCard(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户银行卡编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询用户银行卡列表 */
getList() {
this.loading = true;
return delUserCard(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
if (null != this.daterangeUpdateTime && '' != this.daterangeUpdateTime) {
this.queryParams.params["beginUpdateTime"] = this.daterangeUpdateTime[0];
this.queryParams.params["endUpdateTime"] = this.daterangeUpdateTime[1];
}
listUserCard(this.queryParams).then(response => {
this.userCardList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
cardNum: undefined,
cardAmount: undefined,
bankName: undefined,
deptName: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userCard/export', {
...this.queryParams
}, `userCard_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.daterangeUpdateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户银行卡";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "用户银行卡";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserCard(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户银行卡";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserCard(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserCard(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户银行卡编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delUserCard(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userCard/export', {
...this.queryParams
}, `userCard_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

456
src/views/business/userFriend/index.vue

@ -2,40 +2,18 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="用户id" prop="userId">
<el-input
v-model="queryParams.userId"
placeholder="请输入用户id"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userId" placeholder="请输入用户id" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="好友id" prop="friendId">
<el-input
v-model="queryParams.friendId"
placeholder="请输入好友id"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.friendId" placeholder="请输入好友id" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="删除标志" prop="delFlag">
<el-input
v-model="queryParams.delFlag"
placeholder="请输入删除标志"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.delFlag" placeholder="请输入删除标志" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -45,53 +23,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:userFriend:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:userFriend:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:userFriend:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:userFriend:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:userFriend:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:userFriend:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:userFriend:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:userFriend:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="userFriendList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="用户id" align="center" prop="userId" />
<el-table-column label="好友id" align="center" prop="friendId" />
<el-table-column label="状态" align="center" prop="status" />
@ -101,33 +53,19 @@
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:userFriend:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:userFriend:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:userFriend:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:userFriend:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改用户好友对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -147,174 +85,206 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 用户好友详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="用户id:" >
{{form.userId}}
</el-form-item>
<el-form-item label="好友id:">
{{form.friendId}}
</el-form-item>
<el-form-item label="删除标志:">
{{form.delFlag}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listUserFriend, getUserFriend, delUserFriend, addUserFriend, updateUserFriend } from "@/api/business/userFriend";
import {
listUserFriend,
getUserFriend,
delUserFriend,
addUserFriend,
updateUserFriend
} from "@/api/business/userFriend";
export default {
name: "UserFriend",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userFriendList: [],
//
title: "",
//
open: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
friendId: undefined,
status: undefined,
delFlag: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询用户好友列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listUserFriend(this.queryParams).then(response => {
this.userFriendList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
friendId: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "UserFriend",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userFriendList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
friendId: undefined,
status: undefined,
delFlag: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户好友";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserFriend(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户好友";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserFriend(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserFriend(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户好友编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询用户好友列表 */
getList() {
this.loading = true;
return delUserFriend(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listUserFriend(this.queryParams).then(response => {
this.userFriendList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
friendId: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userFriend/export', {
...this.queryParams
}, `userFriend_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户好友";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "用户好友";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserFriend(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户好友";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserFriend(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserFriend(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户好友编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delUserFriend(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userFriend/export', {
...this.queryParams
}, `userFriend_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

537
src/views/business/userInfo/index.vue

@ -2,88 +2,36 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="用户ID" prop="userId">
<el-input
v-model="queryParams.userId"
placeholder="请输入用户ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userId" placeholder="请输入用户ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="用户唯一编码" prop="userCode">
<el-input
v-model="queryParams.userCode"
placeholder="请输入用户唯一编码"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userCode" placeholder="请输入用户唯一编码" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="姓名" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入姓名"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入姓名" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="性别" prop="gender">
<el-input
v-model="queryParams.gender"
placeholder="请输入性别"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.gender" placeholder="请输入性别" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="唯一ID" prop="idCard">
<el-input
v-model="queryParams.idCard"
placeholder="请输入唯一ID"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.idCard" placeholder="请输入唯一ID" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="手机号" prop="phone">
<el-input
v-model="queryParams.phone"
placeholder="请输入手机号"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.phone" placeholder="请输入手机号" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="年龄" prop="age">
<el-input
v-model="queryParams.age"
placeholder="请输入年龄"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.age" placeholder="请输入年龄" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="地址" prop="addr">
<el-input
v-model="queryParams.addr"
placeholder="请输入地址"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.addr" placeholder="请输入地址" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="删除标志" prop="delFlag">
<el-input
v-model="queryParams.delFlag"
placeholder="请输入删除标志"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.delFlag" placeholder="请输入删除标志" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -93,53 +41,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:userInfo:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:userInfo:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:userInfo:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:userInfo:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:userInfo:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:userInfo:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:userInfo:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:userInfo:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="userInfoList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="用户ID" align="center" prop="userId" />
<el-table-column label="用户唯一编码" align="center" prop="userCode" />
<el-table-column label="姓名" align="center" prop="name" />
@ -160,33 +82,19 @@
<span>{{ parseTime(scope.row.updateTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:userInfo:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:userInfo:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:userInfo:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:userInfo:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改用户信息对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -221,186 +129,233 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 用户信息详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="用户ID:">
{{form.userId}}
</el-form-item>
<el-form-item label="用户唯一编码:">
{{form.userCode}}
</el-form-item>
<el-form-item label="姓名:">
{{form.name}}
</el-form-item>
<el-form-item label="性别:">
{{form.gender}}
</el-form-item>
<el-form-item label="唯一ID:">
{{form.idCard}}
</el-form-item>
<el-form-item label="手机号:">
{{form.phone}}
</el-form-item>
<el-form-item label="年龄:">
{{form.age}}
</el-form-item>
<el-form-item label="地址:">
{{form.addr}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listUserInfo, getUserInfo, delUserInfo, addUserInfo, updateUserInfo } from "@/api/business/userInfo";
import {
listUserInfo,
getUserInfo,
delUserInfo,
addUserInfo,
updateUserInfo
} from "@/api/business/userInfo";
export default {
name: "UserInfo",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userInfoList: [],
//
title: "",
//
open: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
userCode: undefined,
name: undefined,
gender: undefined,
idCard: undefined,
phone: undefined,
age: undefined,
addr: undefined,
status: undefined,
delFlag: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询用户信息列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listUserInfo(this.queryParams).then(response => {
this.userInfoList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
userCode: undefined,
name: undefined,
gender: undefined,
idCard: undefined,
phone: undefined,
age: undefined,
addr: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "UserInfo",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userInfoList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeCreateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
userCode: undefined,
name: undefined,
gender: undefined,
idCard: undefined,
phone: undefined,
age: undefined,
addr: undefined,
status: undefined,
delFlag: undefined,
createTime: undefined,
},
//
form: {},
//
rules: {}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户信息";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserInfo(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户信息";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserInfo(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserInfo(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户信息编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询用户信息列表 */
getList() {
this.loading = true;
return delUserInfo(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
listUserInfo(this.queryParams).then(response => {
this.userInfoList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
userCode: undefined,
name: undefined,
gender: undefined,
idCard: undefined,
phone: undefined,
age: undefined,
addr: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userInfo/export', {
...this.queryParams
}, `userInfo_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户信息";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "用户信息";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserInfo(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户信息";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserInfo(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserInfo(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户信息编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delUserInfo(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userInfo/export', {
...this.queryParams
}, `userInfo_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

496
src/views/business/userPasswd/index.vue

@ -2,52 +2,25 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="用户id" prop="userId">
<el-input
v-model="queryParams.userId"
placeholder="请输入用户id"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userId" placeholder="请输入用户id" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="支付密码(数字组合)" prop="payPasswd">
<el-input
v-model="queryParams.payPasswd"
placeholder="请输入支付密码(数字组合)"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.payPasswd" placeholder="请输入支付密码(数字组合)" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="登录密码(数字组合)" prop="loginPasswd">
<el-input
v-model="queryParams.loginPasswd"
placeholder="请输入登录密码(数字组合)"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.loginPasswd" placeholder="请输入登录密码(数字组合)" clearable
@keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item label="更新时间">
<el-date-picker
v-model="daterangeUpdateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeUpdateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -57,53 +30,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:userPasswd:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:userPasswd:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:userPasswd:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:userPasswd:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:userPasswd:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:userPasswd:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:userPasswd:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:userPasswd:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="userPasswdList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="用户id" align="center" prop="userId" />
<el-table-column label="支付密码(数字组合)" align="center" prop="payPasswd" />
<el-table-column label="设备锁(九宫)" align="center" prop="phoneLock" />
@ -120,33 +67,19 @@
<span>{{ parseTime(scope.row.updateTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:userPasswd:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:userPasswd:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:userPasswd:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:userPasswd:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改用户密码对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -169,185 +102,220 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 用户密码详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="用户id:" prop="userId">
{{form.userId}}
</el-form-item>
<el-form-item label="支付密码(数字组合):">
{{form.payPasswd}}
</el-form-item>
<el-form-item label="设备锁(九宫):">
{{form.phoneLock}}
</el-form-item>
<el-form-item label="登录密码(数字组合):">
{{form.loginPasswd}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listUserPasswd, getUserPasswd, delUserPasswd, addUserPasswd, updateUserPasswd } from "@/api/business/userPasswd";
import {
listUserPasswd,
getUserPasswd,
delUserPasswd,
addUserPasswd,
updateUserPasswd
} from "@/api/business/userPasswd";
export default {
name: "UserPasswd",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userPasswdList: [],
//
title: "",
//
open: false,
//
daterangeCreateTime: [],
//
daterangeUpdateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
payPasswd: undefined,
loginPasswd: undefined,
payStatus: undefined,
delFlag: undefined,
createTime: undefined,
updateTime: undefined
},
//
form: {},
//
rules: {
}
};
},
created() {
this.getList();
},
methods: {
/** 查询用户密码列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
if (null != this.daterangeUpdateTime && '' != this.daterangeUpdateTime) {
this.queryParams.params["beginUpdateTime"] = this.daterangeUpdateTime[0];
this.queryParams.params["endUpdateTime"] = this.daterangeUpdateTime[1];
}
listUserPasswd(this.queryParams).then(response => {
this.userPasswdList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
payPasswd: undefined,
phoneLock: undefined,
loginPasswd: undefined,
payStatus: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "UserPasswd",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userPasswdList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeCreateTime: [],
//
daterangeUpdateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
payPasswd: undefined,
loginPasswd: undefined,
payStatus: undefined,
delFlag: undefined,
createTime: undefined,
updateTime: undefined
},
//
form: {},
//
rules: {}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.daterangeUpdateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户密码";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserPasswd(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户密码";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserPasswd(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserPasswd(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户密码编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询用户密码列表 */
getList() {
this.loading = true;
return delUserPasswd(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
if (null != this.daterangeUpdateTime && '' != this.daterangeUpdateTime) {
this.queryParams.params["beginUpdateTime"] = this.daterangeUpdateTime[0];
this.queryParams.params["endUpdateTime"] = this.daterangeUpdateTime[1];
}
listUserPasswd(this.queryParams).then(response => {
this.userPasswdList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
payPasswd: undefined,
phoneLock: undefined,
loginPasswd: undefined,
payStatus: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userPasswd/export', {
...this.queryParams
}, `userPasswd_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.daterangeUpdateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户密码";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "用户密码";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserPasswd(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户密码";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserPasswd(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserPasswd(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户密码编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delUserPasswd(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userPasswd/export', {
...this.queryParams
}, `userPasswd_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

524
src/views/business/userRegister/index.vue

@ -2,68 +2,29 @@
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="用户id" prop="userId">
<el-input
v-model="queryParams.userId"
placeholder="请输入用户id"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.userId" placeholder="请输入用户id" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="名字" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入名字"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入名字" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="电话" prop="phone">
<el-input
v-model="queryParams.phone"
placeholder="请输入电话"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.phone" placeholder="请输入电话" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="密码" prop="passwd">
<el-input
v-model="queryParams.passwd"
placeholder="请输入密码"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.passwd" placeholder="请输入密码" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="验证码" prop="verifyCode">
<el-input
v-model="queryParams.verifyCode"
placeholder="请输入验证码"
clearable
@keyup.enter.native="handleQuery"
/>
<el-input v-model="queryParams.verifyCode" placeholder="请输入验证码" clearable @keyup.enter.native="handleQuery" />
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker
v-model="daterangeCreateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item label="更新时间">
<el-date-picker
v-model="daterangeUpdateTime"
style="width: 240px"
value-format="yyyy-MM-dd HH:mm:ss"
type="daterange"
range-separator="-"
start-placeholder="开始日期"
end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"
></el-date-picker>
<el-date-picker v-model="daterangeUpdateTime" style="width: 240px" value-format="yyyy-MM-dd HH:mm:ss"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期"
:default-time="['00:00:00', '23:59:59']"></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@ -73,53 +34,27 @@
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['business:userRegister:add']"
>新增</el-button>
<el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
v-hasPermi="['business:userRegister:add']">新增</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['business:userRegister:edit']"
>修改</el-button>
<el-button type="success" plain icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate"
v-hasPermi="['business:userRegister:edit']">修改</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['business:userRegister:remove']"
>删除</el-button>
<el-button type="danger" plain icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete"
v-hasPermi="['business:userRegister:remove']">删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['business:userRegister:export']"
>导出</el-button>
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport"
v-hasPermi="['business:userRegister:export']">导出</el-button>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="userRegisterList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="唯一ID" align="center" prop="id" v-if="true"/>
<el-table-column label="唯一ID" align="center" prop="id" v-if="true" />
<el-table-column label="用户id" align="center" prop="userId" />
<el-table-column label="名字" align="center" prop="name" />
<el-table-column label="电话" align="center" prop="phone" />
@ -136,33 +71,19 @@
<span>{{ parseTime(scope.row.updateTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['business:userRegister:edit']"
>修改</el-button>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['business:userRegister:remove']"
>删除</el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleDetail(scope.row)">详情</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
v-hasPermi="['business:userRegister:edit']">修改</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['business:userRegister:remove']">删除</el-button>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<pagination v-show="total>0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize"
@pagination="getList" />
<!-- 添加或修改用户注册对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
@ -188,190 +109,231 @@
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
<!-- 用户注册详情 -->
<el-dialog :title="title" :visible.sync="detailOpen" width="700px" append-to-body>
<el-form ref="form" :model="form" label-width="auto">
<el-form-item label="用户id:">
{{form.userId}}
</el-form-item>
<el-form-item label="名字:">
{{form.name}}
</el-form-item>
<el-form-item label="电话:">
{{form.phone}}
</el-form-item>
<el-form-item label="密码:">
{{form.passwd}}
</el-form-item>
<el-form-item label="验证码:">
{{form.verifyCode}}
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import { listUserRegister, getUserRegister, delUserRegister, addUserRegister, updateUserRegister } from "@/api/business/userRegister";
import {
listUserRegister,
getUserRegister,
delUserRegister,
addUserRegister,
updateUserRegister
} from "@/api/business/userRegister";
export default {
name: "UserRegister",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userRegisterList: [],
//
title: "",
//
open: false,
//
daterangeCreateTime: [],
//
daterangeUpdateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
name: undefined,
phone: undefined,
passwd: undefined,
verifyCode: undefined,
status: undefined,
createTime: undefined,
updateTime: undefined
},
//
form: {},
//
rules: {
name: [
{ required: true, message: "名字不能为空", trigger: "blur" }
],
}
};
},
created() {
this.getList();
},
methods: {
/** 查询用户注册列表 */
getList() {
this.loading = true;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
if (null != this.daterangeUpdateTime && '' != this.daterangeUpdateTime) {
this.queryParams.params["beginUpdateTime"] = this.daterangeUpdateTime[0];
this.queryParams.params["endUpdateTime"] = this.daterangeUpdateTime[1];
}
listUserRegister(this.queryParams).then(response => {
this.userRegisterList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
name: undefined,
phone: undefined,
passwd: undefined,
verifyCode: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
export default {
name: "UserRegister",
data() {
return {
// loading
buttonLoading: false,
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
userRegisterList: [],
//
title: "",
//
open: false,
//
detailOpen: false,
//
daterangeCreateTime: [],
//
daterangeUpdateTime: [],
//
queryParams: {
pageNum: 1,
pageSize: 10,
userId: undefined,
name: undefined,
phone: undefined,
passwd: undefined,
verifyCode: undefined,
status: undefined,
createTime: undefined,
updateTime: undefined
},
//
form: {},
//
rules: {
name: [{
required: true,
message: "名字不能为空",
trigger: "blur"
}],
}
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
created() {
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.daterangeUpdateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length!==1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户注册";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserRegister(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户注册";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserRegister(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserRegister(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户注册编号为"' + ids + '"的数据项?').then(() => {
methods: {
/** 查询用户注册列表 */
getList() {
this.loading = true;
return delUserRegister(ids);
}).then(() => {
this.loading = false;
this.queryParams.params = {};
if (null != this.daterangeCreateTime && '' != this.daterangeCreateTime) {
this.queryParams.params["beginCreateTime"] = this.daterangeCreateTime[0];
this.queryParams.params["endCreateTime"] = this.daterangeCreateTime[1];
}
if (null != this.daterangeUpdateTime && '' != this.daterangeUpdateTime) {
this.queryParams.params["beginUpdateTime"] = this.daterangeUpdateTime[0];
this.queryParams.params["endUpdateTime"] = this.daterangeUpdateTime[1];
}
listUserRegister(this.queryParams).then(response => {
this.userRegisterList = response.rows;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.detailOpen = false;
this.reset();
},
//
reset() {
this.form = {
id: undefined,
userId: undefined,
name: undefined,
phone: undefined,
passwd: undefined,
verifyCode: undefined,
status: undefined,
delFlag: undefined,
createBy: undefined,
createTime: undefined,
updateBy: undefined,
updateTime: undefined
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {
}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userRegister/export', {
...this.queryParams
}, `userRegister_${new Date().getTime()}.xlsx`)
},
/** 重置按钮操作 */
resetQuery() {
this.daterangeCreateTime = [];
this.daterangeUpdateTime = [];
this.resetForm("queryForm");
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map(item => item.id)
this.single = selection.length !== 1
this.multiple = !selection.length
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加用户注册";
},
/** 详情按钮操作 */
handleDetail(row) {
this.reset();
this.form = row;
this.detailOpen = true;
this.title = "用户注册";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.loading = true;
this.reset();
const id = row.id || this.ids
getUserRegister(id).then(response => {
this.loading = false;
this.form = response.data;
this.open = true;
this.title = "修改用户注册";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
if (valid) {
this.buttonLoading = true;
if (this.form.id != null) {
updateUserRegister(this.form).then(response => {
this.$modal.msgSuccess("修改成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
} else {
addUserRegister(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
this.getList();
}).finally(() => {
this.buttonLoading = false;
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认删除用户注册编号为"' + ids + '"的数据项?').then(() => {
this.loading = true;
return delUserRegister(ids);
}).then(() => {
this.loading = false;
this.getList();
this.$modal.msgSuccess("删除成功");
}).catch(() => {}).finally(() => {
this.loading = false;
});
},
/** 导出按钮操作 */
handleExport() {
this.download('business/userRegister/export', {
...this.queryParams
}, `userRegister_${new Date().getTime()}.xlsx`)
}
}
}
};
};
</script>

Loading…
Cancel
Save