刘翔宇-旅管家 3 years ago
parent 38a4749bb1
commit 030ce888cc

@ -28,10 +28,11 @@ router.beforeEach(async (to, from, next) => {
if (hasToken) { if (hasToken) {
if (to.path === '/login') { if (to.path === '/login') {
// if is logged in, redirect to the home page // if is logged in, redirect to the home page
next({
path: '/' await store.dispatch('user/resetToken');
}) next(to.fullPath)
NProgress.done() NProgress.done()
} else { } else {
// determine whether the user has obtained his permission roles through getInfo // determine whether the user has obtained his permission roles through getInfo

@ -17,8 +17,6 @@
<el-option v-for="item in selects.areasList" :key="item.id" :label="item.name" :value="item.id"> <el-option v-for="item in selects.areasList" :key="item.id" :label="item.name" :value="item.id">
</el-option> </el-option>
</el-select> </el-select>
<el-select class="vm10" filterable v-model="searchFields.status" placeholder="请选择状态"> <el-select class="vm10" filterable v-model="searchFields.status" placeholder="请选择状态">
<el-option v-for="item in selects.statusList" :key="item.id" :label="item.name" :value="item.id"> <el-option v-for="item in selects.statusList" :key="item.id" :label="item.name" :value="item.id">
</el-option> </el-option>
@ -97,6 +95,9 @@
<!-- <div v-if="column.field=='ask_content_detail'">{{scope.row[column.field]?scope.row[column.field].value:""}}</div> <!-- <div v-if="column.field=='ask_content_detail'">{{scope.row[column.field]?scope.row[column.field].value:""}}</div>
<div v-else></div> --> <div v-else></div> -->
</div> </div>
<div v-else-if="column.type=='admin'">
{{getUserName(scope.row)}}
</div>
<!-- <div v-else-if="column.type=='end_type'"> <!-- <div v-else-if="column.type=='end_type'">
<el-tag v-if="scope.row[column.field]==0"></el-tag> <el-tag v-if="scope.row[column.field]==0"></el-tag>
<el-tag type="danger" v-if="scope.row[column.field]==1" >违法转办</el-tag> <el-tag type="danger" v-if="scope.row[column.field]==1" >违法转办</el-tag>
@ -1052,9 +1053,9 @@
}, },
{ {
field: "admin", field: "userName",
title: "提交人", title: "提交人",
type: "format", type: "admin",
align: "center", align: "center",
width: 180 width: 180
}, },
@ -1104,6 +1105,16 @@
} }
}, },
methods: { methods: {
getUserName(row) {
if (row.admin) {
return row.admin.name;
} else if (row.user) {
return row.user.name;
} else {
return "未知";
}
},
handleSelectionChange(val) { handleSelectionChange(val) {
console.log(val) console.log(val)
this.reviewList = val this.reviewList = val

@ -74,6 +74,9 @@
<!-- <div v-if="column.field=='ask_content_detail'">{{scope.row[column.field]?scope.row[column.field].value:""}}</div> <!-- <div v-if="column.field=='ask_content_detail'">{{scope.row[column.field]?scope.row[column.field].value:""}}</div>
<div v-else></div> --> <div v-else></div> -->
</div> </div>
<div v-else-if="column.type=='admin'">
{{getUserName(scope.row)}}
</div>
<!-- <div v-else-if="column.type=='end_type'"> <!-- <div v-else-if="column.type=='end_type'">
<el-tag v-if="scope.row[column.field]==0"></el-tag> <el-tag v-if="scope.row[column.field]==0"></el-tag>
<el-tag type="danger" v-if="scope.row[column.field]==1" >违法转办</el-tag> <el-tag type="danger" v-if="scope.row[column.field]==1" >违法转办</el-tag>
@ -624,9 +627,9 @@
width: 180 width: 180
}, },
{ {
field: "admin", field: "userName",
title: "提交人", title: "提交人",
type: "format", type: "admin",
align: "center", align: "center",
width: 180 width: 180
}, },
@ -655,6 +658,16 @@
watch: { watch: {
}, },
methods: { methods: {
getUserName(row) {
if (row.admin) {
return row.admin.name;
} else if (row.user) {
return row.user.name;
} else {
return "未知";
}
},
initLoad() { initLoad() {
var that = this; var that = this;
var clientHeight = document.documentElement.clientHeight var clientHeight = document.documentElement.clientHeight

@ -52,6 +52,9 @@
<div v-else-if="column.type=='format'"> <div v-else-if="column.type=='format'">
{{scope.row[column.field]?scope.row[column.field].name:""}} {{scope.row[column.field]?scope.row[column.field].name:""}}
</div> </div>
<div v-else-if="column.type=='admin'">
{{getUserName(scope.row)}}
</div>
<!-- <div v-else-if="column.type=='end_type'"> <!-- <div v-else-if="column.type=='end_type'">
<el-tag v-if="scope.row[column.field]==0"></el-tag> <el-tag v-if="scope.row[column.field]==0"></el-tag>
<el-tag type="danger" v-if="scope.row[column.field]==1" >违法转办</el-tag> <el-tag type="danger" v-if="scope.row[column.field]==1" >违法转办</el-tag>
@ -619,6 +622,16 @@
}, },
methods: { methods: {
getUserName(row) {
if (row.admin) {
return row.admin.name;
} else if (row.user) {
return row.user.name;
} else {
return "未知";
}
},
initLoad() { initLoad() {
var that = this; var that = this;
var clientHeight = document.documentElement.clientHeight var clientHeight = document.documentElement.clientHeight

Loading…
Cancel
Save