代理列表

This commit is contained in:
2026-05-11 17:37:13 +08:00
parent db0bfc7fd4
commit dc9cba09b2
12 changed files with 85 additions and 60 deletions

View File

@ -100,4 +100,10 @@
.form-switch-leave-to { .form-switch-leave-to {
opacity: 0; opacity: 0;
transform: translateX(-10px) scale(0.98); transform: translateX(-10px) scale(0.98);
}
.table_form-container {
display: flex;
flex-direction: column;
height: 100%;
} }

View File

@ -1,6 +1,7 @@
<template> <template>
<div class="pagination-container"> <div class="pagination-container">
<el-pagination <el-pagination
style="width: auto;"
v-model:current-page="currentPage" v-model:current-page="currentPage"
v-model:page-size="pageSize" v-model:page-size="pageSize"
:page-sizes="pageSizes" :page-sizes="pageSizes"
@ -112,9 +113,16 @@ const handleCurrentChange = (val: number) => {
<style scoped lang="scss"> <style scoped lang="scss">
.pagination-container { .pagination-container {
position: fixed; // position: fixed;
bottom: 20px; // bottom: 20px;
right: 20px; // float: right;
z-index: 1000; width: 100%;
display: flex;
padding: 10px;
background-color: #fff;
justify-content: flex-end;
align-items: flex-end;
// right: 20px;
// z-index: 1000;
} }
</style> </style>

View File

@ -2,8 +2,7 @@
<div class="table-container"> <div class="table-container">
<el-table <el-table
ref="tableRef" ref="tableRef"
height="100%" style="width: 100%; flex: 1"
style="width: 100%"
:data="tableData" :data="tableData"
:row-key="rowKey" :row-key="rowKey"
:tree-props="treeProps" :tree-props="treeProps"
@ -142,7 +141,15 @@ defineExpose({
<style scoped lang="scss"> <style scoped lang="scss">
.table-container { .table-container {
width: 100%; width: 100%;
height: 100%; height: 0;
// overflow: hidden; flex: 1;
display: flex;
flex-direction: column;
overflow: hidden;
:deep(.el-table) {
flex: 1;
overflow: auto;
}
} }
</style> </style>

View File

@ -11,14 +11,17 @@
<!-- 右侧内容区面包屑 + 页签 + 主体内容 --> <!-- 右侧内容区面包屑 + 页签 + 主体内容 -->
<section class="content-container"> <section class="content-container">
<!-- 面包屑导航 --> <!-- 面包屑导航 -->
<!-- <Breadcrumb />--> <!-- <Breadcrumb />-->
<!-- 页签标签栏 --> <!-- 页签标签栏 -->
<!-- <Tabs />--> <!-- <Tabs />-->
<!-- 主体内容区 --> <!-- 主体内容区 -->
<main class="main-content"> <main class="main-content">
<transition name="fade-transform" mode="out-in"> <transition name="fade-transform" mode="out-in"
style="height: 100%;
display: flex;
flex-direction: column;">
<router-view v-slot="{ Component }"> <router-view v-slot="{ Component }">
<KeepAlive> <KeepAlive>
<component :is="Component" :key="route.path" /> <component :is="Component" :key="route.path" />

View File

@ -1,5 +1,5 @@
<template> <template>
<div class="risk"> <div class="risk table_form-container">
<div class="bar"> <div class="bar">
<span>风控管理</span> <span>风控管理</span>
<el-button type="primary" @click="handleAddRisk" v-auth="'riskControl_createRiskControl'" <el-button type="primary" @click="handleAddRisk" v-auth="'riskControl_createRiskControl'"
@ -380,12 +380,14 @@ const handleClose = () => {
} }
.risk-table-content { .risk-table-content {
flex: 1;
display: flex; display: flex;
gap: 10px; gap: 10px;
.table-switch { .table-switch {
flex-basis: 20%; flex-basis: 20%;
min-width: 200px; min-width: 200px;
height: 100%;
:deep(.el-table__row.current-row) { :deep(.el-table__row.current-row) {
background-color: #ecf5ff !important; background-color: #ecf5ff !important;
@ -395,6 +397,7 @@ const handleClose = () => {
.table-content { .table-content {
flex: 1; flex: 1;
height: 100%;
.risk-content-group { .risk-content-group {
display: flex; display: flex;

View File

@ -3,36 +3,36 @@
<!-- 搜索 --> <!-- 搜索 -->
<CustomerListSearch :search-form="searchForm" :search-options="searchOptions" @search="handleSearch" <CustomerListSearch :search-form="searchForm" :search-options="searchOptions" @search="handleSearch"
@reset="handleReset"></CustomerListSearch> @reset="handleReset"></CustomerListSearch>
<!-- 表格 --> <!-- 表格 -->
<CustomerListTable :table-data="tableTree" :columns="tableColumnsOptions" row-key="userId" <CustomerListTable :table-data="tableTree" :columns="tableColumnsOptions" row-key="userId"
:default-sort="{ prop: 'createTime', order: 'descending' }" @expand-change="handleGetSubList"> :default-sort="{ prop: 'createTime', order: 'descending' }" @expand-change="handleGetSubList">
<template #marginRatio="{ row }"> <template #marginRatio="{ row }">
<el-button v-if="row.role_id === 5" type="primary" size="small" v-auth="'agent_getSelfVarietyPointDiffConfig'" <el-button v-if="row.role_id === 5" type="primary" size="small" v-auth="'agent_getSelfVarietyPointDiffConfig'"
@click="handleMarginRatio(row)"> @click="handleMarginRatio(row)">
修改 修改
</el-button> </el-button>
</template> </template>
<template #commissionRatio="{ row }"> <template #commissionRatio="{ row }">
{{ row.commissionRatio }} {{ row.commissionRatio }}
<el-button v-if="row.role_id === 5" type="primary" size="small" @click="handleCommissionRatio(row)" <el-button v-if="row.role_id === 5" type="primary" size="small" @click="handleCommissionRatio(row)"
v-auth="'agent_editAgent'"> v-auth="'agent_editAgent'">
修改 修改
</el-button> </el-button>
</template> </template>
<template #action="{ row }"> <template #action="{ row }">
<!-- <el-button link type="primary" size="small" @click="handleDetail(row)" v-if="row.userId"> <!-- <el-button link type="primary" size="small" @click="handleDetail(row)" v-if="row.userId">
查看详情 查看详情
</el-button> --> </el-button> -->
<!-- <el-divider direction="vertical" /> --> <!-- <el-divider direction="vertical" /> -->
<el-button link type="primary" size="small" @click="handleEditCustomer(row)"> <el-button link type="primary" size="small" @click="handleEditCustomer(row)">
编辑 编辑
</el-button> </el-button>
<el-divider direction="vertical" /> <el-divider direction="vertical" />
<el-button link type="warning" size="small" @click="handleAdjustAmount(row)"> <el-button link type="warning" size="small" @click="handleAdjustAmount(row)">
调整金额 调整金额
</el-button> </el-button>
</template> </template>
</CustomerListTable> </CustomerListTable>
<!-- 分页 --> <!-- 分页 -->
<CustomerListPagination v-model="currentPage" v-model:pageSizeValue="pageSize" :total="total" <CustomerListPagination v-model="currentPage" v-model:pageSizeValue="pageSize" :total="total"
@pagination-change="handlePaginationChange" /> @pagination-change="handlePaginationChange" />

View File

@ -1,5 +1,5 @@
<template> <template>
<div class="market"> <div class="market table_form-container">
<!-- 搜索 --> <!-- 搜索 -->
<MarketSearch :search-form="marketSearchForm" :search-options="marketSearchOptions" @search="handleSearch" <MarketSearch :search-form="marketSearchForm" :search-options="marketSearchOptions" @search="handleSearch"
@reset="handleReset"> @reset="handleReset">
@ -316,7 +316,7 @@ const mapMarketTree = (data: any) => {
closeProfitLoss: item.wallet_capital.closing_profit, // closeProfitLoss: item.wallet_capital.closing_profit, //
riskMargin: item.wallet_capital.risk, // riskMargin: item.wallet_capital.risk, //
serviceFee: item.wallet_capital.service, // serviceFee: item.wallet_capital.service, //
flag: item.role_id * 1 === 5 ? (item.type! === 1 ? 1 : 2) : null, flag: item.role_id * 1 === 5 ? item.type * 1 : null,
//使 //使
mobile: item.mobile || '--', mobile: item.mobile || '--',
email: item.email || '--', email: item.email || '--',
@ -342,18 +342,10 @@ const handleMarketFormLinkage = async (type: 'level' | 'parentAccountName', valu
// //
let flag = null let flag = null
if ( if (marketForm.value?.level * 1 === 5) flag = 1
(selectedRow.value?.role_id * 1 === 5 || marketForm.value?.level * 1 === 5) && if (marketForm.value?.level * 1 === 6) flag = 2
selectedRow.value?.type * 1 === 1 console.log('datasssssssssssss', marketForm.value)
) const data = await getParAgentListApi({ role_id: +value === 6 ? 5 : value, flag: flag })
flag = 1
if (
(selectedRow.value?.role_id * 1 === 6 || marketForm.value?.level * 1 === 6) &&
selectedRow.value?.type * 1 === 2
)
flag = 2
const data = await getParAgentListApi({ role_id: value, flag: flag })
console.log('datasssssssssssss', data)
// //
marketFormOptionsMap.value.parentAccountName = data.map((item: any) => ({ marketFormOptionsMap.value.parentAccountName = data.map((item: any) => ({
label: item.username, label: item.username,
@ -380,7 +372,7 @@ const handleMarketFormLinkage = async (type: 'level' | 'parentAccountName', valu
marketForm.value.maxCommissionRatio = rulesData.row.wallet_capital.fee_handling_percent marketForm.value.maxCommissionRatio = rulesData.row.wallet_capital.fee_handling_percent
// //
const data = await getPointDiffConfigListApi({ user_id: value }) const data = await getPointDiffConfigListApi({ user_id: value, flag: flag })
// //
marketPointTree.value = data.map((item: any) => ({ marketPointTree.value = data.map((item: any) => ({
...item, ...item,
@ -533,7 +525,7 @@ const handleEditMarket = async () => {
try { try {
// watch // watch
dialogType.value = 'edit' dialogType.value = 'edit'
// //
await handleMarketFormLinkage('level', marketForm.value.level) await handleMarketFormLinkage('level', marketForm.value.level)
if (parentId) { if (parentId) {
@ -741,6 +733,7 @@ const handleCancel = async () => {
.table-container { .table-container {
max-width: 100%; max-width: 100%;
height: 100%;
} }
// //

View File

@ -522,6 +522,11 @@ const handleAdjustAmountClose = () => {
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
.client{
height: 100%;
display: flex;
flex-direction: column;
}
:deep(.el-form-item__content) { :deep(.el-form-item__content) {
margin-left: 0 !important; margin-left: 0 !important;
} }

View File

@ -1,5 +1,5 @@
<template> <template>
<div class="system"> <div class="system table_form-container">
<!-- 菜单列表头 --> <!-- 菜单列表头 -->
<div class="header"> <div class="header">
<h4>菜单列表</h4> <h4>菜单列表</h4>

View File

@ -1,5 +1,5 @@
<template> <template>
<div class="system"> <div class="system table_form-container">
<!-- 角色列表头 --> <!-- 角色列表头 -->
<div class="header"> <div class="header">
<h4>角色列表</h4> <h4>角色列表</h4>

View File

@ -1,5 +1,5 @@
<template> <template>
<div class="system"> <div class="system table_form-container">
<!-- 菜单列表头 --> <!-- 菜单列表头 -->
<MenuHeader :title="menuTitle" :buttons="menuHeaderButtons" @click="handleAddMenu" /> <MenuHeader :title="menuTitle" :buttons="menuHeaderButtons" @click="handleAddMenu" />
<!-- 菜单列表表格 --> <!-- 菜单列表表格 -->

View File

@ -1,5 +1,5 @@
<template> <template>
<div class="variety"> <div class="variety table_form-container">
<!-- 搜索 --> <!-- 搜索 -->
<VarietySearch <VarietySearch
:search-form="searchForm" :search-form="searchForm"