init
This commit is contained in:
@@ -1,16 +1,28 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="app-container">
|
<div class="app-container">
|
||||||
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
|
||||||
|
<el-form-item :label="systemName+'号'" prop="usercode">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.usercode"
|
||||||
|
:placeholder="'请输入'+systemName+'号'"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="手机号" prop="mobile">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.mobile"
|
||||||
|
placeholder="请输入手机号"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
|
|
||||||
<el-row :gutter="10" class="mb8">
|
|
||||||
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
|
||||||
</el-row>
|
|
||||||
|
|
||||||
<el-table v-loading="loading" :data="lowHeightRiskList" @selection-change="handleSelectionChange">
|
<el-table v-loading="loading" :data="lowHeightRiskList" @selection-change="handleSelectionChange">
|
||||||
<el-table-column type="selection" width="55" align="center" />
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
<el-table-column :label="systemName+'号'" align="center" prop="usercode" />
|
<el-table-column :label="systemName+'号'" align="center" prop="usercode" />
|
||||||
@@ -28,11 +40,12 @@
|
|||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="截图次数" align="center" prop="screenshotNum" />
|
<el-table-column label="截图次数" align="center" prop="screenshotNum" />
|
||||||
<el-table-column label="录屏次数" align="center" prop="screenRecordingNum" />
|
<el-table-column label="录屏次数" align="center" prop="screenRecordingNum" />
|
||||||
<el-table-column label="违规权重" align="center" prop="state" >
|
<el-table-column label="登陆IP" align="center" prop="lastLoginIp" width="125"/>
|
||||||
|
<!-- <el-table-column label="违规权重" align="center" prop="state" >
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<cai-dict-tag :options="userRiskLowList" :value="scope.row.state" />
|
<cai-dict-tag :options="userRiskLowList" :value="scope.row.state" />
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>-->
|
||||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<el-button
|
<el-button
|
||||||
@@ -42,6 +55,20 @@
|
|||||||
@click="handleDelete(scope.row)"
|
@click="handleDelete(scope.row)"
|
||||||
v-hasPermi="['cai:lowHeightRisk:remove']"
|
v-hasPermi="['cai:lowHeightRisk:remove']"
|
||||||
>删除</el-button>
|
>删除</el-button>
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-logs"
|
||||||
|
@click="handleUserErrorLog(scope.row)"
|
||||||
|
v-hasPermi="['cai:lowHeightRisk:remove']"
|
||||||
|
>记录</el-button>
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-lock"
|
||||||
|
@click="handleUserForbid(scope.row)"
|
||||||
|
v-hasPermi="['cai:lowHeightRisk:remove']"
|
||||||
|
>封号</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
@@ -54,19 +81,28 @@
|
|||||||
@pagination="getList"
|
@pagination="getList"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
<user-error-list-info-dialog v-if="userErrorListInfoDialogVisible" ref="userErrorListInfoDialog"/>
|
||||||
|
<user-forbid-dialog v-if="userForbidVisible" ref="userForbid" @refreshDataList="getList" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { delLowHeightRisk, listLowHeightRisk } from '@/api/cai/lowHeightRisk'
|
import { delLowHeightRisk, listLowHeightRisk } from '@/api/cai/lowHeightRisk'
|
||||||
import { genderList, userRiskLowList } from '@/constant/statusMap'
|
import { genderList, userRiskLowList } from '@/constant/statusMap'
|
||||||
|
import UserErrorListInfoDialog from '@/views/cai/userErrorLog/user-error-list-info-dialog.vue'
|
||||||
|
import UserForbidDialog from "@/views/cai/user/user-forbid-dialog";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "LowHeightRisk",
|
name: "LowHeightRisk",
|
||||||
|
components: {
|
||||||
|
UserErrorListInfoDialog,UserForbidDialog
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
systemName: process.env.VUE_APP_SYSTEM_HOME,
|
systemName: process.env.VUE_APP_SYSTEM_HOME,
|
||||||
genderList,userRiskLowList,
|
genderList,userRiskLowList,
|
||||||
|
userErrorListInfoDialogVisible: false,
|
||||||
|
userForbidVisible: false,
|
||||||
// 遮罩层
|
// 遮罩层
|
||||||
loading: true,
|
loading: true,
|
||||||
// 选中数组
|
// 选中数组
|
||||||
@@ -84,10 +120,8 @@ export default {
|
|||||||
queryParams: {
|
queryParams: {
|
||||||
pageNum: 1,
|
pageNum: 1,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
userId: undefined,
|
usercode: undefined,
|
||||||
screenshotNum: undefined,
|
mobile: undefined,
|
||||||
screenRecordingNum: undefined,
|
|
||||||
state: undefined,
|
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
@@ -120,12 +154,23 @@ export default {
|
|||||||
this.single = selection.length!==1
|
this.single = selection.length!==1
|
||||||
this.multiple = !selection.length
|
this.multiple = !selection.length
|
||||||
},
|
},
|
||||||
|
handleUserErrorLog(row){
|
||||||
|
this.userErrorListInfoDialogVisible = true
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$refs.userErrorListInfoDialog.init(row.userId)
|
||||||
|
})
|
||||||
|
},
|
||||||
|
handleUserForbid(row){
|
||||||
|
this.userForbidVisible = true
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$refs.userForbid.init(row)
|
||||||
|
})
|
||||||
|
},
|
||||||
/** 删除按钮操作 */
|
/** 删除按钮操作 */
|
||||||
handleDelete(row) {
|
handleDelete(row) {
|
||||||
const ids = row.id || this.ids;
|
this.$modal.confirm('是否确认删除高风险用户"' + row.nickname + '"的数据项?').then(() => {
|
||||||
this.$modal.confirm('是否确认删除高风险用户记录编号为"' + ids + '"的数据项?').then(() => {
|
|
||||||
this.loading = true;
|
this.loading = true;
|
||||||
return delLowHeightRisk(ids);
|
return delLowHeightRisk(row.id);
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.getList();
|
this.getList();
|
||||||
|
|||||||
145
src/views/cai/userErrorLog/user-error-list-info-dialog.vue
Normal file
145
src/views/cai/userErrorLog/user-error-list-info-dialog.vue
Normal file
@@ -0,0 +1,145 @@
|
|||||||
|
<template>
|
||||||
|
<el-dialog title="高危记录" :close-on-click-modal="false" :visible.sync="open" width="900px" append-to-body>
|
||||||
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
|
||||||
|
<el-form-item label="类型" prop="type">
|
||||||
|
<el-select v-model="queryParams.type" clearable size="small">
|
||||||
|
<el-option
|
||||||
|
v-for="dict in userErrorLogTypeList"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="发生地点" prop="homeIndex">
|
||||||
|
<el-select v-model="queryParams.homeIndex" clearable size="small">
|
||||||
|
<el-option
|
||||||
|
v-for="dict in userErrorLogHomeIndexList"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||||
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<el-table v-loading="loading" :data="userErrorLogList" >
|
||||||
|
<el-table-column :label="systemName+'号'" align="center" prop="usercode"/>
|
||||||
|
<el-table-column label="昵称" align="center" prop="nickname"/>
|
||||||
|
<el-table-column label="头像" align="center" prop="avatar">
|
||||||
|
<template v-slot="scope">
|
||||||
|
<image-avatar :src="scope.row.avatar"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="类型" align="center" prop="type" >
|
||||||
|
<template v-slot="scope">
|
||||||
|
<cai-dict-tag :options="userErrorLogTypeList" :value="scope.row.type"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="发生地点" align="center" prop="homeIndex" >
|
||||||
|
<template v-slot="scope">
|
||||||
|
<cai-dict-tag :options="userErrorLogHomeIndexList" :value="scope.row.homeIndex"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="发生时间" align="center" prop="createTime" />
|
||||||
|
</el-table>
|
||||||
|
|
||||||
|
<pagination
|
||||||
|
v-show="total>0"
|
||||||
|
:total="total"
|
||||||
|
:page.sync="queryParams.pageNum"
|
||||||
|
:limit.sync="queryParams.pageSize"
|
||||||
|
@pagination="getList"
|
||||||
|
/>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button @click="open = false">取 消</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {getUserByUsercode, listUserByUserCode} from "@/api/cai/user";
|
||||||
|
import { listMemberPrice } from '@/api/cai/memberPrice'
|
||||||
|
import { addUserMember } from '@/api/cai/userMember'
|
||||||
|
import {updateAccountCoin} from "@/api/cai/account";
|
||||||
|
import {listGoods} from "@/api/cai/goods";
|
||||||
|
import {
|
||||||
|
accountTypeList,
|
||||||
|
genderList,
|
||||||
|
userErrorLogHomeIndexList,
|
||||||
|
userErrorLogTypeList,
|
||||||
|
yesOrNoList
|
||||||
|
} from '@/constant/statusMap'
|
||||||
|
import {listAccountChangeLog, listChangeType} from "@/api/cai/accountChangeLog";
|
||||||
|
import { listUserErrorLog } from '@/api/cai/userErrorLog'
|
||||||
|
|
||||||
|
export default {
|
||||||
|
components: {
|
||||||
|
},
|
||||||
|
data () {
|
||||||
|
return {
|
||||||
|
userErrorLogTypeList,userErrorLogHomeIndexList,genderList,
|
||||||
|
systemName: process.env.VUE_APP_SYSTEM_HOME,
|
||||||
|
open: false,
|
||||||
|
// 遮罩层
|
||||||
|
loading: true,
|
||||||
|
// 显示搜索条件
|
||||||
|
showSearch: true,
|
||||||
|
// 总条数
|
||||||
|
total: 0,
|
||||||
|
// 账户明细表格数据
|
||||||
|
userErrorLogList: [],
|
||||||
|
// 查询参数
|
||||||
|
queryParams: {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
type: undefined,
|
||||||
|
homeIndex: undefined,
|
||||||
|
userId: undefined,
|
||||||
|
mobile: undefined,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
init (userId) {
|
||||||
|
this.open = true;
|
||||||
|
this.queryParams.userId = userId
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
/** 查询账户明细列表 */
|
||||||
|
getList() {
|
||||||
|
this.loading = true;
|
||||||
|
listUserErrorLog(this.queryParams).then(response => {
|
||||||
|
this.userErrorLogList = response.rows;
|
||||||
|
this.total = response.total;
|
||||||
|
this.loading = false;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
/** 搜索按钮操作 */
|
||||||
|
handleQuery() {
|
||||||
|
this.queryParams.pageNum = 1;
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
/** 重置按钮操作 */
|
||||||
|
resetQuery() {
|
||||||
|
this.resetForm("queryForm");
|
||||||
|
this.handleQuery();
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.context-avatar-center {
|
||||||
|
display: flex;
|
||||||
|
align-items: center; /* 垂直居中 */
|
||||||
|
justify-content: center; /* 水平居中 */
|
||||||
|
}
|
||||||
|
</style>
|
||||||
Reference in New Issue
Block a user