|
|
@@ -5,6 +5,7 @@
|
|
|
<el-icon class="img"><ArrowLeftBold /></el-icon>
|
|
|
返回
|
|
|
</el-button>
|
|
|
+ {{ enterTime }}
|
|
|
<!-- 如该任务勾选了所有单科统一模板后,则会出现"整卷填写”和“按题填写”的页面,默认按照整卷填写 -->
|
|
|
<TabSearch v-if="isUnifyTemplate" tabType="box"
|
|
|
:defaultTabKey="defaultQuestionnaireMode" :tabList="[
|
|
|
@@ -213,6 +214,8 @@ import { getEvaluationQuestionDataApi, getEvaluationQuestionDataSplitApi,
|
|
|
} from '@/api/questionnaireCommit'
|
|
|
import {getEvaluationProcessMsgApi} from '@/api/selfQuestionnaireProcess'
|
|
|
|
|
|
+import { unioformDateTransform } from '@/utils/dateTransform';
|
|
|
+
|
|
|
import redTimeIcon from '@/assets/icon/red_time_icon.svg'
|
|
|
import finishIcon from '@/assets/studentQuestionnaire/select_icon.png'
|
|
|
|
|
|
@@ -241,6 +244,9 @@ const isUnifyTemplate = computed(()=>{
|
|
|
// 问卷填写截止时间
|
|
|
const deadlineTime = ref('')
|
|
|
|
|
|
+// 进入某个问卷(整卷)或者 某个试题(按题) 的时间
|
|
|
+const enterTime = ref<any>('')
|
|
|
+
|
|
|
// 倒计时相关参数
|
|
|
const {
|
|
|
DestoryInterval,
|
|
|
@@ -528,6 +534,7 @@ const GetFullQuestionnaireData = async ()=>{
|
|
|
|
|
|
// 这个要默认打开最新的 第一个进行中 或第一个待评价
|
|
|
currentActiveTeacherId.value = teacherList.value?.[finalIndex]?.id || ''
|
|
|
+ enterTime.value = unioformDateTransform(new Date())
|
|
|
}
|
|
|
|
|
|
|
|
|
@@ -535,8 +542,9 @@ const GetFullQuestionnaireData = async ()=>{
|
|
|
// 切换 评价的科目教师
|
|
|
const HandleSubjectTeacherChange = (index,teacher)=>{
|
|
|
currentActiveTeacherId.value = teacher.id
|
|
|
-
|
|
|
currentSelectedQuestionIndex.value = 0
|
|
|
+ enterTime.value = unioformDateTransform(new Date())
|
|
|
+
|
|
|
}
|
|
|
|
|
|
// 问卷试题定位—— 滚动定位到试题中的某一题
|
|
|
@@ -558,6 +566,7 @@ const HandleFinishReview = async ()=>{
|
|
|
let params = {
|
|
|
evaluationCodeRelationId: currentSelectedQuestionnaireData.value.evaluationCodeRelationId,
|
|
|
assessmentId: currentSelectedQuestionnaireData.value.assessmentId,
|
|
|
+ evaluationStartDatetime: enterTime.value,
|
|
|
answerData: Object.values(fullQuestionnaireAnswer.value)
|
|
|
}
|
|
|
|
|
|
@@ -631,6 +640,7 @@ const currentEditQuestion = computed(()=>{
|
|
|
|
|
|
// 获取按题填写问卷数据
|
|
|
const GetSplitQuestionnaireData = async ()=>{
|
|
|
+
|
|
|
let teacherIds = teacherList.value.map(item=>{
|
|
|
return item.id
|
|
|
})
|
|
|
@@ -638,6 +648,15 @@ const GetSplitQuestionnaireData = async ()=>{
|
|
|
if(res?.code == 200){
|
|
|
questionnaireSplitData.value = res.data
|
|
|
}
|
|
|
+
|
|
|
+ // 此处要默认跳转到第一个未提交的题目 编号 ||如果全填完则展示第一个
|
|
|
+ const list = questionaireMsg.value?.questionData || []
|
|
|
+ // 获取第一个 未答完的题
|
|
|
+ const firstUnfinishIndex = list.findIndex(item => item.studentAnswerStatus === 0);
|
|
|
+ const hasUnfinish = firstUnfinishIndex !== -1
|
|
|
+ let finalIndex = hasUnfinish ? firstUnfinishIndex : 0
|
|
|
+ currentSelectedQuestionIndex.value = finalIndex
|
|
|
+ enterTime.value = unioformDateTransform(new Date())
|
|
|
}
|
|
|
|
|
|
|
|
|
@@ -772,6 +791,7 @@ watch(()=>currentEditQuestion.value?.questionType,(newVal)=>{
|
|
|
// 切换当前选中的试题索引
|
|
|
const HandleChangeQuestion = (index,question)=>{
|
|
|
console.log('当前索引--',index)
|
|
|
+ enterTime.value = unioformDateTransform(new Date())
|
|
|
isFinishEdit.value = false
|
|
|
currentSelectedQuestionIndex.value = index
|
|
|
|
|
|
@@ -856,6 +876,7 @@ const HandleFinishCurrentQuestion = async ()=>{
|
|
|
let params = {
|
|
|
questionId: currentSelectedQuestionnaireData.value.questionId,
|
|
|
lastQuestion: currentSelectedQuestionIndex.value + 1 >= questionnaireSplitData.value?.length ? true : false,
|
|
|
+ evaluationStartDatetime: enterTime.value,
|
|
|
answerData:finalAnswerData
|
|
|
}
|
|
|
|