NEZ-1945 fix : 用户列表页面 详细视图下 增加 详情提示窗

This commit is contained in:
likexuan
2022-07-05 13:30:11 +08:00
parent a520848c5a
commit ea09bd51a5
2 changed files with 32 additions and 29 deletions

View File

@@ -27,6 +27,9 @@
>
<div class="detail-row-info">
<div class="asset-manageIp">
<div class="user-name-td"
@mouseenter="labelHover(item, 'user', true, false, $event)"
@mouseleave="labelHover(item, 'user', false, false,)">
<span class="flex-align-center">
<span v-if="item.status" >
<span :class="{'active-icon green-bg':item.status == 1,'active-icon gray-bg':item.status == 0}"></span>
@@ -36,12 +39,20 @@
<el-tag size="mini" v-if="mfaEnable == '1' || item.mfaLevel > 0" style="margin-left: 5px">2FA</el-tag>
</span>
</div>
</div>
<div class="asset-name">
<span>@{{item.username}}</span>
</div>
</div>
</li>
</ul>
<alertLabel
v-if="alertLabelShow"
:id="alertLabelId"
:that="alertLabelObj"
:type="alertLabelType"
:detailList = true
></alertLabel>
</div>
</template>
@@ -50,9 +61,10 @@
import detailViewLeftMixin from '@/components/common/mixin/detailViewLeftMixin'
import alertLabel from '@/components/common/alert/alertLabel'
import { terminalLog } from '@/components/common/js/constants'
import alertLabelMixin from '@/components/common/mixin/alertLabelMixin'
export default {
name: 'userDetail',
mixins: [detailViewLeftMixin],
mixins: [detailViewLeftMixin, alertLabelMixin],
components: {
alertLabel
},
@@ -120,15 +132,15 @@ export default {
},
methods: {
// label 鼠标划入
labelHover (item, type, loading, e) {
if (e) {
const dom = e.currentTarget
const position = dom.getBoundingClientRect()
this.$set(item, 'position', position)
}
this.$set(item, 'loading', loading)
// this.$set(this.tableData,index,item);// 调用父组件
},
// labelHover (item, type, loading, e) {
// if (e) {
// const dom = e.currentTarget
// const position = dom.getBoundingClientRect()
// this.$set(item, 'position', position)
// }
// this.$set(item, 'loading', loading)
// // this.$set(this.tableData,index,item);// 调用父组件
// },
getStatusText () {
return function (status) {
return terminalLog.status[status]

View File

@@ -39,9 +39,7 @@
<template slot-scope="scope" :column="item">
<template v-if="item.prop === 'name'">
<div style="cursor:text" class="document-copy-block">
<div class="user-name-td document-copy-text" :class="{'margin-l-10': !scope.row.online}"
@mouseenter="labelHover(scope.row, 'user', true, false, $event)"
@mouseleave="labelHover(scope.row, 'user', false, false,)">
<div class="user-name-td document-copy-text" :class="{'margin-l-10': !scope.row.online}">
<i class="nz-icon nz-icon-user1 user-online" v-if="scope.row.online" :title="$t('overall.online')"/>
<div>
<div class="flex-align-center">
@@ -120,21 +118,14 @@
<div v-else>&nbsp;</div>
</template>
</el-table>
<alertLabel
v-if="alertLabelShow"
:id="alertLabelId"
:that="alertLabelObj"
:type="alertLabelType"
></alertLabel>
</div>
</template>
<script>
import table from '@/components/common/mixin/table'
import alertLabelMixin from '@/components/common/mixin/alertLabelMixin'
export default {
name: 'userTable',
mixins: [table, alertLabelMixin],
mixins: [table],
props: {
loading: Boolean
},