|
@@ -5,7 +5,14 @@ import { ToolbarConfigType } from '@/components/AToolbar/type'
|
|
|
import { ColumnConfigType } from '@/components/ATable/type'
|
|
|
import { StrAnyObj, StrAnyObjArr } from '@/typings'
|
|
|
import { useHandleData } from '@/utils/useHandleData'
|
|
|
-import { getPageApi, getDetailApi, addApi, editApi, deleteApi } from '@/api/business/contract/info'
|
|
|
+import {
|
|
|
+ getPageApi,
|
|
|
+ getDetailApi,
|
|
|
+ addApi,
|
|
|
+ editApi,
|
|
|
+ deleteApi,
|
|
|
+ getStatistics
|
|
|
+} from '@/api/business/contract/info'
|
|
|
import Detail from './detail.vue'
|
|
|
|
|
|
const queryRef = ref<InstanceType<typeof AForm>>()
|
|
@@ -17,6 +24,7 @@ const pageTotal = ref<number>(0)
|
|
|
|
|
|
const queryData = ref<StrAnyObj>({ pageNum: 1, pageSize: 10 })
|
|
|
const tableData = ref<StrAnyObjArr>([])
|
|
|
+const statisticsData = ref<StrAnyObjArr>([])
|
|
|
const formData = ref<StrAnyObj>({})
|
|
|
|
|
|
const dialogTitle = ref<string>('')
|
|
@@ -81,6 +89,10 @@ const columnConfig: ColumnConfigType[] = [
|
|
|
label: '保险费'
|
|
|
},
|
|
|
{
|
|
|
+ slot: 'receivedAmount',
|
|
|
+ label: '到账金额'
|
|
|
+ },
|
|
|
+ {
|
|
|
prop: 'amount',
|
|
|
label: '金额'
|
|
|
},
|
|
@@ -391,10 +403,13 @@ onMounted(() => {
|
|
|
})
|
|
|
|
|
|
function getPage() {
|
|
|
- getPageApi(queryData.value).then((resp) => {
|
|
|
+ getPageApi(queryData.value).then((resp: StrAnyObjArr) => {
|
|
|
tableData.value = resp.records
|
|
|
pageTotal.value = resp.total
|
|
|
})
|
|
|
+ getStatistics(queryData.value).then((res: StrAnyObjArr) => {
|
|
|
+ statisticsData.value = res
|
|
|
+ })
|
|
|
}
|
|
|
|
|
|
function tableSelectionChange(item: StrAnyObjArr) {
|
|
@@ -438,6 +453,35 @@ function handleRemove(idList: string[]) {
|
|
|
<el-card v-if="showQuery">
|
|
|
<a-form ref="queryRef" v-model="queryData" :config="queryConfig" :span="6"> </a-form>
|
|
|
</el-card>
|
|
|
+ <el-card style="margin-top: 10px">
|
|
|
+ <div style="display: flex; flex-wrap: wrap">
|
|
|
+ <div
|
|
|
+ v-for="(item, index) in statisticsData"
|
|
|
+ :key="index"
|
|
|
+ style="
|
|
|
+ width: calc(25% - 10px);
|
|
|
+ padding: 20px;
|
|
|
+ background-color: #b0e2ffa8;
|
|
|
+ margin-right: 10px;
|
|
|
+ border-radius: 10px;
|
|
|
+ "
|
|
|
+ >
|
|
|
+ <div style="font-size: 18px; font-weight: bold; color: black">
|
|
|
+ {{ item.sellerCompany }}
|
|
|
+ </div>
|
|
|
+ <div style="display: flex; color: #ce00ff; font-weight: bold; padding-top: 6px">
|
|
|
+ <div style="width: 33%">{{ item.contractQuantity }}</div>
|
|
|
+ <div style="width: 33%">{{ item.contractAmount }}</div>
|
|
|
+ <div style="width: 34%">{{ item.fundReceivedAmount }}</div>
|
|
|
+ </div>
|
|
|
+ <div style="display: flex; padding-top: 6px">
|
|
|
+ <div style="width: 33%">合同数量</div>
|
|
|
+ <div style="width: 33%">合同金额</div>
|
|
|
+ <div style="width: 34%">到账金额</div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </el-card>
|
|
|
|
|
|
<a-table
|
|
|
:data="tableData"
|
|
@@ -451,6 +495,24 @@ function handleRemove(idList: string[]) {
|
|
|
@page-size-change="getPage"
|
|
|
@selection-change="tableSelectionChange"
|
|
|
>
|
|
|
+ <template #receivedAmount="{ row }">
|
|
|
+ <div>
|
|
|
+ <el-popover placement="bottom" :width="400">
|
|
|
+ <template #reference>
|
|
|
+ <a style="color: #409eff; cursor: pointer; word-break: break-all">
|
|
|
+ {{ row.receivedAmount }}
|
|
|
+ </a>
|
|
|
+ </template>
|
|
|
+ <div v-if="row.capitalTransactionsList && row.capitalTransactionsList.length > 0">
|
|
|
+ <el-table :data="row.capitalTransactionsList" :border="false" style="width: 100%">
|
|
|
+ <el-table-column label="到账金额" prop="amount" width="100" />
|
|
|
+ <el-table-column label="用户" prop="nickname" width="100" />
|
|
|
+ <el-table-column label="到账时间" prop="tradingTime" min-width="100" />
|
|
|
+ </el-table>
|
|
|
+ </div>
|
|
|
+ </el-popover>
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
</a-table>
|
|
|
|
|
|
<a-dialog
|