From 99ce8c363068eb4076b4f7e9c4d505cc37eb3f78 Mon Sep 17 00:00:00 2001 From: yj <2077506045@qq.com> Date: 星期五, 24 五月 2024 14:20:14 +0800 Subject: [PATCH] 1.修改文字 2.修改练习页面 --- src/lang/th.js | 14 ++++--- src/lang/zh.js | 2 + src/lang/en.js | 18 +++++---- src/layout/index.vue | 3 + src/views/exam/paper/guide.vue | 2 src/views/exam/paper/exercise.vue | 63 +++++++++++++++++-------------- 6 files changed, 58 insertions(+), 44 deletions(-) diff --git a/src/lang/en.js b/src/lang/en.js index 4fde788..ce81d23 100644 --- a/src/lang/en.js +++ b/src/lang/en.js @@ -29,7 +29,7 @@ finishSubmit: 'You have completed the work behavior questionnaire, and the data has been successfully uploaded to the server and saved. Thank you.', selectData: 'Date', startDo: 'Next', - startDo_apifan: 'The test has officially started.', + startDo_apifan: 'Start the Test', second: ' second ', min: ' minute ', hour: ' hour ', @@ -42,12 +42,14 @@ uploadInfo: 'Uploading, saving data, please wait, do not close the browser...', examinee: 'Test-taker:', pleaseAnswerCarefully: '*Please answer carefully', - pleaseAnswerCarefully_exercise: '*This is a practice session, after the practice session, please click the "Start Test" button to take the test.', + pleaseAnswerCarefully_exercise: '*This is the practice session. After you are done with practice, please click the "Start the Test" button.', pleaseAnswerCarefullyCiaq: '*璇疯鐪熶綔绛斻�傜壒鍒彁绀猴紝鏈祴楠屽叧娉ㄧ殑鏄綘瀵瑰悇绫绘椿鍔ㄧ殑鍏磋叮鎴栧枩濂斤紝鑰岄潪鑳藉姏绛夊叾浠栧洜绱狅紒', - exercise_note: 'The following are examples of work behaviours/title styles', - exercise_guide: 'Please read the statements below carefully, judge how far you agree with how each statement describes you, and then click on the appropriate option.', - exercise_note_1: 'The following are examples of basic skills past experience questions', - exercise_guide_1: 'How often you have used these basic skills in the past year and click on the appropriate option.', + exercise_start: 'Begtin practice', + exercise_note: 'Below are examples of work style items.', + exercise_guide: 'Please read the following statements carefully and determine the extent to which you agree that each statement describes you. Then, click the corresponding option.', + exercise_note_1: 'Below are examples of basic skills or past experience items.', + exercise_guide_1: 'Indicate how often you have used these basic skills in the past year, and click the corresponding option.', + exercise_submit_tip: 'You are done with the practice session. Please click the button to start the test.', submitTimeout: ':Submit background timeout', submitExceptionInfo: 'The server network is abnormal, please close the browser and click the link to answer the question', langWelcomeEnglish: 'Welcome to TAI鈥檚 testing website.', @@ -59,8 +61,8 @@ nextPartInfo: 'Please wait, please do not close the browser...', partRemailTime: 'Remaining Time:', finishIntelligenceInfo: 'You have completed the cognitive ability test questionnaire, the data has been successfully uploaded to the server, and has been saved. Thank you.', - finishPersonalityInfo: 'You have completed the personality quetionnaire, and the data has been successfully uploaded to the server and saved. ', - finishCareerInterestsInfo: 'You have completed the Career Interests quetionnaire, and the data has been successfully uploaded to the server and saved. ', + finishPersonalityInfo: 'You have completed the personality questionnaire, and the data has been successfully uploaded to the server and saved. ', + finishCareerInterestsInfo: 'You have completed the Career Interests questionnaire, and the data has been successfully uploaded to the server and saved. ', finishPersonalityDownInfo: 'You may click the button below to download your test report.', finishViewReportInfo: 'You can click on the button below to view your result report.', langWelcomeThai: '喔⑧复喔權笖喔掂笗喔笝喔`副喔氞釜喔灌箞喙�喔о箛喔氞箘喔嬥涪喙屶釜喔赤斧喔`副喔氞笚喔赤箒喔氞笟喔椸笖喔腑喔氞競喔竾', diff --git a/src/lang/th.js b/src/lang/th.js index b1cff6e..b9b55e6 100644 --- a/src/lang/th.js +++ b/src/lang/th.js @@ -29,7 +29,7 @@ finishSubmit: 'You have completed the work behavior questionnaire, and the data has been successfully uploaded to the server and saved. Thank you.', selectData: 'Date', startDo: 'Start the Test', - startDo_apifan: 'The test has officially started.', + startDo_apifan: 'Start the Test', second: ' second ', min: ' minute ', hour: ' hour ', @@ -42,12 +42,14 @@ uploadInfo: 'Uploading, saving data, please wait, do not close the browser...', examinee: 'Test-taker:', pleaseAnswerCarefully: '*Please answer carefully', - pleaseAnswerCarefully_exercise: '*This is a practice session, after the practice session, please click the "Start Test" button to take the test.', + pleaseAnswerCarefully_exercise: '*This is the practice session. After you are done with practice, please click the "Start the Test" button.', pleaseAnswerCarefullyCiaq: '*璇疯鐪熶綔绛斻�傜壒鍒彁绀猴紝鏈祴楠屽叧娉ㄧ殑鏄綘瀵瑰悇绫绘椿鍔ㄧ殑鍏磋叮鎴栧枩濂斤紝鑰岄潪鑳藉姏绛夊叾浠栧洜绱狅紒', - exercise_note: 'The following are examples of work behaviours/title styles', - exercise_guide: 'Please read the statements below carefully, judge how far you agree with how each statement describes you, and then click on the appropriate option.', - exercise_note_1: 'The following are examples of basic skills past experience questions', - exercise_guide_1: 'How often you have used these basic skills in the past year and click on the appropriate option.', + exercise_start: 'Begtin practice', + exercise_note: 'Below are examples of work style items.', + exercise_guide: 'Please read the following statements carefully and determine the extent to which you agree that each statement describes you. Then, click the corresponding option.', + exercise_note_1: 'Below are examples of basic skills or past experience items.', + exercise_guide_1: 'Indicate how often you have used these basic skills in the past year, and click the corresponding option.', + exercise_submit_tip: 'You are done with the practice session. Please click the button to start the test.', submitTimeout: ':Submit background timeout', submitExceptionInfo: 'The server network is abnormal, please close the browser and click the link to answer the question', langWelcomeEnglish: 'Welcome to TAI鈥檚 testing website.', diff --git a/src/lang/zh.js b/src/lang/zh.js index 339824d..90cca7d 100644 --- a/src/lang/zh.js +++ b/src/lang/zh.js @@ -44,10 +44,12 @@ pleaseAnswerCarefully: '*璇疯鐪熶綔绛�', pleaseAnswerCarefully_exercise: '*褰撳墠涓虹粌涔犵幆鑺傦紝缁冧範缁撴潫鍚庤鐐瑰嚮鈥滄寮忓紑濮嬫祴璇曗�濇寜閽寮忚繘琛屾祴璇曘��', pleaseAnswerCarefullyCiaq: '*璇疯鐪熶綔绛斻�傜壒鍒彁绀猴紝鏈祴楠屽叧娉ㄧ殑鏄綘瀵瑰悇绫绘椿鍔ㄧ殑鍏磋叮鎴栧枩濂斤紝鑰岄潪鑳藉姏绛夊叾浠栧洜绱狅紒', + exercise_start: '寮�濮嬬粌涔�', exercise_note: '浠ヤ笅涓哄伐浣滆涓�/棰樼洰椋庢牸鐨勪緥瀛�', exercise_guide: '璇蜂粩缁嗛槄璇讳笅闈㈢殑闄堣堪锛屽垽鏂偍鍦ㄥ澶х▼搴︿笂鍚屾剰姣忎竴闄堣堪瀵规偍鐨勬弿杩帮紝鐒跺悗鐐瑰嚮鐩稿簲鐨勯�夐」銆�', exercise_note_1: '浠ヤ笅涓哄熀鏈妧鑳借繃寰�缁忛獙棰樼洰鐨勪緥瀛�', exercise_guide_1: '鎮ㄥ湪杩囧幓涓�骞翠腑浣跨敤杩囪繖浜涘熀鏈妧鑳界殑棰戝害锛屽苟鐐瑰嚮鐩稿簲鐨勯�夐」銆�', + exercise_submit_tip: '浣犲凡缁忓畬鎴愪簡缁冧範锛岀偣鍑绘寜閽紑濮嬫寮忔祴璇曘��', submitTimeout: ':鎻愪氦鍚庡彴瓒呮椂', submitExceptionInfo: '淇濆瓨鏈嶅姟鍣ㄧ綉缁滃紓甯革紝璇峰叧闂祻瑙堥噸鏂扮偣鍑婚摼鎺ョ瓟棰�', langWelcomeEnglish: 'Welcome to TAI鈥檚 testing website.', diff --git a/src/layout/index.vue b/src/layout/index.vue index 6bbac61..8e5475e 100644 --- a/src/layout/index.vue +++ b/src/layout/index.vue @@ -49,6 +49,8 @@ } }, created () { + console.log('鐜鍙橀噺锛�') + console.log(process.env) }, watch: { logo: function (val) { @@ -60,6 +62,7 @@ this.logoUrl = require('@/assets/logo-t.png') } else if (val !== null) { this.logoUrl = val + this.backgroundColor = '#fff' } else if (sessionLogoUrl !== null) { this.logoUrl = sessionLogoUrl } diff --git a/src/views/exam/paper/exercise.vue b/src/views/exam/paper/exercise.vue index 0edbffc..6ac470e 100644 --- a/src/views/exam/paper/exercise.vue +++ b/src/views/exam/paper/exercise.vue @@ -17,13 +17,10 @@ <hr style="border : 0.5px dashed #b3d8ff;" /> <div style="color: red;font-size: smaller">{{$t('pleaseAnswerCarefully_exercise')}}</div> - <el-row class="do-align-center" v-if="itemOrder > 1"> - <el-button @click="doExam" type="success" round>{{$t('startDo_apifan')}}</el-button> - <el-button @click="preSubject" type="warning" round>{{$t('lastQuestion')}}</el-button> - </el-row> - <el-row class="do-align-center" v-if="itemOrder <= 1"> - <el-button @click="doExam" type="success" round>{{$t('startDo_apifan')}}</el-button> - <el-button @click="nextSubject" type="primary" round>{{$t('nextQuestion')}}</el-button> + <el-row class="do-align-center"> + <el-button v-if="isSubmit" @click="doExam" type="success" round>{{$t('startDo_apifan')}}</el-button> + <el-button v-if="isStart && !isLast" @click="preSubject" type="warning" round>{{$t('lastQuestion')}}</el-button> + <el-button v-if="isStart && isLast" @click="nextSubject" type="primary" round>{{$t('nextQuestion')}}</el-button> </el-row> </el-card> </el-row> @@ -68,26 +65,19 @@ name: this.$route.query.formDo.name }, itemOrder: 1, - itemSize: 2, + itemSize: 3, note: this.$t('exercise_note'), guide: this.$t('exercise_guide'), note_1: this.$t('exercise_note_1'), guide_1: this.$t('exercise_guide_1'), answer: { - answerItems: [ - { - content: '', - readOnly: false - }, - { - content: '', - readOnly: false - } - ] + answerItems: [] }, titleItems: [], questionItem: {}, - isSubmit: false + isSubmit: false, + isStart: false, + isLast: false } }, created: function () { @@ -104,29 +94,44 @@ initQuestion () { this.titleItems = [ { - questionItems: [ - this.formDo.titleItems[0].questionItems[0], - this.formDo.titleItems[0].questionItems[1] - ] + questionItems: [] } ] + for (let i = 0; i < this.itemSize; i++) { + this.titleItems[0].questionItems.push(this.formDo.titleItems[0].questionItems[i]) + } this.questionItem = this.titleItems[0].questionItems[this.itemOrder - 1] + + for (let i = 0; i < this.itemSize; i++) { + let data = { + content: '', + readOnly: false + } + this.answer.answerItems.push(data) + } }, nextSubject () { - console.log(this.answer) - console.log('formDo') - console.log(this.formDo) - if (this.itemOrder === 2) { + this.isStart = true + this.isLast = false + if (this.itemOrder === this.itemSize) { this.isSubmit = true + this.$message({ + message: this.$t('exercise_submit_tip'), + type: 'success' + }) return } - this.itemOrder = 2 + this.itemOrder += 1 this.answer.answerItems[this.itemOrder - 1].readOnly = false this.questionItem = this.titleItems[0].questionItems[this.itemOrder - 1] + if (this.itemOrder === this.itemSize && this.answer.answerItems[this.itemOrder - 1].content !== '') { + this.isSubmit = true + } }, preSubject () { + this.isLast = true this.isSubmit = false - this.itemOrder = 1 + this.itemOrder -= 1 this.answer.answerItems[this.itemOrder - 1].readOnly = false this.questionItem = this.titleItems[0].questionItems[this.itemOrder - 1] }, diff --git a/src/views/exam/paper/guide.vue b/src/views/exam/paper/guide.vue index 32b922f..10122c4 100644 --- a/src/views/exam/paper/guide.vue +++ b/src/views/exam/paper/guide.vue @@ -9,7 +9,7 @@ <el-row class="do-align-center"> <el-button v-if="formDo.questionTemplateId !== 'personality'" @click="doExam" type="primary" round>{{$t('startDo')}}</el-button> <el-button v-if="formDo.questionTemplateId === 'job'" @click="openExplain" type="danger" round>鎵撳紑宀椾綅璇存槑</el-button> - <el-button v-if="formDo.questionTemplateId === 'personality'" @click="openExercise" type="primary" round>缁х画</el-button> + <el-button v-if="formDo.questionTemplateId === 'personality'" @click="openExercise" type="primary" round>{{$t('exercise_start')}}</el-button> </el-row> </el-main> </el-container> -- Gitblit v1.9.1