Authored by xwx

Merge branch 'master' of http://113.200.75.45:82/monitor_v3/hg-monitor-web into master-v32-xwx

@@ -1103,6 +1103,12 @@ layui.define(['xmSelect', 'md5'], function (exports) { @@ -1103,6 +1103,12 @@ layui.define(['xmSelect', 'md5'], function (exports) {
1103 1103
1104 /**检查权限*/ 1104 /**检查权限*/
1105 checkPermission:function(access_token) { 1105 checkPermission:function(access_token) {
  1106 + // Start Wang 2021/12/13 19:42 权限列表,如果能从缓存中加载到数据,则获取缓存中的数据
  1107 + var ps = sessionStorage.getItem('permissions');
  1108 + if(ps && ps != '' && ps != null){
  1109 + return ps.split(',');
  1110 + }
  1111 + // End Wang 2021/12/13 19:43 权限列表,如果能从缓存中加载到数据,则获取缓存中的数据
1106 var pers = []; 1112 var pers = [];
1107 $.ajax({ 1113 $.ajax({
1108 type : 'get', 1114 type : 'get',
@@ -3,41 +3,71 @@ @@ -3,41 +3,71 @@
3 @import "../css/components.css"; 3 @import "../css/components.css";
4 4
5 /*最外层样式*/ 5 /*最外层样式*/
6 -.container{ 6 +.container {
7 background-color: #CCCCCC; 7 background-color: #CCCCCC;
8 padding: 3px 3px; 8 padding: 3px 3px;
9 - width:calc(100% - 10px); 9 + width: calc(100% - 10px);
10 } 10 }
11 11
12 -.container .cm-card{  
13 - overflow-y:auto; 12 +.container .cm-card {
  13 + overflow-y: auto;
14 background: white; 14 background: white;
15 border-radius: 3px 15 border-radius: 3px
16 } 16 }
17 17
  18 +.container .cm-card .search {
  19 + padding: 3px 10px;
  20 + display: flex;
  21 +}
  22 +
  23 +.container .cm-card .search .condition {
  24 + width: calc(100% - 200px);
  25 + display: flex;
  26 + flex-wrap: wrap;
  27 +}
  28 +
  29 +.container .cm-card .search .condition div{
  30 + margin-right: 2px!important;
  31 + margin-bottom: 3px!important;
  32 + width: 250px!important;
  33 +}
  34 +
  35 +.container .cm-card .search .btns {
  36 + width: 200px;
  37 + display: flex;
  38 + padding-left: 10px;
  39 + justify-content: center;
  40 + align-items:center;
  41 +}
  42 +
  43 +.container .cm-card .search-table{
  44 + padding: 0px 6px;
  45 +}
  46 +
18 /* 47 /*
19 共通弹框配置样式 48 共通弹框配置样式
20 custom-class="config-dialog" 49 custom-class="config-dialog"
21 */ 50 */
22 -.config-dialog .el-dialog__header{  
23 - text-align: left!important; 51 +.config-dialog .el-dialog__header {
  52 + text-align: left !important;
24 } 53 }
25 54
26 -.config-dialog .el-dialog__body{  
27 - padding: 5px 10px!important;  
28 - padding-bottom: 20px!important; 55 +.config-dialog .el-dialog__body {
  56 + padding: 5px 10px !important;
  57 + padding-bottom: 20px !important;
29 } 58 }
30 59
31 -.el-form-item{ 60 +.el-form-item {
32 display: flex; 61 display: flex;
33 } 62 }
34 -.el-form-item__content{ 63 +
  64 +.el-form-item__content {
35 width: 60%; 65 width: 60%;
36 } 66 }
37 67
38 68
39 /*加载图标*/ 69 /*加载图标*/
40 -.el-loading-spinner .el-icon{ 70 +.el-loading-spinner .el-icon {
41 width: 70px; 71 width: 70px;
42 height: 70px; 72 height: 70px;
43 background: url(../../../start/layui/css/modules/layer/default/loading-mj.png) no-repeat center; 73 background: url(../../../start/layui/css/modules/layer/default/loading-mj.png) no-repeat center;
@@ -45,7 +75,7 @@ custom-class="config-dialog" @@ -45,7 +75,7 @@ custom-class="config-dialog"
45 animation: sk-chase-dot 2.0s infinite ease-in-out both; 75 animation: sk-chase-dot 2.0s infinite ease-in-out both;
46 opacity: 0.65; 76 opacity: 0.65;
47 display: block; 77 display: block;
48 - margin-left: calc((100% - 70px)/2); 78 + margin-left: calc((100% - 70px) / 2);
49 } 79 }
50 80
51 @keyframes sk-chase-dot { 81 @keyframes sk-chase-dot {
@@ -53,16 +83,26 @@ custom-class="config-dialog" @@ -53,16 +83,26 @@ custom-class="config-dialog"
53 transform: rotate(360deg) 83 transform: rotate(360deg)
54 } 84 }
55 } 85 }
56 -.select-all .el-button{  
57 - height:42px; 86 +
  87 +.select-all .el-button {
  88 + height: 42px;
58 } 89 }
59 -.button-more{  
60 - position: absolute;right: 0;top: 33px;z-index: 1;background: #f5f7fa;width: 80px; padding: 10px; 90 +
  91 +.button-more {
  92 + position: absolute;
  93 + right: 0;
  94 + top: 33px;
  95 + z-index: 1;
  96 + background: #f5f7fa;
  97 + width: 80px;
  98 + padding: 10px;
61 } 99 }
62 -.breadcrumb .el-breadcrumb{ 100 +
  101 +.breadcrumb .el-breadcrumb {
63 background: #ffffff; 102 background: #ffffff;
64 padding: 20px 5px 0; 103 padding: 20px 5px 0;
65 } 104 }
66 -.breadcrumb .el-breadcrumb .el-breadcrumb__item{ 105 +
  106 +.breadcrumb .el-breadcrumb .el-breadcrumb__item {
67 cursor: pointer; 107 cursor: pointer;
68 } 108 }
@@ -9,15 +9,14 @@ @@ -9,15 +9,14 @@
9 :width="getWidth(item.width)"> 9 :width="getWidth(item.width)">
10 <template #default="scope"> 10 <template #default="scope">
11 <slot :row="scope.row" :prop="item.prop" :column="item"> 11 <slot :row="scope.row" :prop="item.prop" :column="item">
12 - <div v-if="typeof(item.render) == 'function'" >  
13 - <div v-if="typeof(item.click) == 'function'">  
14 - <!--<el-link :type="linkType" :underline="isLink" @click="item.click(scope.row)" v-html="item.render(scope.row)"></el-link>-->  
15 - <span @click="item.click(scope.row)" v-html="item.render(scope.row)"></span> 12 + <div v-if="typeof(item.click) == 'function' && typeof(item.render) == 'function'">
  13 + <span style="cursor: pointer" @click="item.click(scope.row)" v-html="item.render(scope.row)"></span>
16 </div> 14 </div>
17 - <div v-else>  
18 - <!-- <el-link :type="linkType" :underline="isLink" v-html="item.render(scope.row)"></el-link>-->  
19 - <span v-html="item.render(scope.row)"></span> 15 + <div v-else-if="typeof(item.click) == 'function'" >
  16 + <span style="cursor: pointer" @click="item.click(scope.row)"> {{scope.row[item.prop]}}</span>
20 </div> 17 </div>
  18 + <div v-else-if="typeof(item.render) == 'function'" >
  19 + <span v-html="item.render(scope.row)">{{scope.row[item.prop]}}</span>
21 </div> 20 </div>
22 <span v-else> 21 <span v-else>
23 {{scope.row[item.prop]}} 22 {{scope.row[item.prop]}}
@@ -26,7 +25,7 @@ @@ -26,7 +25,7 @@
26 </template> 25 </template>
27 </el-table-column> 26 </el-table-column>
28 27
29 - <el-table-column v-if="showTools && columns.length > 0" label="操作" width="80"> 28 + <el-table-column v-if="showTools && columns.length > 0" label="操作" width="80" align="center">
30 <template #default="scope"> 29 <template #default="scope">
31 <slot name="tools" :scope="scope" ></slot> 30 <slot name="tools" :scope="scope" ></slot>
32 </template> 31 </template>
@@ -33,10 +33,6 @@ export default { @@ -33,10 +33,6 @@ export default {
33 type: String, 33 type: String,
34 default: '序号' 34 default: '序号'
35 }, 35 },
36 - /*currentPage: {  
37 - type: Number,  
38 - default: 1  
39 - },*/  
40 // 分页页码设置 36 // 分页页码设置
41 pageSizes: { 37 pageSizes: {
42 type: Array, 38 type: Array,
@@ -79,8 +75,7 @@ export default { @@ -79,8 +75,7 @@ export default {
79 showTools:{ 75 showTools:{
80 type: Boolean, 76 type: Boolean,
81 default: false 77 default: false
82 - },  
83 - 78 + }
84 }, 79 },
85 data() { 80 data() {
86 return {} 81 return {}
@@ -260,6 +260,20 @@ global.getBase64 = (file) => { @@ -260,6 +260,20 @@ global.getBase64 = (file) => {
260 }); 260 });
261 } 261 }
262 262
  263 +/**
  264 + * 判断是否是管理员角色
  265 + * <p>
  266 + * 作者: Wang
  267 + * 时间:2021/12/13 14:31
  268 + */
  269 +global.isAdminRole = () =>{
  270 + let roles = sessionStorage.getItem('roles');
  271 + if(roles && roles.indexOf('ADMIN') != -1){
  272 + return true;
  273 + }
  274 + return false;
  275 +}
  276 +
263 277
264 // 组件默认大小 medium / small / mini 278 // 组件默认大小 medium / small / mini
265 global.elementSize = ''; 279 global.elementSize = '';
@@ -12,7 +12,7 @@ server: @@ -12,7 +12,7 @@ server:
12 key-store-password: Hg0801.. 12 key-store-password: Hg0801..
13 key-password: Hg0801.. 13 key-password: Hg0801..
14 url: 14 url:
15 - gateway: http://127.0.0.1:8080 15 + gateway: https://192.168.0.248:8080
16 inspection_web: http://127.0.0.1:8082 16 inspection_web: http://127.0.0.1:8082
17 assetsweb: http://127.0.0.1:8082 17 assetsweb: http://127.0.0.1:8082
18 mxgraph_editor: http://127.0.0.1:8085 18 mxgraph_editor: http://127.0.0.1:8085
1 <title>故障管理</title> 1 <title>故障管理</title>
2 -<iframe src="/vue3/index.html#/fault/faultForm" class="layadmin-iframe" style="height: 99.5%!important;"/> 2 +<iframe src="/vue3/index.html#/fault/result/index" class="layadmin-iframe" style="height: 99.5%!important;"/>
3 <!--<iframe src="/vue3/index.html#/fault/index" class="layadmin-iframe" style="height: 99.5%!important;"/>--> 3 <!--<iframe src="/vue3/index.html#/fault/index" class="layadmin-iframe" style="height: 99.5%!important;"/>-->
1 <div style="display: flex"> 1 <div style="display: flex">
2 - <div style="cursor:pointer;width: calc(100% - 25px)">{{textString}}</div> 2 + <div @click="openDetail" style="cursor:pointer;width: calc(100% - 25px)">{{textString}}</div>
3 <el-dropdown style="width: 25px"> 3 <el-dropdown style="width: 25px">
4 - <span class="el-dropdown-link" @click="openDetail"> 4 + <span class="el-dropdown-link" style="cursor:pointer;">
5 <i class="el-icon-more" style="color: blue;font-weight: bold;" /> 5 <i class="el-icon-more" style="color: blue;font-weight: bold;" />
6 </span> 6 </span>
7 <template #dropdown> 7 <template #dropdown>
@@ -68,7 +68,7 @@ let configPageEdit = (columns, currentNode) => { @@ -68,7 +68,7 @@ let configPageEdit = (columns, currentNode) => {
68 proxy.$global.showMsg("请选择关联扩展属性!", "warning") 68 proxy.$global.showMsg("请选择关联扩展属性!", "warning")
69 return; 69 return;
70 } 70 }
71 -debugger 71 +
72 if(fieldsValueObj.value[row.id] && Object.keys(fieldsValueObj.value[row.id]).length >0){ 72 if(fieldsValueObj.value[row.id] && Object.keys(fieldsValueObj.value[row.id]).length >0){
73 settingCmDialogFlg.value = flg; 73 settingCmDialogFlg.value = flg;
74 return; 74 return;
@@ -126,7 +126,7 @@ const routes = [{ @@ -126,7 +126,7 @@ const routes = [{
126 component: () => myImport('views/faultDiagnosis/index') 126 component: () => myImport('views/faultDiagnosis/index')
127 }, 127 },
128 { 128 {
129 - path: '/fault/faultForm', 129 + path: '/fault/result/index',
130 name: 'faultForm', 130 name: 'faultForm',
131 component: () => myImport('views/faultDiagnosis/result/index') 131 component: () => myImport('views/faultDiagnosis/result/index')
132 }/*, 132 }/*,
1 <div class="container" :style="{'height':height+'px','max-height':height+'px'}"> 1 <div class="container" :style="{'height':height+'px','max-height':height+'px'}">
2 <div class="cm-card" :style="{'min-height':height+'px','max-height':height+'px','height':'100%'}"> 2 <div class="cm-card" :style="{'min-height':height+'px','max-height':height+'px','height':'100%'}">
3 <div class="search"> 3 <div class="search">
4 - <!--<el-form :inline="true" :model="formInline" class="demo-form-inline">  
5 - <el-form-item >  
6 - <el-input v-model="formInline.user" placeholder="Approved by"></el-input>  
7 - </el-form-item>  
8 - <el-form-item >  
9 - <el-input v-model="formInline.user" placeholder="Approved by"></el-input>  
10 - </el-form-item>  
11 - <el-form-item >  
12 - <el-input v-model="formInline.user" placeholder="Approved by"></el-input>  
13 - </el-form-item>  
14 - <el-form-item >  
15 - <el-input v-model="formInline.user" placeholder="Approved by"></el-input>  
16 - </el-form-item>  
17 - <el-form-item >  
18 - <el-input v-model="formInline.user" placeholder="Approved by"></el-input>  
19 - </el-form-item>  
20 - <el-form-item >  
21 - <el-select v-model="formInline.region" placeholder="Activity zone">  
22 - <el-option label="Zone one" value="shanghai"></el-option>  
23 - <el-option label="Zone two" value="beijing"></el-option>  
24 - </el-select>  
25 - </el-form-item>  
26 - <el-form-item>  
27 - <el-button type="primary" @click="onSubmit">Query</el-button>  
28 - </el-form-item>  
29 - </el-form>-->  
30 <div class="condition"> 4 <div class="condition">
31 <el-form-item> 5 <el-form-item>
32 - <el-input v-model="formInline.user" placeholder="Approved by"></el-input> 6 + <el-input v-model="searchForm.keyword" placeholder="输入关键字"
  7 + @keydown.enter.native="getPage"></el-input>
33 </el-form-item> 8 </el-form-item>
34 - <el-form-item>  
35 - <el-input v-model="formInline.user" placeholder="Approved by"></el-input>  
36 - </el-form-item>  
37 - <el-form-item>  
38 - <el-input v-model="formInline.user" placeholder="Approved by"></el-input>  
39 - </el-form-item>  
40 - <el-form-item>  
41 - <el-select v-model="formInline.region" placeholder="Activity zone"> 9 + <!--<el-form-item>
  10 + <el-select v-model="searchForm.category" placeholder="故障分类">
42 <el-option label="Zone one" value="shanghai"></el-option> 11 <el-option label="Zone one" value="shanghai"></el-option>
43 <el-option label="Zone two" value="beijing"></el-option> 12 <el-option label="Zone two" value="beijing"></el-option>
44 </el-select> 13 </el-select>
45 - </el-form-item>  
46 - 14 + </el-form-item>-->
47 </div> 15 </div>
48 <div class="btns"> 16 <div class="btns">
49 <el-form-item> 17 <el-form-item>
50 - <el-button type="primary" @click="onSubmit">Query</el-button> 18 + <el-button type="primary" @click="getPage">搜索</el-button>
51 </el-form-item> 19 </el-form-item>
52 </div> 20 </div>
53 </div> 21 </div>
54 22
55 - <cm-table-page :columns="[]" :dataList="[]"  
56 - @loaddata="getPage" :showIndex="true" 23 + <div class="search-table">
  24 + <cm-table-page :columns="list.columns"
  25 + :dataList="list.dataList"
  26 + :total="list.total"
  27 + @loaddata="getPageInfo"
57 :showIndex="true" 28 :showIndex="true"
58 - :showSelection="true"  
59 - :pageSizes="[10,50,90, 200, 300, 400]" :pageSize="limit"  
60 - :showBorder="true" :currentPage="currentPage" :total="total" :loading="false"  
61 - :showPage="true" :height="(height - 95)"  
62 - :maxWidth="max"> 29 + :showBorder="true"
  30 + :showPage="true"
  31 + :showTools="true"
  32 + :height="(height - 105)">
  33 + <template #tools="{scope}">
  34 + <el-button type="text" size="small" @click.prevent="handleClick(scope.row,scope.$index)">
  35 + 处理
  36 + </el-button>
  37 + </template>
63 </cm-table-page> 38 </cm-table-page>
64 </div> 39 </div>
  40 + </div>
  41 +
  42 + <!-- 弹框区域 -->
  43 + <cm-dialog :title="faultDetailDialogTitle" width="80%" :showDialogVisible="showFaultDetailDialog"
  44 + @hidedialog="closeFaultDetailDialog" :showFooter="false">
  45 + <template v-slot>
  46 + <div>
  47 + <el-timeline>
  48 + <el-timeline-item timestamp="2018/4/12" placement="top">
  49 + <el-card>
  50 + <h4>Update Github template</h4>
  51 + <p>Tom committed 2018/4/12 20:46</p>
  52 + </el-card>
  53 + </el-timeline-item>
  54 + <el-timeline-item timestamp="2018/4/3" placement="top">
  55 + <el-card>
  56 + <h4>Update Github template</h4>
  57 + <p>Tom committed 2018/4/3 20:46</p>
  58 + </el-card>
  59 + </el-timeline-item>
  60 + <el-timeline-item timestamp="2018/4/2" placement="top">
  61 + <el-card>
  62 + <h4>Update Github template</h4>
  63 + <p>Tom committed 2018/4/2 20:46</p>
  64 + </el-card>
  65 + </el-timeline-item>
  66 + </el-timeline>
  67 + </div>
  68 + </template>
  69 + </cm-dialog>
65 </div> 70 </div>
  1 +const faultDetail = () => {
  2 + const {proxy} = Vue.getCurrentInstance();
  3 + let showFaultDetailDialog = Vue.ref(false);
  4 + let faultDetailDialogTitle = Vue.ref('');
  5 +
  6 +
  7 + let closeFaultDetailDialog = (flg) =>{
  8 + showFaultDetailDialog.value = flg;
  9 + }
  10 +
  11 + return {
  12 + showFaultDetailDialog,
  13 + faultDetailDialogTitle,
  14 + closeFaultDetailDialog
  15 + }
  16 +}
1 export default { 17 export default {
2 name: 'resIndex', 18 name: 'resIndex',
3 template: '', 19 template: '',
4 - components: {  
5 - 'tree-config': Vue.defineAsyncComponent(  
6 - () => myImport('components/page/res/treeconfig/index')  
7 - ),  
8 - }, 20 + components: {},
9 data() { 21 data() {
10 return { 22 return {
11 - props : {  
12 - label:'label',  
13 - children:'children' 23 + props: {
  24 + label: 'label',
  25 + children: 'children'
14 } 26 }
15 } 27 }
16 }, 28 },
17 setup() { 29 setup() {
18 const {proxy} = Vue.getCurrentInstance(); 30 const {proxy} = Vue.getCurrentInstance();
19 - let height = Vue.ref(window.innerHeight -20); 31 + let height = Vue.ref(window.innerHeight - 20);
  32 + // 搜索表单内容
  33 + let searchForm = Vue.ref({
  34 + keyword: '',
  35 + page: 1,
  36 + pageSize: 10
  37 + });
20 38
21 - let formInline = Vue.ref({  
22 - user: '',  
23 - region: '', 39 + // 列表展示结果
  40 + let list = Vue.ref({
  41 + columns: [{
  42 + prop: 'faultBody',
  43 + label: '故障主体',
  44 + click: function (row) {
  45 + // 展示弹框
  46 + }
  47 + }, {
  48 + prop: 'createTime',
  49 + label: '发生时间'
  50 + }, {
  51 + prop: 'faultState',
  52 + label: '故障状态'
  53 + }],
  54 + dataList: [],
  55 + total: 0
24 }); 56 });
  57 +
  58 + /**
  59 + * 分页查询
  60 + * <p>
  61 + * 作者: Wang
  62 + * 时间:2021/12/13 16:51
  63 + */
  64 + let getPage = () => {
  65 + proxy.$http.get(`/api-web/fault/page`, searchForm.value, function (res) {
  66 + if (res && res.data) {
  67 + list.value.dataList = res.data;
  68 + }
  69 + });
  70 + }
  71 +
  72 + let handleClick = (row, index) => {
  73 +
  74 + }
  75 +
  76 + /**
  77 + * 分页切换
  78 + * <p>
  79 + * 作者: Wang
  80 + * 时间:2021/12/13 17:06
  81 + */
  82 + let getPageInfo = ({page, limit}) => {
  83 + searchForm.value.page = page;
  84 + searchForm.value.pageSize = limit;
  85 +
  86 + // 下一页搜索
  87 + getPage();
  88 + }
  89 +
  90 + const {
  91 + showFaultDetailDialog,
  92 + faultDetailDialogTitle,
  93 + closeFaultDetailDialog
  94 + } = faultDetail();
  95 +
25 // 挂载完 96 // 挂载完
26 Vue.onMounted(() => { 97 Vue.onMounted(() => {
27 - 98 + // 初始化加载页面
  99 + getPage();
28 }) 100 })
29 101
30 -  
31 return { 102 return {
32 height, 103 height,
33 - formInline 104 + searchForm,
  105 + list,
  106 + getPage,
  107 + getPageInfo,
  108 + handleClick
34 } 109 }
35 } 110 }
36 } 111 }
@@ -18,18 +18,18 @@ @@ -18,18 +18,18 @@
18 </el-form-item> 18 </el-form-item>
19 19
20 <el-form-item> 20 <el-form-item>
21 - <el-button @click="loadResList">查询</el-button> 21 + <el-button v-if="obj.searchList.length > 0" @click="loadResList">查询</el-button>
22 </el-form-item> 22 </el-form-item>
23 </el-form> 23 </el-form>
24 </div> 24 </div>
25 - <div style="width: 100px"> 25 + <div style="width: 100px" v-if="$global.isAdminRole()">
26 <el-button type="primary" @click="showConfigDialog(true)">配置</el-button> 26 <el-button type="primary" @click="showConfigDialog(true)">配置</el-button>
27 </div> 27 </div>
28 </div> 28 </div>
29 29
30 <cm-table-page :columns="obj.columns" :dataList="obj.maps" @loaddata="getPage" :showIndex="true" 30 <cm-table-page :columns="obj.columns" :dataList="obj.maps" @loaddata="getPage" :showIndex="true"
31 :pageSizes="[10,50,90, 200, 300, 400]" :pageSize="limit" 31 :pageSizes="[10,50,90, 200, 300, 400]" :pageSize="limit"
32 - :showBorder="true" :currentPage="currentPage" :total="total" :loading="false" 32 + :showBorder="true" :total="total" :loading="false"
33 :showPage="true" :height="(height - 95)" 33 :showPage="true" :height="(height - 95)"
34 :maxWidth="max"> 34 :maxWidth="max">
35 <template #default="{row,prop,column}"> 35 <template #default="{row,prop,column}">
@@ -62,9 +62,7 @@ export default { @@ -62,9 +62,7 @@ export default {
62 // 当前点击 62 // 当前点击
63 const currentNode = Vue.ref({}); 63 const currentNode = Vue.ref({});
64 // 搜索框内容 64 // 搜索框内容
65 - const searchForm = Vue.ref({  
66 -  
67 - }); 65 + const searchForm = Vue.ref({});
68 66
69 // 单元格点及保存的数据 67 // 单元格点及保存的数据
70 let cellDetail = Vue.ref({}); 68 let cellDetail = Vue.ref({});
@@ -152,14 +150,15 @@ export default { @@ -152,14 +150,15 @@ export default {
152 } 150 }
153 151
154 let getPage = (pageInfo) =>{ 152 let getPage = (pageInfo) =>{
155 - console.log(pageInfo);  
156 - debugger;  
157 -  
158 page.value = pageInfo.page; 153 page.value = pageInfo.page;
159 limit.value = pageInfo.limit; 154 limit.value = pageInfo.limit;
160 loadResList() 155 loadResList()
161 } 156 }
162 157
  158 + let isManager = () => {
  159 +
  160 + }
  161 +
163 162
164 // 配置页面 163 // 配置页面
165 const {showConfig, configObj, showConfigDialog} = configPage() 164 const {showConfig, configObj, showConfigDialog} = configPage()
  1 +<div class="container" :style="{'height':height+'px','max-height':height+'px'}">
  2 + <div class="cm-card" :style="{'min-height':height+'px','max-height':height+'px','height':'100%'}">
  3 + <div class="search">
  4 + <div class="condition">
  5 + <el-form-item>
  6 + <el-input v-model="formInline.user" placeholder="输入关键字"></el-input>
  7 + </el-form-item>
  8 + <el-form-item>
  9 + <el-select v-model="formInline.region" placeholder="故障分类">
  10 + <el-option label="Zone one" value="shanghai"></el-option>
  11 + <el-option label="Zone two" value="beijing"></el-option>
  12 + </el-select>
  13 + </el-form-item>
  14 + </div>
  15 + <div class="btns">
  16 + <el-form-item>
  17 + <el-button type="primary" @click="onSubmit">搜索</el-button>
  18 + </el-form-item>
  19 + </div>
  20 + </div>
  21 +
  22 + <cm-table-page :columns="[]" :dataList="[]"
  23 + @loaddata="getPage" :showIndex="true"
  24 + :showIndex="true"
  25 + :showSelection="true"
  26 + :pageSizes="[10,50,90, 200, 300, 400]" :pageSize="limit"
  27 + :showBorder="true" :currentPage="currentPage" :total="total" :loading="false"
  28 + :showPage="true" :height="(height - 105)"
  29 + :maxWidth="max">
  30 + </cm-table-page>
  31 + </div>
  32 +</div>
  1 +export default {
  2 + name: 'resIndex',
  3 + template: '',
  4 + components: {
  5 + },
  6 + data() {
  7 + return {
  8 + props : {
  9 + label:'label',
  10 + children:'children'
  11 + }
  12 + }
  13 + },
  14 + setup() {
  15 + const {proxy} = Vue.getCurrentInstance();
  16 + let height = Vue.ref(window.innerHeight -20);
  17 +
  18 + let formInline = Vue.ref({
  19 + user: '',
  20 + region: '',
  21 + });
  22 + // 挂载完
  23 + Vue.onMounted(() => {
  24 +
  25 + })
  26 +
  27 +
  28 + return {
  29 + height,
  30 + formInline
  31 + }
  32 + }
  33 +}