授课记录调整

This commit is contained in:
wangxuemei
2024-10-26 13:40:27 +08:00
parent f0034687c4
commit a6b56cf9fa
6 changed files with 30 additions and 19 deletions

View File

@@ -274,17 +274,17 @@ import {getCookieForName} from "@/api/method";
}
};
function downTemplate() {
if (props.url=='/admin/export/importInTeacherRecord'){
if (props.url==='/admin/export/importInTeacherRecord'){
window.open(
`${process.env.VUE_APP_BASE_API}/admin/export/importInTeacherRecord?
`${process.env.VUE_APP_BASE_API}/admin/export/exportInTeacherRecord?
&name=${props.name||''}`
);}
else if(props.url=='/admin/export/importOutTeacherRecord'){
else if(props.url==='/admin/export/importOutTeacherRecord'){
window.open(
`${process.env.VUE_APP_BASE_API}/admin/export/exportOutTeacherRecord?
&name=${props.name||''}`
);
}else {
}else if(props.url==='/admin/export/exportTeacherExpense') {
window.open(
`${process.env.VUE_APP_BASE_API}/admin/export/importTeacherExpense?
&name=${props.name||''}`

View File

@@ -186,7 +186,7 @@
<span style="margin-left: 5px ;" v-if="formParam.duration != null">{{ (formParam.duration / 60
).toFixed(2) }}小时</span>
<span style="margin-left: 5px ;" v-if="formParam.duration == null">0.00小时</span>
</a-form-item>
</a-form-item>
</a-col>
</a-row>
<!-- 参训人数 studys评分 score-->
@@ -618,7 +618,7 @@ export default {
name: null,
manager:null,
entryType: null,
status: null,
status: 1,
entryType:null,
systemId:null,
endTime:null,
@@ -650,6 +650,7 @@ export default {
};
// 新增讲师
const addTeacher = () => {
cancel()
state.teacherdialog = true;
state.teacherdialogtitle = '添加授课记录'
state.vf = true
@@ -677,6 +678,7 @@ export default {
}
//保存
const createTeacherDialog = async () => {
state.formParam.teachingDate=state.teachingDate ? dayjs(state.teachingDate).format("YYYY-MM-DD").toString() : ""
const formItemNames = Object.keys(rules);
for(let i=0;i<formItemNames.length;i++){
const result = await validateField(formItemNames[i]);
@@ -685,7 +687,6 @@ export default {
}
}
state.formParam = {...state.formParam}
state.formParam.teachingDate=state.teachingDate ? dayjs(state.teachingDate).format("YYYY-MM-DD") : ""
if (state.vf == false) {
updateInTeacherCourse(state.formParam).then(response => {
message.success("修改成功");
@@ -772,6 +773,7 @@ export default {
duration: null,
score: null,
remark: null,
teachingDate:null
}
state.teachingDate=null
}
@@ -817,7 +819,7 @@ export default {
// state.searchParam.trainorgName=orgName
}
const clearNonNumber=()=>{
state.formParam.defaultteachingTime = state.formParam.defaultteachingTime.replace(/\D/g, '');
state.formParam.duration = state.formParam.duration.replace(/\D/g, '');
}
//导入功能
const handleImport = () => {

View File

@@ -213,7 +213,7 @@
<a-row :gutter="16">
<a-col :span="24">
<a-form-item label="讲师介绍">
<Editor v-model:value="formParam.description" />
<Editor v-model:value="formParam.description" :isupload="isupload" />
</a-form-item>
</a-col>
</a-row>
@@ -227,7 +227,7 @@
<a-row :gutter="16">
<a-col :span="24">
<a-form-item label="擅长课程">
<Editor v-model:value="formParam.courses" />
<Editor v-model:value="formParam.courses" :isupload="isupload"/>
</a-form-item>
</a-col>
</a-row>
@@ -455,7 +455,7 @@ export default {
console.log(val, 'description')
})
watch(() => state.formParam.workExperience, (val) => {
console.log(val, '11111')
console.log(val, '')
})
watch(() => state.formParam.courses, (val) => {
console.log(val, 'courses')

View File

@@ -830,6 +830,7 @@ export default {
};
// 新增授课
const addTeacher = () => {
cancel()
state.teacherdialog1 = 0
state.teacherdialog = true;
state.teacherdialogtitle = '添加授课记录'
@@ -856,8 +857,9 @@ export default {
}
//保存
const createTeacherDialog = async () => {
console.log( state.formParam)
state.formParam.tSystemName = state.tSystemNames.systemName
state.formParam.teachingDate=state.teachingDate ? dayjs(state.teachingDate).format("YYYY-MM-DD").toString() : ""
const formItemNames = Object.keys(rules);
for(let i=0;i<formItemNames.length;i++){
const result = await validateField(formItemNames[i]);
@@ -866,7 +868,7 @@ export default {
}
}
state.formParam = {...state.formParam,...state.tSystemNames}
state.formParam.teachingDate=state.teachingDate ? dayjs(state.teachingDate).format("YYYY-MM-DD") : ""
console.log( state.formParam)
if (state.vf == false) {
updateInTeacherCourse(state.formParam).then(response => {
message.success("修改成功");
@@ -926,6 +928,7 @@ export default {
const cancel = () => {
state.formParam = {
recordType: 1,
courseStatus:1,
teacher: null,
orgName: null,
tSystemName: null,
@@ -938,6 +941,7 @@ export default {
remark: null,
offcourseId: null,
createFrom: null,
teachingDate:null,
}
state.teachingDate=null
state.tSystemNames = {

View File

@@ -36,7 +36,7 @@ ExternalLecturer
<a-descriptions title="其他信息" bordered :column="4" :contentStyle="rowCenter" :labelStyle="rowCenter" >
<!-- 一层 -->
<a-descriptions-item label="讲师介绍" :span="4">
<div v-html="formParam.description" style="min-width: 500px;"></div>
<div v-if="formParam.description !=null" style="min-width: 500px;" v-html="formParam.description" ></div>
</a-descriptions-item>
<a-descriptions-item label="备注" :span="4">
{{formParam.remark===null?'--':formParam.remark}}</a-descriptions-item>

View File

@@ -57,11 +57,16 @@
<span class="line" ></span>
<a-descriptions title="其他信息" bordered :column="4" :contentStyle="rowCenter" :labelStyle="rowCenter" >
<!-- 一层 -->
<a-descriptions-item label="讲师介绍" :span="4"><div style="min-width: 500px;">
{{formParam.description ===null ? ' --' :formParam.description}} </div> </a-descriptions-item>
<a-descriptions-item label="工作职责" :span="4">{{formParam.workExperience ===null?'--':formParam.workExperience}}</a-descriptions-item>
<a-descriptions-item label="擅长课程" :span="4">{{formParam.courses===null?'--':formParam.courses}}</a-descriptions-item>
<a-descriptions-item label="教师专长" :span="4">{{formParam.expertise===null?'--':formParam.expertise}}</a-descriptions-item>
<a-descriptions-item label="讲师介绍" :span="4" >
<div v-if="formParam.description !=null" style="min-width: 500px;" v-html="formParam.description" ></div>
</a-descriptions-item>
<a-descriptions-item label="工作职责" :span="4">
<div v-if="formParam.workExperience !=null" style="min-width: 500px;" v-html="formParam.workExperience" ></div>
</a-descriptions-item>
<a-descriptions-item label="擅长课程" :span="4">
<div v-if="formParam.courses !=null" style="min-width: 500px;" v-html="formParam.courses" ></div>
</a-descriptions-item>
<a-descriptions-item label="教师专长" :span="4">{{formParam.expertise===null?'':formParam.expertise}}</a-descriptions-item>
</a-descriptions>
<!-- 记录 -->
<div style="margin-top: 1px;"></div>