Commit 1178b7c4 authored by 黄奎's avatar 黄奎

页面修改

parent 1fb1734c
...@@ -14,6 +14,12 @@ ...@@ -14,6 +14,12 @@
map-options :rules="[val => !!val || '请选择所属校区']" /> map-options :rules="[val => !!val || '请选择所属校区']" />
<q-input type="tel" filled stack-label maxlength="100" :dense="false" v-model="objOption.AssistTel" <q-input type="tel" filled stack-label maxlength="100" :dense="false" v-model="objOption.AssistTel"
ref="AssistTel" class="col-6 q-pr-lg q-pb-lg" label="联系电话" :rules="[val => !!val || '请填写助教联系电话']" /> ref="AssistTel" class="col-6 q-pr-lg q-pb-lg" label="联系电话" :rules="[val => !!val || '请填写助教联系电话']" />
<selectTree v-if="DeptList&&DeptList.length>0" :treeData='DeptList' :defaultArray="returnString"
nodeKey="DeptId" :multiple="false" labelKey="DeptName" childrenKey="ChildList" tipText="选择部门"
@getChild="getChild" classStr="col-6 q-pr-lg q-pb-lg"></selectTree>
<q-select filled stack-label option-value="PostId" option-label="PostName" v-model="objOption.Post_Id"
ref="Post_Id" :options="PostList" label="岗位" :dense="false" class="col-6 q-pb-lg q-pb-lg" emit-value
map-options />
<div class="col-6 q-pb-lg"> <div class="col-6 q-pb-lg">
<q-uploader style="display: inline-block;max-height: 320px;max-width: 100%; background-repeat:no-repeat" <q-uploader style="display: inline-block;max-height: 320px;max-width: 100%; background-repeat:no-repeat"
:style="{'background-image':'url(' + objOption.AssistIcon + ')'}" max-files="1" hide-upload-btn :style="{'background-image':'url(' + objOption.AssistIcon + ')'}" max-files="1" hide-upload-btn
...@@ -43,10 +49,20 @@ ...@@ -43,10 +49,20 @@
import { import {
UploadSelfFile UploadSelfFile
} from '../../../api/common/common' } from '../../../api/common/common'
//部门
import {
getDeptTree
} from '../../../api/system/dept'
//岗位
import {
getPostList
} from '../../../api/system/post'
import extEditor from '../../common/ext-editor' import extEditor from '../../common/ext-editor'
import selectTree from '../../common/select-tree'
export default { export default {
components: { components: {
extEditor, extEditor,
selectTree,
}, },
props: { props: {
saveObj: { saveObj: {
...@@ -63,20 +79,58 @@ ...@@ -63,20 +79,58 @@
AssistName: "", AssistName: "",
AssistTel: '', AssistTel: '',
AssistIcon: '', AssistIcon: '',
AssistIntro: '' AssistIntro: '',
Dept_Id: 0, //部门编号
Post_Id: 0, //岗位编号
}, },
optionTitle: "", optionTitle: "",
schoolList: [], schoolList: [],
saveLoading: false, saveLoading: false,
DeptList: [], //部门列表
PostList: [], //岗位列表
returnString: [], //默认岗位
} }
}, },
created() { created() {
this.queryDeptTree();
this.queryPostList();
this.getSchool(); this.getSchool();
}, },
mounted() { mounted() {
this.initObj() this.initObj()
}, },
methods: { methods: {
getChild(deptArray) {
var tempStr = "";
if (deptArray && deptArray != '') {
tempStr = deptArray;
}
this.objOption.Dept_Id = tempStr;
},
//获取部门结构树
queryDeptTree() {
getDeptTree({}).then(res => {
if (res.Code == 1) {
this.DeptList = res.Data;
}
})
},
//获取岗位列表
queryPostList() {
this.PostList = [];
var postMsg = {
RB_Dept_Id: 0,
};
if (this.objOption.Dept_Id) {
postMsg.RB_Dept_Id = this.objOption.Dept_Id;
}
getPostList(postMsg).then(res => {
if (res.Code == 1) {
this.PostList = res.Data;
}
})
},
//获取编辑器值 //获取编辑器值
getEditValue(obj) { getEditValue(obj) {
this.objOption.AssistIntro = obj; this.objOption.AssistIntro = obj;
...@@ -90,6 +144,11 @@ ...@@ -90,6 +144,11 @@
this.objOption.AssistTel = this.saveObj.AssistTel; this.objOption.AssistTel = this.saveObj.AssistTel;
this.objOption.AssistIcon = this.saveObj.AssistIcon; this.objOption.AssistIcon = this.saveObj.AssistIcon;
this.objOption.AssistIntro = this.saveObj.AssistIntro; this.objOption.AssistIntro = this.saveObj.AssistIntro;
this.objOption.Dept_Id = this.saveObj.Dept_Id;
this.objOption.Post_Id = this.saveObj.Post_Id;
if (this.saveObj.Dept_Id) {
this.returnString.push(this.saveObj.Dept_Id.toString());
}
} else { } else {
this.optionTitle = "新增助教" this.optionTitle = "新增助教"
} }
...@@ -161,13 +220,16 @@ ...@@ -161,13 +220,16 @@
} }
}, },
}, },
watch: {
"objOption.Dept_Id": function (val) {
this.queryPostList();
}
},
} }
</script> </script>
<style> <style>
.upload-assiatant-box .q-uploader__list { .upload-assiatant-box .q-uploader__list {
display: none; display: none;
} }
......
...@@ -11,6 +11,12 @@ ...@@ -11,6 +11,12 @@
class="col-6 q-pr-lg q-pb-lg" label="管理者名称" :rules="[val => !!val || '请填写管理者姓名']" /> class="col-6 q-pr-lg q-pb-lg" label="管理者名称" :rules="[val => !!val || '请填写管理者姓名']" />
<q-input type="tel" filled stack-label maxlength="100" :dense="false" v-model="objOption.MTel" ref="MTel" <q-input type="tel" filled stack-label maxlength="100" :dense="false" v-model="objOption.MTel" ref="MTel"
class="col-6 q-pr-lg q-pb-lg" label="联系电话" :rules="[val => !!val || '请填写管理者联系电话']" /> class="col-6 q-pr-lg q-pb-lg" label="联系电话" :rules="[val => !!val || '请填写管理者联系电话']" />
<selectTree v-if="DeptList&&DeptList.length>0" :treeData='DeptList' :defaultArray="returnString"
nodeKey="DeptId" :multiple="false" labelKey="DeptName" childrenKey="ChildList" tipText="选择部门"
@getChild="getChild" classStr="col-6 q-pr-lg q-pb-lg"></selectTree>
<q-select filled stack-label option-value="PostId" option-label="PostName" v-model="objOption.Post_Id"
ref="Post_Id" :options="PostList" label="岗位" :dense="false" class="col-6 q-pb-lg q-pb-lg" emit-value
map-options />
<div class="col-6 q-pb-lg"> <div class="col-6 q-pb-lg">
<q-uploader style="display: inline-block;max-height: 320px;max-width: 100%; background-repeat:no-repeat" <q-uploader style="display: inline-block;max-height: 320px;max-width: 100%; background-repeat:no-repeat"
:style="{'background-image':'url(' + objOption.MHead + ')'}" max-files="1" hide-upload-btn :style="{'background-image':'url(' + objOption.MHead + ')'}" max-files="1" hide-upload-btn
...@@ -43,9 +49,18 @@ ...@@ -43,9 +49,18 @@
queryRoleDropdown queryRoleDropdown
} }
from '../../../api/system/index' from '../../../api/system/index'
//部门
import {
getDeptTree
} from '../../../api/system/dept'
//岗位
import {
getPostList
} from '../../../api/system/post'
import { import {
UploadSelfFile, UploadSelfFile,
} from '../../../api/common/common' } from '../../../api/common/common'
import selectTree from '../../common/select-tree'
export default { export default {
components: {}, components: {},
props: { props: {
...@@ -54,6 +69,9 @@ ...@@ -54,6 +69,9 @@
default: null default: null
} }
}, },
components: {
selectTree
},
data() { data() {
return { return {
persistent: true, persistent: true,
...@@ -64,22 +82,59 @@ ...@@ -64,22 +82,59 @@
MTel: '', //管理者电话 MTel: '', //管理者电话
MHead: '', //头像 MHead: '', //头像
RoleAuth: "", //角色 RoleAuth: "", //角色
Dept_Id: 0, //部门编号
Post_Id: 0, //岗位编号
}, },
optionTitle: "", optionTitle: "",
schoolList: [], schoolList: [],
roleList: [], //角色列表 roleList: [], //角色列表
saveLoading: false, saveLoading: false,
tempRole: [], tempRole: [],
DeptList: [], //部门列表
PostList: [], //岗位列表
returnString: [], //默认岗位
} }
}, },
created() { created() {
this.queryDeptTree();
this.queryPostList();
this.getrolelist(); this.getrolelist();
this.getSchool(); this.getSchool();
}, },
mounted() { mounted() {
this.initObj() this.initObj();
}, },
methods: { methods: {
getChild(deptArray) {
var tempStr = "";
if (deptArray && deptArray != '') {
tempStr = deptArray;
}
this.objOption.Dept_Id = tempStr;
},
//获取部门结构树
queryDeptTree() {
getDeptTree({}).then(res => {
if (res.Code == 1) {
this.DeptList = res.Data;
}
})
},
//获取岗位列表
queryPostList() {
this.PostList = [];
var postMsg = {
RB_Dept_Id: 0,
};
if (this.objOption.Dept_Id) {
postMsg.RB_Dept_Id = this.objOption.Dept_Id;
}
getPostList(postMsg).then(res => {
if (res.Code == 1) {
this.PostList = res.Data;
}
})
},
getrolelist() { getrolelist() {
queryRoleDropdown({}).then(res => { queryRoleDropdown({}).then(res => {
if (res.Code == 1) { if (res.Code == 1) {
...@@ -105,6 +160,9 @@ ...@@ -105,6 +160,9 @@
this.objOption.MName = res.Data.MName; this.objOption.MName = res.Data.MName;
this.objOption.MTel = res.Data.MTel; this.objOption.MTel = res.Data.MTel;
this.objOption.MHead = res.Data.MHead; this.objOption.MHead = res.Data.MHead;
this.objOption.Post_Id = res.Data.Post_Id;
this.objOption.Dept_Id = res.Data.Dept_Id;
this.returnString.push(res.Data.Dept_Id.toString());
this.tempRole = res.Data.RoleList; this.tempRole = res.Data.RoleList;
this.$forceUpdate(); this.$forceUpdate();
}) })
...@@ -164,6 +222,11 @@ ...@@ -164,6 +222,11 @@
}) })
}, },
}, },
watch: {
"objOption.Dept_Id": function (val) {
this.queryPostList();
}
}
} }
</script> </script>
......
...@@ -16,6 +16,12 @@ ...@@ -16,6 +16,12 @@
ref="TeacherTel" class="col-6 q-pr-lg q-pb-lg" label="联系电话" :rules="[val => !!val || '请填写教师联系电话']" /> ref="TeacherTel" class="col-6 q-pr-lg q-pb-lg" label="联系电话" :rules="[val => !!val || '请填写教师联系电话']" />
<q-input filled stack-label maxlength="100" :dense="false" v-model="objOption.TeacherSay" ref="TeacherSay" <q-input filled stack-label maxlength="100" :dense="false" v-model="objOption.TeacherSay" ref="TeacherSay"
class="col-6 q-pb-lg" label="教师营销语" /> class="col-6 q-pb-lg" label="教师营销语" />
<selectTree v-if="DeptList&&DeptList.length>0" :treeData='DeptList' :defaultArray="returnString"
nodeKey="DeptId" :multiple="false" labelKey="DeptName" childrenKey="ChildList" tipText="选择部门"
@getChild="getChild" classStr="col-6 q-pr-lg q-pb-lg"></selectTree>
<q-select filled stack-label option-value="PostId" option-label="PostName" v-model="objOption.Post_Id"
ref="Post_Id" :options="PostList" label="岗位" :dense="false" class="col-6 q-pb-lg q-pb-lg" emit-value
map-options />
<div class="col-6 q-pr-lg q-pb-lg"> <div class="col-6 q-pr-lg q-pb-lg">
<q-uploader style="display: inline-block;height: 320px;max-width: 100%; background-repeat:no-repeat" <q-uploader style="display: inline-block;height: 320px;max-width: 100%; background-repeat:no-repeat"
:style="{'background-image':'url(' + objOption.TeacherHead + ')'}" max-files="1" hide-upload-btn :style="{'background-image':'url(' + objOption.TeacherHead + ')'}" max-files="1" hide-upload-btn
...@@ -77,10 +83,20 @@ ...@@ -77,10 +83,20 @@
import { import {
UploadSelfFile UploadSelfFile
} from '../../../api/common/common' } from '../../../api/common/common'
//部门
import {
getDeptTree
} from '../../../api/system/dept'
//岗位
import {
getPostList
} from '../../../api/system/post'
import extEditor from '../../common/ext-editor' import extEditor from '../../common/ext-editor'
import selectTree from '../../common/select-tree'
export default { export default {
components: { components: {
extEditor, extEditor,
selectTree
}, },
props: { props: {
saveObj: { saveObj: {
...@@ -103,7 +119,9 @@ ...@@ -103,7 +119,9 @@
IsShow: 1, IsShow: 1,
IsRecommend: 0, IsRecommend: 0,
SortNum: 1, SortNum: 1,
TeachTag: "" TeachTag: "",
Dept_Id: 0, //部门编号
Post_Id: 0, //岗位编号
}, },
optionTitle: "", optionTitle: "",
schoolList: [], schoolList: [],
...@@ -111,15 +129,50 @@ ...@@ -111,15 +129,50 @@
saveLoading: false, saveLoading: false,
tagText: "", tagText: "",
tags: [], tags: [],
DeptList: [], //部门列表
PostList: [], //岗位列表
returnString: [], //默认岗位
} }
}, },
created() { created() {
this.queryDeptTree();
this.queryPostList();
this.getSchool() this.getSchool()
}, },
mounted() { mounted() {
this.initObj() this.initObj()
}, },
methods: { methods: {
getChild(deptArray) {
var tempStr = "";
if (deptArray && deptArray != '') {
tempStr = deptArray;
}
this.objOption.Dept_Id = tempStr;
},
//获取部门结构树
queryDeptTree() {
getDeptTree({}).then(res => {
if (res.Code == 1) {
this.DeptList = res.Data;
}
})
},
//获取岗位列表
queryPostList() {
this.PostList = [];
var postMsg = {
RB_Dept_Id: 0,
};
if (this.objOption.Dept_Id) {
postMsg.RB_Dept_Id = this.objOption.Dept_Id;
}
getPostList(postMsg).then(res => {
if (res.Code == 1) {
this.PostList = res.Data;
}
})
},
getType(type) { getType(type) {
this.uploadType = type; this.uploadType = type;
}, },
...@@ -142,6 +195,12 @@ ...@@ -142,6 +195,12 @@
this.objOption.IsRecommend = this.saveObj.IsRecommend; this.objOption.IsRecommend = this.saveObj.IsRecommend;
this.objOption.SortNum = this.saveObj.SortNum; this.objOption.SortNum = this.saveObj.SortNum;
this.objOption.TeachTag = this.saveObj.TeachTag; this.objOption.TeachTag = this.saveObj.TeachTag;
this.objOption.Dept_Id = this.saveObj.Dept_Id;
this.objOption.Post_Id = this.saveObj.Post_Id;
if(this.saveObj.Dept_Id)
{
this.returnString.push(this.saveObj.Dept_Id.toString());
}
if (this.objOption.TeachTag && this.objOption.TeachTag.length > 0) { if (this.objOption.TeachTag && this.objOption.TeachTag.length > 0) {
this.tags = JSON.parse(this.objOption.TeachTag) this.tags = JSON.parse(this.objOption.TeachTag)
} }
...@@ -232,6 +291,11 @@ ...@@ -232,6 +291,11 @@
} }
}, },
}, },
watch: {
"objOption.Dept_Id": function (val) {
this.queryPostList();
}
},
} }
</script> </script>
......
...@@ -153,6 +153,18 @@ ...@@ -153,6 +153,18 @@
field: 'SName', field: 'SName',
align: 'left', align: 'left',
}, },
{
name: 'DeptName',
label: '所属部门',
field: 'DeptName',
align: 'left',
},
{
name: 'PostName',
label: '岗位名称',
field: 'PostName',
align: 'left',
},
{ {
name: 'AuditStatus', name: 'AuditStatus',
label: '审核状态', label: '审核状态',
......
...@@ -246,7 +246,8 @@ ...@@ -246,7 +246,8 @@
getSchool() { getSchool() {
getSchoolPage(this.msg).then(res => { getSchoolPage(this.msg).then(res => {
this.loading = false this.loading = false
this.data = res.Data.PageData this.data = res.Data.PageData;
this.pageCount = res.Data.PageCount this.pageCount = res.Data.PageCount
}).catch(() => { }).catch(() => {
this.loading = false this.loading = false
......
...@@ -120,7 +120,18 @@ ...@@ -120,7 +120,18 @@
field: 'SName', field: 'SName',
align: 'left', align: 'left',
}, },
{
name: 'DeptName',
label: '部门',
field: 'DeptName',
align: 'left',
},
{
name: 'PostName',
label: '岗位',
field: 'PostName',
align: 'left',
},
{ {
name: 'Status', name: 'Status',
label: '状态', label: '状态',
...@@ -305,8 +316,9 @@ ...@@ -305,8 +316,9 @@
this.loading = true; this.loading = true;
queryManagerPage(this.msg).then(res => { queryManagerPage(this.msg).then(res => {
this.loading = false; this.loading = false;
this.data = res.Data.PageData this.data = res.Data.PageData;
this.pageCount = res.Data.PageCount console.log("data", this.data);
this.pageCount = res.Data.PageCount;
}).catch(() => { }).catch(() => {
this.loading = false this.loading = false
}) })
......
...@@ -102,8 +102,8 @@ ...@@ -102,8 +102,8 @@
style="font-weight:400" class="q-mr-xs" label="审核" @click="showExamine(props.row)" /> style="font-weight:400" class="q-mr-xs" label="审核" @click="showExamine(props.row)" />
<q-btn v-if="props.row.AuditStatus==2" flat size="xs" icon="iconfont icon-ziyuan" color="warning" <q-btn v-if="props.row.AuditStatus==2" flat size="xs" icon="iconfont icon-ziyuan" color="warning"
style="font-weight:400" class="q-mr-xs" label="重置密码" @click="resetPw(props.row.TId)" /> style="font-weight:400" class="q-mr-xs" label="重置密码" @click="resetPw(props.row.TId)" />
<q-btn flat size="xs" icon="iconfont icon-shanchu" color="negative" <q-btn flat size="xs" icon="iconfont icon-shanchu" color="negative" style="font-weight:400"
style="font-weight:400" class="q-mr-xs" label="删除" @click="deleteUser(props.row.TId)" /> class="q-mr-xs" label="删除" @click="deleteUser(props.row.TId)" />
<q-btn v-if="props.row.AuditStatus==3" flat size="xs" icon="iconfont icon-ziyuan" color="negative" <q-btn v-if="props.row.AuditStatus==3" flat size="xs" icon="iconfont icon-ziyuan" color="negative"
style="font-weight:400" class="q-mr-xs" label="重新申请" @click="reApplyTeacher(props.row.TId)" /> style="font-weight:400" class="q-mr-xs" label="重新申请" @click="reApplyTeacher(props.row.TId)" />
<q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="编辑" <q-btn flat size="xs" icon="edit" color="accent" style="font-weight:400" label="编辑"
...@@ -173,6 +173,18 @@ ...@@ -173,6 +173,18 @@
field: 'SName', field: 'SName',
align: 'left', align: 'left',
}, },
{
name: 'DeptName',
label: '所属部门',
field: 'DeptName',
align: 'left',
},
{
name: 'PostName',
label: '岗位名称',
field: 'PostName',
align: 'left',
},
{ {
name: 'AuditStatus', name: 'AuditStatus',
label: '审核状态', label: '审核状态',
......
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