Merge branch 'codeCheck' of https://git.mesalab.cn/nezha/nezha-fronted into codeCheck
This commit is contained in:
@@ -823,6 +823,7 @@ li{
|
||||
.nz-table .el-table {
|
||||
border: none;
|
||||
font-size: 12px;
|
||||
display: table-cell!important;
|
||||
}
|
||||
.nz-table::before {
|
||||
height: 0;
|
||||
|
||||
@@ -93,7 +93,7 @@
|
||||
v-scrollBar:el-table="'small'"
|
||||
>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(_item, _index) in setLabels(value)"
|
||||
v-if="_item.show"
|
||||
:key="`col-${_index}`"
|
||||
|
||||
@@ -39,11 +39,9 @@
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(item, index) in tools.customTableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:minWidth="item.minWidth"
|
||||
:key="`col-${index}`"
|
||||
:label="item.label"
|
||||
:show-overflow-tooltip="item.prop != 'labels' && item.prop != 'alertRule'"
|
||||
@@ -156,7 +154,7 @@
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
<el-table-column width="28" :resizable="false">
|
||||
<el-table-column width="28" :resizable="true">
|
||||
<template slot="header" slot-scope="scope">
|
||||
<span @mousedown.stop="!tools.showCustomTableTitle && (tools.showCustomTableTitle = true)" class="nz-table-gear">
|
||||
<i class="nz-icon nz-icon-gear"></i>
|
||||
|
||||
@@ -35,10 +35,9 @@
|
||||
align="center">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(item, index) in tableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:key="`col-${index}`"
|
||||
:label="item.label"
|
||||
>
|
||||
|
||||
@@ -59,13 +59,11 @@
|
||||
align="center">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(item, index) in tools.customTableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:key="`col-${index}`"
|
||||
:label="item.label"
|
||||
:min-width="(item.minWidth?item.minWidth+'px':'110px')"
|
||||
:sortable="$tableSet.sortableShow(item.prop,'endpointTab')"
|
||||
:prop="$tableSet.propTitle(item.prop,'endpointTab')"
|
||||
:sort-orders="['ascending', 'descending']"
|
||||
|
||||
@@ -72,9 +72,17 @@
|
||||
<div class="result-title">{{$t('overall.result.failedDetail')}}:</div>
|
||||
<div class="result-detail" v-if="importResult&&importResult.failDetail">
|
||||
<el-scrollbar style="height: 100%">
|
||||
<ul>
|
||||
<!-- <ul>
|
||||
<li v-for="(item,index) in importResult.failDetail"><span>{{item.lineNo}}</span>:<span>{{item.errorMsg}}</span> </li>
|
||||
</ul>
|
||||
</ul>-->
|
||||
<template v-for="(item,index) in importResult.failDetail">
|
||||
<div class="import-result-block">
|
||||
<div class="import-result-item">
|
||||
<div class="line-num">{{$t('overall.result.line',[item.lineNo])}}</div>
|
||||
<div>{{item.errorMsg}}</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</el-scrollbar>
|
||||
</div>
|
||||
</div>
|
||||
@@ -324,3 +332,14 @@
|
||||
}
|
||||
/*去除上传文件动画end*/
|
||||
</style>
|
||||
|
||||
<style>
|
||||
.result-detail .import-result-block{
|
||||
}
|
||||
.result-detail .import-result-block .import-result-item{
|
||||
display: flex;
|
||||
}
|
||||
.import-result-item .line-num{
|
||||
width: 55px;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -71,7 +71,8 @@ const cn = {
|
||||
total: "总计",
|
||||
failed: "失败",
|
||||
success: "成功",
|
||||
failedDetail: "失败详情"
|
||||
failedDetail: "失败详情",
|
||||
line:"第{0}行:"
|
||||
},
|
||||
reset: "重置",
|
||||
submit: "保存",
|
||||
|
||||
@@ -75,7 +75,8 @@ const en = {
|
||||
total:'Total',
|
||||
failed:'Failed',
|
||||
success:'Success',
|
||||
failedDetail:'Failed Detail'
|
||||
failedDetail:'Failed Detail',
|
||||
line:'Line {0}:'
|
||||
},
|
||||
reset:'Reset',
|
||||
submit:'Save',
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
<!-->-->
|
||||
<!--</el-table-column>-->
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(item, index) in tableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
@sort-change="tableDataSort"
|
||||
>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(item, index) in tableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
|
||||
@@ -85,14 +85,12 @@
|
||||
align="center">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(item, index) in tools.customTableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:key="`col-${index}`"
|
||||
:label="item.label"
|
||||
show-overflow-tooltip
|
||||
min-width="110px"
|
||||
:sort-orders="['ascending', 'descending']"
|
||||
:sortable="$tableSet.sortableShow(item.prop,'alertRules')"
|
||||
:prop="$tableSet.propTitle(item.prop,'alertRules')"
|
||||
|
||||
@@ -57,15 +57,13 @@
|
||||
align="center">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(item, index) in tools.customTableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:key="`col_${index}`"
|
||||
:label="item.label"
|
||||
:fixed="item.fixed"
|
||||
:show-overflow-tooltip="item.prop != 'Alert' || item.prop != 'Module'"
|
||||
min-width="110px"
|
||||
:class-name="item.prop == 'option' ? 'content-right-options' : ''"
|
||||
:sortable="$tableSet.sortableShow(item.prop,'asset')"
|
||||
:prop="$tableSet.propTitle(item.prop,'asset')"
|
||||
|
||||
@@ -53,10 +53,9 @@
|
||||
align="center">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(item, index) in tools.customTableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:key="`col-${index}`"
|
||||
:label="item.label"
|
||||
:prop="item.prop"
|
||||
|
||||
@@ -53,11 +53,10 @@
|
||||
align="center">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
show-overflow-tooltip
|
||||
v-for="(item, index) in tools.customTableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:key="`col-${index}`"
|
||||
:label="item.label"
|
||||
:sortable="$tableSet.sortableShow(item.prop,'dc')"
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
width="40"
|
||||
align="center">
|
||||
</el-table-column>
|
||||
<el-table-column :resizable="false" v-for="(item, index) in tools.customTableTitle" v-if="item.show" :width="item.width" :class-name="item.prop == 'modelsDetail'?'detail-column':''"
|
||||
<el-table-column :resizable="true" v-for="(item, index) in tools.customTableTitle" v-if="item.show" :class-name="item.prop == 'modelsDetail'?'detail-column':''"
|
||||
:key="`col-${index}`" :label="item.label" :sortable="$tableSet.sortableShow(item.prop,'mib')"
|
||||
:prop="$tableSet.propTitle(item.prop,'mib')"
|
||||
:sort-orders="['ascending', 'descending']">
|
||||
|
||||
@@ -49,10 +49,9 @@
|
||||
width="40"
|
||||
align="center">
|
||||
</el-table-column>
|
||||
<el-table-column :resizable="false"
|
||||
<el-table-column :resizable="true"
|
||||
v-for="(item, index) in tools.customTableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:key="`col-${index}`"
|
||||
:label="item.label"
|
||||
:sortable="$tableSet.sortableShow(item.prop,'model')"
|
||||
|
||||
@@ -36,10 +36,9 @@
|
||||
@sort-change="tableDataSort"
|
||||
>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(item, index) in tools.customTableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:key="`col-${index}`"
|
||||
:label="item.label"
|
||||
:sortable="$tableSet.sortableShow(item.prop,'operationlog')"
|
||||
|
||||
@@ -41,9 +41,8 @@
|
||||
width="40"
|
||||
align="center">
|
||||
</el-table-column>
|
||||
<el-table-column :resizable="false" v-for="(item, index) in tools.customTableTitle"
|
||||
<el-table-column :resizable="true" v-for="(item, index) in tools.customTableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:key="`col-${index}`"
|
||||
:label="item.label"
|
||||
:sortable="$tableSet.sortableShow(item.prop,'promServer')"
|
||||
|
||||
@@ -35,10 +35,9 @@
|
||||
style="width: 100%;"
|
||||
@sort-change="tableDataSort">
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(item, index) in tools.customTableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:key="`col-${index}`"
|
||||
:label="item.label"
|
||||
:sortable="$tableSet.sortableShow(item.prop,'temrminallog')"
|
||||
|
||||
@@ -68,6 +68,7 @@
|
||||
@sort-change="tableDataSort"
|
||||
@row-dblclick="detailEndpoint"
|
||||
@selection-change="(selection)=>{this.batchDeleteObjs=selection}"
|
||||
@header-dragend="()=>{this.$refs.endpointTable.doLayout();}"
|
||||
>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
@@ -76,13 +77,12 @@
|
||||
align="center">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
:resizable="false"
|
||||
:resizable="true"
|
||||
v-for="(item, index) in tools.customTableTitle"
|
||||
v-if="item.show"
|
||||
:width="item.width"
|
||||
:key="`col-${index}`"
|
||||
:label="item.label"
|
||||
min-width="110px"
|
||||
:min-width="item.width"
|
||||
:sortable="$tableSet.sortableShow(item.prop,'project')"
|
||||
:prop="$tableSet.propTitle(item.prop,'project')"
|
||||
:sort-orders="['ascending', 'descending']"
|
||||
@@ -132,7 +132,7 @@
|
||||
<template v-else>-</template>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column width="28" :resizable="false">
|
||||
<el-table-column width="28" :resizable="true">
|
||||
<template slot="header" slot-scope="scope">
|
||||
<span @mousedown.stop="!tools.showCustomTableTitle && (tools.showCustomTableTitle = true)" class="nz-table-gear">
|
||||
<i class="nz-icon nz-icon-gear"></i>
|
||||
|
||||
Reference in New Issue
Block a user