feat(components): 调整分页组件默认页码和每页条数
- 将 fvPagination 组件的默认每页条数从 10 调整为 20 - 在 pageSizes 数组中添加 100 选项 - 更新 fvTable 组件中的默认每页条数和 pageSizes 配置 - 修改首页专项资金项目和研发投入资金的相关文案
This commit is contained in:
@@ -30,12 +30,12 @@ const props = defineProps({
|
||||
},
|
||||
pageSize: {
|
||||
type: Number,
|
||||
default: 10,
|
||||
default: 20,
|
||||
},
|
||||
pageSizes: {
|
||||
type: Object,
|
||||
default(rawProps) {
|
||||
return [10, 15, 20, 30, 50]
|
||||
return [10, 15, 20, 30, 50,100]
|
||||
},
|
||||
},
|
||||
small: {
|
||||
@@ -58,7 +58,7 @@ const total = ref(0)
|
||||
//对应页数
|
||||
const currentPage = ref(1)
|
||||
//每页多少条
|
||||
const pageSize = ref(10)
|
||||
const pageSize = ref(20)
|
||||
//默认每页多少条的数组
|
||||
const pageSizes = ref([])
|
||||
//是否使用小型分页样式
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
<template>
|
||||
<div class="fv-table-container">
|
||||
<el-button v-if="tableConfig.export && tableConfig.export.open&&changeExportPosition" @click="exportTable" color="#DED0B2"
|
||||
<el-button v-if="tableConfig.export && tableConfig.export.open&&changeExportPosition" @click="exportTable"
|
||||
color="#DED0B2"
|
||||
style="float: left;margin-right: 10px">导出
|
||||
</el-button>
|
||||
<!-- 表格头部按钮 -->
|
||||
@@ -18,7 +19,8 @@
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
<el-button v-if="tableConfig.export && tableConfig.export.open&&!changeExportPosition" @click="exportTable" color="#DED0B2"
|
||||
<el-button v-if="tableConfig.export && tableConfig.export.open&&!changeExportPosition" @click="exportTable"
|
||||
color="#DED0B2"
|
||||
style="margin-bottom: 10px">导出
|
||||
</el-button>
|
||||
<!-- 列显示配置 -->
|
||||
@@ -93,7 +95,7 @@
|
||||
v-if="pagination"
|
||||
:current-page="localData.query.pageNum"
|
||||
:page-size="localData.query.pageSize"
|
||||
:page-sizes="[10, 20, 30, 40,50]"
|
||||
:page-sizes="[10, 20, 30, 40,50,100]"
|
||||
:total="localData.total"
|
||||
@changeSize="handleSizeChange"
|
||||
@goPage="handleCurrentChange"
|
||||
@@ -157,7 +159,7 @@ const exportTable = () => {
|
||||
const localData = reactive({
|
||||
list: [], // 表格数据
|
||||
query: {
|
||||
pageSize: 10,
|
||||
pageSize: 20,
|
||||
pageNum: 1
|
||||
},
|
||||
total: 0,
|
||||
@@ -227,7 +229,7 @@ const getList = async () => {
|
||||
if (api) {
|
||||
localData.loading = true
|
||||
try {
|
||||
const {code, data, msg} = await requestList(api, queryParmas).then(res=>{
|
||||
const {code, data, msg} = await requestList(api, queryParmas).then(res => {
|
||||
// console.log(res)
|
||||
return res
|
||||
})
|
||||
@@ -250,8 +252,8 @@ const getList = async () => {
|
||||
localData.loading = false
|
||||
}
|
||||
} catch (error) {
|
||||
console.log("error",error)
|
||||
if (!error){
|
||||
console.log("error", error)
|
||||
if (!error) {
|
||||
return
|
||||
}
|
||||
ElNotification({
|
||||
|
||||
@@ -156,7 +156,7 @@
|
||||
<div class="title-block">
|
||||
<div class="title">
|
||||
<div class="tag"></div>
|
||||
<span>专项资金项目</span>
|
||||
<span>资金类型</span>
|
||||
</div>
|
||||
<div class="more" @click="goToSpecialFund">
|
||||
<span>更多</span>
|
||||
@@ -170,7 +170,7 @@
|
||||
<div id="fundPie" ref="fundPie"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="fund-pie">专项资金项目统计图</div>
|
||||
<div class="fund-pie">资金类型统计图</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-col>
|
||||
@@ -180,7 +180,7 @@
|
||||
<div class="title-block">
|
||||
<div class="title">
|
||||
<div class="tag"></div>
|
||||
<span>研发投入资金</span>
|
||||
<span>研发投入</span>
|
||||
</div>
|
||||
<div class="more" @click="goToResearchFund">
|
||||
<span>更多</span>
|
||||
@@ -201,7 +201,7 @@
|
||||
/>
|
||||
</div>
|
||||
<div v-if="moneyData&&moneyData.length==0" style="margin-top: 30px">
|
||||
<el-empty image-size="135" description="暂无研发投入资金信息~"/>
|
||||
<el-empty image-size="135" description="暂无研发投入信息~"/>
|
||||
</div>
|
||||
<div class="money-block" v-else>
|
||||
<div class="money-container">
|
||||
@@ -219,7 +219,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="fund-pie" v-if="totalMoney" style="text-align: left;margin-left: 70px;margin-top: 10px">
|
||||
研发投入资金统计图
|
||||
研发投入统计图
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user