新增涉疑交易明细筛选
This commit is contained in:
@@ -104,6 +104,7 @@ export function getOverviewSuspiciousTransactions(params) {
|
||||
method: 'get',
|
||||
params: {
|
||||
projectId: params.projectId,
|
||||
modelCode: params.modelCode,
|
||||
suspiciousType: params.suspiciousType,
|
||||
pageNum: params.pageNum,
|
||||
pageSize: params.pageSize
|
||||
|
||||
@@ -17,24 +17,46 @@
|
||||
<div class="block-title">涉疑交易明细</div>
|
||||
<div class="block-subtitle">展示涉疑交易的关键字段与风险金额</div>
|
||||
</div>
|
||||
<div class="block-actions">
|
||||
<el-dropdown size="mini" @command="handleSuspiciousTypeChange">
|
||||
<span class="el-dropdown-link">
|
||||
{{ currentSuspiciousTypeLabel }}
|
||||
<i class="el-icon-arrow-down el-icon--right"></i>
|
||||
</span>
|
||||
<el-dropdown-menu slot="dropdown">
|
||||
<el-dropdown-item
|
||||
v-for="item in suspiciousTypeOptions"
|
||||
:key="item.value"
|
||||
:command="item.value"
|
||||
>
|
||||
{{ item.label }}
|
||||
</el-dropdown-item>
|
||||
</el-dropdown-menu>
|
||||
</el-dropdown>
|
||||
</div>
|
||||
</div>
|
||||
<el-form :inline="true" size="mini" class="suspicious-filter-form" @submit.native.prevent>
|
||||
<el-form-item label="命中模型">
|
||||
<el-select
|
||||
v-model="selectedModelCode"
|
||||
class="suspicious-filter-select"
|
||||
placeholder="全部模型"
|
||||
filterable
|
||||
:disabled="isExternalSuspiciousType"
|
||||
>
|
||||
<el-option label="全部模型" value="" />
|
||||
<el-option
|
||||
v-for="item in riskModelOptions"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="可疑规则">
|
||||
<el-select
|
||||
v-model="currentSuspiciousType"
|
||||
class="suspicious-filter-select suspicious-type-select"
|
||||
placeholder="全部可疑规则"
|
||||
@change="handleSuspiciousTypeSelectChange"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in suspiciousTypeOptions"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="el-icon-search" :loading="suspiciousLoading" @click="handleSuspiciousQuery">
|
||||
查询
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
<el-table
|
||||
v-loading="suspiciousLoading"
|
||||
@@ -348,9 +370,8 @@ import { getBankStatementDetail } from "@/api/ccdiProjectBankStatement";
|
||||
import { buildFlowEvidenceFingerprint, buildFlowEvidenceSnapshot } from "@/utils/ccdiEvidence";
|
||||
|
||||
const SUSPICIOUS_TYPE_OPTIONS = [
|
||||
{ value: "ALL", label: "全部可疑人员类型" },
|
||||
{ value: "NAME_LIST", label: "名单库命中" },
|
||||
{ value: "MODEL_RULE", label: "模型规则命中" },
|
||||
{ value: "ALL", label: "全部可疑规则" },
|
||||
{ value: "MODEL_RULE", label: "员工规则命中" },
|
||||
{ value: "EXTERNAL_PERSON", label: "外部人员预警" },
|
||||
];
|
||||
const DEFAULT_RISK_DETAIL_PAGE_SIZE = 5;
|
||||
@@ -360,6 +381,25 @@ const normalizeSuspiciousType = (value) => (
|
||||
SUSPICIOUS_TYPE_OPTIONS.some((item) => item.value === value) ? value : "ALL"
|
||||
);
|
||||
|
||||
const normalizeRiskModelOptions = (rows) => {
|
||||
if (!Array.isArray(rows)) {
|
||||
return [];
|
||||
}
|
||||
const seen = new Set();
|
||||
return rows
|
||||
.map((item) => ({
|
||||
value: item && (item.value || item.modelCode || item.key),
|
||||
label: item && (item.label || item.modelName || item.title),
|
||||
}))
|
||||
.filter((item) => {
|
||||
if (!item.value || seen.has(item.value)) {
|
||||
return false;
|
||||
}
|
||||
seen.add(item.value);
|
||||
return true;
|
||||
});
|
||||
};
|
||||
|
||||
const ABNORMAL_CUSTOMER_TRANSACTION_RULE_CODE = "ABNORMAL_CUSTOMER_TRANSACTION";
|
||||
const ABNORMAL_CUSTOMER_TRANSACTION_RULE_NAME = "与客户之间非正常资金往来";
|
||||
|
||||
@@ -467,10 +507,12 @@ export default {
|
||||
detailVisible: false,
|
||||
detailData: createEmptyDetailData(),
|
||||
currentSuspiciousType: "ALL",
|
||||
selectedModelCode: "",
|
||||
suspiciousPageNum: 1,
|
||||
suspiciousPageSize: DEFAULT_RISK_DETAIL_PAGE_SIZE,
|
||||
suspiciousTotal: 0,
|
||||
suspiciousTransactionList: [],
|
||||
riskModelOptions: [],
|
||||
employeeCreditNegativeLoading: false,
|
||||
employeeCreditNegativePageNum: 1,
|
||||
employeeCreditNegativePageSize: DEFAULT_RISK_DETAIL_PAGE_SIZE,
|
||||
@@ -492,9 +534,8 @@ export default {
|
||||
suspiciousTypeOptions() {
|
||||
return SUSPICIOUS_TYPE_OPTIONS;
|
||||
},
|
||||
currentSuspiciousTypeLabel() {
|
||||
const matched = this.suspiciousTypeOptions.find((item) => item.value === this.currentSuspiciousType);
|
||||
return matched ? matched.label : "全部可疑人员类型";
|
||||
isExternalSuspiciousType() {
|
||||
return this.currentSuspiciousType === "EXTERNAL_PERSON";
|
||||
},
|
||||
},
|
||||
watch: {
|
||||
@@ -504,6 +545,8 @@ export default {
|
||||
handler(value) {
|
||||
this.projectId = value && value.projectId ? value.projectId : null;
|
||||
this.currentSuspiciousType = normalizeSuspiciousType(value && value.suspiciousType);
|
||||
this.selectedModelCode = "";
|
||||
this.riskModelOptions = normalizeRiskModelOptions(value && value.riskModelOptions);
|
||||
this.suspiciousPageNum = 1;
|
||||
this.suspiciousPageSize = DEFAULT_RISK_DETAIL_PAGE_SIZE;
|
||||
this.suspiciousTotal = Number(value && value.total) || 0;
|
||||
@@ -527,8 +570,12 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
buildFlowEvidenceFingerprint,
|
||||
async handleSuspiciousTypeChange(command) {
|
||||
this.currentSuspiciousType = command;
|
||||
handleSuspiciousTypeSelectChange(value) {
|
||||
if (value === "EXTERNAL_PERSON") {
|
||||
this.selectedModelCode = "";
|
||||
}
|
||||
},
|
||||
async handleSuspiciousQuery() {
|
||||
this.suspiciousPageNum = 1;
|
||||
await this.loadSuspiciousTransactions();
|
||||
},
|
||||
@@ -571,6 +618,7 @@ export default {
|
||||
try {
|
||||
const response = await getOverviewSuspiciousTransactions({
|
||||
projectId: this.projectId,
|
||||
modelCode: this.selectedModelCode,
|
||||
suspiciousType: this.currentSuspiciousType,
|
||||
pageNum: this.suspiciousPageNum,
|
||||
pageSize: this.suspiciousPageSize,
|
||||
@@ -954,6 +1002,35 @@ export default {
|
||||
color: #94a3b8;
|
||||
}
|
||||
|
||||
.suspicious-filter-form {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
align-items: center;
|
||||
gap: 8px 12px;
|
||||
margin-bottom: 14px;
|
||||
padding: 10px 12px;
|
||||
background: #f8fafc;
|
||||
border: 1px solid #e2e8f0;
|
||||
}
|
||||
|
||||
.suspicious-filter-form :deep(.el-form-item) {
|
||||
margin-right: 0;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.suspicious-filter-form :deep(.el-form-item__label) {
|
||||
color: #475569;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.suspicious-filter-select {
|
||||
width: 220px;
|
||||
}
|
||||
|
||||
.suspicious-type-select {
|
||||
width: 160px;
|
||||
}
|
||||
|
||||
.result-table {
|
||||
width: 100%;
|
||||
}
|
||||
@@ -1182,6 +1259,21 @@ export default {
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
.suspicious-filter-form {
|
||||
align-items: stretch;
|
||||
}
|
||||
|
||||
.suspicious-filter-form :deep(.el-form-item) {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.suspicious-filter-form :deep(.el-form-item__content),
|
||||
.suspicious-filter-select,
|
||||
.suspicious-type-select,
|
||||
.suspicious-filter-form :deep(.el-button) {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.detail-overview-grid {
|
||||
grid-template-columns: 1fr;
|
||||
gap: 18px;
|
||||
|
||||
@@ -463,6 +463,7 @@ export function createOverviewLoadedData({
|
||||
riskDetails: {
|
||||
...mockOverviewData.riskDetails,
|
||||
projectId,
|
||||
riskModelOptions: normalizeRiskModelCards(riskModelCardsData && riskModelCardsData.cardList),
|
||||
suspiciousTransactionList: normalizeSuspiciousTransactions(suspiciousData && suspiciousData.rows),
|
||||
suspiciousType: "ALL",
|
||||
total: suspiciousData && suspiciousData.total ? suspiciousData.total : 0,
|
||||
|
||||
Reference in New Issue
Block a user