feat: 添加分页功能至租户和租户用户表格,优化数据展示
This commit is contained in:
parent
910f8b540e
commit
863fcd2d55
|
|
@ -3,11 +3,11 @@ ENV = development
|
||||||
|
|
||||||
# 本地环境接口地址
|
# 本地环境接口地址
|
||||||
# VITE_API_URL = http://4155gf93ll13.vicp.fun/admin
|
# VITE_API_URL = http://4155gf93ll13.vicp.fun/admin
|
||||||
VITE_API_URL = http://localhost:13579/admin
|
# VITE_API_URL = http://localhost:13579/admin
|
||||||
# VITE_API_URL = https://cankao.cs.com.cn/admin
|
# VITE_API_URL = https://cankao.cs.com.cn/admin
|
||||||
# VITE_API_URL = http://127.0.0.1:13579/admin
|
# VITE_API_URL = http://127.0.0.1:13579/admin
|
||||||
|
|
||||||
# VITE_API_URL = http://123.60.153.169:8040/admin
|
VITE_API_URL = http://123.60.153.169:8040/admin
|
||||||
|
|
||||||
# VITE_API_URL = /api
|
# VITE_API_URL = /api
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<tableComponents :tableData="tableData" :tableLoading="loading" :hadExpand="false">
|
<tableComponents :tableData="tableData" :tableLoading="loading" :hadExpand="false" @currentChange="currentChange" @sizeChange="sizeChange">
|
||||||
<el-table-column prop="companyType" label="企业类型" align="center">
|
<el-table-column prop="companyType" label="企业类型" align="center">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
{{ COMPANYTYPE_CONST[scope.row.companyType]?.label }}
|
{{ COMPANYTYPE_CONST[scope.row.companyType]?.label }}
|
||||||
|
|
@ -224,6 +224,16 @@ function exportExcel() {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function currentChange(val) {
|
||||||
|
tableData.page = val;
|
||||||
|
getData();
|
||||||
|
}
|
||||||
|
|
||||||
|
function sizeChange(val) {
|
||||||
|
tableData.size = val;
|
||||||
|
getData();
|
||||||
|
}
|
||||||
|
|
||||||
// 页面加载时
|
// 页面加载时
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
NextLoading.done();
|
NextLoading.done();
|
||||||
|
|
|
||||||
|
|
@ -34,7 +34,7 @@
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
<tableComponents :tableData="tableData" :tableLoading="loading" :hadExpand="false">
|
<tableComponents :tableData="tableData" :tableLoading="loading" :hadExpand="false" @currentChange="currentChange" @sizeChange="sizeChange">
|
||||||
<el-table-column prop="name" label="姓名" align="center" />
|
<el-table-column prop="name" label="姓名" align="center" />
|
||||||
<el-table-column prop="mobile" label="手机号" align="center" />
|
<el-table-column prop="mobile" label="手机号" align="center" />
|
||||||
<el-table-column prop="companyName" label="企业名称" align="center" />
|
<el-table-column prop="companyName" label="企业名称" align="center" />
|
||||||
|
|
@ -221,6 +221,16 @@ function clearForm() {
|
||||||
getData();
|
getData();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function currentChange(val) {
|
||||||
|
tableData.page = val;
|
||||||
|
getData();
|
||||||
|
}
|
||||||
|
|
||||||
|
function sizeChange(val) {
|
||||||
|
tableData.size = val;
|
||||||
|
getData();
|
||||||
|
}
|
||||||
|
|
||||||
// 页面加载时
|
// 页面加载时
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
NextLoading.done();
|
NextLoading.done();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue