添加日志记录
This commit is contained in:
@@ -1,51 +1,68 @@
|
||||
<template>
|
||||
<el-table :data="tableData" style="width: 100%">
|
||||
<el-table-column prop="date" label="用户" width="180"> </el-table-column>
|
||||
<el-table-column prop="name" label="操作" width="180"> </el-table-column>
|
||||
<el-table-column prop="address" label="操作内容"> </el-table-column>
|
||||
<el-table-column prop="address" label="相关信息"> </el-table-column>
|
||||
<div style="height:95%">
|
||||
<el-table :show-overflow-tooltip="true" :data="tableData" height="calc(100% - 100px)" style="width: 100%">
|
||||
<el-table-column prop="user" label="用户" width="180"
|
||||
:filters="[{ text: 'xuzongyang', value: 'xuzongyang' }, { text: 'wanyongkang', value: 'wanyongkang' }]"
|
||||
:filter-method="filterTag"
|
||||
> </el-table-column>
|
||||
<el-table-column prop="operation" label="操作" width="180"> </el-table-column>
|
||||
<el-table-column prop="record" label="操作内容"> </el-table-column>
|
||||
<el-table-column show-overflow-tooltip prop="create_time" label="操作时间"> </el-table-column>
|
||||
</el-table>
|
||||
<el-pagination
|
||||
background
|
||||
:current-page="pageNum"
|
||||
style="top:88%"
|
||||
layout="prev, pager, next"
|
||||
:page-size = "50"
|
||||
@prev-click="prev_page"
|
||||
@next-click="next_page"
|
||||
@current-change="handleCurrentChange"
|
||||
:total="count">
|
||||
</el-pagination>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
data () {
|
||||
return {
|
||||
tableData: [
|
||||
{
|
||||
date: "2016-05-02",
|
||||
name: "王小虎",
|
||||
address: "上海市普陀区金沙江路 1518 弄",
|
||||
},
|
||||
{
|
||||
date: "2016-05-04",
|
||||
name: "王小虎",
|
||||
address: "上海市普陀区金沙江路 1517 弄",
|
||||
},
|
||||
{
|
||||
date: "2016-05-01",
|
||||
name: "王小虎",
|
||||
address: "上海市普陀区金沙江路 1519 弄",
|
||||
},
|
||||
{
|
||||
date: "2016-05-03",
|
||||
name: "王小虎",
|
||||
address: "上海市普陀区金沙江路 1516 弄",
|
||||
},
|
||||
],
|
||||
};
|
||||
},
|
||||
|
||||
created() {
|
||||
this.$store.commit("setCurrentNav", "日志记录");
|
||||
this.getData();
|
||||
},
|
||||
methods: {
|
||||
getData(){
|
||||
this.$api.get("baseinfo/v1/user/page", this.searchModel).then(res => {
|
||||
console.log(res);
|
||||
});
|
||||
tableData: [],
|
||||
count: 0,
|
||||
pageNum: 1
|
||||
}
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
created () {
|
||||
this.$store.commit('setCurrentNav', '日志记录')
|
||||
this.getData()
|
||||
},
|
||||
methods: {
|
||||
getData () {
|
||||
this.$api.get('http://autophp.wyk/api/index/index').then(res => {
|
||||
this.tableData = res.data
|
||||
this.count = parseInt(res.count)
|
||||
})
|
||||
},
|
||||
prev_page () {
|
||||
this.$api.get('http://autophp.wyk/api/index/pageList', {page: this.pageNum}).then(res => {
|
||||
this.tableData = res.data
|
||||
})
|
||||
},
|
||||
next_page () {
|
||||
this.$api.get('http://autophp.wyk/api/index/pageList', {page: this.pageNum}).then(res => {
|
||||
this.tableData = res.data
|
||||
})
|
||||
},
|
||||
handleCurrentChange: function (currentPage) {
|
||||
this.pageNum = currentPage
|
||||
this.$api.get('http://autophp.wyk/api/index/pageList', {page: this.pageNum}).then(res => {
|
||||
this.tableData = res.data
|
||||
})
|
||||
},
|
||||
filterTag (value, row) {
|
||||
return row.user === value
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -190,15 +190,26 @@ export default {
|
||||
}
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.$store.commit("setCurrentNav", "会员管理>>账号管理");
|
||||
var userId = this.$route.query.userId;
|
||||
if (userId) this.searchModel.UserId = userId;
|
||||
this.get();
|
||||
this.getProductWithPackage();
|
||||
created () {
|
||||
this.$store.commit('setCurrentNav', '会员管理>>账号管理')
|
||||
var userId = this.$route.query.userId
|
||||
if (userId) this.searchModel.UserId = userId
|
||||
this.get()
|
||||
this.getProductWithPackage()
|
||||
// eslint-disable-next-line camelcase
|
||||
let user_info = this.$local.getUserByCache().Manager.RealName
|
||||
// eslint-disable-next-line camelcase
|
||||
if (userId) {
|
||||
this.$api.post('http://autophp.wyk/logs/index/clickInfo', {
|
||||
user: user_info,
|
||||
operation: '点击客户信息产品账号',
|
||||
record: '查看该客户的产品信息',
|
||||
userid: userId
|
||||
}).then(res => {})
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
search(){
|
||||
search () {
|
||||
this.searchModel.PageIndex=1;
|
||||
this.get();
|
||||
},
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
</router-link>
|
||||
<span class="handel cursor edit" @click="edit(scope.row)">编辑</span>
|
||||
<span class="handel cursor edit" @click="showAmountDetail(scope.row)">明细</span>
|
||||
<el-popover placement="bottom" trigger="hover" width="180">
|
||||
<el-popover @show="showHandle(scope.row)" placement="bottom" trigger="hover" width="180">
|
||||
<div class="popover_box">
|
||||
<span>QQ号:{{scope.row.QQ||'--'}}</span>
|
||||
<span>微信:{{scope.row.Wx||'--'}}</span>
|
||||
@@ -207,11 +207,19 @@ export default {
|
||||
}
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.$store.commit("setCurrentNav", "用户管理>>会员管理");
|
||||
var currentUser=this.$local.getUserByCache();
|
||||
this.IsRoot=currentUser.Manager.IsRootUser;
|
||||
this.get();
|
||||
created () {
|
||||
this.$store.commit('setCurrentNav', '用户管理>>会员管理')
|
||||
var currentUser = this.$local.getUserByCache()
|
||||
this.IsRoot = currentUser.Manager.IsRootUser
|
||||
this.get()
|
||||
|
||||
// eslint-disable-next-line camelcase
|
||||
let user_info = this.$local.getUserByCache().Manager.RealName
|
||||
this.$api.post('http://autophp.wyk/logs/index/clickVipInfo', {
|
||||
user: user_info,
|
||||
operation: '点击客户管理',
|
||||
record: '查询客户信息列表'
|
||||
}).then(res => {})
|
||||
},
|
||||
methods: {
|
||||
search(){
|
||||
@@ -301,14 +309,32 @@ export default {
|
||||
this.$api
|
||||
.get("baseinfo/v1/user/AmountDetail?userId=" + item.Id)
|
||||
.then(res => {
|
||||
this.detailAmountData = res.Data;
|
||||
this.detailAmountData = res.Data
|
||||
});
|
||||
},
|
||||
dataExport(){
|
||||
this.$api.getDownloadFile("/baseinfo/v1/user/Export");
|
||||
showHandle (r) {
|
||||
// eslint-disable-next-line camelcase
|
||||
let user_info = this.$local.getUserByCache().Manager.RealName
|
||||
this.$api.post('http://autophp.wyk/logs/index/hoveInfo', {
|
||||
user: user_info,
|
||||
operation: '点击客户信息会员价',
|
||||
record: '查看会员的产品价格',
|
||||
info: r.LoginCode
|
||||
}).then(res => {})
|
||||
},
|
||||
dataExport () {
|
||||
this.$api.getDownloadFile('/baseinfo/v1/user/Export')
|
||||
// eslint-disable-next-line camelcase
|
||||
let user_info = this.$local.getUserByCache().Manager.RealName
|
||||
this.$api.post('http://autophp.wyk/logs/index/export', {
|
||||
user: user_info,
|
||||
operation: '点击导出所有客户信息',
|
||||
record: '导出所有客户信息列表',
|
||||
info: '本次点击时间之前所有客户数据'
|
||||
}).then(res => {})
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
</script>
|
||||
<style scoped>
|
||||
</style>
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
type="primary"
|
||||
icon="el-icon-sold-out"
|
||||
v-if="$local.isRoot()"
|
||||
@click="dataExport"
|
||||
@click="dataExport"
|
||||
>导出</el-button>
|
||||
<!-- <el-button size="small" type="primary" icon="el-icon-sold-out" @click="dataExport" v-if="$local.isRoot()">导出</el-button> -->
|
||||
<div class="search-box">
|
||||
|
||||
@@ -135,6 +135,16 @@ export default {
|
||||
this.currentDiscount.userId=this.$route.query.id;
|
||||
this.get();
|
||||
this.getProductDiscounts();
|
||||
if (this.current.UserId) {
|
||||
// eslint-disable-next-line camelcase
|
||||
let user_info = this.$local.getUserByCache().Manager.RealName
|
||||
this.$api.post('http://autophp.wyk/logs/index/clickInfo', {
|
||||
user: user_info,
|
||||
operation: '点击客户信息会员价',
|
||||
record: '查看会员的产品价格',
|
||||
userid: this.current.UserId
|
||||
}).then(res => {})
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
get() {
|
||||
|
||||
Reference in New Issue
Block a user