fix: 表格样式统一修改。

This commit is contained in:
tianyongbao
2024-04-29 15:06:24 +08:00
parent c4e5781280
commit d149dec61f
38 changed files with 1832 additions and 2304 deletions

View File

@@ -39,8 +39,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-scrollbar>
<el-table v-loading="loading" :data="accountDealRecordList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="accountDealRecordList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column label="账户名称" align="center" prop="accountName" />
<el-table-column label="记账类型" align="center" prop="type">
<template #default="scope">
@@ -60,7 +59,7 @@
<dict-tag :options="deal_category" :value="scope.row.dealCategory" />
</template>
</el-table-column>
<el-table-column label="备注" align="center" width="350" prop="remark" />
<el-table-column label="备注" align="center" width="380" prop="remark" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template v-slot="scope">
<div class="ctrl-btn d-flex">
@@ -72,7 +71,6 @@
</el-table-column>
</el-table>
<el-pagination small background layout="total, prev, pager, next" :total="total" @current-change="handleCurrentChange" />
</el-scrollbar>
</div>
</div>
<!-- 添加或修改账户交易记录对话框 -->
@@ -117,7 +115,6 @@
</el-dialog>
</div>
</template>
<script setup name="AccountDealRecord">
import {
listAccountDealRecord,

View File

@@ -4,31 +4,16 @@
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="名称" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入名称"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入名称" clearable @keyup.enter="handleQuery" />
</el-form-item>
<el-form-item label="账户类型" prop="type">
<el-select v-model="queryParams.type" placeholder="请选择账户类型" clearable>
<el-option
v-for="dict in account_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
<el-option v-for="dict in account_type" :key="dict.value" :label="dict.label" :value="dict.value" />
</el-select>
</el-form-item>
<el-form-item label="账户状态" prop="state">
<el-select v-model="queryParams.state" placeholder="请选择账户状态" clearable>
<el-option
v-for="dict in account_state"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
<el-option v-for="dict in account_state" :key="dict.value" :label="dict.label" :value="dict.value" />
</el-select>
</el-form-item>
</el-form>
@@ -41,26 +26,13 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:accounts:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:accounts:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:accounts:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:accounts:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:accounts:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:accounts:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="accountsList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="accountsList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="名称" align="center" prop="name" />
<el-table-column label="账户类型" align="center" prop="type">
@@ -97,12 +69,7 @@
</el-form-item>
<el-form-item label="账户类型" prop="type">
<el-select v-model="form.type" placeholder="请选择账户类型">
<el-option
v-for="dict in account_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in account_type" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="账号" prop="code">
@@ -116,18 +83,12 @@
</el-form-item>
<el-form-item label="账户状态" prop="state">
<el-select v-model="form.state" placeholder="请选择账户状态">
<el-option
v-for="dict in account_state"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in account_state" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
</el-form-item>
</el-form>
<template v-if="title !== '查看记账账户'" #footer>
<div class="dialog-footer">
@@ -168,7 +129,13 @@
<el-dialog :title="titleTransferRecord" v-model="openTransferRecord" width="1100px" append-to-body destroy-on-close>
<el-form :model="queryTransferRecordParams" ref="queryTransferRecordRef" inline>
<el-form-item label="选择时间" prop="startTime">
<el-date-picker v-model="queryTransferRecordParams.time" type="daterange" range-separator="至" start-placeholder="开始时间" end-placeholder="结束时间" />
<el-date-picker
v-model="queryTransferRecordParams.time"
type="daterange"
range-separator=""
start-placeholder="开始时间"
end-placeholder="结束时间"
/>
</el-form-item>
<el-form-item label="">
<el-button type="primary" icon="Search" @click="handleTransferRecordQuery">搜索</el-button>
@@ -247,18 +214,10 @@ const data = reactive({
state: null
},
rules: {
name: [
{ required: true, message: '名称不能为空', trigger: 'blur' }
],
type: [
{ required: true, message: '账户类型不能为空', trigger: 'change' }
],
code: [
{ required: true, message: '账号不能为空', trigger: 'blur' }
],
balance: [
{ required: true, message: '余额不能为空', trigger: 'blur' }
]
name: [{ required: true, message: '名称不能为空', trigger: 'blur' }],
type: [{ required: true, message: '账户类型不能为空', trigger: 'change' }],
code: [{ required: true, message: '账号不能为空', trigger: 'blur' }],
balance: [{ required: true, message: '余额不能为空', trigger: 'blur' }]
}
})
@@ -289,7 +248,7 @@ const { queryParams, form, rules } = toRefs(data)
/** 查询记账账户列表 */
function getList() {
loading.value = true
listAccounts(queryParams.value).then(response => {
listAccounts(queryParams.value).then((response) => {
accountsList.value = response.rows
total.value = response.total
loading.value = false
@@ -344,7 +303,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -367,7 +326,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getAccounts(_id).then(response => {
getAccounts(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改记账账户'
@@ -376,16 +335,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.accountsRef.validate(valid => {
proxy.$refs.accountsRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateAccounts(form.value).then(response => {
updateAccounts(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addAccounts(form.value).then(response => {
addAccounts(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -398,19 +357,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delAccounts(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/accounts/export', {
proxy.download(
'invest/accounts/export',
{
...queryParams.value
}, `accounts_${new Date().getTime()}.xlsx`)
},
`accounts_${new Date().getTime()}.xlsx`
)
}
/** 历史数据按钮操作 */

View File

@@ -27,7 +27,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="creditCardBillList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="creditCardBillList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="信用卡" align="center" prop="bankNameCode" />
<el-table-column label="账单名称" align="center" prop="name" />

View File

@@ -29,7 +29,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="installmentHistoryList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="installmentHistoryList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="信用卡" align="center" width="200" prop="bankNameCode" />
<el-table-column label="分期金额" align="center" prop="installmentAmount" />

View File

@@ -41,8 +41,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-scrollbar>
<el-table v-loading="loading" :data="CreditQueryRecordList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="CreditQueryRecordList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="查询日期" align="center" prop="queryDate" width="150">
<template #default="scope">
@@ -72,7 +71,6 @@
</el-table-column>
</el-table>
<el-pagination small background layout="total, prev, pager, next" :total="total" @current-change="handleCurrentChange" />
</el-scrollbar>
</div>
</div>
<!-- 添加或修改征信查询记录对话框 -->

View File

@@ -3,7 +3,7 @@
<div class="search-con">
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="信用卡" style="width: 500px;" prop="inAccountId">
<el-form-item label="信用卡" style="width: 500px" prop="inAccountId">
<el-select v-model="queryParams.inAccountId" placeholder="请选择信用卡" clearable>
<el-option v-for="bankCardLend in creditCardList" :key="bankCardLend.id" :label="bankCardLend.nameCode" :value="bankCardLend.id" />
</el-select>
@@ -18,32 +18,24 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:accountsTransferRecord:add']"
>新增</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:accountsTransferRecord:add']">新增</el-button>
<!-- <el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:accountsTransferRecord:remove']"
>删除</el-button> -->
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:accountsTransferRecord:export']"
>导出</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:accountsTransferRecord:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="accountsTransferRecordList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="accountsTransferRecordList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<!-- <el-table-column type="selection" width="55" align="center" /> -->
<el-table-column label="名称" align="center" prop="name" />
<el-table-column label="储蓄卡" align="center" prop="outAccountName" />
<el-table-column label="信用卡" align="center" prop="inAccountName" />
<el-table-column label="还款时间" width='180' align="center" prop="createTime" />
<el-table-column label="还款金额" width='150' align="center" prop="amount" />
<el-table-column label="还款时间" width="180" align="center" prop="createTime" />
<el-table-column label="还款金额" width="150" align="center" prop="amount" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template v-slot="scope">
<div class="ctrl-btn d-flex">
@@ -71,12 +63,7 @@
</el-select>
</el-form-item>
<el-form-item label="还款时间" prop="createTime">
<el-date-picker clearable
v-model="form.createTime"
type="datetime"
value-format="YYYY-MM-DD HH:mm:ss"
placeholder="请选择还款时间">
</el-date-picker>
<el-date-picker clearable v-model="form.createTime" type="datetime" value-format="YYYY-MM-DD HH:mm:ss" placeholder="请选择还款时间"> </el-date-picker>
</el-form-item>
<el-form-item label="还款金额" prop="amount">
<el-input v-model="form.amount" placeholder="请输入还款金额" />
@@ -96,7 +83,13 @@
</template>
<script setup name="AccountsTransferRecord">
import { listAccountsTransferRecord, getAccountsTransferRecord, delAccountsTransferRecord, addAccountsTransferRecord, updateAccountsTransferRecord } from '@/api/invest/accountsTransferRecord'
import {
listAccountsTransferRecord,
getAccountsTransferRecord,
delAccountsTransferRecord,
addAccountsTransferRecord,
updateAccountsTransferRecord
} from '@/api/invest/accountsTransferRecord'
import { listAccounts } from '@/api/invest/accounts'
// eslint-disable-next-line no-unused-vars
import { require } from '@/utils/require'
@@ -155,18 +148,10 @@ const data = reactive({
pageSize: 1000
},
rules: {
inAccountId: [
{ required: true, message: '信用卡不能为空', trigger: 'blur' }
],
outAccountId: [
{ required: true, message: '储蓄卡不能为空', trigger: 'blur' }
],
amount: [
{ required: true, message: '还款金额不能为空', trigger: 'blur' }
],
createTime: [
{ required: true, message: '还款时间不能为空', trigger: 'blur' }
]
inAccountId: [{ required: true, message: '信用卡不能为空', trigger: 'blur' }],
outAccountId: [{ required: true, message: '储蓄卡不能为空', trigger: 'blur' }],
amount: [{ required: true, message: '还款金额不能为空', trigger: 'blur' }],
createTime: [{ required: true, message: '还款时间不能为空', trigger: 'blur' }]
}
})
@@ -212,7 +197,7 @@ function getFutruesStocksList() {
/** 查询信用卡还款列表 */
function getList() {
loading.value = true
listAccountsTransferRecord(queryParams.value).then(response => {
listAccountsTransferRecord(queryParams.value).then((response) => {
accountsTransferRecordList.value = response.rows
total.value = response.total
loading.value = false
@@ -268,7 +253,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -291,7 +276,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getAccountsTransferRecord(_id).then(response => {
getAccountsTransferRecord(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改信用卡还款'
@@ -300,16 +285,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.accountsTransferRecordRef.validate(valid => {
proxy.$refs.accountsTransferRecordRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateAccountsTransferRecord(form.value).then(response => {
updateAccountsTransferRecord(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addAccountsTransferRecord(form.value).then(response => {
addAccountsTransferRecord(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -322,19 +307,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delAccountsTransferRecord(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/accountsTransferRecord/export', {
proxy.download(
'invest/accountsTransferRecord/export',
{
...queryParams.value
}, `accountsTransferRecord_${new Date().getTime()}.xlsx`)
},
`accountsTransferRecord_${new Date().getTime()}.xlsx`
)
}
getFutruesStocksList()
getDebitList()

View File

@@ -4,12 +4,7 @@
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="信用卡名称" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入信用卡名称"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入信用卡名称" clearable @keyup.enter="handleQuery" />
</el-form-item>
</el-form>
<div class="search-btn-con">
@@ -21,26 +16,13 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:bankcard:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:bankcard:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:bankcard:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:bankcard:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:bankcard:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:bankcard:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="bankcardList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="bankcardList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="信用卡名称" align="center" prop="name" />
<el-table-column label="信用卡卡号" align="center" prop="code" />
@@ -49,9 +31,9 @@
<span>{{ parseTime(scope.row.activationDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="账单日" align="center" width='100' prop="billDateName" />
<el-table-column label="还款日" align="center" width='100' prop="payDateName" />
<el-table-column label="延缓期限" align="center" width='100' prop="delayPeriod" />
<el-table-column label="账单日" align="center" width="100" prop="billDateName" />
<el-table-column label="还款日" align="center" width="100" prop="payDateName" />
<el-table-column label="延缓期限" align="center" width="100" prop="delayPeriod" />
<el-table-column label="信用卡额度" align="center" prop="creditLimit" />
<el-table-column label="有效期" align="center" prop="effectiveDate" width="180">
<template #default="scope">
@@ -106,32 +88,17 @@
<el-input v-model="form.openingBank" placeholder="请输入开户行" />
</el-form-item>
<el-form-item label="开户日期" prop="activationDate">
<el-date-picker clearable
v-model="form.activationDate"
type="date"
value-format="YYYY-MM-DD"
placeholder="请选择开户日期">
</el-date-picker>
<el-date-picker clearable v-model="form.activationDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择开户日期"> </el-date-picker>
</el-form-item>
<el-form-item label="宽限期" prop="delayPeriod">
<el-input v-model="form.delayPeriod" placeholder="请输入延缓期限" />
</el-form-item>
<el-form-item label="有效期" prop="effectiveDate">
<el-date-picker clearable
v-model="form.effectiveDate"
type="date"
value-format="YYYY-MM-DD"
placeholder="请选择有效期">
</el-date-picker>
<el-date-picker clearable v-model="form.effectiveDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择有效期"> </el-date-picker>
</el-form-item>
<el-form-item label="账单日消费" prop="isNextBillDate">
<el-select v-model="form.isNextBillDate" placeholder="请选择账单日消费">
<el-option
v-for="dict in is_next_bill_date"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in is_next_bill_date" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="账单日时间" prop="nextBillDateTime">
@@ -139,12 +106,7 @@
</el-form-item>
<el-form-item label="0账单操作" prop="isZeroBill">
<el-select v-model="form.isZeroBill" placeholder="请选择0账单操作">
<el-option
v-for="dict in is_zero_bill"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in is_zero_bill" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="备注" prop="remark">
@@ -191,24 +153,12 @@ const data = reactive({
type: '2'
},
rules: {
name: [
{ required: true, message: '信用卡名称不能为空', trigger: 'blur' }
],
code: [
{ required: true, message: '信用卡卡号不能为空', trigger: 'blur' }
],
billDate: [
{ required: true, message: '账单日不能为空', trigger: 'blur' }
],
payDate: [
{ required: true, message: '还款日不能为空', trigger: 'blur' }
],
creditLimit: [
{ required: true, message: '信用卡额度不能为空', trigger: 'blur' }
],
cvv: [
{ required: true, message: '信用卡安全码不能为空', trigger: 'blur' }
]
name: [{ required: true, message: '信用卡名称不能为空', trigger: 'blur' }],
code: [{ required: true, message: '信用卡卡号不能为空', trigger: 'blur' }],
billDate: [{ required: true, message: '账单日不能为空', trigger: 'blur' }],
payDate: [{ required: true, message: '还款日不能为空', trigger: 'blur' }],
creditLimit: [{ required: true, message: '信用卡额度不能为空', trigger: 'blur' }],
cvv: [{ required: true, message: '信用卡安全码不能为空', trigger: 'blur' }]
}
})
@@ -233,7 +183,7 @@ const { queryParams, form, rules } = toRefs(data)
/** 查询信用卡信息列表 */
function getList() {
loading.value = true
listBankcardLend(queryParams.value).then(response => {
listBankcardLend(queryParams.value).then((response) => {
bankcardList.value = response.rows
total.value = response.total
loading.value = false
@@ -295,7 +245,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -318,7 +268,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getBankcardLend(_id).then(response => {
getBankcardLend(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改信用卡信息'
@@ -327,16 +277,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.bankcardRef.validate(valid => {
proxy.$refs.bankcardRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateBankcardLend(form.value).then(response => {
updateBankcardLend(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addBankcardLend(form.value).then(response => {
addBankcardLend(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -349,19 +299,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delBankcardLend(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/bankcard/export', {
proxy.download(
'invest/bankcard/export',
{
...queryParams.value
}, `bankcard_${new Date().getTime()}.xlsx`)
},
`bankcard_${new Date().getTime()}.xlsx`
)
}
getList()

View File

@@ -4,30 +4,15 @@
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="名称" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入名称"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入名称" clearable @keyup.enter="handleQuery" />
</el-form-item>
<el-form-item label="类型" prop="type">
<el-select v-model="queryParams.type" placeholder="请选择类型" clearable>
<el-option
v-for="dict in debit_infors_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
<el-option v-for="dict in debit_infors_type" :key="dict.value" :label="dict.label" :value="dict.value" />
</el-select>
</el-form-item>
<el-form-item label="放贷机构" prop="lenders">
<el-input
v-model="queryParams.lenders"
placeholder="请输入放贷机构"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.lenders" placeholder="请输入放贷机构" clearable @keyup.enter="handleQuery" />
</el-form-item>
</el-form>
<div class="search-btn-con">
@@ -39,27 +24,13 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:debitInfors:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:debitInfors:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:debitInfors:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:debitInfors:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:debitInfors:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:debitInfors:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-scrollbar>
<el-table v-loading="loading" :data="debitInforsList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="debitInforsList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="名称" align="center" prop="name" />
<el-table-column label="类型" align="center" width="100" prop="type">
@@ -83,7 +54,6 @@
</el-table-column>
</el-table>
<el-pagination small background layout="total, prev, pager, next" :total="total" @current-change="handleCurrentChange" />
</el-scrollbar>
</div>
</div>
<!-- 添加或修改信贷产品管理对话框 -->
@@ -94,12 +64,7 @@
</el-form-item>
<el-form-item label="类型" prop="type">
<el-select v-model="form.type" placeholder="请选择类型">
<el-option
v-for="dict in debit_infors_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in debit_infors_type" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="放贷机构" prop="lenders">
@@ -138,17 +103,17 @@
<el-form-item label="贷款余额" prop="loanBalance">
<el-input v-model="form.loanBalance" placeholder="请输入贷款余额" />
</el-form-item>
<el-form-item label="适用客群" style="width: 850px;" prop="applicableCustomerGroups">
<el-input v-model="form.applicableCustomerGroups" rows='3' type="textarea" placeholder="请输入适用客群" />
<el-form-item label="适用客群" style="width: 850px" prop="applicableCustomerGroups">
<el-input v-model="form.applicableCustomerGroups" rows="3" type="textarea" placeholder="请输入适用客群" />
</el-form-item>
<el-form-item label="征信条件" style="width: 850px;" prop="creditConditions">
<el-input v-model="form.creditConditions" rows='3' type="textarea" placeholder="请输入征信条件" />
<el-form-item label="征信条件" style="width: 850px" prop="creditConditions">
<el-input v-model="form.creditConditions" rows="3" type="textarea" placeholder="请输入征信条件" />
</el-form-item>
<el-form-item label="所需材料" style="width: 850px;" prop="requiredMaterials">
<el-input v-model="form.requiredMaterials" rows='2' type="textarea" placeholder="请输入所需材料" />
<el-form-item label="所需材料" style="width: 850px" prop="requiredMaterials">
<el-input v-model="form.requiredMaterials" rows="2" type="textarea" placeholder="请输入所需材料" />
</el-form-item>
<el-form-item label="负债要求" style="width: 850px;" prop="debtRequirements">
<el-input v-model="form.debtRequirements" rows='2' type="textarea" placeholder="请输入负债要求" />
<el-form-item label="负债要求" style="width: 850px" prop="debtRequirements">
<el-input v-model="form.debtRequirements" rows="2" type="textarea" placeholder="请输入负债要求" />
</el-form-item>
</el-form>
<template v-if="title !== '查看信贷产品管理'" #footer>
@@ -192,30 +157,14 @@ const data = reactive({
lenders: null
},
rules: {
name: [
{ required: true, message: '名称不能为空', trigger: 'blur' }
],
lenders: [
{ required: true, message: '放贷机构不能为空', trigger: 'blur' }
],
type: [
{ required: true, message: '类型不能为空', trigger: 'blur' }
],
loanLimit: [
{ required: true, message: '贷款额度不能为空', trigger: 'blur' }
],
lendingRate: [
{ required: true, message: '贷款利率不能为空', trigger: 'blur' }
],
loanTerm: [
{ required: true, message: '贷款期限不能为空', trigger: 'blur' }
],
repaymentMethod: [
{ required: true, message: '还款方式不能为空', trigger: 'blur' }
],
applyMethod: [
{ required: true, message: '申请方式不能为空', trigger: 'blur' }
]
name: [{ required: true, message: '名称不能为空', trigger: 'blur' }],
lenders: [{ required: true, message: '放贷机构不能为空', trigger: 'blur' }],
type: [{ required: true, message: '类型不能为空', trigger: 'blur' }],
loanLimit: [{ required: true, message: '贷款额度不能为空', trigger: 'blur' }],
lendingRate: [{ required: true, message: '贷款利率不能为空', trigger: 'blur' }],
loanTerm: [{ required: true, message: '贷款期限不能为空', trigger: 'blur' }],
repaymentMethod: [{ required: true, message: '还款方式不能为空', trigger: 'blur' }],
applyMethod: [{ required: true, message: '申请方式不能为空', trigger: 'blur' }]
}
})
@@ -240,7 +189,7 @@ const { queryParams, form, rules } = toRefs(data)
/** 查询信贷产品管理列表 */
function getList() {
loading.value = true
listDebitInfors(queryParams.value).then(response => {
listDebitInfors(queryParams.value).then((response) => {
debitInforsList.value = response.rows
total.value = response.total
loading.value = false
@@ -305,7 +254,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -328,7 +277,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getDebitInfors(_id).then(response => {
getDebitInfors(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改信贷产品管理'
@@ -337,16 +286,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.debitInforsRef.validate(valid => {
proxy.$refs.debitInforsRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateDebitInfors(form.value).then(response => {
updateDebitInfors(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addDebitInfors(form.value).then(response => {
addDebitInfors(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -359,19 +308,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delDebitInfors(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/debitInfors/export', {
proxy.download(
'invest/debitInfors/export',
{
...queryParams.value
}, `debitInfors_${new Date().getTime()}.xlsx`)
},
`debitInfors_${new Date().getTime()}.xlsx`
)
}
getList()

View File

@@ -3,12 +3,12 @@
<div class="search-con">
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="转入账户" style="width: 500px;" prop="inAccountId">
<el-form-item label="转入账户" style="width: 500px" prop="inAccountId">
<el-select v-model="queryParams.inAccountId" placeholder="请选择转入账户" clearable>
<el-option v-for="debitCard in debitCardList" :key="debitCard.id" :label="debitCard.nameCode" :value="debitCard.id" />
</el-select>
</el-form-item>
<el-form-item label="转出账户" style="width: 500px;" prop="outAccountId">
<el-form-item label="转出账户" style="width: 500px" prop="outAccountId">
<el-select v-model="queryParams.outAccountId" placeholder="请选择转出账户" clearable>
<el-option v-for="debitCard in debitCardList" :key="debitCard.id" :label="debitCard.nameCode" :value="debitCard.id" />
</el-select>
@@ -23,32 +23,24 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:accountsTransferRecord:add']"
>新增</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:accountsTransferRecord:add']">新增</el-button>
<!-- <el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:accountsTransferRecord:remove']"
>删除</el-button> -->
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:accountsTransferRecord:export']"
>导出</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:accountsTransferRecord:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="accountsTransferRecordList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="accountsTransferRecordList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<!-- <el-table-column type="selection" width="55" align="center" /> -->
<el-table-column label="名称" align="center" prop="name" />
<el-table-column label="转出账户" align="center" prop="outAccountName" />
<el-table-column label="转入账户" align="center" prop="inAccountName" />
<el-table-column label="转账时间" width='180' align="center" prop="createTime" />
<el-table-column label="转账金额" width='150' align="center" prop="amount" />
<el-table-column label="转账时间" width="180" align="center" prop="createTime" />
<el-table-column label="转账金额" width="150" align="center" prop="amount" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template v-slot="scope">
<div class="ctrl-btn d-flex">
@@ -76,12 +68,7 @@
</el-select>
</el-form-item>
<el-form-item label="转账时间" prop="createTime">
<el-date-picker clearable
v-model="form.createTime"
type="datetime"
value-format="YYYY-MM-DD HH:mm:ss"
placeholder="请选择转账时间">
</el-date-picker>
<el-date-picker clearable v-model="form.createTime" type="datetime" value-format="YYYY-MM-DD HH:mm:ss" placeholder="请选择转账时间"> </el-date-picker>
</el-form-item>
<el-form-item label="转账金额" prop="amount">
<el-input v-model="form.amount" placeholder="请输入转账金额" />
@@ -101,7 +88,13 @@
</template>
<script setup name="AccountsTransferRecord">
import { listAccountsTransferRecord, getAccountsTransferRecord, delAccountsTransferRecord, addAccountsTransferRecord, updateAccountsTransferRecord } from '@/api/invest/accountsTransferRecord'
import {
listAccountsTransferRecord,
getAccountsTransferRecord,
delAccountsTransferRecord,
addAccountsTransferRecord,
updateAccountsTransferRecord
} from '@/api/invest/accountsTransferRecord'
import { listAccounts } from '@/api/invest/accounts'
// eslint-disable-next-line no-unused-vars
import { require } from '@/utils/require'
@@ -160,18 +153,10 @@ const data = reactive({
pageSize: 1000
},
rules: {
inAccountId: [
{ required: true, message: '转账户不能为空', trigger: 'blur' }
],
outAccountId: [
{ required: true, message: '转出账户不能为空', trigger: 'blur' }
],
amount: [
{ required: true, message: '转账金额不能为空', trigger: 'blur' }
],
createTime: [
{ required: true, message: '转账时间不能为空', trigger: 'blur' }
]
inAccountId: [{ required: true, message: '转入账户不能为空', trigger: 'blur' }],
outAccountId: [{ required: true, message: '转账户不能为空', trigger: 'blur' }],
amount: [{ required: true, message: '转账金额不能为空', trigger: 'blur' }],
createTime: [{ required: true, message: '转账时间不能为空', trigger: 'blur' }]
}
})
@@ -217,7 +202,7 @@ function getFutruesStocksList() {
/** 查询储蓄卡转账列表 */
function getList() {
loading.value = true
listAccountsTransferRecord(queryParams.value).then(response => {
listAccountsTransferRecord(queryParams.value).then((response) => {
accountsTransferRecordList.value = response.rows
total.value = response.total
loading.value = false
@@ -273,7 +258,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -296,7 +281,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getAccountsTransferRecord(_id).then(response => {
getAccountsTransferRecord(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改储蓄卡转账'
@@ -305,20 +290,20 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.accountsTransferRecordRef.validate(valid => {
proxy.$refs.accountsTransferRecordRef.validate((valid) => {
if (valid) {
if (form.value.outAccountId === form.value.inAccountId) {
proxy.$modal.msgError('转入转出账户不能是同一个账户。')
return
}
if (form.value.id != null) {
updateAccountsTransferRecord(form.value).then(response => {
updateAccountsTransferRecord(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addAccountsTransferRecord(form.value).then(response => {
addAccountsTransferRecord(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -331,19 +316,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delAccountsTransferRecord(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/accountsTransferRecord/export', {
proxy.download(
'invest/accountsTransferRecord/export',
{
...queryParams.value
}, `accountsTransferRecord_${new Date().getTime()}.xlsx`)
},
`accountsTransferRecord_${new Date().getTime()}.xlsx`
)
}
getFutruesStocksList()
getDebitList()

View File

@@ -4,12 +4,7 @@
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="储蓄卡名称" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入储蓄卡名称"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入储蓄卡名称" clearable @keyup.enter="handleQuery" />
</el-form-item>
</el-form>
<div class="search-btn-con">
@@ -21,26 +16,13 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:bankcard:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:bankcard:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:bankcard:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:bankcard:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:bankcard:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:bankcard:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="bankcardList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="bankcardList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="储蓄卡名称" align="center" width="180" prop="name" />
<el-table-column label="储蓄卡卡号" align="center" prop="code" />
@@ -82,29 +64,14 @@
<el-input v-model="form.openingBank" placeholder="请输入开户行" />
</el-form-item>
<el-form-item label="开户日期" prop="activationDate">
<el-date-picker clearable
v-model="form.activationDate"
type="date"
value-format="YYYY-MM-DD"
placeholder="请选择开户日期">
</el-date-picker>
<el-date-picker clearable v-model="form.activationDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择开户日期"> </el-date-picker>
</el-form-item>
<el-form-item label="有效期" prop="effectiveDate">
<el-date-picker clearable
v-model="form.effectiveDate"
type="date"
value-format="YYYY-MM-DD"
placeholder="请选择有效期">
</el-date-picker>
<el-date-picker clearable v-model="form.effectiveDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择有效期"> </el-date-picker>
</el-form-item>
<el-form-item label="储蓄卡类型" prop="debitType">
<el-select v-model="form.debitType" placeholder="请选择储蓄卡类型">
<el-option
v-for="dict in debit_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in debit_type" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="备注" prop="remark">
@@ -151,12 +118,8 @@ const data = reactive({
type: '1'
},
rules: {
name: [
{ required: true, message: '储蓄卡名称不能为空', trigger: 'blur' }
],
code: [
{ required: true, message: '储蓄卡卡号不能为空', trigger: 'blur' }
]
name: [{ required: true, message: '储蓄卡名称不能为空', trigger: 'blur' }],
code: [{ required: true, message: '储蓄卡卡号不能为空', trigger: 'blur' }]
}
})
@@ -181,7 +144,7 @@ const { queryParams, form, rules } = toRefs(data)
/** 查询储蓄卡信息列表 */
function getList() {
loading.value = true
listBankcardLend(queryParams.value).then(response => {
listBankcardLend(queryParams.value).then((response) => {
bankcardList.value = response.rows
total.value = response.total
loading.value = false
@@ -240,7 +203,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -263,7 +226,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getBankcardLend(_id).then(response => {
getBankcardLend(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改储蓄卡信息'
@@ -272,16 +235,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.bankcardRef.validate(valid => {
proxy.$refs.bankcardRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateBankcardLend(form.value).then(response => {
updateBankcardLend(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addBankcardLend(form.value).then(response => {
addBankcardLend(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -294,19 +257,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delBankcardLend(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/bankcard/export', {
proxy.download(
'invest/bankcard/export',
{
...queryParams.value
}, `bankcard_${new Date().getTime()}.xlsx`)
},
`bankcard_${new Date().getTime()}.xlsx`
)
}
getList()

View File

@@ -4,12 +4,7 @@
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="名称" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入名称"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入名称" clearable @keyup.enter="handleQuery" />
</el-form-item>
</el-form>
<div class="search-btn-con">
@@ -21,26 +16,13 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:futureStocks:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:futureStocks:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:futureStocks:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:futureStocks:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:futureStocks:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:futureStocks:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="futureStocksList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="futureStocksList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="名称" align="center" prop="name" />
<el-table-column label="账号" align="center" prop="code" />
@@ -94,12 +76,7 @@
<el-input v-model="form.fundPassword" placeholder="请输入资金密码" />
</el-form-item>
<el-form-item label="开户日期" prop="activationDate">
<el-date-picker clearable
v-model="form.activationDate"
type="date"
value-format="YYYY-MM-DD"
placeholder="请选择开户日期">
</el-date-picker>
<el-date-picker clearable v-model="form.activationDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择开户日期"> </el-date-picker>
</el-form-item>
<el-form-item label="手续费" prop="commission">
<el-input v-model="form.commission" placeholder="请输入手续费" />
@@ -158,30 +135,16 @@ const data = reactive({
pageSize: 1000
},
rules: {
name: [
{ required: true, message: '名称不能为空', trigger: 'blur' }
],
code: [
{ required: true, message: '账号不能为空', trigger: 'blur' }
],
password: [
{ required: true, message: '密码不能为空', trigger: 'blur' }
],
tradingCenterCode: [
{ required: true, message: '期货交易中心账号不能为空', trigger: 'blur' }
],
tradingCenterPassword: [
{ required: true, message: '期货交易中心密码不能为空', trigger: 'blur' }
],
fundPassword: [
{ required: true, message: '资金密码不能为空', trigger: 'blur' }
],
name: [{ required: true, message: '名称不能为空', trigger: 'blur' }],
code: [{ required: true, message: '账号不能为空', trigger: 'blur' }],
password: [{ required: true, message: '密码不能为空', trigger: 'blur' }],
tradingCenterCode: [{ required: true, message: '期货交易中心账号不能为空', trigger: 'blur' }],
tradingCenterPassword: [{ required: true, message: '期货交易中心密码不能为空', trigger: 'blur' }],
fundPassword: [{ required: true, message: '资金密码不能为空', trigger: 'blur' }],
// debitCard: [
// { required: true, message: '关联储蓄卡不能为空', trigger: 'blur' }
// ],
activationDate: [
{ required: true, message: '开户日期不能为空', trigger: 'blur' }
]
activationDate: [{ required: true, message: '开户日期不能为空', trigger: 'blur' }]
}
})
@@ -213,7 +176,7 @@ function getDebitCardList() {
/** 查询期货信息列表 */
function getList() {
loading.value = true
listFutureStocks(queryParams.value).then(response => {
listFutureStocks(queryParams.value).then((response) => {
futureStocksList.value = response.rows
total.value = response.total
loading.value = false
@@ -271,7 +234,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -294,7 +257,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getFutureStocks(_id).then(response => {
getFutureStocks(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改期货信息'
@@ -303,16 +266,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.futureStocksRef.validate(valid => {
proxy.$refs.futureStocksRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateFutureStocks(form.value).then(response => {
updateFutureStocks(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addFutureStocks(form.value).then(response => {
addFutureStocks(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -325,19 +288,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delFutureStocks(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/futureStocks/export', {
proxy.download(
'invest/futureStocks/export',
{
...queryParams.value
}, `futureStocks_${new Date().getTime()}.xlsx`)
},
`futureStocks_${new Date().getTime()}.xlsx`
)
}
getDebitCardList()
getList()

View File

@@ -9,12 +9,7 @@
</el-select>
</el-form-item>
<el-form-item label="账单名称" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入账单名称"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入账单名称" clearable @keyup.enter="handleQuery" />
</el-form-item>
</el-form>
<div class="search-btn-con">
@@ -26,26 +21,13 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:futureStocksBill:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:futureStocksBill:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:futureStocksBill:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:futureStocksBill:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:futureStocksBill:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:futureStocksBill:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="futureStocksBillList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="futureStocksBillList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="期货账户" align="center" prop="futureStocksNameCode" />
<el-table-column label="账单名称" align="center" prop="name" />
@@ -73,12 +55,7 @@
</el-select>
</el-form-item>
<el-form-item label="账单日" prop="billDate">
<el-date-picker clearable
v-model="form.billDate"
type="date"
value-format="YYYY-MM-DD"
placeholder="请选择账单日">
</el-date-picker>
<el-date-picker clearable v-model="form.billDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择账单日"> </el-date-picker>
</el-form-item>
<el-form-item label="期货收益" prop="billAmount">
<el-input v-model="form.billAmount" placeholder="请输入期货收益" />
@@ -135,15 +112,9 @@ const data = reactive({
pageSize: 1000
},
rules: {
billDate: [
{ required: true, message: '账单日不能为空', trigger: 'blur' }
],
futureStocksId: [
{ required: true, message: '期货账户不能为空', trigger: 'blur' }
],
billAmount: [
{ required: true, message: '期货收益不能为空', trigger: 'blur' }
]
billDate: [{ required: true, message: '账单日不能为空', trigger: 'blur' }],
futureStocksId: [{ required: true, message: '期货账户不能为空', trigger: 'blur' }],
billAmount: [{ required: true, message: '期货收益不能为空', trigger: 'blur' }]
}
})
@@ -175,7 +146,7 @@ function getFutureStocksList() {
/** 查询期货账单列表 */
function getList() {
loading.value = true
listFutureStocksBill(queryParams.value).then(response => {
listFutureStocksBill(queryParams.value).then((response) => {
futureStocksBillList.value = response.rows
total.value = response.total
loading.value = false
@@ -229,7 +200,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -252,7 +223,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getFutureStocksBill(_id).then(response => {
getFutureStocksBill(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改期货账单'
@@ -261,16 +232,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.futureStocksBillRef.validate(valid => {
proxy.$refs.futureStocksBillRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateFutureStocksBill(form.value).then(response => {
updateFutureStocksBill(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addFutureStocksBill(form.value).then(response => {
addFutureStocksBill(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -283,19 +254,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delFutureStocksBill(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/futureStocksBill/export', {
proxy.download(
'invest/futureStocksBill/export',
{
...queryParams.value
}, `futureStocksBill_${new Date().getTime()}.xlsx`)
},
`futureStocksBill_${new Date().getTime()}.xlsx`
)
}
getFutureStocksList()
getList()

View File

@@ -4,21 +4,11 @@
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="标题" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入标题"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入标题" clearable @keyup.enter="handleQuery" />
</el-form-item>
<el-form-item label="类型" prop="type">
<el-select v-model="queryParams.type" placeholder="请选择类型" clearable>
<el-option
v-for="dict in journey_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
<el-option v-for="dict in journey_type" :key="dict.value" :label="dict.label" :value="dict.value" />
</el-select>
</el-form-item>
</el-form>
@@ -31,27 +21,13 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:heartJourney:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:heartJourney:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:heartJourney:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:heartJourney:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:heartJourney:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:heartJourney:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-scrollbar>
<el-table v-loading="loading" :data="heartJourneyList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="heartJourneyList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="标题" align="center" width="200" prop="name" />
<el-table-column label="类型" align="center" width="100" prop="type">
@@ -72,7 +48,6 @@
</el-table-column>
</el-table>
<el-pagination small background layout="total, prev, pager, next" :total="total" @current-change="handleCurrentChange" />
</el-scrollbar>
</div>
</div>
<!-- 添加或修改心路历程对话框 -->
@@ -83,21 +58,11 @@
</el-form-item>
<el-form-item label="类型" prop="type">
<el-select v-model="form.type" placeholder="请选择类型">
<el-option
v-for="dict in journey_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in journey_type" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="时间" prop="createTime">
<el-date-picker clearable
v-model="form.createTime"
type="datetime"
value-format="YYYY-MM-DD HH:mm:ss"
placeholder="请选择时间">
</el-date-picker>
<el-date-picker clearable v-model="form.createTime" type="datetime" value-format="YYYY-MM-DD HH:mm:ss" placeholder="请选择时间"> </el-date-picker>
</el-form-item>
<el-form-item label="内容">
<el-input v-model="form.remark" type="textarea" rows="12" placeholder="请输入内容" />
@@ -143,18 +108,10 @@ const data = reactive({
type: null
},
rules: {
name: [
{ required: true, message: '标题不能为空', trigger: 'blur' }
],
type: [
{ required: true, message: '类型不能为空', trigger: 'change' }
],
createTime: [
{ required: true, message: '创建时间不能为空', trigger: 'blur' }
],
remark: [
{ required: true, message: '内容不能为空', trigger: 'blur' }
]
name: [{ required: true, message: '标题不能为空', trigger: 'blur' }],
type: [{ required: true, message: '类型不能为空', trigger: 'change' }],
createTime: [{ required: true, message: '创建时间不能为空', trigger: 'blur' }],
remark: [{ required: true, message: '内容不能为空', trigger: 'blur' }]
}
})
@@ -179,7 +136,7 @@ const { queryParams, form, rules } = toRefs(data)
/** 查询心路历程列表 */
function getList() {
loading.value = true
listHeartJourney(queryParams.value).then(response => {
listHeartJourney(queryParams.value).then((response) => {
heartJourneyList.value = response.rows
total.value = response.total
loading.value = false
@@ -228,7 +185,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -251,7 +208,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getHeartJourney(_id).then(response => {
getHeartJourney(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改心路历程'
@@ -260,16 +217,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.heartJourneyRef.validate(valid => {
proxy.$refs.heartJourneyRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateHeartJourney(form.value).then(response => {
updateHeartJourney(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addHeartJourney(form.value).then(response => {
addHeartJourney(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -282,19 +239,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delHeartJourney(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/heartJourney/export', {
proxy.download(
'invest/heartJourney/export',
{
...queryParams.value
}, `heartJourney_${new Date().getTime()}.xlsx`)
},
`heartJourney_${new Date().getTime()}.xlsx`
)
}
getList()

View File

@@ -29,8 +29,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-scrollbar>
<el-table v-loading="loading" :data="accountDealRecordList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="accountDealRecordList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column label="账户名称" align="center" prop="accountName" />
<el-table-column label="交易时间" align="center" prop="createTime" />
<el-table-column label="交易金额" align="center" prop="amount" />
@@ -40,7 +39,7 @@
<dict-tag :options="profit_loss" :value="scope.row.dealType" />
</template>
</el-table-column>
<el-table-column label="备注" align="center" width="350" prop="remark" />
<el-table-column label="备注" align="center" prop="remark" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template v-slot="scope">
<div class="ctrl-btn d-flex">
@@ -52,7 +51,6 @@
</el-table-column>
</el-table>
<el-pagination small background layout="total, prev, pager, next" :total="total" @current-change="handleCurrentChange" />
</el-scrollbar>
</div>
</div>
<!-- 添加或修改投资交易记录对话框 -->

View File

@@ -3,12 +3,12 @@
<div class="search-con">
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="转入账户" style="width: 500px;" prop="inAccountId">
<el-form-item label="转入账户" style="width: 500px" prop="inAccountId">
<el-select v-model="queryParams.inAccountId" placeholder="请选择转入账户" clearable>
<el-option v-for="futruesStocks in futruesStocksList" :key="futruesStocks.id" :label="futruesStocks.nameDebitNameCode" :value="futruesStocks.id" />
</el-select>
</el-form-item>
<el-form-item label="转出账户" style="width: 500px;" prop="outAccountId">
<el-form-item label="转出账户" style="width: 500px" prop="outAccountId">
<el-select v-model="queryParams.outAccountId" placeholder="请选择转出账户" clearable>
<el-option v-for="futruesStocks in futruesStocksList" :key="futruesStocks.id" :label="futruesStocks.nameDebitNameCode" :value="futruesStocks.id" />
</el-select>
@@ -23,32 +23,24 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:accountsTransferRecord:add']"
>新增</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:accountsTransferRecord:add']">新增</el-button>
<!-- <el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:accountsTransferRecord:remove']"
>删除</el-button> -->
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:accountsTransferRecord:export']"
>导出</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:accountsTransferRecord:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="accountsTransferRecordList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="accountsTransferRecordList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<!-- <el-table-column type="selection" width="55" align="center" /> -->
<el-table-column label="名称" align="center" prop="name" />
<el-table-column label="转出账户" align="center" prop="outAccountName" />
<el-table-column label="转入账户" align="center" prop="inAccountName" />
<el-table-column label="转账时间" width='180' align="center" prop="createTime" />
<el-table-column label="转账金额" width='150' align="center" prop="amount" />
<el-table-column label="转账时间" width="180" align="center" prop="createTime" />
<el-table-column label="转账金额" width="150" align="center" prop="amount" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template v-slot="scope">
<div class="ctrl-btn d-flex">
@@ -72,21 +64,11 @@
</el-form-item>
<el-form-item label="交易类型" prop="dealType">
<el-select v-model="form.dealType" placeholder="请选择交易类型">
<el-option
v-for="dict in in_out"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in in_out" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="转账时间" prop="createTime">
<el-date-picker clearable
v-model="form.createTime"
type="datetime"
value-format="YYYY-MM-DD HH:mm:ss"
placeholder="请选择转账时间">
</el-date-picker>
<el-date-picker clearable v-model="form.createTime" type="datetime" value-format="YYYY-MM-DD HH:mm:ss" placeholder="请选择转账时间"> </el-date-picker>
</el-form-item>
<el-form-item label="转账金额" prop="amount">
<el-input v-model="form.amount" placeholder="请输入转账金额" />
@@ -106,7 +88,13 @@
</template>
<script setup name="AccountsTransferRecord">
import { listAccountsTransferRecord, getAccountsTransferRecord, delAccountsTransferRecord, addAccountsTransferRecord, updateAccountsTransferRecord } from '@/api/invest/accountsTransferRecord'
import {
listAccountsTransferRecord,
getAccountsTransferRecord,
delAccountsTransferRecord,
addAccountsTransferRecord,
updateAccountsTransferRecord
} from '@/api/invest/accountsTransferRecord'
import { listAccounts } from '@/api/invest/accounts'
import { listFutureStocks } from '@/api/invest/futureStocks'
@@ -165,18 +153,10 @@ const data = reactive({
pageSize: 1000
},
rules: {
inAccountId: [
{ required: true, message: '投资账户不能为空', trigger: 'blur' }
],
dealType: [
{ required: true, message: '交易类型不能为空', trigger: 'blur' }
],
amount: [
{ required: true, message: '转账金额不能为空', trigger: 'blur' }
],
createTime: [
{ required: true, message: '转账时间不能为空', trigger: 'blur' }
]
inAccountId: [{ required: true, message: '投资账户不能为空', trigger: 'blur' }],
dealType: [{ required: true, message: '交易类型不能为空', trigger: 'blur' }],
amount: [{ required: true, message: '转账金额不能为空', trigger: 'blur' }],
createTime: [{ required: true, message: '转账时间不能为空', trigger: 'blur' }]
}
})
@@ -222,7 +202,7 @@ function getFutruesStocksList() {
/** 查询投资账户记账列表 */
function getList() {
loading.value = true
listAccountsTransferRecord(queryParams.value).then(response => {
listAccountsTransferRecord(queryParams.value).then((response) => {
accountsTransferRecordList.value = response.rows
total.value = response.total
loading.value = false
@@ -278,7 +258,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -287,7 +267,7 @@ function handleSelectionChange (selection) {
const handleView = (row) => {
reset()
const _id = row.id || ids.value
getAccountsTransferRecord(_id).then(response => {
getAccountsTransferRecord(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '查看投资账户记账'
@@ -305,7 +285,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getAccountsTransferRecord(_id).then(response => {
getAccountsTransferRecord(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改投资账户记账'
@@ -314,16 +294,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.accountsTransferRecordRef.validate(valid => {
proxy.$refs.accountsTransferRecordRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateAccountsTransferRecord(form.value).then(response => {
updateAccountsTransferRecord(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addAccountsTransferRecord(form.value).then(response => {
addAccountsTransferRecord(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -336,19 +316,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delAccountsTransferRecord(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/accountsTransferRecord/export', {
proxy.download(
'invest/accountsTransferRecord/export',
{
...queryParams.value
}, `accountsTransferRecord_${new Date().getTime()}.xlsx`)
},
`accountsTransferRecord_${new Date().getTime()}.xlsx`
)
}
getFutruesStocksList()
getDebitList()

View File

@@ -4,12 +4,7 @@
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="借贷名称" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入借贷名称"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入借贷名称" clearable @keyup.enter="handleQuery" />
</el-form-item>
</el-form>
<div class="search-btn-con">
@@ -21,26 +16,13 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:bankcard:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:bankcard:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:bankcard:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:bankcard:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:bankcard:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:bankcard:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="bankcardList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="bankcardList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="借贷名称" align="center" prop="name" />
<el-table-column label="编号" align="center" prop="code" />
@@ -74,12 +56,7 @@
</el-form-item>
<el-form-item label="类型" prop="lendType">
<el-select v-model="form.lendType" placeholder="请选择类型">
<el-option
v-for="dict in lend_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in lend_type" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="备注" prop="remark">
@@ -126,12 +103,8 @@ const data = reactive({
type: '3'
},
rules: {
name: [
{ required: true, message: '借贷名称不能为空', trigger: 'blur' }
],
lendType: [
{ required: true, message: '类型不能为空', trigger: 'blur' }
]
name: [{ required: true, message: '借贷名称不能为空', trigger: 'blur' }],
lendType: [{ required: true, message: '类型不能为空', trigger: 'blur' }]
}
})
@@ -156,7 +129,7 @@ const { queryParams, form, rules } = toRefs(data)
/** 查询网贷信息列表 */
function getList() {
loading.value = true
listBankcardLend(queryParams.value).then(response => {
listBankcardLend(queryParams.value).then((response) => {
bankcardList.value = response.rows
total.value = response.total
loading.value = false
@@ -215,7 +188,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -238,7 +211,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getBankcardLend(_id).then(response => {
getBankcardLend(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改网贷信息'
@@ -247,16 +220,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.bankcardRef.validate(valid => {
proxy.$refs.bankcardRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateBankcardLend(form.value).then(response => {
updateBankcardLend(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addBankcardLend(form.value).then(response => {
addBankcardLend(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -269,19 +242,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delBankcardLend(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/bankcard/export', {
proxy.download(
'invest/bankcard/export',
{
...queryParams.value
}, `bankcard_${new Date().getTime()}.xlsx`)
},
`bankcard_${new Date().getTime()}.xlsx`
)
}
getList()

View File

@@ -3,12 +3,12 @@
<div class="search-con">
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="转入账户" style="width: 500px;" prop="inAccountId">
<el-form-item label="转入账户" style="width: 500px" prop="inAccountId">
<el-select v-model="queryParams.inAccountId" placeholder="请选择转入账户" clearable>
<el-option v-for="lend in lendList" :key="lend.id" :label="lend.nameCode" :value="lend.id" />
</el-select>
</el-form-item>
<el-form-item label="转出账户" style="width: 500px;" prop="outAccountId">
<el-form-item label="转出账户" style="width: 500px" prop="outAccountId">
<el-select v-model="queryParams.outAccountId" placeholder="请选择转出账户" clearable>
<el-option v-for="lend in lendList" :key="lend.id" :label="lend.nameCode" :value="lend.id" />
</el-select>
@@ -23,32 +23,24 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:accountsTransferRecord:add']"
>新增</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:accountsTransferRecord:add']">新增</el-button>
<!-- <el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:accountsTransferRecord:remove']"
>删除</el-button> -->
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:accountsTransferRecord:export']"
>导出</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:accountsTransferRecord:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="accountsTransferRecordList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="accountsTransferRecordList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<!-- <el-table-column type="selection" width="55" align="center" /> -->
<el-table-column label="名称" align="center" prop="name" />
<el-table-column label="转出账户" align="center" prop="outAccountName" />
<el-table-column label="转入账户" align="center" prop="inAccountName" />
<el-table-column label="借贷时间" width='180' align="center" prop="createTime" />
<el-table-column label="借贷金额" width='150' align="center" prop="amount" />
<el-table-column label="借贷时间" width="180" align="center" prop="createTime" />
<el-table-column label="借贷金额" width="150" align="center" prop="amount" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template v-slot="scope">
<div class="ctrl-btn d-flex">
@@ -77,21 +69,11 @@
</el-form-item>
<el-form-item label="交易类型" prop="dealType">
<el-select v-model="form.dealType" placeholder="请选择交易类型">
<el-option
v-for="dict in record_lend_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in record_lend_type" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="借贷时间" prop="createTime">
<el-date-picker clearable
v-model="form.createTime"
type="datetime"
value-format="YYYY-MM-DD HH:mm:ss"
placeholder="请选择借贷时间">
</el-date-picker>
<el-date-picker clearable v-model="form.createTime" type="datetime" value-format="YYYY-MM-DD HH:mm:ss" placeholder="请选择借贷时间"> </el-date-picker>
</el-form-item>
<el-form-item label="借贷金额" prop="amount">
<el-input v-model="form.amount" placeholder="请输入借贷金额" />
@@ -111,7 +93,13 @@
</template>
<script setup name="AccountsTransferRecord">
import { listAccountsTransferRecord, getAccountsTransferRecord, delAccountsTransferRecord, addAccountsTransferRecord, updateAccountsTransferRecord } from '@/api/invest/accountsTransferRecord'
import {
listAccountsTransferRecord,
getAccountsTransferRecord,
delAccountsTransferRecord,
addAccountsTransferRecord,
updateAccountsTransferRecord
} from '@/api/invest/accountsTransferRecord'
import { listAccounts } from '@/api/invest/accounts'
// eslint-disable-next-line no-unused-vars
import { require } from '@/utils/require'
@@ -159,21 +147,11 @@ const data = reactive({
pageSize: 1000
},
rules: {
inAccountId: [
{ required: true, message: '借贷账户不能为空', trigger: 'blur' }
],
outAccountId: [
{ required: true, message: '储蓄卡不能为空', trigger: 'blur' }
],
dealType: [
{ required: true, message: '交易类型不能为空', trigger: 'blur' }
],
amount: [
{ required: true, message: '借贷金额不能为空', trigger: 'blur' }
],
createTime: [
{ required: true, message: '借贷时间不能为空', trigger: 'blur' }
]
inAccountId: [{ required: true, message: '借贷账户不能为空', trigger: 'blur' }],
outAccountId: [{ required: true, message: '储蓄卡不能为空', trigger: 'blur' }],
dealType: [{ required: true, message: '交易类型不能为空', trigger: 'blur' }],
amount: [{ required: true, message: '借贷金额不能为空', trigger: 'blur' }],
createTime: [{ required: true, message: '借贷时间不能为空', trigger: 'blur' }]
}
})
@@ -212,7 +190,7 @@ function getDebitList() {
/** 查询借贷记账列表 */
function getList() {
loading.value = true
listAccountsTransferRecord(queryParams.value).then(response => {
listAccountsTransferRecord(queryParams.value).then((response) => {
accountsTransferRecordList.value = response.rows
total.value = response.total
loading.value = false
@@ -268,7 +246,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -291,7 +269,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getAccountsTransferRecord(_id).then(response => {
getAccountsTransferRecord(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改借贷记账'
@@ -300,16 +278,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.accountsTransferRecordRef.validate(valid => {
proxy.$refs.accountsTransferRecordRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateAccountsTransferRecord(form.value).then(response => {
updateAccountsTransferRecord(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addAccountsTransferRecord(form.value).then(response => {
addAccountsTransferRecord(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -322,19 +300,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delAccountsTransferRecord(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/accountsTransferRecord/export', {
proxy.download(
'invest/accountsTransferRecord/export',
{
...queryParams.value
}, `accountsTransferRecord_${new Date().getTime()}.xlsx`)
},
`accountsTransferRecord_${new Date().getTime()}.xlsx`
)
}
getDebitList()
getLendList()

View File

@@ -29,8 +29,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-scrollbar>
<el-table v-loading="loading" :data="installmentHistoryList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="installmentHistoryList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="网贷机构" align="center" width="150" prop="bankNameCode" />
<el-table-column label="借款金额" align="center" prop="installmentAmount" />
@@ -76,7 +75,6 @@
</el-table-column>
</el-table>
<el-pagination small background layout="total, prev, pager, next" :total="total" @current-change="handleCurrentChange" />
</el-scrollbar>
</div>
</div>
<!-- 添加或修改网络贷款对话框 -->

View File

@@ -10,12 +10,7 @@
</el-form-item>
<el-form-item label="账户状态" prop="state">
<el-select v-model="queryParams.state" placeholder="请选择账户状态" clearable>
<el-option
v-for="dict in settle_state"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
<el-option v-for="dict in settle_state" :key="dict.value" :label="dict.label" :value="dict.value" />
</el-select>
</el-form-item>
</el-form>
@@ -28,28 +23,15 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:installmentHistory:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:installmentHistory:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:installmentHistory:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:installmentHistory:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:installmentHistory:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:installmentHistory:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="installmentHistoryList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="installmentHistoryList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="人情借贷" align="center" width='200' prop="bankNameCode" />
<el-table-column label="人情借贷" align="center" width="200" prop="bankNameCode" />
<el-table-column label="借款金额" align="center" prop="installmentAmount" />
<el-table-column label="借款日期" align="center" prop="installmentDate" width="180">
<template #default="scope">
@@ -61,7 +43,7 @@
<span>{{ parseTime(scope.row.closeDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="账户状态" align="center" width='100' prop="state">
<el-table-column label="账户状态" align="center" width="100" prop="state">
<template #default="scope">
<dict-tag :options="settle_state" :value="scope.row.state" />
</template>
@@ -92,29 +74,14 @@
<el-input v-model="form.installmentAmount" placeholder="请输入借款金额" />
</el-form-item>
<el-form-item label="借款日期" prop="installmentDate">
<el-date-picker clearable
v-model="form.installmentDate"
type="date"
value-format="YYYY-MM-DD"
placeholder="请选择借款日期">
</el-date-picker>
<el-date-picker clearable v-model="form.installmentDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择借款日期"> </el-date-picker>
</el-form-item>
<el-form-item label="还款日期" prop="closeDate">
<el-date-picker clearable
v-model="form.closeDate"
type="date"
value-format="YYYY-MM-DD"
placeholder="请选择还款日期">
</el-date-picker>
<el-date-picker clearable v-model="form.closeDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择还款日期"> </el-date-picker>
</el-form-item>
<el-form-item label="账户状态" prop="state">
<el-select v-model="form.state" placeholder="请选择账户状态">
<el-option
v-for="dict in settle_state"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in settle_state" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="备注" prop="remark">
@@ -132,7 +99,13 @@
</template>
<script setup name="InstallmentHistory">
import { listInstallmentHistory, getInstallmentHistory, delInstallmentHistory, addInstallmentHistory, updateInstallmentHistory } from '@/api/invest/installmentHistory'
import {
listInstallmentHistory,
getInstallmentHistory,
delInstallmentHistory,
addInstallmentHistory,
updateInstallmentHistory
} from '@/api/invest/installmentHistory'
import { listBankcardLend } from '@/api/invest/bankcardlend'
// eslint-disable-next-line no-unused-vars
import { require } from '@/utils/require'
@@ -171,18 +144,10 @@ const data = reactive({
pageSize: 1000
},
rules: {
bankCardLendId: [
{ required: true, message: '人情借贷不能为空', trigger: 'blur' }
],
installmentAmount: [
{ required: true, message: '借款金额不能为空', trigger: 'blur' }
],
installmentDate: [
{ required: true, message: '借款日期不能为空', trigger: 'blur' }
],
state: [
{ required: true, message: '账户状态不能为空', trigger: 'change' }
]
bankCardLendId: [{ required: true, message: '人情借贷不能为空', trigger: 'blur' }],
installmentAmount: [{ required: true, message: '借款金额不能为空', trigger: 'blur' }],
installmentDate: [{ required: true, message: '借款日期不能为空', trigger: 'blur' }],
state: [{ required: true, message: '账户状态不能为空', trigger: 'change' }]
}
})
@@ -214,7 +179,7 @@ function getCreditCardList() {
/** 查询人情借贷列表 */
function getList() {
loading.value = true
listInstallmentHistory(queryParams.value).then(response => {
listInstallmentHistory(queryParams.value).then((response) => {
installmentHistoryList.value = response.rows
total.value = response.total
loading.value = false
@@ -274,7 +239,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -297,7 +262,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getInstallmentHistory(_id).then(response => {
getInstallmentHistory(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改人情借贷'
@@ -306,16 +271,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.installmentHistoryRef.validate(valid => {
proxy.$refs.installmentHistoryRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateInstallmentHistory(form.value).then(response => {
updateInstallmentHistory(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addInstallmentHistory(form.value).then(response => {
addInstallmentHistory(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -328,19 +293,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delInstallmentHistory(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/installmentHistory/export', {
proxy.download(
'invest/installmentHistory/export',
{
...queryParams.value
}, `installmentHistory_${new Date().getTime()}.xlsx`)
},
`installmentHistory_${new Date().getTime()}.xlsx`
)
}
getCreditCardList()
getList()

View File

@@ -3,12 +3,12 @@
<div class="search-con">
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="POS机" style="width: 500px;" prop="posId">
<el-form-item label="POS机" style="width: 500px" prop="posId">
<el-select v-model="queryParams.posId" placeholder="请选择POS机" clearable>
<el-option v-for="pos in posMachineList" :key="pos.id" :label="pos.nameMerchantName" :value="pos.id" />
</el-select>
</el-form-item>
<el-form-item label="信用卡" style="width: 500px;" prop="outAccountId">
<el-form-item label="信用卡" style="width: 500px" prop="outAccountId">
<el-select v-model="queryParams.outAccountId" placeholder="请选择信用卡" clearable>
<el-option v-for="creditCard in bankCardLendList" :key="creditCard.id" :label="creditCard.nameCode" :value="creditCard.id" />
</el-select>
@@ -23,35 +23,27 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:accountsTransferRecord:add']"
>新增</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:accountsTransferRecord:add']">新增</el-button>
<!-- <el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:accountsTransferRecord:remove']"
>删除</el-button> -->
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:accountsTransferRecord:export']"
>导出</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:accountsTransferRecord:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="accountsTransferRecordList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="accountsTransferRecordList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<!-- <el-table-column type="selection" width="55" align="center" /> -->
<el-table-column label="POS机名称" align="center" prop="posName" />
<el-table-column label="刷卡商户" align="center" prop="merchantName" />
<el-table-column label="刷卡时间" align="center" prop="createTime" />
<el-table-column label="信用卡" align="center" prop="outAccountName" />
<el-table-column label="交易金额" align="center" prop="amount" />
<el-table-column label="手续费" width='100' align="center" prop="commission" />
<el-table-column label="手续费" width="100" align="center" prop="commission" />
<el-table-column label="储蓄卡" align="center" prop="inAccountName" />
<el-table-column label="入账金额" width='120' align="center" prop="actualAmount" />
<el-table-column label="入账金额" width="120" align="center" prop="actualAmount" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template v-slot="scope">
<div class="ctrl-btn d-flex">
@@ -79,12 +71,7 @@
</el-select>
</el-form-item>
<el-form-item label="刷卡时间" prop="createTime">
<el-date-picker clearable
v-model="form.createTime"
type="datetime"
value-format="YYYY-MM-DD HH:mm:ss"
placeholder="请选择刷卡时间">
</el-date-picker>
<el-date-picker clearable v-model="form.createTime" type="datetime" value-format="YYYY-MM-DD HH:mm:ss" placeholder="请选择刷卡时间"> </el-date-picker>
</el-form-item>
<el-form-item label="刷卡金额" prop="amount">
<el-input v-model="form.amount" placeholder="请输入刷卡金额" />
@@ -104,7 +91,13 @@
</template>
<script setup name="AccountsTransferRecord">
import { listAccountsTransferRecord, getAccountsTransferRecord, delAccountsTransferRecord, addAccountsTransferRecord, updateAccountsTransferRecord } from '@/api/invest/accountsTransferRecord'
import {
listAccountsTransferRecord,
getAccountsTransferRecord,
delAccountsTransferRecord,
addAccountsTransferRecord,
updateAccountsTransferRecord
} from '@/api/invest/accountsTransferRecord'
import { listPosmachine } from '@/api/invest/posmachine'
import { listAccounts } from '@/api/invest/accounts'
// eslint-disable-next-line no-unused-vars
@@ -157,18 +150,10 @@ const data = reactive({
pageSize: 1000
},
rules: {
outAccountId: [
{ required: true, message: '信用卡不能为空', trigger: 'blur' }
],
posId: [
{ required: true, message: 'POS机不能为空', trigger: 'blur' }
],
amount: [
{ required: true, message: '刷卡金额不能为空', trigger: 'blur' }
],
createTime: [
{ required: true, message: '刷卡时间不能为空', trigger: 'blur' }
]
outAccountId: [{ required: true, message: '信用卡不能为空', trigger: 'blur' }],
posId: [{ required: true, message: 'POS机不能为空', trigger: 'blur' }],
amount: [{ required: true, message: '刷卡金额不能为空', trigger: 'blur' }],
createTime: [{ required: true, message: '刷卡时间不能为空', trigger: 'blur' }]
}
})
@@ -214,7 +199,7 @@ function getFutruesStocksList() {
/** 查询POS机刷卡列表 */
function getList() {
loading.value = true
listAccountsTransferRecord(queryParams.value).then(response => {
listAccountsTransferRecord(queryParams.value).then((response) => {
accountsTransferRecordList.value = response.rows
total.value = response.total
loading.value = false
@@ -270,7 +255,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -293,7 +278,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getAccountsTransferRecord(_id).then(response => {
getAccountsTransferRecord(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改POS机刷卡'
@@ -302,16 +287,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.accountsTransferRecordRef.validate(valid => {
proxy.$refs.accountsTransferRecordRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateAccountsTransferRecord(form.value).then(response => {
updateAccountsTransferRecord(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addAccountsTransferRecord(form.value).then(response => {
addAccountsTransferRecord(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -324,19 +309,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delAccountsTransferRecord(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/accountsTransferRecord/export', {
proxy.download(
'invest/accountsTransferRecord/export',
{
...queryParams.value
}, `accountsTransferRecord_${new Date().getTime()}.xlsx`)
},
`accountsTransferRecord_${new Date().getTime()}.xlsx`
)
}
getFutruesStocksList()
getPosMachineList()

View File

@@ -4,30 +4,15 @@
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="pos机名称" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入pos机名称"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入pos机名称" clearable @keyup.enter="handleQuery" />
</el-form-item>
<el-form-item label="类型" prop="type">
<el-select v-model="queryParams.type" placeholder="请选择类型" clearable>
<el-option
v-for="dict in pos_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
<el-option v-for="dict in pos_type" :key="dict.value" :label="dict.label" :value="dict.value" />
</el-select>
</el-form-item>
<el-form-item label="商户名称" prop="merchantName">
<el-input
v-model="queryParams.merchantName"
placeholder="请输入商户名称"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.merchantName" placeholder="请输入商户名称" clearable @keyup.enter="handleQuery" />
</el-form-item>
</el-form>
<div class="search-btn-con">
@@ -39,26 +24,13 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:posmachine:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:posmachine:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:posmachine:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:posmachine:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:posmachine:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:posmachine:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="posmachineList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="posmachineList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="pos机名称" align="center" prop="name" />
<el-table-column label="支付公司" align="center" prop="payCompany" />
@@ -98,12 +70,7 @@
</el-form-item>
<el-form-item label="类型" prop="type">
<el-select v-model="form.type" placeholder="请选择类型">
<el-option
v-for="dict in pos_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in pos_type" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="编号" prop="code">
@@ -128,24 +95,14 @@
</el-form-item>
<el-form-item label="商户类型" prop="merchantType">
<el-select v-model="form.merchantType" placeholder="请选择商户类型">
<el-option
v-for="dict in merchant_type"
:key="dict.value"
:label="dict.label"
:value="dict.value"
></el-option>
<el-option v-for="dict in merchant_type" :key="dict.value" :label="dict.label" :value="dict.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="商户码" prop="merchantCode">
<el-input v-model="form.merchantCode" placeholder="请输入商户码" />
</el-form-item>
<el-form-item label="启用日期" prop="activationDate">
<el-date-picker clearable
v-model="form.activationDate"
type="date"
value-format="YYYY-MM-DD"
placeholder="请选择启用日期">
</el-date-picker>
<el-date-picker clearable v-model="form.activationDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择启用日期"> </el-date-picker>
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="form.remark" type="textarea" placeholder="请输入备注" />
@@ -199,33 +156,15 @@ const data = reactive({
pageSize: 1000
},
rules: {
name: [
{ required: true, message: 'pos机名称不能为空', trigger: 'blur' }
],
code: [
{ required: true, message: '编码不能为空', trigger: 'blur' }
],
payCompany: [
{ required: true, message: '支付公司不能为空', trigger: 'blur' }
],
type: [
{ required: true, message: '类型不能为空', trigger: 'change' }
],
manufacture: [
{ required: true, message: '厂商不能为空', trigger: 'blur' }
],
merchantName: [
{ required: true, message: '商户名称不能为空', trigger: 'blur' }
],
rate: [
{ required: true, message: '刷卡费率不能为空', trigger: 'blur' }
],
debitCard: [
{ required: true, message: '结算卡不能为空', trigger: 'blur' }
],
merchantType: [
{ required: true, message: '商户类型不能为空', trigger: 'change' }
]
name: [{ required: true, message: 'pos机名称不能为空', trigger: 'blur' }],
code: [{ required: true, message: '编码不能为空', trigger: 'blur' }],
payCompany: [{ required: true, message: '支付公司不能为空', trigger: 'blur' }],
type: [{ required: true, message: '类型不能为空', trigger: 'change' }],
manufacture: [{ required: true, message: '厂商不能为空', trigger: 'blur' }],
merchantName: [{ required: true, message: '商户名称不能为空', trigger: 'blur' }],
rate: [{ required: true, message: '刷卡费率不能为空', trigger: 'blur' }],
debitCard: [{ required: true, message: '结算卡不能为空', trigger: 'blur' }],
merchantType: [{ required: true, message: '商户类型不能为空', trigger: 'change' }]
}
})
@@ -257,7 +196,7 @@ function getDebitCardList() {
/** 查询pos机信息列表 */
function getList() {
loading.value = true
listPosmachine(queryParams.value).then(response => {
listPosmachine(queryParams.value).then((response) => {
posmachineList.value = response.rows
total.value = response.total
loading.value = false
@@ -315,7 +254,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -338,7 +277,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getPosmachine(_id).then(response => {
getPosmachine(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改pos机信息'
@@ -347,16 +286,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.posmachineRef.validate(valid => {
proxy.$refs.posmachineRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updatePosmachine(form.value).then(response => {
updatePosmachine(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addPosmachine(form.value).then(response => {
addPosmachine(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -369,19 +308,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delPosmachine(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/posmachine/export', {
proxy.download(
'invest/posmachine/export',
{
...queryParams.value
}, `posmachine_${new Date().getTime()}.xlsx`)
},
`posmachine_${new Date().getTime()}.xlsx`
)
}
getDebitCardList()
getList()

View File

@@ -4,12 +4,7 @@
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="100px">
<el-form-item label="名称" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入名称"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入名称" clearable @keyup.enter="handleQuery" />
</el-form-item>
</el-form>
<div class="search-btn-con">
@@ -21,26 +16,13 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:futureStocks:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:futureStocks:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:futureStocks:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:futureStocks:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:futureStocks:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:futureStocks:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="futureStocksList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="futureStocksList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="名称" align="center" prop="name" />
<el-table-column label="账号" align="center" prop="code" />
@@ -83,12 +65,7 @@
</el-select>
</el-form-item>
<el-form-item label="开户日期" prop="activationDate">
<el-date-picker clearable
v-model="form.activationDate"
type="date"
value-format="YYYY-MM-DD"
placeholder="请选择开户日期">
</el-date-picker>
<el-date-picker clearable v-model="form.activationDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择开户日期"> </el-date-picker>
</el-form-item>
<el-form-item label="手续费" prop="commission">
<el-input v-model="form.commission" placeholder="请输入手续费" />
@@ -144,30 +121,14 @@ const data = reactive({
pageSize: 1000
},
rules: {
name: [
{ required: true, message: '名称不能为空', trigger: 'blur' }
],
code: [
{ required: true, message: '账号不能为空', trigger: 'blur' }
],
password: [
{ required: true, message: '密码不能为空', trigger: 'blur' }
],
tradingCenterCode: [
{ required: true, message: '期货交易中心账号不能为空', trigger: 'blur' }
],
tradingCenterPassword: [
{ required: true, message: '期货交易中心密码不能为空', trigger: 'blur' }
],
fundPassword: [
{ required: true, message: '资金密码不能为空', trigger: 'blur' }
],
debitCard: [
{ required: true, message: '关联储蓄卡不能为空', trigger: 'blur' }
],
activationDate: [
{ required: true, message: '开户日期不能为空', trigger: 'blur' }
]
name: [{ required: true, message: '名称不能为空', trigger: 'blur' }],
code: [{ required: true, message: '账号不能为空', trigger: 'blur' }],
password: [{ required: true, message: '密码不能为空', trigger: 'blur' }],
tradingCenterCode: [{ required: true, message: '期货交易中心账号不能为空', trigger: 'blur' }],
tradingCenterPassword: [{ required: true, message: '期货交易中心密码不能为空', trigger: 'blur' }],
fundPassword: [{ required: true, message: '资金密码不能为空', trigger: 'blur' }],
debitCard: [{ required: true, message: '关联储蓄卡不能为空', trigger: 'blur' }],
activationDate: [{ required: true, message: '开户日期不能为空', trigger: 'blur' }]
}
})
@@ -199,7 +160,7 @@ function getDebitCardList() {
/** 查询股票信息列表 */
function getList() {
loading.value = true
listFutureStocks(queryParams.value).then(response => {
listFutureStocks(queryParams.value).then((response) => {
futureStocksList.value = response.rows
total.value = response.total
loading.value = false
@@ -257,7 +218,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -280,7 +241,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getFutureStocks(_id).then(response => {
getFutureStocks(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改股票信息'
@@ -289,16 +250,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.futureStocksRef.validate(valid => {
proxy.$refs.futureStocksRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateFutureStocks(form.value).then(response => {
updateFutureStocks(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addFutureStocks(form.value).then(response => {
addFutureStocks(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -311,19 +272,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delFutureStocks(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/futureStocks/export', {
proxy.download(
'invest/futureStocks/export',
{
...queryParams.value
}, `futureStocks_${new Date().getTime()}.xlsx`)
},
`futureStocks_${new Date().getTime()}.xlsx`
)
}
getDebitCardList()
getList()

View File

@@ -9,12 +9,7 @@
</el-select>
</el-form-item>
<el-form-item label="账单名称" prop="name">
<el-input
v-model="queryParams.name"
placeholder="请输入账单名称"
clearable
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.name" placeholder="请输入账单名称" clearable @keyup.enter="handleQuery" />
</el-form-item>
</el-form>
<div class="search-btn-con">
@@ -26,26 +21,13 @@
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button
@click="handleAdd"
icon="Plus"
v-hasPermi="['invest:futureStocksBill:add']"
>新增</el-button>
<el-button
:disabled="multiple"
icon="Delete"
@click="handleDelete"
v-hasPermi="['invest:futureStocksBill:remove']"
>删除</el-button>
<el-button
@click="handleExport"
icon="Download"
v-hasPermi="['invest:futureStocksBill:export']"
>导出</el-button>
<el-button @click="handleAdd" icon="Plus" v-hasPermi="['invest:futureStocksBill:add']">新增</el-button>
<el-button :disabled="multiple" icon="Delete" @click="handleDelete" v-hasPermi="['invest:futureStocksBill:remove']">删除</el-button>
<el-button @click="handleExport" icon="Download" v-hasPermi="['invest:futureStocksBill:export']">导出</el-button>
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="futureStocksBillList" @selection-change="handleSelectionChange">
<el-table v-loading="loading" :data="futureStocksBillList" @selection-change="handleSelectionChange" height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="股票账户" align="center" prop="futureStocksNameCode" />
<el-table-column label="账单名称" align="center" prop="name" />
@@ -73,12 +55,7 @@
</el-select>
</el-form-item>
<el-form-item label="账单日" prop="billDate">
<el-date-picker clearable
v-model="form.billDate"
type="date"
value-format="YYYY-MM-DD"
placeholder="请选择账单日">
</el-date-picker>
<el-date-picker clearable v-model="form.billDate" type="date" value-format="YYYY-MM-DD" placeholder="请选择账单日"> </el-date-picker>
</el-form-item>
<el-form-item label="股票收益" prop="billAmount">
<el-input v-model="form.billAmount" placeholder="请输入股票收益" />
@@ -135,15 +112,9 @@ const data = reactive({
pageSize: 1000
},
rules: {
billDate: [
{ required: true, message: '账单日不能为空', trigger: 'blur' }
],
futureStocksId: [
{ required: true, message: '股票账户不能为空', trigger: 'blur' }
],
billAmount: [
{ required: true, message: '股票收益不能为空', trigger: 'blur' }
]
billDate: [{ required: true, message: '账单日不能为空', trigger: 'blur' }],
futureStocksId: [{ required: true, message: '股票账户不能为空', trigger: 'blur' }],
billAmount: [{ required: true, message: '股票收益不能为空', trigger: 'blur' }]
}
})
@@ -175,7 +146,7 @@ function getFutureStocksList() {
/** 查询股票账单列表 */
function getList() {
loading.value = true
listFutureStocksBill(queryParams.value).then(response => {
listFutureStocksBill(queryParams.value).then((response) => {
futureStocksBillList.value = response.rows
total.value = response.total
loading.value = false
@@ -229,7 +200,7 @@ const handleCurrentChange = (val) => {
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.id)
ids.value = selection.map((item) => item.id)
single.value = selection.length !== 1
multiple.value = !selection.length
}
@@ -252,7 +223,7 @@ function handleAdd () {
function handleUpdate(row) {
reset()
const _id = row.id || ids.value
getFutureStocksBill(_id).then(response => {
getFutureStocksBill(_id).then((response) => {
form.value = response.data
open.value = true
title.value = '修改股票账单'
@@ -261,16 +232,16 @@ function handleUpdate (row) {
/** 提交按钮 */
function submitForm() {
proxy.$refs.futureStocksBillRef.validate(valid => {
proxy.$refs.futureStocksBillRef.validate((valid) => {
if (valid) {
if (form.value.id != null) {
updateFutureStocksBill(form.value).then(response => {
updateFutureStocksBill(form.value).then((response) => {
proxy.$modal.msgSuccess('修改成功')
open.value = false
getList()
})
} else {
addFutureStocksBill(form.value).then(response => {
addFutureStocksBill(form.value).then((response) => {
proxy.$modal.msgSuccess('新增成功')
open.value = false
getList()
@@ -283,19 +254,27 @@ function submitForm () {
/** 删除按钮操作 */
function handleDelete(row) {
const _ids = row.id || ids.value
proxy.$modal.confirm('是否确认删除选中的数据项?').then(function() {
proxy.$modal
.confirm('是否确认删除选中的数据项?')
.then(function () {
return delFutureStocksBill(_ids)
}).then(() => {
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
}).catch(() => {})
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download('invest/futureStocksBill/export', {
proxy.download(
'invest/futureStocksBill/export',
{
...queryParams.value
}, `futureStocksBill_${new Date().getTime()}.xlsx`)
},
`futureStocksBill_${new Date().getTime()}.xlsx`
)
}
getFutureStocksList()
getList()

View File

@@ -35,7 +35,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="jobList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.64rem)">
<el-table v-loading="loading" :data="jobList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="任务编号" width="100" align="center" prop="jobId" />
<el-table-column label="任务名称" align="center" prop="jobName" :show-overflow-tooltip="true" />

View File

@@ -1,43 +1,19 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch" label-width="68px">
<div class="search-con" ref="searchHeightRef">
<div class="title">查询条件</div>
<el-form :model="queryParams" ref="queryRef" :inline="true" v-show="showSearch">
<el-form-item label="任务名称" prop="jobName">
<el-input
v-model="queryParams.jobName"
placeholder="请输入任务名称"
clearable
style="width: 240px"
@keyup.enter="handleQuery"
/>
<el-input v-model="queryParams.jobName" placeholder="请输入任务名称" clearable style="width: 200px" @keyup.enter="handleQuery" />
</el-form-item>
<el-form-item label="任务组名" prop="jobGroup">
<el-select
v-model="queryParams.jobGroup"
placeholder="请选择任务组名"
clearable
style="width: 240px"
>
<el-option
v-for="dict in sys_job_group"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
<el-select v-model="queryParams.jobGroup" placeholder="请选择任务组名" clearable style="width: 200px">
<el-option v-for="dict in sys_job_group" :key="dict.value" :label="dict.label" :value="dict.value" />
</el-select>
</el-form-item>
<el-form-item label="执行状态" prop="status">
<el-select
v-model="queryParams.status"
placeholder="请选择执行状态"
clearable
style="width: 240px"
>
<el-option
v-for="dict in sys_common_status"
:key="dict.value"
:label="dict.label"
:value="dict.value"
/>
<el-form-item label="任务状态" prop="status">
<el-select v-model="queryParams.status" placeholder="请选择任务状态" clearable style="width: 200px">
<el-option v-for="dict in sys_common_status" :key="dict.value" :label="dict.label" :value="dict.value" />
</el-select>
</el-form-item>
<el-form-item label="执行时间" style="width: 308px">
@@ -50,52 +26,24 @@
end-placeholder="结束日期"
></el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
<el-button icon="Refresh" @click="resetQuery">重置</el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="Delete"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['monitor:job:remove']"
>删除</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="Delete"
@click="handleClean"
v-hasPermi="['monitor:job:remove']"
>清空</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="Download"
@click="handleExport"
v-hasPermi="['monitor:job:export']"
>导出</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
plain
icon="Close"
@click="handleClose"
>关闭</el-button>
</el-col>
<right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<div class="search-btn-con">
<el-button type="primary" icon="Search" @click="handleQuery">搜索</el-button>
<el-button type="info" icon="Refresh" @click="resetQuery">重置</el-button>
</div>
</div>
<div class="main-con" :style="{ height: mainStyleHeight }">
<div class="title-con">
<div class="title">基本信息</div>
<div class="operate-btn-con">
<el-button icon="Delete" :disabled="multiple" @click="handleDelete" v-hasPermi="['monitor:job:remove']">删除</el-button>
<el-button icon="Delete" @click="handleClean" v-hasPermi="['monitor:job:remove']">清空</el-button>
<el-button icon="Download" @click="handleExport" v-hasPermi="['monitor:job:export']">导出</el-button>
<el-button icon="Close" @click="handleClose" v-hasPermi="['monitor:job:query']">关闭</el-button>
<!-- <right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar> -->
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="jobLogList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="日志编号" width="80" align="center" prop="jobLogId" />
@@ -123,15 +71,16 @@
</template>
</el-table-column>
</el-table>
<pagination
v-show="total > 0"
<el-pagination
small
background
layout="total, prev, pager, next"
:total="total"
v-model:page="queryParams.pageNum"
v-model:limit="queryParams.pageSize"
@pagination="getList"
v-model:current-page="currentPage"
@current-change="handleCurrentChange"
/>
</div>
</div>
<!-- 调度日志详细 -->
<el-dialog title="调度日志详细" v-model="open" width="700px" append-to-body>
<el-form :model="form" label-width="100px">
@@ -171,22 +120,22 @@
</template>
<script setup name="JobLog">
import { getJob } from "@/api/monitor/job";
import { listJobLog, delJobLog, cleanJobLog } from "@/api/monitor/jobLog";
import { getJob } from '@/api/monitor/job'
import { listJobLog, delJobLog, cleanJobLog } from '@/api/monitor/jobLog'
const { proxy } = getCurrentInstance();
const { sys_common_status, sys_job_group } = proxy.useDict("sys_common_status", "sys_job_group");
const jobLogList = ref([]);
const open = ref(false);
const loading = ref(true);
const showSearch = ref(true);
const ids = ref([]);
const multiple = ref(true);
const total = ref(0);
const dateRange = ref([]);
const route = useRoute();
const { proxy } = getCurrentInstance()
const { sys_common_status, sys_job_group } = proxy.useDict('sys_common_status', 'sys_job_group')
const jobLogList = ref([])
const open = ref(false)
const loading = ref(true)
const showSearch = ref(true)
const ids = ref([])
const multiple = ref(true)
const total = ref(0)
const dateRange = ref([])
const route = useRoute()
const currentPage = ref(1)
const data = reactive({
form: {},
queryParams: {
@@ -196,82 +145,100 @@ const data = reactive({
dictType: undefined,
status: undefined
}
});
})
const { queryParams, form, rules } = toRefs(data);
const { queryParams, form, rules } = toRefs(data)
/** 查询调度日志列表 */
function getList() {
loading.value = true;
listJobLog(proxy.addDateRange(queryParams.value, dateRange.value)).then(response => {
jobLogList.value = response.rows;
total.value = response.total;
loading.value = false;
});
loading.value = true
listJobLog(proxy.addDateRange(queryParams.value, dateRange.value)).then((response) => {
jobLogList.value = response.rows
total.value = response.total
loading.value = false
})
}
// 返回按钮
function handleClose() {
const obj = { path: "/monitor/job" };
proxy.$tab.closeOpenPage(obj);
const obj = { path: '/monitor/job' }
proxy.$tab.closeOpenPage(obj)
}
/** 搜索按钮操作 */
function handleQuery() {
queryParams.value.pageNum = 1;
getList();
queryParams.value.pageNum = 1
getList()
}
/** 重置按钮操作 */
function resetQuery() {
dateRange.value = [];
proxy.resetForm("queryRef");
handleQuery();
dateRange.value = []
proxy.resetForm('queryRef')
currentPage.value = 1
handleQuery()
}
// 多选框选中数据
function handleSelectionChange(selection) {
ids.value = selection.map(item => item.jobLogId);
multiple.value = !selection.length;
ids.value = selection.map((item) => item.jobLogId)
multiple.value = !selection.length
}
/** 详细按钮操作 */
function handleView(row) {
open.value = true;
form.value = row;
open.value = true
form.value = row
}
/** 删除按钮操作 */
function handleDelete(row) {
proxy.$modal.confirm('是否确认删除调度日志编号为"' + ids.value + '"的数据项?').then(function () {
return delJobLog(ids.value);
}).then(() => {
getList();
proxy.$modal.msgSuccess("删除成功");
}).catch(() => {});
proxy.$modal
.confirm('是否确认删除调度日志编号为"' + ids.value + '"的数据项?')
.then(function () {
return delJobLog(ids.value)
})
.then(() => {
getList()
proxy.$modal.msgSuccess('删除成功')
})
.catch(() => {})
}
/** 清空按钮操作 */
function handleClean() {
proxy.$modal.confirm("是否确认清空所有调度日志数据项?").then(function () {
return cleanJobLog();
}).then(() => {
getList();
proxy.$modal.msgSuccess("清空成功");
}).catch(() => {});
proxy.$modal
.confirm('是否确认清空所有调度日志数据项?')
.then(function () {
return cleanJobLog()
})
.then(() => {
getList()
proxy.$modal.msgSuccess('清空成功')
})
.catch(() => {})
}
/** 导出按钮操作 */
function handleExport() {
proxy.download("schedule/job/log/export", {
...queryParams.value,
}, `job_log_${new Date().getTime()}.xlsx`);
proxy.download(
'schedule/job/log/export',
{
...queryParams.value
},
`job_log_${new Date().getTime()}.xlsx`
)
}
// 分页
const handleCurrentChange = (val) => {
queryParams.value.pageNum = val
getList()
}
(() => {
const jobId = route.params && route.params.jobId;
;(() => {
const jobId = route.params && route.params.jobId
if (jobId !== undefined && jobId != 0) {
getJob(jobId).then(response => {
queryParams.value.jobName = response.data.jobName;
queryParams.value.jobGroup = response.data.jobGroup;
getList();
});
getJob(jobId).then((response) => {
queryParams.value.jobName = response.data.jobName
queryParams.value.jobGroup = response.data.jobGroup
getList()
})
} else {
getList();
getList()
}
})();
})()
getList();
getList()
</script>

View File

@@ -25,7 +25,7 @@
:data="onlineList.slice((pageNum - 1) * pageSize, pageNum * pageSize)"
style="width: 100%"
stripe
height="calc(100% - 0.64rem)"
height="calc(100% - 0.62rem)"
>
<el-table-column label="序号" width="50" type="index" align="center">
<template #default="scope">

View File

@@ -43,7 +43,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="configList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.64rem)">
<el-table v-loading="loading" :data="configList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="参数主键" align="center" prop="configId" />
<el-table-column label="参数名称" align="center" prop="configName" :show-overflow-tooltip="true" />

View File

@@ -35,7 +35,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="dataList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.64rem)">
<el-table v-loading="loading" :data="dataList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="字典编码" align="center" prop="dictCode" />
<el-table-column label="字典标签" align="center" prop="dictLabel">

View File

@@ -43,7 +43,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="typeList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.64rem)">
<el-table v-loading="loading" :data="typeList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="字典编号" align="center" prop="dictId" />
<el-table-column label="字典名称" align="center" prop="dictName" :show-overflow-tooltip="true" />

View File

@@ -51,7 +51,7 @@
:default-sort="defaultSort"
@sort-change="handleSortChange"
stripe
height="calc(100% - 0.64rem)"
height="calc(100% - 0.62rem)"
>
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="访问编号" align="center" prop="infoId" />

View File

@@ -31,7 +31,7 @@
:data="menuList"
row-key="menuId"
:default-expand-all="isExpandAll"
height="calc(100% - 0.64rem)"
height="calc(100% - 0.62rem)"
:tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
stripe
>

View File

@@ -31,7 +31,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="noticeList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.64rem)">
<el-table v-loading="loading" :data="noticeList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="序号" align="center" prop="noticeId" width="100" />
<el-table-column label="公告标题" align="center" prop="noticeTitle" :show-overflow-tooltip="true" />

View File

@@ -57,7 +57,7 @@
:default-sort="defaultSort"
@sort-change="handleSortChange"
stripe
height="calc(100% - 0.64rem)"
height="calc(100% - 0.62rem)"
>
<el-table-column type="selection" width="50" align="center" />
<el-table-column label="日志编号" align="center" prop="operId" />

View File

@@ -32,7 +32,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="postList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.64rem)">
<el-table v-loading="loading" :data="postList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="岗位编号" align="center" prop="postId" />
<el-table-column label="岗位编码" align="center" prop="postCode" />

View File

@@ -26,7 +26,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="userList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.64rem)">
<el-table v-loading="loading" :data="userList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="用户名称" prop="userName" :show-overflow-tooltip="true" />
<el-table-column label="用户昵称" prop="nickName" :show-overflow-tooltip="true" />

View File

@@ -42,7 +42,7 @@
</div>
<div class="content-con" v-loading="loading">
<!-- 表格数据 -->
<el-table v-loading="loading" :data="roleList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.64rem)">
<el-table v-loading="loading" :data="roleList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="角色编号" prop="roleId" width="120" />
<el-table-column label="角色名称" prop="roleName" :show-overflow-tooltip="true" width="150" />

View File

@@ -62,7 +62,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="userList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.64rem)">
<el-table v-loading="loading" :data="userList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.62rem)">
<el-table-column type="selection" width="50" align="center" />
<el-table-column label="用户编号" align="center" key="userId" prop="userId" v-if="columns[0].visible" />
<el-table-column label="用户名称" align="center" key="userName" prop="userName" v-if="columns[1].visible" :show-overflow-tooltip="true" />

View File

@@ -37,7 +37,7 @@
</div>
</div>
<div class="content-con" v-loading="loading">
<el-table v-loading="loading" :data="tableList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.64rem)">
<el-table v-loading="loading" :data="tableList" @selection-change="handleSelectionChange" stripe height="calc(100% - 0.62rem)">
<el-table-column type="selection" align="center" width="55"></el-table-column>
<el-table-column label="序号" type="index" width="50" align="center">
<template #default="scope">