|
@@ -1,7 +1,28 @@
|
|
|
<template>
|
|
|
<div>
|
|
|
<el-header>
|
|
|
- <el-button type="primary" icon="el-icon-circle-plus-outline" @click="addBlockServerDialogVisible = true">新增</el-button>
|
|
|
+ <el-header>
|
|
|
+ <el-form inline label-position="right" label-width="60px">
|
|
|
+ <el-form-item label="业务线:">
|
|
|
+ <el-select v-model="searchForm.lineId" filterable placeholder="请选择业务线">
|
|
|
+ <el-option
|
|
|
+ v-for="item in businessLines"
|
|
|
+ :key="item.lineId"
|
|
|
+ :label="item.lineName"
|
|
|
+ :value="item.lineId"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="服务名:">
|
|
|
+ <el-input v-model="searchForm.serverName" />
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item>
|
|
|
+ <el-button type="primary" icon="el-icon-search" @click="getNsServerCheckClick">查询</el-button>
|
|
|
+ <el-button type="primary" icon="el-icon-refresh" @click="reset">重置</el-button>
|
|
|
+ <el-button type="primary" icon="el-icon-circle-plus-outline" @click="addBlockServerDialogVisible = true">新增</el-button>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ </el-header>
|
|
|
</el-header>
|
|
|
<el-table
|
|
|
:data="tableData"
|
|
@@ -65,8 +86,8 @@
|
|
|
<el-pagination
|
|
|
background
|
|
|
layout="total, sizes, ->, prev, pager, next, jumper"
|
|
|
- :current-page="currentPage"
|
|
|
- :page-size="pageSize"
|
|
|
+ :current-page="searchForm.pageNum"
|
|
|
+ :page-size="searchForm.pageSize"
|
|
|
:page-sizes="[10,30,50,total]"
|
|
|
:total="total"
|
|
|
@size-change="handleSizeChange"
|
|
@@ -92,8 +113,12 @@ export default {
|
|
|
tableData: null,
|
|
|
blockServer: null,
|
|
|
total: 0,
|
|
|
- pageSize: 10,
|
|
|
- currentPage: 1,
|
|
|
+ searchForm: {
|
|
|
+ lineId: null,
|
|
|
+ serverName: null,
|
|
|
+ pageSize: 10,
|
|
|
+ pageNum: 1
|
|
|
+ },
|
|
|
businessLines: [{
|
|
|
lineName: '代驾',
|
|
|
lineId: 1
|
|
@@ -125,7 +150,7 @@ export default {
|
|
|
return date.substring(0, 10) + ' ' + date.substring(11, 19)
|
|
|
},
|
|
|
getNsServerCheckClick() {
|
|
|
- getNsServerCheck({ 'pageNum': this.currentPage, 'pageSize': this.pageSize })
|
|
|
+ getNsServerCheck(this.searchForm)
|
|
|
.then(res => {
|
|
|
this.tableData = res.data.list
|
|
|
this.total = res.data.number
|
|
@@ -153,11 +178,17 @@ export default {
|
|
|
})
|
|
|
},
|
|
|
handleSizeChange: function(pageSize) {
|
|
|
- this.pageSize = pageSize
|
|
|
+ this.searchForm.pageSize = pageSize
|
|
|
this.getNsServerCheckClick()
|
|
|
},
|
|
|
- handleCurrentChange: function(currentPage) {
|
|
|
- this.currentPage = currentPage
|
|
|
+ handleCurrentChange: function(pageNum) {
|
|
|
+ this.searchForm.pageNum = pageNum
|
|
|
+ this.getNsServerCheckClick()
|
|
|
+ },
|
|
|
+ reset() {
|
|
|
+ this.searchForm.lineId = null
|
|
|
+ this.searchForm.serverName = null
|
|
|
+ this.searchForm.pageNum = 1
|
|
|
this.getNsServerCheckClick()
|
|
|
}
|
|
|
}
|