Commit 5fd9a9dc authored by FangYuePeng's avatar FangYuePeng

Merge remote-tracking branch 'origin/1.0' into 1.0

parents e28e1f59 f5e90b8a
...@@ -155,4 +155,12 @@ export function transformDept(data) { ...@@ -155,4 +155,12 @@ export function transformDept(data) {
}) })
} }
// 17.查询所属部门
export function listAllDept(query) {
return request({
url: '/system/dept/listAll',
method: 'get',
params: query
})
}
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
<div class="search" style="border-bottom: 14px solid #f4f4f4"> <div class="search" style="border-bottom: 14px solid #f4f4f4">
<el-form ref="queryForm" style="padding: 0 0 0 10px" :model="queryParams" :inline="true"> <el-form ref="queryForm" style="padding: 0 0 0 10px" :model="queryParams" :inline="true">
<el-form-item label="课程名称" prop="lessonName"> <el-form-item label="课程名称" prop="lessonName">
<el-input v-model="queryParams.lessonName" placeholder="课程名称" :maxlength="15" style="margin-right: 15px" /> <el-input v-model="queryParams.lessonName" placeholder="课程名称" :maxlength="15" style="width: 200px" />
</el-form-item> </el-form-item>
<!-- 课程方案--> <!-- 课程方案-->
<el-form-item label="课程方案" prop="classPlan"> <el-form-item label="课程方案" prop="classPlan">
...@@ -72,7 +72,7 @@ ...@@ -72,7 +72,7 @@
<el-form-item label="首页显示" prop="homeDisplay"> <el-form-item label="首页显示" prop="homeDisplay">
<el-select v-model="queryParams.homeDisplay" placeholder="首页显示" clearable> <el-select v-model="queryParams.homeDisplay" placeholder="首页显示" clearable>
<el-option <el-option
v-for="item in homeDisplay" v-for="item in homeDisplayList"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"
...@@ -83,8 +83,8 @@ ...@@ -83,8 +83,8 @@
<el-form-item label="企业精品课" prop="entQualityLesson"> <el-form-item label="企业精品课" prop="entQualityLesson">
<el-select v-model="queryParams.entQualityLesson" placeholder="企业精品课" clearable> <el-select v-model="queryParams.entQualityLesson" placeholder="企业精品课" clearable>
<el-option <el-option
v-for="item in entQualityLesson" v-for="(item,index) in entQualityLessonList"
:key="item.value" :key="index"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"
/> />
...@@ -94,7 +94,7 @@ ...@@ -94,7 +94,7 @@
<el-form-item label="院校精品课" prop="schoolQualityLesson"> <el-form-item label="院校精品课" prop="schoolQualityLesson">
<el-select v-model="queryParams.schoolQualityLesson" placeholder="院校精品课" clearable> <el-select v-model="queryParams.schoolQualityLesson" placeholder="院校精品课" clearable>
<el-option <el-option
v-for="item in entQualityLesson" v-for="item in entQualityLessonList"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"
...@@ -279,7 +279,7 @@ ...@@ -279,7 +279,7 @@
<span>{{ scope.row.id }}</span> <span>{{ scope.row.id }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="封面" prop="defaultUrl"> <el-table-column align="center" min-width="120px" label="封面" prop="defaultUrl">
<template slot-scope="scope"> <template slot-scope="scope">
<div :id="step(scope.$index)"> <div :id="step(scope.$index)">
<el-image <el-image
...@@ -303,27 +303,27 @@ ...@@ -303,27 +303,27 @@
<span>{{ scope.row.classHour }}</span> <span>{{ scope.row.classHour }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="课程方案" prop="classPlan" :show-overflow-tooltip="true"> <el-table-column align="center" label="课程方案" prop="classPlan" min-width="120px" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ getCoursePlanName( scope.row.classPlan) }}</span> <span>{{ getCoursePlanName( scope.row.classPlan) }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="岗位分类" prop="jobClassify" :show-overflow-tooltip="true"> <el-table-column align="center" label="岗位分类" prop="jobClassify" min-width="120px" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ getJobClassificationName(scope.row.jobClassify) }}</span> <span>{{ getJobClassificationName(scope.row.jobClassify) }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="技术分类" prop="tecClassify" :show-overflow-tooltip="true"> <el-table-column align="center" label="技术分类" prop="tecClassify" min-width="120px" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ getCourseDirectionName(scope.row.tecClassify) }}</span> <span>{{ getCourseDirectionName(scope.row.tecClassify) }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="难度等级" prop="difficultyClassify" :show-overflow-tooltip="true"> <el-table-column align="center" label="难度等级" prop="difficultyClassify" min-width="120px" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ getDifficultyLevelName(scope.row.difficultyClassify) }}</span> <span>{{ getDifficultyLevelName(scope.row.difficultyClassify) }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="一句话介绍" prop="lessonBrief" :show-overflow-tooltip="true"> <el-table-column align="center" label="一句话介绍" prop="lessonBrief" min-width="200px" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.lessonBrief }}</span> <span>{{ scope.row.lessonBrief }}</span>
</template> </template>
...@@ -335,7 +335,7 @@ ...@@ -335,7 +335,7 @@
</template> </template>
</el-table-column> </el-table-column>
<!-- 价格--> <!-- 价格-->
<el-table-column align="center" label="价格" prop="lessonPrice" :show-overflow-tooltip="true"> <el-table-column align="center" label="价格(元)" prop="lessonPrice" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.lessonPrice }}</span> <span>{{ scope.row.lessonPrice }}</span>
</template> </template>
...@@ -360,7 +360,7 @@ ...@@ -360,7 +360,7 @@
/> />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="企业精品课" prop="entQualityLesson" :show-overflow-tooltip="true"> <el-table-column align="center" label="企业精品课" prop="entQualityLesson" min-width="100px" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<el-switch <el-switch
v-model="entQualityLesson" v-model="entQualityLesson"
...@@ -370,7 +370,7 @@ ...@@ -370,7 +370,7 @@
/> />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="院校精品课" prop="schoolQualityLesson" :show-overflow-tooltip="true"> <el-table-column align="center" label="院校精品课" prop="schoolQualityLesson" min-width="100px" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<el-switch <el-switch
v-model="schoolQualityLesson" v-model="schoolQualityLesson"
...@@ -380,7 +380,7 @@ ...@@ -380,7 +380,7 @@
/> />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="课程介绍" prop="lessonDescription" :show-overflow-tooltip="true"> <el-table-column align="left" label="课程介绍" prop="lessonDescription" min-width="150px" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.lessonDescription }}</span> <span>{{ scope.row.lessonDescription }}</span>
</template> </template>
...@@ -404,17 +404,16 @@ ...@@ -404,17 +404,16 @@
:type="commonField.typeParent" :type="commonField.typeParent"
:size="commonField.size" :size="commonField.size"
@click="handleExamination(scope.row)" @click="handleExamination(scope.row)"
>试管理</el-button> ></el-button>
<el-button <el-button
:class="commonField.updateClass" :class="commonField.updateClass"
:type="commonField.typeParent" :type="commonField.typeParent"
:size="commonField.size" :size="commonField.size"
@click="removeCourse(scope.$index)" @click="removeCourse(scope.row)"
>删除</el-button> >删除</el-button>
<!-- <el-button type="text" @click="resetcover(scope.$index)" >恢复封面</el-button>--> <!-- <el-button type="text" @click="resetcover(scope.$index)" >恢复封面</el-button>-->
<!-- <el-button type="text" @click="removeCourse(scope.$index)">删除</el-button>--> <!-- <el-button type="text" @click="removeCourse(scope.$index)">删除</el-button>-->
</template> </template>
</el-table-column>
</el-table-column></el-table> </el-table-column></el-table>
</div> </div>
<pagination <pagination
...@@ -554,8 +553,8 @@ export default { ...@@ -554,8 +553,8 @@ export default {
}, },
// 课程状态list // 课程状态list
courseStatus: [ courseStatus: [
{ value: '0', label: '已发布' }, { value: '1', label: '已发布' },
{ value: '1', label: '未发布' } { value: '0', label: '未发布' }
], ],
// 课程方向 // 课程方向
courseDirection: [], courseDirection: [],
...@@ -584,12 +583,12 @@ export default { ...@@ -584,12 +583,12 @@ export default {
totalStuHours: 0 totalStuHours: 0
}, },
// 是否首页显示list // 是否首页显示list
homeDisplay: [ homeDisplayList: [
{ value: '0', label: '显示' }, { value: '0', label: '显示' },
{ value: '1', label: '未显示' } { value: '1', label: '未显示' }
], ],
// 是否企业精品课list // 是否企业精品课list
entQualityLesson: [ entQualityLessonList: [
{ value: '0', label: '是' }, { value: '0', label: '是' },
{ value: '1', label: '否' } { value: '1', label: '否' }
], ],
...@@ -615,7 +614,9 @@ export default { ...@@ -615,7 +614,9 @@ export default {
teacherName: '', teacherName: '',
lessonPrice: '', lessonPrice: '',
homeDisplay: '', homeDisplay: '',
flag: '' flag: '',
schoolQualityLesson: '',
entQualityLesson: ''
}, },
coursePlanOptions: [], coursePlanOptions: [],
// pagination // pagination
...@@ -748,35 +749,37 @@ export default { ...@@ -748,35 +749,37 @@ export default {
lessonPrice: _this.queryParams.lessonPrice, lessonPrice: _this.queryParams.lessonPrice,
homeDisplay: _this.queryParams.homeDisplay, homeDisplay: _this.queryParams.homeDisplay,
flag: _this.queryParams.flag, flag: _this.queryParams.flag,
schoolQualityLesson: _this.queryParams.schoolQualityLesson,
entQualityLesson: _this.queryParams.entQualityLesson,
sort: 'create_date desc' sort: 'create_date desc'
} }
queryBLessonsByPagination(params).then(res => { queryBLessonsByPagination(params).then(res => {
var pages = res.rows// 查询过来的每页数据 var pages = res.rows// 查询过来的每页数据
_this.total = res.total// 总记录数 _this.total = res.total// 总记录数
_this.bussid = [] _this.bussid = []
// for (let i = 0; i < pages.length; i++) { for (let i = 0; i < pages.length; i++) {
// var obj = {} var obj = {}
// obj.id = i + 1 obj.id = i + 1
// obj.tcode = pages[i].code obj.tcode = pages[i].code
// obj.tlessonName = pages[i].lessonName obj.tlessonName = pages[i].lessonName
// obj.bussinessId = pages[i].businessId obj.bussinessId = pages[i].businessId
// obj.tname = pages[i].name obj.tname = pages[i].name
// obj.tsex = (pages[i].sex == '1') ? '女' : '男' obj.tsex = (pages[i].sex == '1') ? '女' : '男'
// obj.imageSrc = pages[i].defaultUrl ? pages[i].defaultUrl : require('@/assets/image/test.png') obj.imageSrc = pages[i].defaultUrl ? pages[i].defaultUrl : require('@/assets/image/test.png')
// obj.srclist = [] obj.srclist = []
// obj.srclist.push(obj.imageSrc) obj.srclist.push(obj.imageSrc)
// obj.directionId = pages[i].directionId obj.directionId = pages[i].directionId
// obj.directionName = pages[i].directionName obj.directionName = pages[i].directionName
// obj.directionCode = pages[i].directionCode obj.directionCode = pages[i].directionCode
// obj.classHour = pages[i].classHour obj.classHour = pages[i].classHour
// obj.chapterClassHour = pages[i].chapterClassHour obj.chapterClassHour = pages[i].chapterClassHour
// obj.credits = pages[i].credits obj.credits = pages[i].credits
// obj.credit = pages[i].credits obj.credit = pages[i].credits
// obj.totalStuHours = pages[i].classHour obj.totalStuHours = pages[i].classHour
// _this.bussid.push(pages[i].businessId) _this.bussid.push(pages[i].businessId)
// // obj.imageSrc="http://imgsrc.baidu.com/image/c0%3Dshijue1%2C0%2C0%2C294%2C40/sign=60aeee5da74bd11310c0bf7132c6ce7a/72f082025aafa40fe3c0c4f3a164034f78f0199d.jpg"; obj.imageSrc = 'http://imgsrc.baidu.com/image/c0%3Dshijue1%2C0%2C0%2C294%2C40/sign=60aeee5da74bd11310c0bf7132c6ce7a/72f082025aafa40fe3c0c4f3a164034f78f0199d.jpg'
// data[i] = obj data[i] = obj
// } }
_this.tableData = pages _this.tableData = pages
console.log('tableData', _this.tableData) console.log('tableData', _this.tableData)
_this.fullscreenLoading = false _this.fullscreenLoading = false
...@@ -1157,7 +1160,8 @@ export default { ...@@ -1157,7 +1160,8 @@ export default {
this.loadData() this.loadData()
}, },
// search // search
removeCourse(index) { removeCourse(row) {
// console.log('index111111111111111111', index)
var that = this var that = this
this.$confirm('确定要删除吗?', '提示', { this.$confirm('确定要删除吗?', '提示', {
...@@ -1167,14 +1171,14 @@ export default { ...@@ -1167,14 +1171,14 @@ export default {
}).then(() => { }).then(() => {
that.fullscreenLoading = true that.fullscreenLoading = true
const params = { const params = {
id: that.bussid[index] id: row.businessId
} }
blessonRemove(params).then(response => { blessonRemove(params).then(response => {
that.fullscreenLoading = false that.fullscreenLoading = false
// alert(JSON.stringify(response)); // alert(JSON.stringify(response));
var type = response.code var type = response.code
var message = response.message var message = response.message
type = (type == 200 && message == '操作成功') ? 'success' : 'error' type = (type === 200 && message === '操作成功') ? 'success' : 'error'
that.$notify({ that.$notify({
title: '成功', title: '成功',
message: message, message: message,
...@@ -1212,9 +1216,9 @@ export default { ...@@ -1212,9 +1216,9 @@ export default {
}, },
//* ************目录*************// //* ************目录*************//
loadCurCat(index) { loadCurCat(index) {
console.log('什么玩意', this.bussid[index])
this.showSwitch.courseContent = false this.showSwitch.courseContent = false
this.showSwitch.curCat = true this.showSwitch.curCat = true
this.curCatForm.id = this.bussid[index] this.curCatForm.id = this.bussid[index]
this.curCatForm.totalStuHours = this.tableData[index].totalStuHours this.curCatForm.totalStuHours = this.tableData[index].totalStuHours
this.curCatForm.tlessonName = this.tableData[index].tlessonName this.curCatForm.tlessonName = this.tableData[index].tlessonName
......
...@@ -73,7 +73,8 @@ ...@@ -73,7 +73,8 @@
<div style="padding:5px 10px"> <div style="padding:5px 10px">
<div class="tableTitle">角色管理列表</div> <div class="tableTitle">角色管理列表</div>
<el-table v-loading="loading" border :data="roleList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" border :data="roleList" @selection-change="handleSelectionChange">
<el-table-column type="index" label="角色编号" width="120" /> <el-table-column type="index" label="序号" width="50" />
<el-table-column label="角色编号" prop="number"></el-table-column>
<el-table-column label="角色名称" prop="roleName" :show-overflow-tooltip="true"> <el-table-column label="角色名称" prop="roleName" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.roleName || '-' }} {{ scope.row.roleName || '-' }}
...@@ -96,7 +97,7 @@ ...@@ -96,7 +97,7 @@
</el-table-column> </el-table-column>
<el-table-column label="更新时间" :show-overflow-tooltip="true" align="center" prop="createTime"> <el-table-column label="更新时间" :show-overflow-tooltip="true" align="center" prop="createTime">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.createDate | transformDateByFormat('YYYY-MM-DD HH:mm') }}</span> <span>{{ scope.row.updateDate | transformDateByFormat('YYYY-MM-DD HH:mm') }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="操作" class-name="small-padding fixed-width" width="200px"> <el-table-column label="操作" class-name="small-padding fixed-width" width="200px">
......
...@@ -12,6 +12,36 @@ ...@@ -12,6 +12,36 @@
style="width: 150px" style="width: 150px"
/> />
</el-form-item> </el-form-item>
<el-form-item label="所属单位" prop="belongDeptId">
<el-select v-model="queryParams.belongDeptId" filterable placeholder="请选择" style="width: 150px">
<el-option
v-for="(item,index) in deptList"
:key="index"
:label="item.deptName"
:value="item.businessId"
/>
</el-select>
</el-form-item>
<el-form-item label="手机号" prop="phone">
<el-input
v-model="queryParams.phone"
placeholder="手机号"
clearable
:maxlength="30"
size="small"
style="width: 150px"
/>
</el-form-item>
<el-form-item label="角色" prop="roleId">
<el-select v-model="queryParams.roleId" placeholder="请选择" style="width: 150px">
<el-option
v-for="item in options"
:key="item.businessId"
:label="item.roleName"
:value="item.businessId"
/>
</el-select>
</el-form-item>
<el-form-item label="状态" prop="flag"> <el-form-item label="状态" prop="flag">
<el-select <el-select
v-model="queryParams.flag" v-model="queryParams.flag"
...@@ -45,40 +75,42 @@ ...@@ -45,40 +75,42 @@
@click="resetQuery" @click="resetQuery"
>{{ commonField.resetName }}</el-button> >{{ commonField.resetName }}</el-button>
</el-form-item> </el-form-item>
<el-form-item style="float: right"> <div style="text-align: end;">
<!-- <el-button--> <el-form-item>
<!-- :class="commonField.addClass"--> <!-- <el-button-->
<!-- :type="commonField.typePrimary"--> <!-- :class="commonField.addClass"-->
<!-- @click="handleTest"--> <!-- :type="commonField.typePrimary"-->
<!-- >图片预览测试</el-button>--> <!-- @click="handleTest"-->
<!-- //新增按钮--> <!-- >图片预览测试</el-button>-->
<el-button <!-- //新增按钮-->
v-hasPermi="hasAddPerm" <el-button
:class="commonField.addClass" v-hasPermi="hasAddPerm"
:type="commonField.typePrimary" :class="commonField.addClass"
:icon="commonField.addIcon" :type="commonField.typePrimary"
:size="commonField.smallSize" :icon="commonField.addIcon"
@click="handleAdd" :size="commonField.smallSize"
>{{ commonField.addName }}</el-button> @click="handleAdd"
<!-- //导入按钮--> >{{ commonField.addName }}</el-button>
<el-button <!-- //导入按钮-->
v-hasPermi="hasImportPerm" <el-button
:class="commonField.importClass" v-hasPermi="hasImportPerm"
:type="commonField.typeWarning" :class="commonField.importClass"
:icon="commonField.importIcon" :type="commonField.typeWarning"
:size="commonField.smallSize" :icon="commonField.importIcon"
@click="handleImport" :size="commonField.smallSize"
>{{ commonField.importName }}</el-button> @click="handleImport"
<!-- //导出--> >{{ commonField.importName }}</el-button>
<el-button <!-- //导出-->
v-hasPermi="hasExportPerm" <el-button
:class="commonField.exportClass" v-hasPermi="hasExportPerm"
:type="commonField.typeSuccess" :class="commonField.exportClass"
:icon="commonField.exportIcon" :type="commonField.typeSuccess"
:size="commonField.smallSize" :icon="commonField.exportIcon"
@click="handleExport" :size="commonField.smallSize"
>{{ commonField.exportName }}</el-button> @click="handleExport"
</el-form-item> >{{ commonField.exportName }}</el-button>
</el-form-item>
</div>
</el-form> </el-form>
</div> </div>
<div style="padding:5px 10px"> <div style="padding:5px 10px">
...@@ -89,11 +121,13 @@ ...@@ -89,11 +121,13 @@
:data="userList" :data="userList"
> >
<el-table-column type="index" label="序号" width="90" /> <el-table-column type="index" label="序号" width="90" />
<!-- <el-table-column label="用户类型" prop="username" :show-overflow-tooltip="true">--> <el-table-column label="用户类型" prop="identity" :show-overflow-tooltip="true">
<!-- <template slot-scope="scope">--> <template slot-scope="scope">
<!-- {{ scope.row.username || '-' }}--> <span v-if="scope.row.identity === 1">管理员</span>
<!-- </template>--> <span v-if="scope.row.identity === 2">单位用户</span>
<!-- </el-table-column>--> <span v-if="scope.row.identity === 3">个人用户</span>
</template>
</el-table-column>
<el-table-column label="登录名" prop="username" :show-overflow-tooltip="true"> <el-table-column label="登录名" prop="username" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.username || '-' }} {{ scope.row.username || '-' }}
...@@ -104,11 +138,11 @@ ...@@ -104,11 +138,11 @@
{{ scope.row.name || '-' }} {{ scope.row.name || '-' }}
</template> </template>
</el-table-column> </el-table-column>
<!-- <el-table-column label="所属单位" prop="username" :show-overflow-tooltip="true">&ndash;&gt;--> <el-table-column label="所属单位" prop="deptName" :show-overflow-tooltip="true">-->
<!-- <template slot-scope="scope">--> <template slot-scope="scope">
<!-- {{ scope.row.username || '-' }}--> {{ scope.row.deptName || '-' }}
<!-- </template>--> </template>
<!-- </el-table-column>--> </el-table-column>
<el-table-column label="手机号" prop="phone" :show-overflow-tooltip="true"> <el-table-column label="手机号" prop="phone" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.phone || '-' }} {{ scope.row.phone || '-' }}
...@@ -180,6 +214,20 @@ ...@@ -180,6 +214,20 @@
<!-- 添加或修改参数配置对话框 --> <!-- 添加或修改参数配置对话框 -->
<el-dialog :title="title" :visible.sync="open" width="600px" append-to-body> <el-dialog :title="title" :visible.sync="open" width="600px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px"> <el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-row>
<el-col :span="24">
<el-form-item label="用户类型" prop="identity">
<el-select v-model="form.identity" placeholder="请选择用户类型" style="width: 100%" >
<el-option
v-for="(item,index) in userTypeList"
:key="index"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item v-if="form.businessId == undefined" label="登录名" prop="username"> <el-form-item v-if="form.businessId == undefined" label="登录名" prop="username">
...@@ -250,20 +298,20 @@ ...@@ -250,20 +298,20 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<!-- <el-row>--> <el-row>
<!-- <el-col :span="24">--> <el-col :span="24">
<!-- <el-form-item label="部门" prop="postId">--> <el-form-item label="所属单位" prop="postId">
<!-- <treeSelect--> <treeSelect
<!-- v-model="form.deptId"--> v-model="form.deptId"
<!-- :disable-branch-nodes="true"--> :disable-branch-nodes="true"
<!-- :options="deptChildren"--> :options="deptChildren"
<!-- :show-count="true"--> :show-count="true"
<!-- placeholder="请选择归属部门"--> placeholder="请选择所属单位"
<!-- @input="changeValue"--> @input="changeValue"
<!-- />--> />
<!-- </el-form-item>--> </el-form-item>
<!-- </el-col>--> </el-col>
<!-- </el-row>--> </el-row>
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
<el-form-item label="角色" prop="postId"> <el-form-item label="角色" prop="postId">
...@@ -396,7 +444,7 @@ import { ...@@ -396,7 +444,7 @@ import {
// userLoginManage // userLoginManage
} from '@/api/system/user' } from '@/api/system/user'
import { getToken } from '@/utils/auth' import { getToken } from '@/utils/auth'
import { treeSelect } from '@/api/system/dept' import { listAllDept, treeSelect } from '@/api/system/dept'
import TreeSelect from '@riophae/vue-treeselect' import TreeSelect from '@riophae/vue-treeselect'
import '@riophae/vue-treeselect/dist/vue-treeselect.css' import '@riophae/vue-treeselect/dist/vue-treeselect.css'
import { getListRole } from '@/api/system/role' import { getListRole } from '@/api/system/role'
...@@ -421,6 +469,21 @@ export default { ...@@ -421,6 +469,21 @@ export default {
callback() callback()
} }
return { return {
userTypeList: [
{
label: '管理员',
value: '1'
},
{
label: '单位用户',
value: '2'
},
{
label: '个人用户',
value: '3'
}
],
deptList: [],
initialImgPreviewIndex: 0, // 预览打开看到的图片下标 initialImgPreviewIndex: 0, // 预览打开看到的图片下标
imagePreviewUrls: [], // 预览图片的下标 imagePreviewUrls: [], // 预览图片的下标
showImgViewer: false, showImgViewer: false,
...@@ -606,6 +669,7 @@ export default { ...@@ -606,6 +669,7 @@ export default {
// 分页参数初始化为{"page":1,"rows":10},如需自定义分页参数,自行修改 // 分页参数初始化为{"page":1,"rows":10},如需自定义分页参数,自行修改
this.queryParams = JSON.parse(getDataCache(this.$route.path)) // 获取存储的筛选项 this.queryParams = JSON.parse(getDataCache(this.$route.path)) // 获取存储的筛选项
this.getList() // 列表查询 this.getList() // 列表查询
this.getDeptList()
this.getTreeSelect() // 查询部门下拉树结构 this.getTreeSelect() // 查询部门下拉树结构
this.getRole() // 查询角色下拉 this.getRole() // 查询角色下拉
// this.getConfigKey('sys.user.initPassword').then(response => { // this.getConfigKey('sys.user.initPassword').then(response => {
...@@ -613,6 +677,14 @@ export default { ...@@ -613,6 +677,14 @@ export default {
// }) // })
}, },
methods: { methods: {
// 获取所有部门信息
getDeptList() {
listAllDept().then(res => {
if (res.code === 200) {
this.deptList = res.data
}
})
},
handlePictureCardPreview(file) { handlePictureCardPreview(file) {
const index = this.imagePreviewUrls.indexOf(file.url) const index = this.imagePreviewUrls.indexOf(file.url)
if (index >= 0) { if (index >= 0) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment