mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-18 15:26:48 +08:00
讲师管理bug
This commit is contained in:
@@ -1,20 +1,20 @@
|
||||
<template>
|
||||
<div>
|
||||
<a-popover :getPopupContainer="
|
||||
<!-- <a-popover :getPopupContainer="
|
||||
(triggerNode) => {
|
||||
return triggerNode.parentNode || document.body;
|
||||
}
|
||||
" v-model:visible="visible" placement="bottom" trigger="click">
|
||||
<template #content v-if="!disabled">
|
||||
" v-model:visible="visible" placement="bottom" trigger="click"> -->
|
||||
<!-- <template #content v-if="!disabled"> -->
|
||||
<div class="pover">
|
||||
<div class="search">
|
||||
<a-select
|
||||
v-model:value="selectName"
|
||||
:disabled="disabled"
|
||||
v-model:value="selectData"
|
||||
style="width: 100%"
|
||||
placeholder="请查询姓名或工号"
|
||||
:options="isOpen?options:selectOptions"
|
||||
:filter-option="false"
|
||||
allowClear
|
||||
showSearch
|
||||
:open="isOpen"
|
||||
:defaultOpen="false"
|
||||
@@ -28,7 +28,7 @@
|
||||
</template>
|
||||
</a-select>
|
||||
</div>
|
||||
<div class="tree">
|
||||
<!-- <div class="tree">
|
||||
<a-tree show-icon allow-clear tree-default-expand-all :tree-data="treeData" :loading="orgLoading"
|
||||
:load-data="onLoadData" @expand="onExpand" v-model:selectedKeys="stuTreeSelectKeys"
|
||||
v-model:expandedKeys="stuTreeExpandedKeys" :fieldNames="{
|
||||
@@ -44,12 +44,11 @@
|
||||
</div>
|
||||
<div class="btn">
|
||||
<div class="btn0 btn1" @click="notChange">取消</div>
|
||||
<!-- <div class="btn0 btn2" @click="changeOut">确定</div> -->
|
||||
<a-button :loading="loadingChange" @click="changeOut" class="btn0 btn2" type="primary">确定</a-button>
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<a-select
|
||||
<!-- </template> -->
|
||||
<!-- <a-select
|
||||
v-model:value="selectData"
|
||||
style="width: 100%"
|
||||
placeholder="请选择讲师"
|
||||
@@ -62,8 +61,8 @@
|
||||
<template v-if="loading" #notFoundContent>
|
||||
<a-spin size="small"/>
|
||||
</template>
|
||||
</a-select>
|
||||
</a-popover>
|
||||
</a-select> -->
|
||||
<!-- </a-popover> -->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -130,6 +129,9 @@ watch(()=>props.value,(val)=>{
|
||||
selectData.value = null
|
||||
}
|
||||
},{immediate:true})
|
||||
onMounted(()=>{
|
||||
console.log('hahhahahahahhaha')
|
||||
})
|
||||
const teacherName = ref('')
|
||||
const selectName = ref(null)
|
||||
const options = ref([]);
|
||||
@@ -164,7 +166,18 @@ const handleChange = (e,l) => {
|
||||
neworgName.value= neworgName.value[ neworgName.value.length-1]
|
||||
}
|
||||
changeValue.value = l
|
||||
// emit('tlevel',l)
|
||||
emit('tlevel',l)
|
||||
emit('tlevel',changeValue.value)
|
||||
// selectData.value = teacherName.value
|
||||
emit('update:value',selectData.value)
|
||||
emit('update:lable',orgName.value)
|
||||
emit('update:orgId',orgId.value)
|
||||
// emit('update:system',systemName.value)
|
||||
emit('update:level',levelName.value)
|
||||
// emit('update:newlable',neworgName.value)
|
||||
emit('update:id',teacherId.value)
|
||||
emit('update:payrollPlaceCode',payrollPlaceCode.value)
|
||||
emit('update:payrollPlaceName',payrollPlaceName.value)
|
||||
};
|
||||
function debounce(func, wait) {
|
||||
let timeout;
|
||||
@@ -381,6 +394,7 @@ watch(()=>teacherId.value,(val)=>{
|
||||
)
|
||||
})
|
||||
}
|
||||
emit('update:system',systemName.value)
|
||||
}
|
||||
loadingChange.value = false
|
||||
// emit('update:system',systemName.value)
|
||||
@@ -425,11 +439,11 @@ const changeOut = () => {
|
||||
left: 0px !important;
|
||||
}
|
||||
.pover{
|
||||
::v-deep .ant-select-selector{
|
||||
height: 30px !important;
|
||||
border-radius: 4px !important;
|
||||
line-height: 30px !important;
|
||||
}
|
||||
// ::v-deep .ant-select-selector{
|
||||
// height: 30px !important;
|
||||
// border-radius: 4px !important;
|
||||
// line-height: 30px !important;
|
||||
// }
|
||||
.search{
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
@@ -3958,13 +3958,18 @@ function onFocusEnd(){
|
||||
// }
|
||||
state.addLoading = true;
|
||||
editPlan(postData)
|
||||
.then(() => {
|
||||
.then((res) => {
|
||||
if(res.data.code == 200){
|
||||
getTableDate3();
|
||||
handleCancelStu();
|
||||
rest();
|
||||
}else{
|
||||
message.error(res.data.msg)
|
||||
}
|
||||
state.addLoading = false;
|
||||
})
|
||||
.catch((err) => {
|
||||
message.error(err.data.msg)
|
||||
state.loading = false;
|
||||
console.log(err);
|
||||
});
|
||||
|
||||
@@ -1241,7 +1241,7 @@ export default {
|
||||
state.formParam.description = state.formParam.description == null ? '<p><br></p>' : state.formParam.description
|
||||
state.formParam.workExperience = state.formParam.workExperience == null ? '<p><br></p>' : state.formParam.workExperience
|
||||
state.formParam.courses = state.formParam.courses == null ? '<p><br></p>' : state.formParam.courses
|
||||
// state.formParam.photo = state.formParam.photo === null ? avatar : state.formParam.photo
|
||||
state.formParam.photo = state.formParam.photo == null ? null : state.formParam.photo.includes('upload') ? res.data.data.photo : '/upload'+res.data.data.photo
|
||||
state.tSystemNames.systemName = res.data.data.tsystemName
|
||||
state.tSystemNames.systemId = res.data.data.tsystemId
|
||||
state.tSystemNames.systemCode = res.data.data.systemCode
|
||||
@@ -1378,6 +1378,15 @@ export default {
|
||||
};
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
::v-deep .ant-form-item-with-help .ant-form-item-explain{
|
||||
min-height: 0 !important;
|
||||
}
|
||||
::v-deep .ant-form-item-has-error .ant-select:not(.ant-select-disabled):not(.ant-select-customize-input) .ant-select-selector{
|
||||
border-color: #40a9ff !important;
|
||||
}
|
||||
::v-deep .search .ant-select-focused .ant-select-focused:not(.ant-select-disabled).ant-select:not(.ant-select-customize-input) .ant-select-selector{
|
||||
border-color: #40a9ff !important;
|
||||
}
|
||||
.ant-form-item{
|
||||
margin-bottom: 12px;
|
||||
}
|
||||
|
||||
@@ -216,17 +216,24 @@
|
||||
</a-row>
|
||||
<!-- 授课日期 teachingDate 开课状态 courseStatus -->
|
||||
<a-row :gutter="16">
|
||||
<!-- <a-col :span="12">
|
||||
<a-form-item label="课程归属组织" name="sourceBelongId">
|
||||
<OrgClass v-model:value="formParam.sourceBelongId" v-model:name="formParam.sourceBelongFullName"></OrgClass>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="培训发生组织" name="trainOrgId">
|
||||
<a-select v-model:value="formParam.trainOrgId" placeholder="请选择培训发生组织" allowClear
|
||||
:options="orgList" @change="changeOrg">
|
||||
</a-select>
|
||||
<!-- <OrgClass v-model:value="formParam.sourceBelongId" v-model:name="formParam.sourceBelongFullName"></OrgClass> -->
|
||||
</a-form-item>
|
||||
</a-col> -->
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="授课/课程日期 :" name="teachingDate">
|
||||
<a-date-picker class="draitem" v-model:value="teachingDate" style="width:100%" format="YYYY-MM-DD HH:mm"
|
||||
:show-time="{ format: 'HH:mm' }" type="datetime" placeholder="请选择课程日期" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
||||
</a-row>
|
||||
<!-- 授课时长 teaching 评分 score-->
|
||||
<a-row :gutter="16">
|
||||
<a-col :span="12">
|
||||
<a-form-item label="开课状态">
|
||||
<a-radio-group v-model:value="formParam.courseStatus" class="draitem">
|
||||
@@ -235,10 +242,6 @@
|
||||
</a-radio-group>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<!-- 授课时长 teaching 评分 score-->
|
||||
<a-row :gutter="16">
|
||||
|
||||
<a-col :span="12">
|
||||
<a-form-item label="授课时长" name="teaching">
|
||||
<a-input v-model:value="formParam.teaching" style="width:100%; height: 40px; border-radius: 8px ; "
|
||||
@@ -249,6 +252,10 @@
|
||||
<span style="margin-left: 5px ;" v-if="formParam.teaching == null">0.00小时</span> -->
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
|
||||
</a-row>
|
||||
<!-- 参训人数 studys-->
|
||||
<a-row :gutter="16">
|
||||
<a-col :span="12">
|
||||
<a-form-item label="评分" name="score">
|
||||
<!-- <a-input class="draitem" v-model:value="formParam.score" @blur="clearscoreNumber" placeholder="" allowClear showSearch>
|
||||
@@ -257,10 +264,6 @@
|
||||
style="width:100%; height: 40px; border-radius: 8px ; " placeholder="请输入评分" />
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<!-- 参训人数 studys-->
|
||||
<a-row :gutter="16">
|
||||
|
||||
<a-col :span="12">
|
||||
<a-form-item label="参训人数" name="studys">
|
||||
<a-input v-model:value="formParam.studys" class="draitem" placeholder="请输入参训人数" :maxLength="8"
|
||||
@@ -418,6 +421,7 @@ import { fileUp } from "../../api/Lecturer";
|
||||
import SearchTeacher from "@/components/project/SearchTeacher";
|
||||
import { useStore } from "vuex";
|
||||
import OrgClass from "@/components/project/OrgClass";
|
||||
import { queryTrainOrgPor,} from "../../api/organization";
|
||||
export default {
|
||||
name: "InsideTeaching",
|
||||
components: {
|
||||
@@ -444,6 +448,7 @@ export default {
|
||||
state.searchParam = JSON.parse(search)
|
||||
}
|
||||
searchSubmit()
|
||||
orgListDatas()
|
||||
})
|
||||
const route = useRoute()
|
||||
const formRef = ref();
|
||||
@@ -485,10 +490,11 @@ export default {
|
||||
name: null,
|
||||
teacherName: null,
|
||||
teachingDate: null,
|
||||
// sourceBelongId: null,
|
||||
trainOrgId: null,
|
||||
sourceBelongFullName: null,
|
||||
score: 0,
|
||||
},
|
||||
orgList: [],
|
||||
startTime: null,
|
||||
searchParam:
|
||||
{
|
||||
@@ -656,18 +662,18 @@ export default {
|
||||
width: 120,
|
||||
},
|
||||
{
|
||||
title: '所属组织 ',
|
||||
dataIndex: 'orgName',
|
||||
key: 'orgName',
|
||||
title: '培训发生组织 ',
|
||||
dataIndex: 'trainOrg',
|
||||
key: 'trainOrg',
|
||||
ellipsis: true, align: "center",
|
||||
width: 200,
|
||||
// customRender: (value, record) => {
|
||||
// return (
|
||||
// <div>
|
||||
// {value.record.orgName}
|
||||
// </div>
|
||||
// )
|
||||
// }
|
||||
customRender: (value, record) => {
|
||||
return (
|
||||
<div>
|
||||
{value.record.trainOrg||'-'}
|
||||
</div>
|
||||
)
|
||||
}
|
||||
},
|
||||
{
|
||||
title: '数据来源',
|
||||
@@ -790,8 +796,8 @@ export default {
|
||||
<div>
|
||||
{value.record.createdFee == 0 || value.record.createdFee == 1
|
||||
? {
|
||||
"0": "未提交",
|
||||
"1": "已提交",
|
||||
"0": "否",
|
||||
"1": "是",
|
||||
}[value.record.createdFee + ""] || ""
|
||||
: "-"}
|
||||
</div>
|
||||
@@ -812,6 +818,25 @@ export default {
|
||||
const tableData = ref([
|
||||
|
||||
])
|
||||
const orgListDatas = () => {
|
||||
const obj = {
|
||||
pageNo:1,
|
||||
pageSize:50
|
||||
}
|
||||
queryTrainOrgPor(obj).then((res) => {
|
||||
console.log(res,'rssssss')
|
||||
state.orgList = res.data.data?.map(item=>{
|
||||
return{
|
||||
label: item.affiliationName,
|
||||
value: item.id
|
||||
}
|
||||
})
|
||||
})
|
||||
}
|
||||
const changeOrg = (e,l) => {
|
||||
console.log(e,'eeeee',l)
|
||||
state.formParam.trainOrgName = l?.label
|
||||
}
|
||||
const rules = {
|
||||
name: [{ required: true, message: '', log: '讲师不能为空' }],
|
||||
orgName: [{ required: true, message: '', log: '讲师组织不能为空' }],
|
||||
@@ -819,7 +844,7 @@ export default {
|
||||
tsystemName: [{ required: true, message: '', log: '讲师体系不能为空' }],
|
||||
courseTypeId: [{ required: true, message: '', log: '内容分类不能为空' }],
|
||||
courseName: [{ required: true, message: '', log: '课程名称不能为空' }],
|
||||
// sourceBelongId: [{ required: true, message: '', log: '课程归属组织不能为空' }],
|
||||
trainOrgId: [{ required: true, message: '', log: '课程归属组织不能为空' }],
|
||||
teachingDate: [{ required: true, message: '', log: '授课日期不能为空' }],
|
||||
teaching: [{ required: true, message: '', log: '授课时长不能为空' }],
|
||||
courseStatus: [{ required: true, message: '', log: '开课状态不能为空' }],
|
||||
@@ -1053,7 +1078,7 @@ export default {
|
||||
score: 0,
|
||||
type: null,
|
||||
remark: null,
|
||||
// sourceBelongId: null,
|
||||
trainOrgId: null,
|
||||
sourceBelongFullName: null,
|
||||
offcourseId: null,
|
||||
createFrom: null,
|
||||
@@ -1307,6 +1332,8 @@ export default {
|
||||
clearstudysNumber,
|
||||
beforeUpload2,
|
||||
rules,
|
||||
orgListDatas,
|
||||
changeOrg,
|
||||
formRef,
|
||||
column,
|
||||
tableDatas,
|
||||
|
||||
@@ -221,7 +221,7 @@
|
||||
>
|
||||
<a-button class="drabtn" @click="cancelTeacherDialog" >取消</a-button>
|
||||
<a-button class="drabtn" type="primary" @click="createTeacherDialog(0)" :loading="buttonLoading">保存</a-button>
|
||||
<a-button v-if="editParams||editIndex>1" class="drabtn" type="primary" @click="createTeacherDialog(1)" :loading="buttonLoading">提交</a-button>
|
||||
<a-button class="drabtn" type="primary" @click="createTeacherDialog(1)" :loading="buttonLoading">提交</a-button>
|
||||
</div>
|
||||
</a-drawer>
|
||||
<AddOrgContent :Addtitle="'选择组织'" v-model:showContent="showContent" v-model:AddContentList="formParam.affiliationOrgList" />
|
||||
|
||||
Reference in New Issue
Block a user