代码提交
This commit is contained in:
parent
fd2f43e882
commit
1a82c09598
|
@ -1,7 +1,7 @@
|
||||||
<template>
|
<template>
|
||||||
<el-dialog title="Collection robot" v-model="state.isShowDialog" width="700px">
|
<el-dialog title="Collection robot" v-model="state.isShowDialog" width="700px">
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="5" style="text-align:center ;">
|
<el-col :span="3" style="text-align:center ;">
|
||||||
<el-image style="height:40px ; width:100px!" src="/baidu.jpg"></el-image>
|
<el-image style="height:40px ; width:100px!" src="/baidu.jpg"></el-image>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="9">
|
<el-col :span="9">
|
||||||
|
@ -10,7 +10,7 @@
|
||||||
</el-input>
|
</el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="5">
|
<el-col :span="3">
|
||||||
<el-form-item label="page" style="text-align:center ; margin-left: 10px;">
|
<el-form-item label="page" style="text-align:center ; margin-left: 10px;">
|
||||||
<el-input v-model="state.baidu.page" type="number" style="width: 70px ;"></el-input>
|
<el-input v-model="state.baidu.page" type="number" style="width: 70px ;"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
@ -30,7 +30,7 @@
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="5" style="text-align:center ;">
|
<el-col :span="3" style="text-align:center ;">
|
||||||
<el-image style="height:40px ; width:100px!" src="/bing.webp"></el-image>
|
<el-image style="height:40px ; width:100px!" src="/bing.webp"></el-image>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="9" >
|
<el-col :span="9" >
|
||||||
|
@ -38,7 +38,7 @@
|
||||||
<el-input v-model="state.bing.keywords"></el-input>
|
<el-input v-model="state.bing.keywords"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="5" >
|
<el-col :span="3" >
|
||||||
<el-form-item label="page" style="text-align:center; margin-left: 10px;">
|
<el-form-item label="page" style="text-align:center; margin-left: 10px;">
|
||||||
<el-input v-model="state.bing.page" type="number" style="width: 70px ;"></el-input>
|
<el-input v-model="state.bing.page" type="number" style="width: 70px ;"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
|
@ -23,9 +23,9 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleDisasterSizeChange" @current-change="onHandleDisasterCurrentChange"
|
<el-pagination @size-change="onHandleDisasterSizeChange" @current-change="onHandleDisasterCurrentChange"
|
||||||
class="mt15" :pager-count="5" :page-sizes="[10, 20, 30]"
|
class="mt15" :pager-count="2" :page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.disasterData.param.pageNum" background
|
v-model:current-page="state.disasterData.param.pageNum" background
|
||||||
v-model:page-size="state.disasterData.param.pageSize" layout="total, sizes, prev, pager, next, jumper"
|
v-model:page-size="state.disasterData.param.pageSize" layout="total, sizes, prev, pager, next"
|
||||||
:total="state.disasterData.total">
|
:total="state.disasterData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</div>
|
</div>
|
||||||
|
@ -34,53 +34,54 @@
|
||||||
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
||||||
<div class="system-user-search mb15" style="display: flex;margin-left: 10px;margin-top: 10px;">
|
<div class="system-user-search mb15" style="display: flex;margin-left: 10px;margin-top: 10px;">
|
||||||
<el-form-item label="type" label-width="100px">
|
<el-form-item label="type" label-width="100px">
|
||||||
<el-select v-model="state.searchName" placeholder="Please select data type" style="max-width: 200px"
|
<el-select v-model="state.searchName" placeholder="Please select data type" style="max-width: 200px"
|
||||||
size="default" clearable @change="getTableData();state.queryTitle=''">
|
size="default" clearable @change="getTableData(); state.queryTitle = ''">
|
||||||
<el-option value="1" label="news"></el-option>
|
<el-option value="1" label="news"></el-option>
|
||||||
<el-option value="2" label="socialMedia"></el-option>
|
<el-option value="2" label="socialMedia"></el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="stateus" label-width="100px">
|
<el-form-item label="stateus" label-width="100px">
|
||||||
<el-select v-model="state.srarchType" placeholder="Please select data type" style="max-width: 200px"
|
<el-select v-model=" state.srarchType " placeholder="Please select data type" style="max-width: 200px"
|
||||||
size="default" clearable>
|
size="default" clearable>
|
||||||
<el-option value="0" label="No review"></el-option>
|
<el-option value="0" label="No review"></el-option>
|
||||||
<el-option value="1" label="reserve"></el-option>
|
<el-option value="1" label="reserve"></el-option>
|
||||||
<el-option value="2" label="not retain"></el-option>
|
<el-option value="2" label="not retain"></el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="title" label-width="100px" v-if = "state.searchName=='1'">
|
<el-form-item label="title" label-width="100px" v-if=" state.searchName == '1' ">
|
||||||
<el-input v-model="state.queryTitle" placeholder="Please enter a title"></el-input>
|
<el-input v-model=" state.queryTitle " placeholder="Please enter a title"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-button size="default" type="primary" class="ml10" @click="getTableData">
|
<el-button size="default" type="primary" class="ml10" @click=" getTableData ">
|
||||||
<el-icon>
|
<el-icon>
|
||||||
<ele-Search />
|
<ele-Search />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
search
|
search
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button size="default" type="success" class="ml10" @click="openDialog">
|
<el-button size="default" type="success" class="ml10" @click=" openDialog ">
|
||||||
<el-icon>
|
<el-icon>
|
||||||
<ele-Upload />
|
<ele-Upload />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
review
|
review
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
<el-table :data="state.tableData.data" v-loading="state.tableData.loading"
|
<el-table :data=" state.tableData.data " v-loading=" state.tableData.loading "
|
||||||
@selection-change="handleSelectionChange" style="width: 100%">
|
@selection-change=" handleSelectionChange " style="width: 100%">
|
||||||
<el-table-column type="selection" width="55" />
|
<el-table-column type="selection" width="55" />
|
||||||
<el-table-column type="index" label="ID" width="50" />
|
<el-table-column type="index" label="ID" width="50" />
|
||||||
<el-table-column v-if = "state.searchName=='1'" prop="title" label="title" show-overflow-tooltip></el-table-column>
|
<el-table-column v-if=" state.searchName == '1' " prop="title" label="title"
|
||||||
|
show-overflow-tooltip></el-table-column>
|
||||||
<el-table-column prop="content" label="content" show-overflow-tooltip></el-table-column>
|
<el-table-column prop="content" label="content" show-overflow-tooltip></el-table-column>
|
||||||
<el-table-column prop="type" label="type" show-overflow-tooltip >
|
<el-table-column prop="type" label="type" show-overflow-tooltip>
|
||||||
<template #default="scope">
|
<template #default=" scope ">
|
||||||
<el-tag type="info" v-if="state.searchName=='1' && scope.row.type == 0">baidu(中文)</el-tag>
|
<el-tag type="info" v-if=" state.searchName == '1' && scope.row.type == 0 ">baidu(中文)</el-tag>
|
||||||
<el-tag type="info" v-if="state.searchName=='1' && scope.row.type == 1">bing</el-tag>
|
<el-tag type="info" v-if=" state.searchName == '1' && scope.row.type == 1 ">bing</el-tag>
|
||||||
<el-tag type="info" v-if="state.searchName=='2' && scope.row.type == 0">twitter</el-tag>
|
<el-tag type="info" v-if=" state.searchName == '2' && scope.row.type == 0 ">twitter</el-tag>
|
||||||
<el-tag type="info" v-if="state.searchName=='2' && scope.row.type == 1">weibo</el-tag>
|
<el-tag type="info" v-if=" state.searchName == '2' && scope.row.type == 1 ">weibo</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="content" label="link" show-overflow-tooltip>
|
<el-table-column prop="content" label="link" show-overflow-tooltip>
|
||||||
<template #default="scope">
|
<template #default=" scope ">
|
||||||
<a :href="scope.row.link" target="_blank">goto link</a>
|
<a :href=" scope.row.link " target="_blank">goto link</a>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|
||||||
|
@ -93,22 +94,25 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="uploadTime" label="Upload time" show-overflow-tooltip></el-table-column> -->
|
<el-table-column prop="uploadTime" label="Upload time" show-overflow-tooltip></el-table-column> -->
|
||||||
<el-table-column prop="Operate" label="Operate" show-overflow-tooltip>
|
<el-table-column prop="Operate" label="Operate" show-overflow-tooltip>
|
||||||
<template #default="scope">
|
<template #default=" scope ">
|
||||||
<el-button size="small" text type="info" v-if="scope.row.status == 0" @click="openDialog(scope.row,true)">review</el-button>
|
<el-button size="small" text type="info" v-if=" scope.row.status == 0 "
|
||||||
<el-button size="small" text type="success" v-if="scope.row.status == 1" @click="openDialog(scope.row,false)">review</el-button>
|
@click=" openDialog(scope.row, true) ">review</el-button>
|
||||||
<el-button size="small" text type="danger" v-if="scope.row.status == 2" @click="openDialog(scope.row,false)">review</el-button>
|
<el-button size="small" text type="success" v-if=" scope.row.status == 1 "
|
||||||
|
@click=" openDialog(scope.row, false) ">review</el-button>
|
||||||
|
<el-button size="small" text type="danger" v-if=" scope.row.status == 2 "
|
||||||
|
@click=" openDialog(scope.row, false) ">review</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
<el-pagination style="margin-left: 20px;" @size-change=" onHandleSizeChange " @current-change=" onHandleCurrentChange " class="mt15"
|
||||||
:pager-count="5" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum" background
|
:pager-count="3" :page-sizes=" [10, 20, 30] " v-model:current-page=" state.tableData.param.pageNum " background
|
||||||
v-model:page-size="state.tableData.param.pageSize" layout="total, sizes, prev, pager, next, jumper"
|
v-model:page-size=" state.tableData.param.pageSize " layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total=" state.tableData.total" >
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-dialog v-model="state.dialogVisible" title="Review" width="30%" >
|
<el-dialog v-model=" state.dialogVisible " title="Review" width="30%">
|
||||||
<!-- <el-form-item label="status">
|
<!-- <el-form-item label="status">
|
||||||
<el-select v-model="state.edit.status" placeholder="please select data type" style="max-width: 200px"
|
<el-select v-model="state.edit.status" placeholder="please select data type" style="max-width: 200px"
|
||||||
size="default" clearable>
|
size="default" clearable>
|
||||||
|
@ -120,18 +124,18 @@
|
||||||
|
|
||||||
<template #footer>
|
<template #footer>
|
||||||
<span class="dialog-footer">
|
<span class="dialog-footer">
|
||||||
<el-button @click="state.dialogVisible = false">Cancel</el-button>
|
<el-button @click=" state.dialogVisible = false ">Cancel</el-button>
|
||||||
<el-button type=" primary" @click="reviews(1)">
|
<el-button type=" primary" @click=" reviews(1) ">
|
||||||
reserve
|
reserve
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button type="danger" @click="reviews(2)">
|
<el-button type="danger" @click=" reviews(2) ">
|
||||||
not retain
|
not retain
|
||||||
</el-button>
|
</el-button>
|
||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</el-config-provider>
|
</el-config-provider>
|
||||||
<boot ref="bootRef" @callback="getTableData" />
|
<boot ref="bootRef" @callback=" getTableData " />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -164,11 +168,11 @@ const state = reactive({
|
||||||
multipleSelection: [],
|
multipleSelection: [],
|
||||||
searchName: '1',
|
searchName: '1',
|
||||||
disasterId: null,
|
disasterId: null,
|
||||||
queryTitle:"",
|
queryTitle: "",
|
||||||
edit: {
|
edit: {
|
||||||
status: 0,
|
status: 0,
|
||||||
},
|
},
|
||||||
srarchType:"0",
|
srarchType: "0",
|
||||||
disasterData: {
|
disasterData: {
|
||||||
data: [],
|
data: [],
|
||||||
total: 0,
|
total: 0,
|
||||||
|
@ -190,12 +194,12 @@ const state = reactive({
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
selectList :[],
|
selectList: [],
|
||||||
});
|
});
|
||||||
const openDialog = async (row,bool) => {
|
const openDialog = async (row, bool) => {
|
||||||
if(bool){
|
if (bool) {
|
||||||
state.selectList = [row]
|
state.selectList = [row]
|
||||||
}else{
|
} else {
|
||||||
state.selectList = state.multipleSelection
|
state.selectList = state.multipleSelection
|
||||||
}
|
}
|
||||||
state.dialogVisible = true;
|
state.dialogVisible = true;
|
||||||
|
@ -204,7 +208,7 @@ const reviews = async (status) => {
|
||||||
let ids = state.selectList.map((item) => item.id);
|
let ids = state.selectList.map((item) => item.id);
|
||||||
//将ids 转为字符串 使用逗号分隔
|
//将ids 转为字符串 使用逗号分隔
|
||||||
ids = ids.join(',');
|
ids = ids.join(',');
|
||||||
let res = await review(ids,status,state.searchName=='1'?true:false);
|
let res = await review(ids, status, state.searchName == '1' ? true : false);
|
||||||
if (res) {
|
if (res) {
|
||||||
state.dialogVisible = false;
|
state.dialogVisible = false;
|
||||||
ElMessage.success('success');
|
ElMessage.success('success');
|
||||||
|
@ -276,7 +280,7 @@ const getDisasterData = () => {
|
||||||
// 初始化表格数据
|
// 初始化表格数据
|
||||||
const getTableData = () => {
|
const getTableData = () => {
|
||||||
state.tableData.loading = true;
|
state.tableData.loading = true;
|
||||||
getNewsList(state.tableData.param.pageNum, state.tableData.param.pageSize, { "disasterId": state.disasterId, "isDeleted": 0,status :state.srarchType ,title:state.queryTitle}, state.searchName == '1' ? true : false).then(res => {
|
getNewsList(state.tableData.param.pageNum, state.tableData.param.pageSize, { "disasterId": state.disasterId, "isDeleted": 0, status: state.srarchType, title: state.queryTitle }, state.searchName == '1' ? true : false).then(res => {
|
||||||
state.tableData.data = res.records;
|
state.tableData.data = res.records;
|
||||||
state.tableData.total = res.total;
|
state.tableData.total = res.total;
|
||||||
})
|
})
|
||||||
|
@ -287,7 +291,7 @@ const getTableData = () => {
|
||||||
}, 500);
|
}, 500);
|
||||||
};
|
};
|
||||||
// 打开上传弹窗
|
// 打开上传弹窗
|
||||||
const startBot = (row:any) => {
|
const startBot = (row: any) => {
|
||||||
bootRef.value.openDialog(row);
|
bootRef.value.openDialog(row);
|
||||||
|
|
||||||
};
|
};
|
||||||
|
@ -370,10 +374,13 @@ onMounted(() => {
|
||||||
.system-role-container {
|
.system-role-container {
|
||||||
.system-role-padding {
|
.system-role-padding {
|
||||||
padding: 15px;
|
padding: 15px;
|
||||||
|
|
||||||
.el-table {
|
.el-table {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -12,9 +12,9 @@
|
||||||
<el-table-column prop="disasterTime" label="disaster time" show-overflow-tooltip></el-table-column>
|
<el-table-column prop="disasterTime" label="disaster time" show-overflow-tooltip></el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleDisasterSizeChange" @current-change="onHandleDisasterCurrentChange"
|
<el-pagination @size-change="onHandleDisasterSizeChange" @current-change="onHandleDisasterCurrentChange"
|
||||||
class="mt15" :pager-count="5" :page-sizes="[10, 20, 30]"
|
class="mt15" :pager-count="3" :page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.disasterData.param.pageNum" background
|
v-model:current-page="state.disasterData.param.pageNum" background
|
||||||
v-model:page-size="state.disasterData.param.pageSize" layout="total, sizes, prev, pager, next, jumper"
|
v-model:page-size="state.disasterData.param.pageSize" layout="total, sizes, prev, pager, next"
|
||||||
:total="state.disasterData.total">
|
:total="state.disasterData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</div>
|
</div>
|
||||||
|
@ -68,8 +68,8 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
||||||
:pager-count="5" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum" background
|
:pager-count="3" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum" background
|
||||||
v-model:page-size="state.tableData.param.pageSize" layout="total, sizes, prev, pager, next, jumper"
|
v-model:page-size="state.tableData.param.pageSize" layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</div>
|
</div>
|
||||||
|
@ -277,4 +277,8 @@ onMounted(() => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -4,41 +4,24 @@
|
||||||
<el-row :gutter="22">
|
<el-row :gutter="22">
|
||||||
<el-col :span="10">
|
<el-col :span="10">
|
||||||
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
||||||
<el-table :data="state.disasterData.data"
|
<el-table :data="state.disasterData.data" v-loading="state.disasterData.loading" style="width: 100%"
|
||||||
v-loading="state.disasterData.loading"
|
highlight-current-row @row-click="tableClick">
|
||||||
style="width: 100%"
|
<el-table-column type="index" label="ID" width="50" />
|
||||||
highlight-current-row
|
<el-table-column prop="disasterType" label="Disaster type" show-overflow-tooltip></el-table-column>
|
||||||
@row-click="tableClick">
|
<el-table-column prop="disasterCountry" label="disaster country" show-overflow-tooltip></el-table-column>
|
||||||
<el-table-column type="index"
|
<el-table-column prop="disasterTime" label="disaster time" show-overflow-tooltip></el-table-column>
|
||||||
label="ID"
|
|
||||||
width="50" />
|
|
||||||
<el-table-column prop="disasterType"
|
|
||||||
label="Disaster type"
|
|
||||||
show-overflow-tooltip></el-table-column>
|
|
||||||
<el-table-column prop="disasterCountry"
|
|
||||||
label="disaster country"
|
|
||||||
show-overflow-tooltip></el-table-column>
|
|
||||||
<el-table-column prop="disasterTime"
|
|
||||||
label="disaster time"
|
|
||||||
show-overflow-tooltip></el-table-column>
|
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleDisasterSizeChange"
|
<el-pagination @size-change="onHandleDisasterSizeChange" @current-change="onHandleDisasterCurrentChange"
|
||||||
@current-change="onHandleDisasterCurrentChange"
|
class="mt15" :pager-count="3" :page-sizes="[10, 20, 30]"
|
||||||
class="mt15"
|
v-model:current-page="state.disasterData.param.pageNum" background
|
||||||
:pager-count="5"
|
v-model:page-size="state.disasterData.param.pageSize" layout="total, sizes, prev, pager, next"
|
||||||
:page-sizes="[10, 20, 30]"
|
:total="state.disasterData.total">
|
||||||
v-model:current-page="state.disasterData.param.pageNum"
|
|
||||||
background
|
|
||||||
v-model:page-size="state.disasterData.param.pageSize"
|
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
|
||||||
:total="state.disasterData.total">
|
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="14">
|
<el-col :span="14">
|
||||||
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
||||||
<div class="system-user-search mb15"
|
<div class="system-user-search mb15" style="display: flex;margin-left: 10px;margin-top: 10px;">
|
||||||
style="display: flex;margin-left: 10px;margin-top: 10px;">
|
|
||||||
<!-- <el-input size="default" placeholder="please enter username" style="max-width: 180px" v-model="state.searchName"
|
<!-- <el-input size="default" placeholder="please enter username" style="max-width: 180px" v-model="state.searchName"
|
||||||
clearable></el-input>
|
clearable></el-input>
|
||||||
<el-button size="default" type="primary" class="ml10" @click="getTableData">
|
<el-button size="default" type="primary" class="ml10" @click="getTableData">
|
||||||
|
@ -47,19 +30,13 @@
|
||||||
</el-icon>
|
</el-icon>
|
||||||
search
|
search
|
||||||
</el-button>-->
|
</el-button>-->
|
||||||
<el-button size="default"
|
<el-button size="default" type="success" class="ml10" @click="uploadData">
|
||||||
type="success"
|
|
||||||
class="ml10"
|
|
||||||
@click="uploadData">
|
|
||||||
<el-icon>
|
<el-icon>
|
||||||
<ele-Upload />
|
<ele-Upload />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
upload
|
upload
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button size="default"
|
<el-button size="default" type="danger" class="ml10" @click="batchDel">
|
||||||
type="danger"
|
|
||||||
class="ml10"
|
|
||||||
@click="batchDel">
|
|
||||||
<el-icon>
|
<el-icon>
|
||||||
<ele-Delete />
|
<ele-Delete />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
|
@ -67,40 +44,24 @@
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<el-table :data="state.tableData.data"
|
<el-table :data="state.tableData.data" v-loading="state.tableData.loading"
|
||||||
v-loading="state.tableData.loading"
|
@selection-change="handleSelectionChange" style="width: 100%">
|
||||||
@selection-change="handleSelectionChange"
|
<el-table-column type="selection" width="55" />
|
||||||
style="width: 100%">
|
<el-table-column type="index" label="ID" width="50" />
|
||||||
<el-table-column type="selection"
|
<el-table-column prop="name" label="name" show-overflow-tooltip>
|
||||||
width="55" />
|
|
||||||
<el-table-column type="index"
|
|
||||||
label="ID"
|
|
||||||
width="50" />
|
|
||||||
<el-table-column prop="name"
|
|
||||||
label="name"
|
|
||||||
show-overflow-tooltip>
|
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
{{formatName(scope.row.name)}}
|
{{ formatName(scope.row.name) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="link"
|
<el-table-column prop="link" label="image" show-overflow-tooltip>
|
||||||
label="image"
|
|
||||||
show-overflow-tooltip>
|
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-popover trigger="hover"
|
<el-popover trigger="hover" placement="right" popper-class="max-h-300px overflow-auto" :width="330">
|
||||||
placement="right"
|
|
||||||
popper-class="max-h-300px overflow-auto"
|
|
||||||
:width="330">
|
|
||||||
<!-- table中原本显示的图片 -->
|
<!-- table中原本显示的图片 -->
|
||||||
<template #reference>
|
<template #reference>
|
||||||
<img :src="scope.row.link"
|
<img :src="scope.row.link" :alt="scope.row.link" style="max-height: 130px;max-width: 130px">
|
||||||
:alt="scope.row.link"
|
|
||||||
style="max-height: 130px;max-width: 130px">
|
|
||||||
</template>
|
</template>
|
||||||
<!-- 鼠标移入时弹出的图片 -->
|
<!-- 鼠标移入时弹出的图片 -->
|
||||||
<img :src="scope.row.link"
|
<img :src="scope.row.link" alt="" style="height: 150px;width: 300px">
|
||||||
alt=""
|
|
||||||
style="height: 150px;width: 300px">
|
|
||||||
</el-popover>
|
</el-popover>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
@ -114,42 +75,26 @@
|
||||||
<el-table-column prop="type"
|
<el-table-column prop="type"
|
||||||
label="type"
|
label="type"
|
||||||
show-overflow-tooltip></el-table-column>-->
|
show-overflow-tooltip></el-table-column>-->
|
||||||
<el-table-column prop="Operate"
|
<el-table-column prop="Operate" label="Operate" show-overflow-tooltip>
|
||||||
label="Operate"
|
|
||||||
show-overflow-tooltip>
|
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button size="small"
|
<el-button size="small" text type="primary" @click="editData(scope.row)">Edit</el-button>
|
||||||
text
|
<el-button size="small" text type="primary" @click="del(scope.row)">Delete</el-button>
|
||||||
type="primary"
|
|
||||||
@click="editData(scope.row)">Edit</el-button>
|
|
||||||
<el-button size="small"
|
|
||||||
text
|
|
||||||
type="primary"
|
|
||||||
@click="del(scope.row)">Delete</el-button>
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleSizeChange"
|
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
||||||
@current-change="onHandleCurrentChange"
|
:pager-count="3" :page-sizes="[10, 20, 30]"
|
||||||
class="mt15"
|
v-model:current-page="state.tableData.param.pageNum" background
|
||||||
:pager-count="5"
|
v-model:page-size="state.tableData.param.pageSize" layout="total, sizes, prev, pager, next"
|
||||||
:page-sizes="[10, 20, 30]"
|
:total="state.tableData.total">
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
|
||||||
background
|
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
|
||||||
:total="state.tableData.total">
|
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
</el-config-provider>
|
</el-config-provider>
|
||||||
<RoleDialog ref="roleDialogRef"
|
<RoleDialog ref="roleDialogRef" @refresh="getTableData()" />
|
||||||
@refresh="getTableData()" />
|
<Upload ref="uploadRef" @callback="getTableData" />
|
||||||
<Upload ref="uploadRef"
|
<EditPicture ref="editUploadRef" @callback="getTableData" />
|
||||||
@callback="getTableData" />
|
|
||||||
<EditPicture ref="editUploadRef"
|
|
||||||
@callback="getTableData" />
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -172,198 +117,205 @@ const editUploadRef = ref();
|
||||||
// 定义变量内容
|
// 定义变量内容
|
||||||
const roleDialogRef = ref();
|
const roleDialogRef = ref();
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
multipleSelection: [],
|
multipleSelection: [],
|
||||||
tabVal: 'first',
|
tabVal: 'first',
|
||||||
disasterId: null,
|
disasterId: null,
|
||||||
disasterData: {
|
disasterData: {
|
||||||
data: [],
|
data: [],
|
||||||
total: 0,
|
total: 0,
|
||||||
loading: false,
|
loading: false,
|
||||||
param: {
|
param: {
|
||||||
search: '',
|
search: '',
|
||||||
pageNum: 1,
|
pageNum: 1,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
tableData: {
|
tableData: {
|
||||||
data: [],
|
data: [],
|
||||||
total: 0,
|
total: 0,
|
||||||
loading: false,
|
loading: false,
|
||||||
param: {
|
param: {
|
||||||
search: '',
|
search: '',
|
||||||
pageNum: 1,
|
pageNum: 1,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
const handleSelectionChange = (val) => {
|
const handleSelectionChange = (val) => {
|
||||||
state.multipleSelection = val;
|
state.multipleSelection = val;
|
||||||
};
|
};
|
||||||
//格式化图片名称
|
//格式化图片名称
|
||||||
const formatName = (name) => {
|
const formatName = (name) => {
|
||||||
if (name) {
|
if (name) {
|
||||||
return name.substr(0, name.indexOf('.'));
|
return name.substr(0, name.indexOf('.'));
|
||||||
}
|
}
|
||||||
return name;
|
return name;
|
||||||
};
|
};
|
||||||
const auditData = (row) => {
|
const auditData = (row) => {
|
||||||
let id = row.id;
|
let id = row.id;
|
||||||
auditRef.value.openDialog([{ id: id }]);
|
auditRef.value.openDialog([{ id: id }]);
|
||||||
};
|
};
|
||||||
//格式化字节
|
//格式化字节
|
||||||
const formatSize = (size) => {
|
const formatSize = (size) => {
|
||||||
var data = '';
|
var data = '';
|
||||||
if (size < 0.1 * 1024) {
|
if (size < 0.1 * 1024) {
|
||||||
//如果小于0.1KB转化成B
|
//如果小于0.1KB转化成B
|
||||||
data = size.toFixed(2) + 'B';
|
data = size.toFixed(2) + 'B';
|
||||||
} else if (size < 0.1 * 1024 * 1024) {
|
} else if (size < 0.1 * 1024 * 1024) {
|
||||||
//如果小于0.1MB转化成KB
|
//如果小于0.1MB转化成KB
|
||||||
data = (size / 1024).toFixed(2) + 'KB';
|
data = (size / 1024).toFixed(2) + 'KB';
|
||||||
} else if (size < 0.1 * 1024 * 1024 * 1024) {
|
} else if (size < 0.1 * 1024 * 1024 * 1024) {
|
||||||
//如果小于0.1GB转化成MB
|
//如果小于0.1GB转化成MB
|
||||||
data = (size / (1024 * 1024)).toFixed(2) + 'MB';
|
data = (size / (1024 * 1024)).toFixed(2) + 'MB';
|
||||||
} else {
|
} else {
|
||||||
//其他转化成GB
|
//其他转化成GB
|
||||||
data = (size / (1024 * 1024 * 1024)).toFixed(2) + 'GB';
|
data = (size / (1024 * 1024 * 1024)).toFixed(2) + 'GB';
|
||||||
}
|
}
|
||||||
var sizestr = data + '';
|
var sizestr = data + '';
|
||||||
var len = sizestr.indexOf('.');
|
var len = sizestr.indexOf('.');
|
||||||
var dec = sizestr.substr(len + 1, 2);
|
var dec = sizestr.substr(len + 1, 2);
|
||||||
if (dec == '00') {
|
if (dec == '00') {
|
||||||
//当小数点后为00时 去掉小数部分
|
//当小数点后为00时 去掉小数部分
|
||||||
return sizestr.substring(0, len) + sizestr.substr(len + 3, 2);
|
return sizestr.substring(0, len) + sizestr.substr(len + 3, 2);
|
||||||
}
|
}
|
||||||
return sizestr;
|
return sizestr;
|
||||||
};
|
};
|
||||||
const formatSizeUnits = (size) => {
|
const formatSizeUnits = (size) => {
|
||||||
if (size === 0 || size === -1) return '0 B';
|
if (size === 0 || size === -1) return '0 B';
|
||||||
var k = 1000, // or 1024
|
var k = 1000, // or 1024
|
||||||
sizes = ['B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'],
|
sizes = ['B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'],
|
||||||
i = Math.floor(Math.log(size) / Math.log(k));
|
i = Math.floor(Math.log(size) / Math.log(k));
|
||||||
|
|
||||||
return (size / Math.pow(k, i)).toPrecision(3) + ' ' + sizes[i];
|
return (size / Math.pow(k, i)).toPrecision(3) + ' ' + sizes[i];
|
||||||
};
|
};
|
||||||
//灾害表格点击事件
|
//灾害表格点击事件
|
||||||
const tableClick = (row, column, event) => {
|
const tableClick = (row, column, event) => {
|
||||||
state.disasterId = row.disasterId;
|
state.disasterId = row.disasterId;
|
||||||
getTableData();
|
getTableData();
|
||||||
};
|
};
|
||||||
// 初始化灾害表格数据
|
// 初始化灾害表格数据
|
||||||
const getDisasterData = () => {
|
const getDisasterData = () => {
|
||||||
state.disasterData.loading = true;
|
state.disasterData.loading = true;
|
||||||
getDisasterPage(state.disasterData.param.pageNum, state.disasterData.param.pageSize, {}).then((res) => {
|
getDisasterPage(state.disasterData.param.pageNum, state.disasterData.param.pageSize, {}).then((res) => {
|
||||||
state.disasterData.data = res.records;
|
state.disasterData.data = res.records;
|
||||||
state.disasterData.total = res.total;
|
state.disasterData.total = res.total;
|
||||||
state.disasterData.loading = false;
|
state.disasterData.loading = false;
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
// 初始化表格数据
|
// 初始化表格数据
|
||||||
const getTableData = () => {
|
const getTableData = () => {
|
||||||
state.tableData.loading = true;
|
state.tableData.loading = true;
|
||||||
getPicturePage(state.tableData.param.pageNum, state.tableData.param.pageSize, { disasterId_equal: state.disasterId, isDeleted_equal: 0 }).then(
|
getPicturePage(state.tableData.param.pageNum, state.tableData.param.pageSize, { disasterId_equal: state.disasterId, isDeleted_equal: 0 }).then(
|
||||||
(res) => {
|
(res) => {
|
||||||
state.tableData.data = res.records;
|
state.tableData.data = res.records;
|
||||||
state.tableData.total = res.total;
|
state.tableData.total = res.total;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
state.tableData.loading = false;
|
state.tableData.loading = false;
|
||||||
}, 500);
|
}, 500);
|
||||||
};
|
};
|
||||||
// 打开上传弹窗
|
// 打开上传弹窗
|
||||||
const uploadData = () => {
|
const uploadData = () => {
|
||||||
if (state.disasterId == null) {
|
if (state.disasterId == null) {
|
||||||
ElMessage.warning('Please select the disaster first');
|
ElMessage.warning('Please select the disaster first');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
uploadRef.value.openDialog(state.disasterId);
|
uploadRef.value.openDialog(state.disasterId);
|
||||||
};
|
};
|
||||||
// 打开修改角色弹窗
|
// 打开修改角色弹窗
|
||||||
const editData = (row) => {
|
const editData = (row) => {
|
||||||
editUploadRef.value.openDialog(row);
|
editUploadRef.value.openDialog(row);
|
||||||
};
|
};
|
||||||
//批量删除图片数据
|
//批量删除图片数据
|
||||||
const batchDel = () => {
|
const batchDel = () => {
|
||||||
if (state.multipleSelection.length == 0) {
|
if (state.multipleSelection.length == 0) {
|
||||||
ElMessage.warning('Select the data to be operated first');
|
ElMessage.warning('Select the data to be operated first');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
ElMessageBox.confirm(`This action batch deletes the picture data,Whether to continue?`, 'tip', {
|
ElMessageBox.confirm(`This action batch deletes the picture data,Whether to continue?`, 'tip', {
|
||||||
confirmButtonText: 'confirm',
|
confirmButtonText: 'confirm',
|
||||||
cancelButtonText: 'cancel',
|
cancelButtonText: 'cancel',
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
let id = state.multipleSelection.map((item) => item.id);
|
let id = state.multipleSelection.map((item) => item.id);
|
||||||
delPicture(id.join()).then((res) => {
|
delPicture(id.join()).then((res) => {
|
||||||
getTableData();
|
getTableData();
|
||||||
ElMessage.success('delete successfully');
|
ElMessage.success('delete successfully');
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
.catch(() => {});
|
.catch(() => { });
|
||||||
};
|
};
|
||||||
// 删除图片信息
|
// 删除图片信息
|
||||||
const del = (row) => {
|
const del = (row) => {
|
||||||
ElMessageBox.confirm(`This action will delete the picture:“${row.name}”,,Whether to continue?`, 'tip', {
|
ElMessageBox.confirm(`This action will delete the picture:“${row.name}”,,Whether to continue?`, 'tip', {
|
||||||
confirmButtonText: 'confirm',
|
confirmButtonText: 'confirm',
|
||||||
cancelButtonText: 'cancel',
|
cancelButtonText: 'cancel',
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
delPicture(row.id).then((res) => {
|
delPicture(row.id).then((res) => {
|
||||||
getTableData();
|
getTableData();
|
||||||
ElMessage.success('delete successfully');
|
ElMessage.success('delete successfully');
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
.catch(() => {});
|
.catch(() => { });
|
||||||
};
|
};
|
||||||
// 分页改变
|
// 分页改变
|
||||||
const onHandleDisasterSizeChange = (val) => {
|
const onHandleDisasterSizeChange = (val) => {
|
||||||
state.disasterData.param.pageSize = val;
|
state.disasterData.param.pageSize = val;
|
||||||
getDisasterData();
|
getDisasterData();
|
||||||
};
|
};
|
||||||
// 分页改变
|
// 分页改变
|
||||||
const onHandleDisasterCurrentChange = (val) => {
|
const onHandleDisasterCurrentChange = (val) => {
|
||||||
state.disasterData.param.pageNum = val;
|
state.disasterData.param.pageNum = val;
|
||||||
getDisasterData();
|
getDisasterData();
|
||||||
};
|
};
|
||||||
// 分页改变
|
// 分页改变
|
||||||
const onHandleSizeChange = (val) => {
|
const onHandleSizeChange = (val) => {
|
||||||
state.tableData.param.pageSize = val;
|
state.tableData.param.pageSize = val;
|
||||||
getTableData();
|
getTableData();
|
||||||
};
|
};
|
||||||
// 分页改变
|
// 分页改变
|
||||||
const onHandleCurrentChange = (val) => {
|
const onHandleCurrentChange = (val) => {
|
||||||
state.tableData.param.pageNum = val;
|
state.tableData.param.pageNum = val;
|
||||||
getTableData();
|
getTableData();
|
||||||
};
|
};
|
||||||
// 页面加载时
|
// 页面加载时
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
getDisasterData();
|
getDisasterData();
|
||||||
//getTableData();
|
//getTableData();
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
<style>
|
<style>
|
||||||
.demo-tabs > .el-tabs__content {
|
.mt15 {
|
||||||
padding: 32px;
|
float: right;
|
||||||
color: #6b778c;
|
margin-bottom: 15px;
|
||||||
font-size: 32px;
|
}
|
||||||
font-weight: 600;
|
|
||||||
|
.demo-tabs>.el-tabs__content {
|
||||||
|
padding: 32px;
|
||||||
|
color: #6b778c;
|
||||||
|
font-size: 32px;
|
||||||
|
font-weight: 600;
|
||||||
}
|
}
|
||||||
|
|
||||||
.system-role-container {
|
.system-role-container {
|
||||||
.system-role-padding {
|
.system-role-padding {
|
||||||
padding: 15px;
|
padding: 15px;
|
||||||
.el-table {
|
|
||||||
flex: 1;
|
.el-table {
|
||||||
}
|
flex: 1;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.demo-tabs > .el-tabs__content {
|
|
||||||
padding: 32px;
|
.demo-tabs>.el-tabs__content {
|
||||||
color: #6b778c;
|
padding: 32px;
|
||||||
font-size: 32px;
|
color: #6b778c;
|
||||||
font-weight: 600;
|
font-size: 32px;
|
||||||
|
font-weight: 600;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -25,12 +25,12 @@
|
||||||
<el-pagination @size-change="onHandleDisasterSizeChange"
|
<el-pagination @size-change="onHandleDisasterSizeChange"
|
||||||
@current-change="onHandleDisasterCurrentChange"
|
@current-change="onHandleDisasterCurrentChange"
|
||||||
class="mt15"
|
class="mt15"
|
||||||
:pager-count="5"
|
:pager-count="3"
|
||||||
:page-sizes="[10, 20, 30]"
|
:page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.disasterData.param.pageNum"
|
v-model:current-page="state.disasterData.param.pageNum"
|
||||||
background
|
background
|
||||||
v-model:page-size="state.disasterData.param.pageSize"
|
v-model:page-size="state.disasterData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
layout="total, sizes, prev, pager, next"
|
||||||
:total="state.disasterData.total">
|
:total="state.disasterData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</div>
|
</div>
|
||||||
|
@ -96,7 +96,7 @@
|
||||||
clearable
|
clearable
|
||||||
placeholder="Select resolution" />
|
placeholder="Select resolution" />
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="5">
|
<el-col :span="3">
|
||||||
<el-button size="default"
|
<el-button size="default"
|
||||||
type="primary"
|
type="primary"
|
||||||
class="ml10"
|
class="ml10"
|
||||||
|
@ -188,12 +188,12 @@
|
||||||
<el-pagination @size-change="onHandleSizeChange"
|
<el-pagination @size-change="onHandleSizeChange"
|
||||||
@current-change="onHandleCurrentChange"
|
@current-change="onHandleCurrentChange"
|
||||||
class="mt15"
|
class="mt15"
|
||||||
:pager-count="5"
|
:pager-count="3"
|
||||||
:page-sizes="[10, 20, 30]"
|
:page-sizes="[10, 20, 30]"
|
||||||
background
|
background
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
v-model:current-page="state.tableData.param.pageNum"
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</div>
|
</div>
|
||||||
|
@ -640,4 +640,8 @@ const searchDisasterDate = () => {
|
||||||
.el-pagination {
|
.el-pagination {
|
||||||
padding-left: 1%;
|
padding-left: 1%;
|
||||||
}
|
}
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
|
@ -7,7 +7,7 @@
|
||||||
<el-card class="box-card">
|
<el-card class="box-card">
|
||||||
<span>Select time range</span>
|
<span>Select time range</span>
|
||||||
<el-row class="block">
|
<el-row class="block">
|
||||||
<el-col :span="5">
|
<el-col :span="3">
|
||||||
<span class="demonstration">Start time</span>
|
<span class="demonstration">Start time</span>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="19">
|
<el-col :span="19">
|
||||||
|
@ -19,7 +19,7 @@
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row class="block">
|
<el-row class="block">
|
||||||
<el-col :span="5">
|
<el-col :span="3">
|
||||||
<span class="demonstration">End time</span>
|
<span class="demonstration">End time</span>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="19">
|
<el-col :span="19">
|
||||||
|
|
|
@ -1,44 +1,28 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="system-role-container layout-padding">
|
<div class="system-role-container layout-padding">
|
||||||
<el-config-provider :locale="en">
|
<el-config-provider :locale="en">
|
||||||
<el-row :gutter="22">
|
<el-row :gutter="22">
|
||||||
<el-col :span="10">
|
<el-col :span="10">
|
||||||
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
||||||
<el-table :data="state.disasterData.data"
|
<el-table :data="state.disasterData.data" v-loading="state.disasterData.loading" style="width: 100%"
|
||||||
v-loading="state.disasterData.loading"
|
highlight-current-row @row-click="tableClick">
|
||||||
style="width: 100%"
|
<el-table-column type="index" label="ID" width="50" />
|
||||||
highlight-current-row
|
<el-table-column prop="disasterType" label="Disaster type" show-overflow-tooltip></el-table-column>
|
||||||
@row-click="tableClick">
|
<el-table-column prop="disasterCountry" label="disaster country" show-overflow-tooltip></el-table-column>
|
||||||
<el-table-column type="index"
|
<el-table-column prop="disasterTime" label="disaster time" show-overflow-tooltip></el-table-column>
|
||||||
label="ID"
|
</el-table>
|
||||||
width="50" />
|
<el-pagination @size-change="onHandleDisasterSizeChange" @current-change="onHandleDisasterCurrentChange"
|
||||||
<el-table-column prop="disasterType"
|
class="mt15" :pager-count="3" :page-sizes="[10, 20, 30]"
|
||||||
label="Disaster type"
|
v-model:current-page="state.disasterData.param.pageNum" background
|
||||||
show-overflow-tooltip></el-table-column>
|
v-model:page-size="state.disasterData.param.pageSize" layout="total, sizes, prev, pager, next"
|
||||||
<el-table-column prop="disasterCountry"
|
:total="state.disasterData.total">
|
||||||
label="disaster country"
|
</el-pagination>
|
||||||
show-overflow-tooltip></el-table-column>
|
</div>
|
||||||
<el-table-column prop="disasterTime"
|
</el-col>
|
||||||
label="disaster time"
|
<el-col :span="14">
|
||||||
show-overflow-tooltip></el-table-column>
|
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
||||||
</el-table>
|
<div class="system-user-search mb15" style="display: flex;margin-left: 10px;margin-top: 10px;">
|
||||||
<el-pagination @size-change="onHandleDisasterSizeChange"
|
<!-- <el-input size="default" placeholder="please enter username" style="max-width: 180px" v-model="state.searchName"
|
||||||
@current-change="onHandleDisasterCurrentChange"
|
|
||||||
class="mt15"
|
|
||||||
:pager-count="5"
|
|
||||||
:page-sizes="[10, 20, 30]"
|
|
||||||
v-model:current-page="state.disasterData.param.pageNum"
|
|
||||||
background
|
|
||||||
v-model:page-size="state.disasterData.param.pageSize"
|
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
|
||||||
:total="state.disasterData.total">
|
|
||||||
</el-pagination>
|
|
||||||
</div>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="14">
|
|
||||||
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
|
||||||
<div class="system-user-search mb15" style="display: flex;margin-left: 10px;margin-top: 10px;">
|
|
||||||
<!-- <el-input size="default" placeholder="please enter username" style="max-width: 180px" v-model="state.searchName"
|
|
||||||
clearable></el-input>
|
clearable></el-input>
|
||||||
<el-button size="default" type="primary" class="ml10" @click="getTableData">
|
<el-button size="default" type="primary" class="ml10" @click="getTableData">
|
||||||
<el-icon>
|
<el-icon>
|
||||||
|
@ -46,109 +30,72 @@
|
||||||
</el-icon>
|
</el-icon>
|
||||||
search
|
search
|
||||||
</el-button>-->
|
</el-button>-->
|
||||||
<el-button size="default" type="success" class="ml10" @click="uploadData">
|
<el-button size="default" type="success" class="ml10" @click="uploadData">
|
||||||
<el-icon>
|
<el-icon>
|
||||||
<ele-Upload/>
|
<ele-Upload />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
upload
|
upload
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button size="default" type="danger" class="ml10" @click="batchDel">
|
<el-button size="default" type="danger" class="ml10" @click="batchDel">
|
||||||
<el-icon>
|
<el-icon>
|
||||||
<ele-Delete/>
|
<ele-Delete />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
batch delete
|
batch delete
|
||||||
</el-button>
|
</el-button>
|
||||||
|
</div>
|
||||||
|
<el-tabs v-model="activeName" class="demo-tabs" @tab-change="handleClick" type="card">
|
||||||
|
<el-tab-pane label="wordclouds" name="first">
|
||||||
|
<el-table :data="state.tableData.data" v-loading="state.tableData.loading"
|
||||||
|
@selection-change="handleSelectionChange" style="width: 100%">
|
||||||
|
<el-table-column type="selection" width="55" />
|
||||||
|
<el-table-column type="index" label="ID" width="50" />
|
||||||
|
<el-table-column prop="time" label="time" show-overflow-tooltip></el-table-column>
|
||||||
|
<el-table-column prop="frequency" label="frequency" show-overflow-tooltip></el-table-column>
|
||||||
|
<el-table-column prop="word" label="word" show-overflow-tooltip></el-table-column>
|
||||||
|
<el-table-column prop="Operate" label="Operate" show-overflow-tooltip>
|
||||||
|
<template #default="scope">
|
||||||
|
<el-button size="small" text type="primary" @click="editWordCloud(scope.row)">Edit</el-button>
|
||||||
|
<el-button size="small" text type="primary" @click="delWordCloud(scope.row)">Delete</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
||||||
|
:pager-count="3" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum"
|
||||||
|
background v-model:page-size="state.tableData.param.pageSize"
|
||||||
|
layout="total, sizes, prev, pager, next" :total="state.tableData.total">
|
||||||
|
</el-pagination>
|
||||||
|
</el-tab-pane>
|
||||||
|
<el-tab-pane label="hotspot" name="second">
|
||||||
|
<el-table :data="state.tableData.data" v-loading="state.tableData.loading"
|
||||||
|
@selection-change="handleSelectionHotspotChange" style="width: 100%">
|
||||||
|
<el-table-column type="selection" width="55" />
|
||||||
|
<el-table-column type="index" label="ID" width="50" />
|
||||||
|
<el-table-column prop="areaCn" label="area cn" show-overflow-tooltip></el-table-column>
|
||||||
|
<el-table-column prop="areaEn" label="area en" show-overflow-tooltip></el-table-column>
|
||||||
|
<el-table-column prop="frequency" label="frequency" show-overflow-tooltip></el-table-column>
|
||||||
|
<el-table-column prop="Operate" label="Operate" show-overflow-tooltip>
|
||||||
|
<template #default="scope">
|
||||||
|
<el-button size="small" text type="primary" @click="editHotspot(scope.row)">Edit</el-button>
|
||||||
|
<el-button size="small" text type="primary" @click="delHotspot(scope.row)">Delete</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
||||||
|
:pager-count="3" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum"
|
||||||
|
background v-model:page-size="state.tableData.param.pageSize"
|
||||||
|
layout="total, sizes, prev, pager, next" :total="state.tableData.total">
|
||||||
|
</el-pagination>
|
||||||
|
</el-tab-pane>
|
||||||
|
</el-tabs>
|
||||||
</div>
|
</div>
|
||||||
<el-tabs v-model="activeName" class="demo-tabs" @tab-change="handleClick" type="card">
|
</el-col>
|
||||||
<el-tab-pane label="wordclouds" name="first">
|
</el-row>
|
||||||
<el-table :data="state.tableData.data"
|
|
||||||
v-loading="state.tableData.loading"
|
|
||||||
@selection-change="handleSelectionChange"
|
|
||||||
style="width: 100%">
|
|
||||||
<el-table-column type="selection" width="55" />
|
|
||||||
<el-table-column type="index"
|
|
||||||
label="ID"
|
|
||||||
width="50" />
|
|
||||||
<el-table-column prop="time"
|
|
||||||
label="time"
|
|
||||||
show-overflow-tooltip></el-table-column>
|
|
||||||
<el-table-column prop="frequency"
|
|
||||||
label="frequency"
|
|
||||||
show-overflow-tooltip></el-table-column>
|
|
||||||
<el-table-column prop="word"
|
|
||||||
label="word"
|
|
||||||
show-overflow-tooltip></el-table-column>
|
|
||||||
<el-table-column prop="Operate"
|
|
||||||
label="Operate"
|
|
||||||
show-overflow-tooltip>
|
|
||||||
<template #default="scope">
|
|
||||||
<el-button size="small" text type="primary" @click="editWordCloud(scope.row)">Edit</el-button>
|
|
||||||
<el-button size="small" text type="primary" @click="delWordCloud(scope.row)">Delete</el-button>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
</el-table>
|
|
||||||
<el-pagination @size-change="onHandleSizeChange"
|
|
||||||
@current-change="onHandleCurrentChange"
|
|
||||||
class="mt15"
|
|
||||||
:pager-count="5"
|
|
||||||
:page-sizes="[10, 20, 30]"
|
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
|
||||||
background
|
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
|
||||||
:total="state.tableData.total">
|
|
||||||
</el-pagination>
|
|
||||||
</el-tab-pane>
|
|
||||||
<el-tab-pane label="hotspot" name="second">
|
|
||||||
<el-table :data="state.tableData.data"
|
|
||||||
v-loading="state.tableData.loading"
|
|
||||||
@selection-change="handleSelectionHotspotChange"
|
|
||||||
style="width: 100%">
|
|
||||||
<el-table-column type="selection" width="55" />
|
|
||||||
<el-table-column type="index"
|
|
||||||
label="ID"
|
|
||||||
width="50" />
|
|
||||||
<el-table-column prop="areaCn"
|
|
||||||
label="area cn"
|
|
||||||
show-overflow-tooltip></el-table-column>
|
|
||||||
<el-table-column prop="areaEn"
|
|
||||||
label="area en"
|
|
||||||
show-overflow-tooltip></el-table-column>
|
|
||||||
<el-table-column prop="frequency"
|
|
||||||
label="frequency"
|
|
||||||
show-overflow-tooltip></el-table-column>
|
|
||||||
<el-table-column prop="Operate"
|
|
||||||
label="Operate"
|
|
||||||
show-overflow-tooltip>
|
|
||||||
<template #default="scope">
|
|
||||||
<el-button size="small" text type="primary" @click="editHotspot(scope.row)">Edit</el-button>
|
|
||||||
<el-button size="small" text type="primary" @click="delHotspot(scope.row)">Delete</el-button>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
</el-table>
|
|
||||||
<el-pagination @size-change="onHandleSizeChange"
|
|
||||||
@current-change="onHandleCurrentChange"
|
|
||||||
class="mt15"
|
|
||||||
:pager-count="5"
|
|
||||||
:page-sizes="[10, 20, 30]"
|
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
|
||||||
background
|
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
|
||||||
:total="state.tableData.total">
|
|
||||||
</el-pagination>
|
|
||||||
</el-tab-pane>
|
|
||||||
</el-tabs>
|
|
||||||
</div>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
</el-config-provider>
|
</el-config-provider>
|
||||||
<RoleDialog ref="roleDialogRef"
|
<RoleDialog ref="roleDialogRef" @refresh="getTableData()" />
|
||||||
@refresh="getTableData()" />
|
<HotspotForm ref="hotspotRef" @callback="getTableData" />
|
||||||
<HotspotForm ref="hotspotRef" @callback="getTableData"/>
|
<WordClouds ref="wordCloudsRef" @callback="getTableData" />
|
||||||
<WordClouds ref="wordCloudsRef" @callback="getTableData"/>
|
<EditHotspotForm ref="editHotspotRef" @callback="getTableData" />
|
||||||
<EditHotspotForm ref="editHotspotRef" @callback="getTableData"/>
|
<EditWordCloudsForm ref="editWordCloudsRef" @callback="getTableData" />
|
||||||
<EditWordCloudsForm ref="editWordCloudsRef" @callback="getTableData"/>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -158,7 +105,7 @@ import HotspotForm from './component/hotspotForm.vue';
|
||||||
import WordClouds from './component/wordCloudForm.vue';
|
import WordClouds from './component/wordCloudForm.vue';
|
||||||
import EditHotspotForm from './component/editHotspotForm.vue';
|
import EditHotspotForm from './component/editHotspotForm.vue';
|
||||||
import EditWordCloudsForm from './component/editWordCloudForm.vue';
|
import EditWordCloudsForm from './component/editWordCloudForm.vue';
|
||||||
import {getWordClouds,getHotspot,getDisasterPage,delData} from '/@/api/data/visualData.js';
|
import { getWordClouds, getHotspot, getDisasterPage, delData } from '/@/api/data/visualData.js';
|
||||||
import en from 'element-plus/dist/locale/en.mjs'
|
import en from 'element-plus/dist/locale/en.mjs'
|
||||||
const activeName = ref('first');
|
const activeName = ref('first');
|
||||||
const hotspotRef = ref();
|
const hotspotRef = ref();
|
||||||
|
@ -176,10 +123,10 @@ const uploadRef = ref();
|
||||||
// 定义变量内容
|
// 定义变量内容
|
||||||
const roleDialogRef = ref();
|
const roleDialogRef = ref();
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
multipleWord:[],
|
multipleWord: [],
|
||||||
multipleHotspot:[],
|
multipleHotspot: [],
|
||||||
tabVal:'first',
|
tabVal: 'first',
|
||||||
disasterId:null,
|
disasterId: null,
|
||||||
disasterData: {
|
disasterData: {
|
||||||
data: [],
|
data: [],
|
||||||
total: 0,
|
total: 0,
|
||||||
|
@ -211,7 +158,7 @@ const handleSelectionHotspotChange = (val) => {
|
||||||
}
|
}
|
||||||
const handleClick = (tab) => {
|
const handleClick = (tab) => {
|
||||||
state.tabVal = tab;
|
state.tabVal = tab;
|
||||||
state. tableData={
|
state.tableData = {
|
||||||
data: [],
|
data: [],
|
||||||
total: 0,
|
total: 0,
|
||||||
loading: false,
|
loading: false,
|
||||||
|
@ -225,7 +172,7 @@ const handleClick = (tab) => {
|
||||||
};
|
};
|
||||||
const auditData = (row) => {
|
const auditData = (row) => {
|
||||||
let id = row.id
|
let id = row.id
|
||||||
auditRef.value.openDialog([{"id":id}]);
|
auditRef.value.openDialog([{ "id": id }]);
|
||||||
}
|
}
|
||||||
//格式化字节
|
//格式化字节
|
||||||
const formatSize = (size) => {
|
const formatSize = (size) => {
|
||||||
|
@ -250,8 +197,8 @@ const formatSize = (size) => {
|
||||||
const formatSizeUnits = (size) => {
|
const formatSizeUnits = (size) => {
|
||||||
if (size === 0) return '0 B';
|
if (size === 0) return '0 B';
|
||||||
var k = 1000, // or 1024
|
var k = 1000, // or 1024
|
||||||
sizes = ['B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'],
|
sizes = ['B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'],
|
||||||
i = Math.floor(Math.log(size) / Math.log(k));
|
i = Math.floor(Math.log(size) / Math.log(k));
|
||||||
|
|
||||||
return (size / Math.pow(k, i)).toPrecision(3) + ' ' + sizes[i];
|
return (size / Math.pow(k, i)).toPrecision(3) + ' ' + sizes[i];
|
||||||
}
|
}
|
||||||
|
@ -263,7 +210,7 @@ const tableClick = (row, column, event) => {
|
||||||
// 初始化灾害表格数据
|
// 初始化灾害表格数据
|
||||||
const getDisasterData = () => {
|
const getDisasterData = () => {
|
||||||
state.disasterData.loading = true;
|
state.disasterData.loading = true;
|
||||||
getDisasterPage(state.disasterData.param.pageNum,state.disasterData.param.pageSize,{}).then(res=>{
|
getDisasterPage(state.disasterData.param.pageNum, state.disasterData.param.pageSize, {}).then(res => {
|
||||||
state.disasterData.data = res.records;
|
state.disasterData.data = res.records;
|
||||||
state.disasterData.total = res.total;
|
state.disasterData.total = res.total;
|
||||||
state.disasterData.loading = false;
|
state.disasterData.loading = false;
|
||||||
|
@ -273,13 +220,13 @@ const getDisasterData = () => {
|
||||||
// 初始化表格数据
|
// 初始化表格数据
|
||||||
const getTableData = () => {
|
const getTableData = () => {
|
||||||
state.tableData.loading = true;
|
state.tableData.loading = true;
|
||||||
if(state.tabVal == 'first'){
|
if (state.tabVal == 'first') {
|
||||||
getWordClouds(state.tableData.param.pageNum,state.tableData.param.pageSize,{"disasterId_equal":state.disasterId,"isDeleted_equal":0}).then(res=>{
|
getWordClouds(state.tableData.param.pageNum, state.tableData.param.pageSize, { "disasterId_equal": state.disasterId, "isDeleted_equal": 0 }).then(res => {
|
||||||
state.tableData.data = res.records;
|
state.tableData.data = res.records;
|
||||||
state.tableData.total = res.total;
|
state.tableData.total = res.total;
|
||||||
})
|
})
|
||||||
}else {
|
} else {
|
||||||
getHotspot(state.tableData.param.pageNum,state.tableData.param.pageSize,{"disasterId_equal":state.disasterId,"isDeleted_equal":0}).then(res=>{
|
getHotspot(state.tableData.param.pageNum, state.tableData.param.pageSize, { "disasterId_equal": state.disasterId, "isDeleted_equal": 0 }).then(res => {
|
||||||
state.tableData.data = res.records;
|
state.tableData.data = res.records;
|
||||||
state.tableData.total = res.total;
|
state.tableData.total = res.total;
|
||||||
})
|
})
|
||||||
|
@ -290,7 +237,7 @@ const getTableData = () => {
|
||||||
};
|
};
|
||||||
// 打开上传弹窗
|
// 打开上传弹窗
|
||||||
const uploadData = () => {
|
const uploadData = () => {
|
||||||
if(state.disasterId == null){
|
if (state.disasterId == null) {
|
||||||
ElMessage.warning("Please select the disaster first")
|
ElMessage.warning("Please select the disaster first")
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -306,11 +253,11 @@ const editWordCloud = (row) => {
|
||||||
};
|
};
|
||||||
//批量删除词云或者热点数据
|
//批量删除词云或者热点数据
|
||||||
const batchDel = () => {
|
const batchDel = () => {
|
||||||
if(state.tabVal == 'first' && state.multipleWord.length == 0){
|
if (state.tabVal == 'first' && state.multipleWord.length == 0) {
|
||||||
ElMessage.warning("Select the data to be operated first");
|
ElMessage.warning("Select the data to be operated first");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if(state.tabVal == 'second' && state.multipleHotspot.length == 0){
|
if (state.tabVal == 'second' && state.multipleHotspot.length == 0) {
|
||||||
ElMessage.warning("Select the data to be operated first");
|
ElMessage.warning("Select the data to be operated first");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -319,24 +266,24 @@ const batchDel = () => {
|
||||||
cancelButtonText: 'cancel',
|
cancelButtonText: 'cancel',
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
if(state.tabVal == 'first'){
|
if (state.tabVal == 'first') {
|
||||||
//删除词云
|
//删除词云
|
||||||
let id = state.multipleWord.map(item=>item.id)
|
let id = state.multipleWord.map(item => item.id)
|
||||||
delData(id.join(),1).then(res=>{
|
delData(id.join(), 1).then(res => {
|
||||||
getTableData();
|
getTableData();
|
||||||
ElMessage.success('delete successfully');
|
ElMessage.success('delete successfully');
|
||||||
})
|
})
|
||||||
}else{
|
} else {
|
||||||
//删除热点
|
//删除热点
|
||||||
let id = state.multipleHotspot.map(item=>item.id)
|
let id = state.multipleHotspot.map(item => item.id)
|
||||||
delData(id.join(),2).then(res=>{
|
delData(id.join(), 2).then(res => {
|
||||||
getTableData();
|
getTableData();
|
||||||
ElMessage.success('delete successfully');
|
ElMessage.success('delete successfully');
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch(() => {});
|
.catch(() => { });
|
||||||
}
|
}
|
||||||
// 删除词云
|
// 删除词云
|
||||||
const delWordCloud = (row) => {
|
const delWordCloud = (row) => {
|
||||||
|
@ -345,13 +292,13 @@ const delWordCloud = (row) => {
|
||||||
cancelButtonText: 'cancel',
|
cancelButtonText: 'cancel',
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
delData(row.id,1).then(res=>{
|
delData(row.id, 1).then(res => {
|
||||||
getTableData();
|
getTableData();
|
||||||
ElMessage.success('delete successfully');
|
ElMessage.success('delete successfully');
|
||||||
})
|
|
||||||
})
|
})
|
||||||
.catch(() => {});
|
})
|
||||||
|
.catch(() => { });
|
||||||
};
|
};
|
||||||
|
|
||||||
// 删除热点
|
// 删除热点
|
||||||
|
@ -361,13 +308,13 @@ const delHotspot = (row) => {
|
||||||
cancelButtonText: 'cancel',
|
cancelButtonText: 'cancel',
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
delData(row.id,2).then(res=>{
|
delData(row.id, 2).then(res => {
|
||||||
getTableData();
|
getTableData();
|
||||||
ElMessage.success('delete successfully');
|
ElMessage.success('delete successfully');
|
||||||
})
|
|
||||||
})
|
})
|
||||||
.catch(() => {});
|
})
|
||||||
|
.catch(() => { });
|
||||||
};
|
};
|
||||||
// 分页改变
|
// 分页改变
|
||||||
const onHandleDisasterSizeChange = (val) => {
|
const onHandleDisasterSizeChange = (val) => {
|
||||||
|
@ -396,7 +343,7 @@ onMounted(() => {
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
<style>
|
<style>
|
||||||
.demo-tabs > .el-tabs__content {
|
.demo-tabs>.el-tabs__content {
|
||||||
padding: 32px;
|
padding: 32px;
|
||||||
color: #6b778c;
|
color: #6b778c;
|
||||||
font-size: 32px;
|
font-size: 32px;
|
||||||
|
@ -406,15 +353,21 @@ onMounted(() => {
|
||||||
.system-role-container {
|
.system-role-container {
|
||||||
.system-role-padding {
|
.system-role-padding {
|
||||||
padding: 15px;
|
padding: 15px;
|
||||||
|
|
||||||
.el-table {
|
.el-table {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.demo-tabs > .el-tabs__content {
|
|
||||||
padding: 32px;
|
.demo-tabs>.el-tabs__content {
|
||||||
|
padding: 10px;
|
||||||
color: #6b778c;
|
color: #6b778c;
|
||||||
font-size: 32px;
|
font-size: 32px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
}
|
}
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -90,12 +90,12 @@
|
||||||
@size-change="onHandleSizeChange"
|
@size-change="onHandleSizeChange"
|
||||||
@current-change="onHandleCurrentChange"
|
@current-change="onHandleCurrentChange"
|
||||||
class="mt15"
|
class="mt15"
|
||||||
:pager-count="5"
|
:pager-count="3"
|
||||||
:page-sizes="[10, 20, 30]"
|
:page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
v-model:current-page="state.tableData.param.pageNum"
|
||||||
background
|
background
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total"
|
:total="state.tableData.total"
|
||||||
>
|
>
|
||||||
</el-pagination> -->
|
</el-pagination> -->
|
||||||
|
|
|
@ -90,12 +90,12 @@
|
||||||
@size-change="onHandleSizeChange"
|
@size-change="onHandleSizeChange"
|
||||||
@current-change="onHandleCurrentChange"
|
@current-change="onHandleCurrentChange"
|
||||||
class="mt15"
|
class="mt15"
|
||||||
:pager-count="5"
|
:pager-count="3"
|
||||||
:page-sizes="[10, 20, 30]"
|
:page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
v-model:current-page="state.tableData.param.pageNum"
|
||||||
background
|
background
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total"
|
:total="state.tableData.total"
|
||||||
>
|
>
|
||||||
</el-pagination> -->
|
</el-pagination> -->
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item class="login-animation3" v-if="state.captchaMode">
|
<el-form-item class="login-animation3" v-if="state.captchaMode">
|
||||||
<el-col :span="15">
|
<el-col :span="15">
|
||||||
<el-input text maxlength="5" placeholder="Please input validate code" v-model="state.ruleForm.code" clearable autocomplete="off">
|
<el-input text maxlength="3" placeholder="Please input validate code" v-model="state.ruleForm.code" clearable autocomplete="off">
|
||||||
<template #prefix>
|
<template #prefix>
|
||||||
<el-icon class="el-input__icon"><ele-Position /></el-icon>
|
<el-icon class="el-input__icon"><ele-Position /></el-icon>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
@ -57,9 +57,9 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
||||||
:pager-count="5" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum"
|
:pager-count="3" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum"
|
||||||
background v-model:page-size="state.tableData.param.pageSize"
|
background v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper" :total="state.tableData.total">
|
layout="total, sizes, prev, pager, next" :total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</el-card>
|
</el-card>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
@ -217,3 +217,10 @@ onMounted(() => {
|
||||||
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
<style>
|
||||||
|
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
|
@ -12,9 +12,9 @@
|
||||||
<el-table-column prop="disasterTime" label="disaster time" show-overflow-tooltip></el-table-column>
|
<el-table-column prop="disasterTime" label="disaster time" show-overflow-tooltip></el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleDisasterSizeChange" @current-change="onHandleDisasterCurrentChange"
|
<el-pagination @size-change="onHandleDisasterSizeChange" @current-change="onHandleDisasterCurrentChange"
|
||||||
class="mt15" :pager-count="5" :page-sizes="[10, 20, 30]"
|
class="mt15" :pager-count="3" :page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.disasterData.param.pageNum" background
|
v-model:current-page="state.disasterData.param.pageNum" background
|
||||||
v-model:page-size="state.disasterData.param.pageSize" layout="total, sizes, prev, pager, next, jumper"
|
v-model:page-size="state.disasterData.param.pageSize" layout="total, sizes, prev, pager, next"
|
||||||
:total="state.disasterData.total">
|
:total="state.disasterData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</div>
|
</div>
|
||||||
|
@ -50,8 +50,8 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
||||||
:pager-count="5" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum" background
|
:pager-count="3" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum" background
|
||||||
v-model:page-size="state.tableData.param.pageSize" layout="total, sizes, prev, pager, next, jumper"
|
v-model:page-size="state.tableData.param.pageSize" layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</div>
|
</div>
|
||||||
|
@ -241,4 +241,8 @@ onMounted(() => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -62,10 +62,10 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange"
|
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange"
|
||||||
class="mt15" :pager-count="5" :page-sizes="[10, 20, 30]"
|
class="mt15" :pager-count="3" :page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.tableData.param.pageNum" background
|
v-model:current-page="state.tableData.param.pageNum" background
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper" :total="state.tableData.total">
|
layout="total, sizes, prev, pager, next" :total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</el-card>
|
</el-card>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
@ -171,3 +171,10 @@ onMounted(() => {
|
||||||
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
<style>
|
||||||
|
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -18,9 +18,9 @@
|
||||||
<el-table-column prop="email" label="E-mail" show-overflow-tooltip></el-table-column>
|
<el-table-column prop="email" label="E-mail" show-overflow-tooltip></el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
||||||
:pager-count="5" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum"
|
:pager-count="3" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum"
|
||||||
background v-model:page-size="state.tableData.param.pageSize"
|
background v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper" :total="state.tableData.total">
|
layout="total, sizes, prev, pager, next" :total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</el-card>
|
</el-card>
|
||||||
<template #footer>
|
<template #footer>
|
||||||
|
@ -131,3 +131,9 @@ defineExpose({
|
||||||
openDialog,
|
openDialog,
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
<style>
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
</style>
|
|
@ -1,45 +1,46 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="system-role-container layout-padding">
|
<div class="system-role-container layout-padding">
|
||||||
<el-config-provider :locale="en">
|
<el-config-provider :locale="en">
|
||||||
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
<div class="system-role-padding layout-padding-auto layout-padding-view">
|
||||||
<el-tabs v-model="activeName" class="demo-tabs" @tab-click="handleClick" style="margin-left: 20px">
|
<el-tabs v-model="activeName" class="demo-tabs" @tab-click="handleClick" style="margin-left: 20px">
|
||||||
<el-tab-pane label="unchecked" name="first">
|
<el-tab-pane label="unchecked" name="first">
|
||||||
<el-table :data="state.tableData.data" v-loading="state.tableData.loading" style="width: 100%">
|
<el-table :data="state.tableData.data" v-loading="state.tableData.loading" style="width: 100%">
|
||||||
<el-table-column type="index" label="ID" width="50" />
|
<el-table-column type="index" label="ID" width="50" />
|
||||||
<el-table-column prop="username" label="User name" show-overflow-tooltip></el-table-column>
|
<el-table-column prop="username" label="User name" show-overflow-tooltip></el-table-column>
|
||||||
<el-table-column prop="organization" label="Organization" show-overflow-tooltip></el-table-column>
|
<el-table-column prop="organization" label="Organization" show-overflow-tooltip></el-table-column>
|
||||||
<el-table-column prop="disasterType" label="Disaster type" show-overflow-tooltip>
|
<el-table-column prop="disasterType" label="Disaster type" show-overflow-tooltip>
|
||||||
<!-- 在disasterType中获取dictKey 对应的dictValue -->
|
<!-- 在disasterType中获取dictKey 对应的dictValue -->
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-tag type="info">{{ getValue(scope.row.disasterType) }}</el-tag>
|
<el-tag type="info">{{ getValue(scope.row.disasterType) }}</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="disasterKeyword" label="Disaster keyword" show-overflow-tooltip></el-table-column>
|
<el-table-column prop="disasterKeyword" label="Disaster keyword" show-overflow-tooltip></el-table-column>
|
||||||
<!-- <el-table-column prop="affectedCountry" label="Affected country" show-overflow-tooltip></el-table-column> -->
|
<!-- <el-table-column prop="affectedCountry" label="Affected country" show-overflow-tooltip></el-table-column> -->
|
||||||
<!-- <el-table-column prop="Longitude" label="Longitude" show-overflow-tooltip></el-table-column>
|
<!-- <el-table-column prop="Longitude" label="Longitude" show-overflow-tooltip></el-table-column>
|
||||||
<el-table-column prop="Latitude" label="Latitude" show-overflow-tooltip></el-table-column> -->
|
<el-table-column prop="Latitude" label="Latitude" show-overflow-tooltip></el-table-column> -->
|
||||||
<el-table-column prop="disasterTime" label="Disaster time" show-overflow-tooltip>
|
<el-table-column prop="disasterTime" label="Disaster time" show-overflow-tooltip>
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<!-- 格式化去除时分秒 -->
|
<!-- 格式化去除时分秒 -->
|
||||||
{{ dateFormat(scope.row.disasterTime) }}
|
{{ dateFormat(scope.row.disasterTime) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- <el-table-column prop="responseTime" label="Response time" show-overflow-tooltip></el-table-column> -->
|
<!-- <el-table-column prop="responseTime" label="Response time" show-overflow-tooltip></el-table-column> -->
|
||||||
<el-table-column prop="respondStatus" label="Response status" show-overflow-tooltip>
|
<el-table-column prop="respondStatus" label="Response status" show-overflow-tooltip>
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-tag type="info" v-if="scope.row.respondStatus === 0">Not reviewed</el-tag>
|
<el-tag type="info" v-if="scope.row.respondStatus === 0">Not reviewed</el-tag>
|
||||||
<el-tag type="info" v-if="scope.row.respondStatus === 1">Failed</el-tag>
|
<el-tag type="info" v-if="scope.row.respondStatus === 1">Failed</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="Operate" label="Operate" show-overflow-tooltip>
|
<el-table-column prop="Operate" label="Operate" show-overflow-tooltip>
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button size="small" text type="primary" @click="onOpenEditRole('edit', scope.row)">Review</el-button>
|
<el-button size="small" text type="primary"
|
||||||
</template>
|
@click="onOpenEditRole('edit', scope.row)">Review</el-button>
|
||||||
</el-table-column>
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
<!-- <el-table-column prop="describe" label="角色描述" show-overflow-tooltip></el-table-column>
|
<!-- <el-table-column prop="describe" label="角色描述" show-overflow-tooltip></el-table-column>
|
||||||
<el-table-column prop="createTime" label="创建时间" show-overflow-tooltip></el-table-column> -->
|
<el-table-column prop="createTime" label="创建时间" show-overflow-tooltip></el-table-column> -->
|
||||||
<!-- <el-table-column prop="status" label="角色状态" show-overflow-tooltip>
|
<!-- <el-table-column prop="status" label="角色状态" show-overflow-tooltip>
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-tag type="success" v-if="scope.row.status">启用</el-tag>
|
<el-tag type="success" v-if="scope.row.status">启用</el-tag>
|
||||||
<el-tag type="info" v-else>禁用</el-tag>
|
<el-tag type="info" v-else>禁用</el-tag>
|
||||||
|
@ -55,96 +56,96 @@
|
||||||
>
|
>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column> -->
|
</el-table-column> -->
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
||||||
:pager-count="5" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.current" background
|
:pager-count="3" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.current" background
|
||||||
v-model:page-size="state.tableData.param.size" layout="total, sizes, prev, pager, next, jumper"
|
v-model:page-size="state.tableData.param.size" layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
<el-tab-pane label="checked" name="second">
|
<el-tab-pane label="checked" name="second">
|
||||||
<el-table :data="state.tableData.data" v-loading="state.tableData.loading" style="width: 100%">
|
<el-table :data="state.tableData.data" v-loading="state.tableData.loading" style="width: 100%">
|
||||||
<el-table-column type="index" label="ID" width="50" />
|
<el-table-column type="index" label="ID" width="50" />
|
||||||
<el-table-column prop="username" label="User name" show-overflow-tooltip></el-table-column>
|
<el-table-column prop="username" label="User name" show-overflow-tooltip></el-table-column>
|
||||||
<!-- <el-table-column prop="Administrator" label="Administrator" show-overflow-tooltip></el-table-column> -->
|
<!-- <el-table-column prop="Administrator" label="Administrator" show-overflow-tooltip></el-table-column> -->
|
||||||
<el-table-column prop="organization" label="Organization" show-overflow-tooltip></el-table-column>
|
<el-table-column prop="organization" label="Organization" show-overflow-tooltip></el-table-column>
|
||||||
<el-table-column prop="email" label="Email" show-overflow-tooltip></el-table-column>
|
<el-table-column prop="email" label="Email" show-overflow-tooltip></el-table-column>
|
||||||
<el-table-column prop="disasterType" label="Disaster type" show-overflow-tooltip>
|
<el-table-column prop="disasterType" label="Disaster type" show-overflow-tooltip>
|
||||||
<!-- 在disasterType中获取dictKey 对应的dictValue -->
|
<!-- 在disasterType中获取dictKey 对应的dictValue -->
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-tag type="info">{{ getValue(scope.row.disasterType) }}</el-tag>
|
<el-tag type="info">{{ getValue(scope.row.disasterType) }}</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="disasterKeyword" label="Disaster keyword" show-overflow-tooltip></el-table-column>
|
<el-table-column prop="disasterKeyword" label="Disaster keyword" show-overflow-tooltip></el-table-column>
|
||||||
<!-- <el-table-column prop="Affected country" label="Affected country" show-overflow-tooltip></el-table-column> -->
|
<!-- <el-table-column prop="Affected country" label="Affected country" show-overflow-tooltip></el-table-column> -->
|
||||||
<!-- <el-table-column prop="Longitude" label="Longitude" show-overflow-tooltip></el-table-column>
|
<!-- <el-table-column prop="Longitude" label="Longitude" show-overflow-tooltip></el-table-column>
|
||||||
<el-table-column prop="Latitude" label="Latitude" show-overflow-tooltip></el-table-column> -->
|
<el-table-column prop="Latitude" label="Latitude" show-overflow-tooltip></el-table-column> -->
|
||||||
<el-table-column prop="disasterTime" label="Disaster time" show-overflow-tooltip>
|
<el-table-column prop="disasterTime" label="Disaster time" show-overflow-tooltip>
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<!-- 格式化去除时分秒 -->
|
<!-- 格式化去除时分秒 -->
|
||||||
{{ dateFormat(scope.row.disasterTime) }}
|
{{ dateFormat(scope.row.disasterTime) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- <el-table-column prop="responseTime" label="Response time" show-overflow-tooltip></el-table-column> -->
|
<!-- <el-table-column prop="responseTime" label="Response time" show-overflow-tooltip></el-table-column> -->
|
||||||
<!-- <el-table-column prop="Operate" label="Operate" show-overflow-tooltip></el-table-column> -->
|
<!-- <el-table-column prop="Operate" label="Operate" show-overflow-tooltip></el-table-column> -->
|
||||||
<el-table-column prop="respondStatus" label="Response status" show-overflow-tooltip>
|
<el-table-column prop="respondStatus" label="Response status" show-overflow-tooltip>
|
||||||
|
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-tag type="info" v-if="scope.row.respondStatus === 2">Reviewed</el-tag>
|
<el-tag type="info" v-if="scope.row.respondStatus === 2">Reviewed</el-tag>
|
||||||
<el-tag type="info" v-if="scope.row.respondStatus === 1">Failed</el-tag>
|
<el-tag type="info" v-if="scope.row.respondStatus === 1">Failed</el-tag>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
||||||
:pager-count="5" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.current" background
|
:pager-count="3" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.current" background
|
||||||
v-model:page-size="state.tableData.param.size" layout="total, sizes, prev, pager, next, jumper"
|
v-model:page-size="state.tableData.param.size" layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
</el-tabs>
|
</el-tabs>
|
||||||
</div>
|
</div>
|
||||||
<el-dialog v-model="state.dialogVisible" title="Review" width="30%" :before-close="handleClose">
|
<el-dialog v-model="state.dialogVisible" title="Review" width="30%" :before-close="handleClose">
|
||||||
<el-container style="margin-top: -2%;margin-bottom: 2%;">
|
<el-container style="margin-top: -2%;margin-bottom: 2%;">
|
||||||
<el-radio v-model="state.radio" label='1' @click="mapEvents('1')">Point</el-radio>
|
<el-radio v-model="state.radio" label='1' @click="mapEvents('1')">Point</el-radio>
|
||||||
<el-radio v-model="state.radio" label='2' @click="mapEvents('2')">Area</el-radio>
|
<el-radio v-model="state.radio" label='2' @click="mapEvents('2')">Area</el-radio>
|
||||||
<el-button type="primary" style="margin-left: 5%;" @click="ClearSubmit">Clear</el-button>
|
<el-button type="primary" style="margin-left: 5%;" @click="ClearSubmit">Clear</el-button>
|
||||||
</el-container>
|
</el-container>
|
||||||
<el-container style="margin-top: 2%;margin-bottom: 2%;" v-if="state.radio==='1'?true:false">
|
<el-container style="margin-top: 2%;margin-bottom: 2%;" v-if="state.radio === '1' ? true : false">
|
||||||
<span style="line-height: 35px;"> Latitude:</span>
|
<span style="line-height: 35px;"> Latitude:</span>
|
||||||
<el-input placeholder="请输入内容" style="height:35px;margin-right: 1%;" v-model="state.dislat"></el-input>
|
<el-input placeholder="请输入内容" style="height:35px;margin-right: 1%;" v-model="state.dislat"></el-input>
|
||||||
<span style="line-height: 35px;">Longitude:</span>
|
<span style="line-height: 35px;">Longitude:</span>
|
||||||
<el-input placeholder="请输入内容" style="height:35px;" ></el-input>
|
<el-input placeholder="请输入内容" style="height:35px;"></el-input>
|
||||||
</el-container>
|
</el-container>
|
||||||
|
|
||||||
<Map style="height:350px ; width:100% ;margin-bottom: 10px;" ref="map"></Map>
|
<Map style="height:350px ; width:100% ;margin-bottom: 10px;" ref="map"></Map>
|
||||||
|
|
||||||
<MapPage style="height:350px ; width:100% ;margin-bottom: 10px;" ref="mapRef"></MapPage>
|
<MapPage style="height:350px ; width:100% ;margin-bottom: 10px;" ref="mapRef"></MapPage>
|
||||||
|
|
||||||
<el-form-item label="Disaster Time">
|
<el-form-item label="Disaster Time">
|
||||||
<el-date-picker v-model="state.edit.disasterTime" type="date" value-format="YYYY-MM-DD"
|
<el-date-picker v-model="state.edit.disasterTime" type="date" value-format="YYYY-MM-DD"
|
||||||
placeholder="Select date and time" />
|
placeholder="Select date and time" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<template #footer>
|
<template #footer>
|
||||||
<span class="dialog-footer">
|
<span class="dialog-footer">
|
||||||
<el-button @click="dialogVisible = false">Cancel</el-button>
|
<el-button @click="dialogVisible = false">Cancel</el-button>
|
||||||
<el-button type="danger" @click="reviews(1)">
|
<el-button type="danger" @click="reviews(1)">
|
||||||
Not Review
|
Not Review
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button type="primary" @click="reviews(2)">
|
<el-button type="primary" @click="reviews(2)">
|
||||||
Review
|
Review
|
||||||
</el-button>
|
</el-button>
|
||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</el-config-provider>
|
</el-config-provider>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup name="userResponse">
|
<script setup name="userResponse">
|
||||||
import en from 'element-plus/dist/locale/en.mjs'
|
import en from 'element-plus/dist/locale/en.mjs'
|
||||||
import { reactive, onMounted, ref, nextTick,watchEffect,defineAsyncComponent } from 'vue';
|
import { reactive, onMounted, ref, nextTick, watchEffect, defineAsyncComponent } from 'vue';
|
||||||
import { ElMessageBox, ElMessage } from 'element-plus';
|
import { ElMessageBox, ElMessage } from 'element-plus';
|
||||||
import { getList, review } from '/@/api/disasterInfo/index';
|
import { getList, review } from '/@/api/disasterInfo/index';
|
||||||
import { getDictionary } from '/@/api/system/dictbiz';
|
import { getDictionary } from '/@/api/system/dictbiz';
|
||||||
|
@ -165,7 +166,7 @@ const handleClick = (tab, event) => {
|
||||||
getTableData();
|
getTableData();
|
||||||
};
|
};
|
||||||
const MapPage = defineAsyncComponent({
|
const MapPage = defineAsyncComponent({
|
||||||
loader:() =>import('/@/components/Map.vue'),
|
loader: () => import('/@/components/Map.vue'),
|
||||||
delay: 200,
|
delay: 200,
|
||||||
})
|
})
|
||||||
const onAllocation = (row) => {
|
const onAllocation = (row) => {
|
||||||
|
@ -192,9 +193,9 @@ const state = reactive({
|
||||||
disasterTypeList: [],
|
disasterTypeList: [],
|
||||||
selectName: 'first',
|
selectName: 'first',
|
||||||
edit: {},
|
edit: {},
|
||||||
radio:null,
|
radio: null,
|
||||||
dislat:'',
|
dislat: '',
|
||||||
dislon:''
|
dislon: ''
|
||||||
});
|
});
|
||||||
// 初始化表格数据
|
// 初始化表格数据
|
||||||
const getTableData = () => {
|
const getTableData = () => {
|
||||||
|
@ -227,29 +228,29 @@ const onOpenEditRole = (type, row) => {
|
||||||
});
|
});
|
||||||
state.dialogVisible = true;
|
state.dialogVisible = true;
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
state.radio = "1"
|
state.radio = "1"
|
||||||
// mapRef.value.mapOperations.removeAll()
|
// mapRef.value.mapOperations.removeAll()
|
||||||
//赋值地图范围,并且可以修改点或者区域
|
//赋值地图范围,并且可以修改点或者区域
|
||||||
if(state.wktPoint){
|
if (state.wktPoint) {
|
||||||
mapRef.value.mapOperations.removeLayer(state.wktPoint)
|
mapRef.value.mapOperations.removeLayer(state.wktPoint)
|
||||||
}
|
}
|
||||||
state.wktPoint= mapRef.value.mapOperations.wktParseToMap(row.geometry)
|
state.wktPoint = mapRef.value.mapOperations.wktParseToMap(row.geometry)
|
||||||
// mapRef.value.mapOperations.on("click", (res)=>{
|
// mapRef.value.mapOperations.on("click", (res)=>{
|
||||||
// mapRef.value.mapOperations.clearPolygon()
|
// mapRef.value.mapOperations.clearPolygon()
|
||||||
// mapRef.value.mapOperations.removeLayer( state.wktPoint)
|
// mapRef.value.mapOperations.removeLayer( state.wktPoint)
|
||||||
// mapRef.value.mapOperations.addInteractMarker(res.latlng.lat, res.latlng.lng)
|
// mapRef.value.mapOperations.addInteractMarker(res.latlng.lat, res.latlng.lng)
|
||||||
// })
|
// })
|
||||||
mapEvents('1')
|
mapEvents('1')
|
||||||
},100);
|
}, 100);
|
||||||
};
|
};
|
||||||
const mapEvents = (ev)=>{
|
const mapEvents = (ev) => {
|
||||||
if(ev == '1'){
|
if (ev == '1') {
|
||||||
mapRef.value.mapOperations.clearPolygon()
|
mapRef.value.mapOperations.clearPolygon()
|
||||||
// mapRef.value.mapOperations.on("click", mapClick)
|
// mapRef.value.mapOperations.on("click", mapClick)
|
||||||
mapRef.value.mapOperations.on("mousemove", changelatlon)
|
mapRef.value.mapOperations.on("mousemove", changelatlon)
|
||||||
variableStore.polygoncontrol = "option1"
|
variableStore.polygoncontrol = "option1"
|
||||||
}else{
|
} else {
|
||||||
mapRef.value.mapOperations.off("click",mapClick);
|
mapRef.value.mapOperations.off("click", mapClick);
|
||||||
// mapRef.value.mapOperations.drawPolygon()
|
// mapRef.value.mapOperations.drawPolygon()
|
||||||
// mapRef.value.mapOperations.drawCreated()
|
// mapRef.value.mapOperations.drawCreated()
|
||||||
variableStore.polygoncontrol = "option2"
|
variableStore.polygoncontrol = "option2"
|
||||||
|
@ -261,10 +262,10 @@ const ClearSubmit = () => {
|
||||||
variableStore.wktdata = null
|
variableStore.wktdata = null
|
||||||
}, 100)
|
}, 100)
|
||||||
}
|
}
|
||||||
const mapClick=(res)=>{
|
const mapClick = (res) => {
|
||||||
mapRef.value.mapOperations.removeLayer( state.wktPoint)
|
mapRef.value.mapOperations.removeLayer(state.wktPoint)
|
||||||
changelatlon(res);
|
changelatlon(res);
|
||||||
mapRef.value.mapOperations.addInteractMarker(res.latlng.lat.toFixed(3),res.latlng.lng.toFixed(3))
|
mapRef.value.mapOperations.addInteractMarker(res.latlng.lat.toFixed(3), res.latlng.lng.toFixed(3))
|
||||||
}
|
}
|
||||||
|
|
||||||
const reviews = (index) => {
|
const reviews = (index) => {
|
||||||
|
@ -299,46 +300,46 @@ const onMapClick = (e) => {
|
||||||
}
|
}
|
||||||
const changelatlon = (e) => {
|
const changelatlon = (e) => {
|
||||||
|
|
||||||
state.dislat = e.latlng.lat.toFixed(3);
|
state.dislat = e.latlng.lat.toFixed(3);
|
||||||
state.dislon = e.latlng.lng.toFixed(3);
|
state.dislon = e.latlng.lng.toFixed(3);
|
||||||
// state.lon = state.lon % 360;
|
// state.lon = state.lon % 360;
|
||||||
// if (state.lon < 0) {
|
// if (state.lon < 0) {
|
||||||
// state.lon = state.lon + 360;
|
// state.lon = state.lon + 360;
|
||||||
// }
|
// }
|
||||||
// state.lon = state.lon.toFixed(3);
|
// state.lon = state.lon.toFixed(3);
|
||||||
if (state.dislat < 0) {
|
if (state.dislat < 0) {
|
||||||
state.dislat = String(Math.abs(state.dislat)) + "°S"
|
state.dislat = String(Math.abs(state.dislat)) + "°S"
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
state.dislat = String(state.dislat) + "°N"
|
state.dislat = String(state.dislat) + "°N"
|
||||||
}
|
}
|
||||||
|
|
||||||
if (state.dislon <= 180 && state.dislon >= 0) {
|
|
||||||
state.dislon = String(Math.abs(state.dislon)) + "°E"
|
|
||||||
}
|
|
||||||
else if (state.dislon > 180 && state.dislon <= 360) {
|
|
||||||
state.dislon = String((360 - state.dislon).toFixed(3)) + "°W"
|
|
||||||
}
|
|
||||||
else if (state.dislon < 0) {
|
|
||||||
let n = Math.floor(state.dislon / 360)
|
|
||||||
state.dislon = (state.dislon - n * 360).toFixed(3)
|
|
||||||
if (state.dislon <= 180 && state.dislon >= 0) {
|
if (state.dislon <= 180 && state.dislon >= 0) {
|
||||||
state.dislon = String(Math.abs(state.dislon)) + "°E"
|
state.dislon = String(Math.abs(state.dislon)) + "°E"
|
||||||
}
|
}
|
||||||
else if (state.dislon > 180 && state.dislon <= 360) {
|
else if (state.dislon > 180 && state.dislon <= 360) {
|
||||||
state.dislon = String((360 - state.dislon).toFixed(3)) + "°W"
|
state.dislon = String((360 - state.dislon).toFixed(3)) + "°W"
|
||||||
}
|
}
|
||||||
}
|
else if (state.dislon < 0) {
|
||||||
else if (state.dislon > 360) {
|
let n = Math.floor(state.dislon / 360)
|
||||||
let n = Math.floor(state.dislon / 360)
|
state.dislon = (state.dislon - n * 360).toFixed(3)
|
||||||
state.dislon = (state.dislon - n * 360).toFixed(3)
|
if (state.dislon <= 180 && state.dislon >= 0) {
|
||||||
if (state.dislon <= 180 && state.dislon >= 0) {
|
state.dislon = String(Math.abs(state.dislon)) + "°E"
|
||||||
state.dislon = String(Math.abs(state.dislon)) + "°E"
|
}
|
||||||
|
else if (state.dislon > 180 && state.dislon <= 360) {
|
||||||
|
state.dislon = String((360 - state.dislon).toFixed(3)) + "°W"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (state.dislon > 180 && state.dislon <= 360) {
|
else if (state.dislon > 360) {
|
||||||
state.dislon = String((360 - state.dislon).toFixed(3)) + "°W"
|
let n = Math.floor(state.dislon / 360)
|
||||||
|
state.dislon = (state.dislon - n * 360).toFixed(3)
|
||||||
|
if (state.dislon <= 180 && state.dislon >= 0) {
|
||||||
|
state.dislon = String(Math.abs(state.dislon)) + "°E"
|
||||||
|
}
|
||||||
|
else if (state.dislon > 180 && state.dislon <= 360) {
|
||||||
|
state.dislon = String((360 - state.dislon).toFixed(3)) + "°W"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
// 页面加载时
|
// 页面加载时
|
||||||
|
@ -348,7 +349,7 @@ onMounted(() => {
|
||||||
state.disasterTypeList = res;
|
state.disasterTypeList = res;
|
||||||
});
|
});
|
||||||
watchEffect(() => {
|
watchEffect(() => {
|
||||||
if (state.radio== "1") {
|
if (state.radio == "1") {
|
||||||
// map.value.mapOperations.on("click", onMapClick)
|
// map.value.mapOperations.on("click", onMapClick)
|
||||||
// map.value.mapOperations.clearPolygon()
|
// map.value.mapOperations.clearPolygon()
|
||||||
// map.value.mapOperations.on("mousemove", changelatlon)
|
// map.value.mapOperations.on("mousemove", changelatlon)
|
||||||
|
@ -384,4 +385,8 @@ const getValue = (key) => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -38,12 +38,12 @@
|
||||||
@size-change="onHandleSizeChange"
|
@size-change="onHandleSizeChange"
|
||||||
@current-change="onHandleCurrentChange"
|
@current-change="onHandleCurrentChange"
|
||||||
class="mt15"
|
class="mt15"
|
||||||
:pager-count="5"
|
:pager-count="3"
|
||||||
:page-sizes="[10, 20, 30]"
|
:page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
v-model:current-page="state.tableData.param.pageNum"
|
||||||
background
|
background
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total"
|
:total="state.tableData.total"
|
||||||
>
|
>
|
||||||
</el-pagination> -->
|
</el-pagination> -->
|
||||||
|
|
|
@ -74,12 +74,12 @@
|
||||||
<el-pagination @size-change="onHandleSizeChange"
|
<el-pagination @size-change="onHandleSizeChange"
|
||||||
@current-change="onHandleCurrentChange"
|
@current-change="onHandleCurrentChange"
|
||||||
class="mt15"
|
class="mt15"
|
||||||
:pager-count="5"
|
:pager-count="3"
|
||||||
:page-sizes="[10, 20, 30]"
|
:page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
v-model:current-page="state.tableData.param.pageNum"
|
||||||
background
|
background
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</div>
|
</div>
|
||||||
|
@ -175,4 +175,8 @@ onMounted(() => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -42,8 +42,8 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
<el-pagination @size-change="onHandleSizeChange" @current-change="onHandleCurrentChange" class="mt15"
|
||||||
:pager-count="5" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum" background
|
:pager-count="3" :page-sizes="[10, 20, 30]" v-model:current-page="state.tableData.param.pageNum" background
|
||||||
v-model:page-size="state.tableData.param.pageSize" layout="total, sizes, prev, pager, next, jumper"
|
v-model:page-size="state.tableData.param.pageSize" layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</el-card>
|
</el-card>
|
||||||
|
@ -148,4 +148,8 @@ onMounted(() => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -59,12 +59,12 @@
|
||||||
<el-pagination @size-change="onHandleSizeChange"
|
<el-pagination @size-change="onHandleSizeChange"
|
||||||
@current-change="onHandleCurrentChange"
|
@current-change="onHandleCurrentChange"
|
||||||
class="mt15"
|
class="mt15"
|
||||||
:pager-count="5"
|
:pager-count="3"
|
||||||
:page-sizes="[10, 20, 30]"
|
:page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
v-model:current-page="state.tableData.param.pageNum"
|
||||||
background
|
background
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</el-config-provider>
|
</el-config-provider>
|
||||||
|
@ -201,4 +201,8 @@ onMounted(() => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -22,12 +22,12 @@
|
||||||
<el-pagination @size-change="onHandleSizeChange"
|
<el-pagination @size-change="onHandleSizeChange"
|
||||||
@current-change="onHandleCurrentChange"
|
@current-change="onHandleCurrentChange"
|
||||||
class="mt15"
|
class="mt15"
|
||||||
:pager-count="5"
|
:pager-count="3"
|
||||||
:page-sizes="[10, 20, 30]"
|
:page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
v-model:current-page="state.tableData.param.pageNum"
|
||||||
background
|
background
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</el-config-provider>
|
</el-config-provider>
|
||||||
|
@ -125,5 +125,8 @@ defineExpose({
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
|
@ -44,12 +44,12 @@
|
||||||
<el-pagination @size-change="onHandleSizeChange"
|
<el-pagination @size-change="onHandleSizeChange"
|
||||||
@current-change="onHandleCurrentChange"
|
@current-change="onHandleCurrentChange"
|
||||||
class="mt15"
|
class="mt15"
|
||||||
:pager-count="5"
|
:pager-count="3"
|
||||||
:page-sizes="[10, 20, 30]"
|
:page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
v-model:current-page="state.tableData.param.pageNum"
|
||||||
background
|
background
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
<DisasterInfo ref="disasterInfoRef" @callback="getTableData"/>
|
<DisasterInfo ref="disasterInfoRef" @callback="getTableData"/>
|
||||||
|
@ -154,5 +154,8 @@ defineExpose({
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
|
@ -60,12 +60,12 @@
|
||||||
<el-pagination @size-change="onHandleSizeChange"
|
<el-pagination @size-change="onHandleSizeChange"
|
||||||
@current-change="onHandleCurrentChange"
|
@current-change="onHandleCurrentChange"
|
||||||
class="mt15"
|
class="mt15"
|
||||||
:pager-count="5"
|
:pager-count="3"
|
||||||
:page-sizes="[10, 20, 30]"
|
:page-sizes="[10, 20, 30]"
|
||||||
v-model:current-page="state.tableData.param.pageNum"
|
v-model:current-page="state.tableData.param.pageNum"
|
||||||
background
|
background
|
||||||
v-model:page-size="state.tableData.param.pageSize"
|
v-model:page-size="state.tableData.param.pageSize"
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
layout="total, sizes, prev, pager, next"
|
||||||
:total="state.tableData.total">
|
:total="state.tableData.total">
|
||||||
</el-pagination>
|
</el-pagination>
|
||||||
</el-config-provider>
|
</el-config-provider>
|
||||||
|
@ -234,4 +234,8 @@ onMounted(() => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.mt15 {
|
||||||
|
float: right;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
Loading…
Reference in New Issue