xiala
This commit is contained in:
parent
6e46c063b9
commit
f45bdcdde6
Binary file not shown.
|
@ -96,8 +96,6 @@ export const asyncRoutes = [
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
// youpei 是只针对地坪项目新建的菜单
|
// youpei 是只针对地坪项目新建的菜单
|
||||||
{
|
{
|
||||||
path: '/youpei',
|
path: '/youpei',
|
||||||
|
@ -175,7 +173,7 @@ export const asyncRoutes = [
|
||||||
component: Layout,
|
component: Layout,
|
||||||
redirect: '/Qmanage/question',
|
redirect: '/Qmanage/question',
|
||||||
name: 'Qmanage',
|
name: 'Qmanage',
|
||||||
meta: { title: '题库管理', icon: 'table' },
|
meta: { title: '题库管理', icon: 'table', perms: ['qmanage'] },
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: 'subject',
|
path: 'subject',
|
||||||
|
@ -216,7 +214,7 @@ export const asyncRoutes = [
|
||||||
component: Layout,
|
component: Layout,
|
||||||
redirect: '/sjmanage/workscope',
|
redirect: '/sjmanage/workscope',
|
||||||
name: 'Sjmanage',
|
name: 'Sjmanage',
|
||||||
meta: { title: '出卷管理', icon: 'component', perms: [] },
|
meta: { title: '出卷管理', icon: 'component', perms: ['workscope'] },
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: 'testrule',
|
path: 'testrule',
|
||||||
|
@ -285,7 +283,7 @@ export const asyncRoutes = [
|
||||||
component: Layout,
|
component: Layout,
|
||||||
redirect: '/exammanage/index',
|
redirect: '/exammanage/index',
|
||||||
name: 'Exammanage',
|
name: 'Exammanage',
|
||||||
meta: { title: '考证管理', icon: 'component' },
|
meta: { title: '考证管理', icon: 'component', perms: ['exammanage'] },
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: 'index',
|
path: 'index',
|
||||||
|
@ -306,7 +304,7 @@ export const asyncRoutes = [
|
||||||
component: Layout,
|
component: Layout,
|
||||||
redirect: '/threshold/source',
|
redirect: '/threshold/source',
|
||||||
name: 'Threshold',
|
name: 'Threshold',
|
||||||
meta: { title: '阈值库', icon: 'component', perms: ['threshold_view']},
|
meta: { title: '阈值库', icon: 'component', perms: ['threshold_view'] },
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: 'source',
|
path: 'source',
|
||||||
|
@ -364,7 +362,7 @@ export const asyncRoutes = [
|
||||||
component: Layout,
|
component: Layout,
|
||||||
redirect: '/system/admin',
|
redirect: '/system/admin',
|
||||||
name: 'System',
|
name: 'System',
|
||||||
meta: { title: '系统管理', icon: 'tree', perms: [] },
|
meta: { title: '系统管理', icon: 'tree', perms: ['system_admin'] },
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: 'banner',
|
path: 'banner',
|
||||||
|
@ -404,14 +402,14 @@ export const asyncRoutes = [
|
||||||
component: Layout,
|
component: Layout,
|
||||||
redirect: '/changepassword',
|
redirect: '/changepassword',
|
||||||
name: 'ChangePW',
|
name: 'ChangePW',
|
||||||
meta: { title: '修改密码', icon: 'tree' },
|
meta: { title: '修改密码', icon: 'tree', perms: ['change_password'] },
|
||||||
hidden: true,
|
hidden: true,
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: '',
|
path: '',
|
||||||
name: 'ChangePassword',
|
name: 'ChangePassword',
|
||||||
component: () => import('@/views/system/changepassword'),
|
component: () => import('@/views/system/changepassword'),
|
||||||
meta: { title: '修改密码', noCache: true, icon: '' },
|
meta: { title: '修改密码', noCache: true, icon: '', perms: ['change_password'] },
|
||||||
hidden: true
|
hidden: true
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
|
@ -49,11 +49,11 @@ const actions = {
|
||||||
generateRoutes({ commit }, perms) {
|
generateRoutes({ commit }, perms) {
|
||||||
return new Promise(resolve => {
|
return new Promise(resolve => {
|
||||||
let accessedRoutes
|
let accessedRoutes
|
||||||
if (perms.includes('admin')) {
|
// if (perms.includes('admin')) {
|
||||||
accessedRoutes = asyncRoutes || []
|
// accessedRoutes = asyncRoutes || []
|
||||||
} else {
|
// } else {
|
||||||
accessedRoutes = filterAsyncRoutes(asyncRoutes, perms)
|
accessedRoutes = filterAsyncRoutes(asyncRoutes, perms)
|
||||||
}
|
// }
|
||||||
commit('SET_ROUTES', accessedRoutes)
|
commit('SET_ROUTES', accessedRoutes)
|
||||||
resolve(accessedRoutes)
|
resolve(accessedRoutes)
|
||||||
})
|
})
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="app-container">
|
<div class="app-container">
|
||||||
<div style="margin-top:10px">
|
<div style="margin-top:10px">
|
||||||
|
<!--
|
||||||
<el-select
|
<el-select
|
||||||
v-model="listQuery.is_pass"
|
v-model="listQuery.is_pass"
|
||||||
placeholder="是否通过"
|
placeholder="是否通过"
|
||||||
|
@ -30,7 +31,7 @@
|
||||||
:label="item.label"
|
:label="item.label"
|
||||||
:value="item.value"
|
:value="item.value"
|
||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select> -->
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="value"
|
v-model="value"
|
||||||
type="daterange"
|
type="daterange"
|
||||||
|
|
|
@ -346,20 +346,7 @@
|
||||||
<el-input v-model="consumer.ID_number1" placeholder="身份证号" />
|
<el-input v-model="consumer.ID_number1" placeholder="身份证号" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="头像" prop="avatar">
|
|
||||||
<el-upload
|
|
||||||
class="avatar-uploader"
|
|
||||||
:action="upUrl"
|
|
||||||
accept="image/jpeg, image/gif, image/png, image/bmp"
|
|
||||||
:show-file-list="false"
|
|
||||||
:on-success="handleAvatarSuccess"
|
|
||||||
:before-upload="beforeAvatarUpload"
|
|
||||||
:headers="upHeaders"
|
|
||||||
>
|
|
||||||
<img v-if="consumer.avatar" :src="consumer.avatar" class="avatar">
|
|
||||||
<i v-else class="el-icon-plus avatar-uploader-icon" />
|
|
||||||
</el-upload>
|
|
||||||
</el-form-item>
|
|
||||||
</el-form>
|
</el-form>
|
||||||
<div style="text-align:right;">
|
<div style="text-align:right;">
|
||||||
<el-button type="danger" @click="dialogVisible=false">取消</el-button>
|
<el-button type="danger" @click="dialogVisible=false">取消</el-button>
|
||||||
|
@ -537,16 +524,7 @@ export default {
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
checkPermission,
|
checkPermission,
|
||||||
handleAvatarSuccess(res, file) {
|
|
||||||
this.consumer.avatar = res.data.path
|
|
||||||
},
|
|
||||||
beforeAvatarUpload(file) {
|
|
||||||
const isLt2M = file.size / 1024 / 1024 < 2
|
|
||||||
if (!isLt2M) {
|
|
||||||
this.$message.error('上传图片大小不能超过 2MB!')
|
|
||||||
}
|
|
||||||
return isLt2M
|
|
||||||
},
|
|
||||||
handleUploadSuccess(res, file) {
|
handleUploadSuccess(res, file) {
|
||||||
if (res.code == 200) {
|
if (res.code == 200) {
|
||||||
const loading = this.$loading({ text: '正在导入中...' })
|
const loading = this.$loading({ text: '正在导入中...' })
|
||||||
|
|
|
@ -279,11 +279,11 @@ this.$confirm("确认删除该考试记录吗?将丢失数据!", "警告", {
|
||||||
}else{
|
}else{
|
||||||
this.listQuery.ordering = '-' + val.prop
|
this.listQuery.ordering = '-' + val.prop
|
||||||
}
|
}
|
||||||
|
|
||||||
this.getList()
|
this.getList()
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<template>
|
<template>
|
||||||
<el-container>
|
<el-container>
|
||||||
<el-header>
|
<el-header style="height: 90px;">
|
||||||
<div style="margin-top: 10px;">
|
<div style="margin-top: 10px;">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="listQuery.search"
|
v-model="listQuery.search"
|
||||||
|
@ -18,16 +18,17 @@
|
||||||
@click="resetFilter"
|
@click="resetFilter"
|
||||||
>刷新重置</el-button>
|
>刷新重置</el-button>
|
||||||
</div>
|
</div>
|
||||||
<div style="margin-top:10px">
|
<div style="margin-top: 10px;" >
|
||||||
<el-button type="primary" icon="el-icon-plus" @click="handleCreate('文档')">文档</el-button>
|
<el-button type="primary" icon="el-icon-plus" @click="handleCreate('文档')">文档</el-button>
|
||||||
<el-button type="primary" icon="el-icon-plus" @click="handleCreate('视频')">视频</el-button>
|
<el-button type="primary" icon="el-icon-plus" @click="handleCreate('视频')">视频</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-header>
|
</el-header>
|
||||||
<el-main>
|
<el-main>
|
||||||
|
|
||||||
<el-table
|
<el-table
|
||||||
v-loading="listLoading"
|
v-loading="listLoading"
|
||||||
:data="materialList.results"
|
:data="materialList.results"
|
||||||
style="width: 100%;margin-top:30px;"
|
style="width: 100%;"
|
||||||
border
|
border
|
||||||
max-height="600"
|
max-height="600"
|
||||||
>
|
>
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
<el-input v-model="Form.elink" style="width: 80%" />
|
<el-input v-model="Form.elink" style="width: 80%" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item v-show="is_show" label="内容" prop="content">
|
<el-form-item label="内容" prop="content">
|
||||||
<tinymce v-model="Form.content" :height="400" width="80%" />
|
<tinymce v-model="Form.content" :height="400" width="80%" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
|
|
|
@ -37,14 +37,12 @@
|
||||||
type="primary"
|
type="primary"
|
||||||
size="small"
|
size="small"
|
||||||
icon="el-icon-edit"
|
icon="el-icon-edit"
|
||||||
:disabled="!checkPermission(['article_update'])"
|
|
||||||
@click="handleEdit(scope)"
|
@click="handleEdit(scope)"
|
||||||
/>
|
/>
|
||||||
<el-button
|
<el-button
|
||||||
type="danger"
|
type="danger"
|
||||||
size="small"
|
size="small"
|
||||||
icon="el-icon-delete"
|
icon="el-icon-delete"
|
||||||
:disabled="!checkPermission(['article_delete'])"
|
|
||||||
@click="handleDelete(scope)"
|
@click="handleDelete(scope)"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
@ -117,8 +115,7 @@
|
||||||
type="danger"
|
type="danger"
|
||||||
size="small"
|
size="small"
|
||||||
icon="el-icon-delete"
|
icon="el-icon-delete"
|
||||||
:disabled="!checkPermission(['article_delete'])"
|
@click="handleDelete2(scope)"
|
||||||
@click="handleDelete(scope)"
|
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
@ -333,6 +330,26 @@ export default {
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
handleDelete2(scope) {
|
||||||
|
this.$confirm('确认删数据吗?将丢失数据!', '警告', {
|
||||||
|
confirmButtonText: '确认',
|
||||||
|
cancelButtonText: '取消',
|
||||||
|
type: 'error'
|
||||||
|
})
|
||||||
|
.then(async() => {
|
||||||
|
await deleteChildcomany(scope.row.id)
|
||||||
|
this.getList2()
|
||||||
|
this.getList()
|
||||||
|
this.$message({
|
||||||
|
type: 'success',
|
||||||
|
message: '成功删除!'
|
||||||
|
})
|
||||||
|
})
|
||||||
|
// eslint-disable-next-line handle-callback-err
|
||||||
|
.catch(err => {
|
||||||
|
// console.error(err);
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue