From 8cdcb6b7950710cbcf701cb5149e1b2f949e1b0f Mon Sep 17 00:00:00 2001 From: 闫增涛 <1829501689@qq.com> Date: 星期三, 15 五月 2024 11:50:57 +0800 Subject: [PATCH] 题目资源 --- src/books/childHealth/view/content/components/chapter003.vue | 22 src/assets/js/config.js | 2 src/store/index.js | 6 src/books/childHealth/view/content/components/chapter0004.vue | 17 src/books/childHealth/view/content/components/chapter008.vue | 20 src/books/childHealth/view/content/components/chapter006.vue | 26 public/information.json | 10 src/assets/methods/examination.js | 349 +++++++----- src/books/childHealth/view/content/components/chapter011.vue | 52 + src/books/childHealth/view/content/components/chapter002.vue | 23 src/books/childHealth/view/content/index.vue | 18 /dev/null | 145 ----- src/books/childHealth/view/content/components/chapter010.vue | 17 src/books/childHealth/view/content/components/chapter007.vue | 26 src/books/childHealth/view/content/components/chapter009.vue | 17 src/books/childHealth/assets/examinationList.js | 147 +++++ src/books/childHealth/view/content/components/chapter005.vue | 25 src/books/childHealth/view/index.vue | 20 src/components/examinations/index.vue | 517 ++++++++++--------- src/assets/methods/resources.js | 6 src/books/childHealth/view/content/components/chapter001.vue | 89 +- 21 files changed, 874 insertions(+), 680 deletions(-) diff --git a/public/information.json b/public/information.json index 5998ba9..b579e88 100644 --- a/public/information.json +++ b/public/information.json @@ -2,17 +2,23 @@ { "label": "涓撻涓� 瀛﹀墠鍎跨鐢熺悊鍙戣偛鐗圭偣涓庝繚鍋�", "id": "a008", - "page":1, + "page":1, + "start":1, + "end":42, "children": [ { "label": "瀛︿範涓婚涓� 杩愬姩绯荤粺", "id": "b001", "page":2, + "start":2, + "end":6, "children": [ { "label": "涓�銆佸鍓嶅効绔ヨ繍鍔ㄧ郴缁熺殑鐗圭偣", "id": "c001", - "page":2 + "page":2, + "start":2, + "end":4 } ] } diff --git a/src/assets/js/config.js b/src/assets/js/config.js index df755b0..6e59257 100644 --- a/src/assets/js/config.js +++ b/src/assets/js/config.js @@ -1,6 +1,6 @@ // export const requestCtx = "http://182.92.203.7:3001"; // 璇锋眰鍦板潃 // export const appId = 27; -export const requestCtx = "http://jsysf.bnuic.com"; // 璇锋眰鍦板潃 +export const requestCtx = "https://jsek.bnuic.com"; // 璇锋眰鍦板潃 export const resourceCtx = "http://182.92.203.7:3007/books/resource/1"; // 璧勬簮璇锋眰鍦板潃 export const publicCtx = "http://182.92.203.7:3007/books/book/1"; // 璧勬簮璇锋眰鍦板潃 export const bookList = [ diff --git a/src/assets/methods/examination.js b/src/assets/methods/examination.js index 132c0ed..7ebe2ad 100644 --- a/src/assets/methods/examination.js +++ b/src/assets/methods/examination.js @@ -1,152 +1,207 @@ -import {activeBook} from '@/assets/js/config' -import MG from '@/assets/js/middleGround/WebMiddleGroundApi' - const getQuestionList = (rootCmsItemId,questionList) => { +import { activeBook } from "@/assets/js/config"; +import MG from "@/assets/js/middleGround/WebMiddleGroundApi"; +import getPublicImage from '@/assets/js/middleGround/tool' +const getQuestionList = (rootCmsItemId, questionList) => { + let questionArr = []; let cardList = [ - + { + catalogName: "鍗曢�夐", + infoList: [], + }, + { + catalogName: "鍒ゆ柇棰�", + infoList: [], + }, + { + catalogName: "澶氶�夐", + infoList: [], + }, + { + catalogName: "濉┖棰�", + infoList: [], + }, + { + catalogName: "绠�绛旈", + infoList: [], + }, ]; - let query = { - path: '*', - cmsPath: rootCmsItemId, - cmsType: '*', - productId: activeBook.bookId, - queryType: '*', - itemIds: questionList.map((item) => item + ''), - itemFields: { - Embedded_QuestionBank_Stem: [], - Embedded_QuestionBank_AnalysisCon: [], - Embedded_QuestionBank_Answer: [], - Embedded_QuestionBank_Option: [], - Embedded_QuestionBank_QuestionType: [], - Embedded_QuestionBank_StemStyle: [], - Embedded_QuestionBank_OptionStyle: [], - Embedded_QuestionBank_KnowledgePoint: [], - Embedded_QuestionBank_Difficulty: [] + let singleChoiceArr = []; // 鍗曢�� + let judgeArr = []; // 鍒ゆ柇 + let shortArr = []; // 绠�绛� + let multipleChoiceArr = []; // 澶氶�� + let completionArr = []; // 濉┖ + for (let qindex = 0; qindex < questionList.length; qindex++) { + const qitem = questionList[qindex]; + let query = { + path: "*", + cmsPath: rootCmsItemId, + cmsType: "*", + productId: activeBook.bookId, + queryType: "*", + itemIds: qitem + "", + itemFields: { + Embedded_QuestionBank_Stem: [], + Embedded_QuestionBank_AnalysisCon: [], + Embedded_QuestionBank_Answer: [], + Embedded_QuestionBank_Option: [], + Embedded_QuestionBank_QuestionType: [], + Embedded_QuestionBank_StemStyle: [], + Embedded_QuestionBank_OptionStyle: [], + Embedded_QuestionBank_KnowledgePoint: [], + Embedded_QuestionBank_Difficulty: [], + }, + }; + MG.store.getProductDetail(query).then((res) => { + res.datas.cmsDatas[0].datas.forEach((item, index) => { + const questionObj = { + number: index + 1, // 棰樺彿 + id: item.id, + stem: item.Embedded_QuestionBank_QuestionType == "completion" ? + JSON.parse(item.Embedded_QuestionBank_Stem) + .stemTxt.replaceAll("<vacancy>", ",input,") + .split(",") : JSON.parse(item.Embedded_QuestionBank_Stem), // 棰樺共 + answer: item.Embedded_QuestionBank_Answer, // 绛旀 + option: item.Embedded_QuestionBank_Option ? + JSON.parse(item.Embedded_QuestionBank_Option) : "", // 閫夋嫨棰橀�夐」 + analysisCon: item.Embedded_QuestionBank_AnalysisCon, // 瑙f瀽 + questionType: item.Embedded_QuestionBank_QuestionType, // 棰樺瀷 + optionStyle: item.Embedded_QuestionBank_OptionStyle, // 閫夐」鏄剧ず绫诲瀷 + stemStyle: item.Embedded_QuestionBank_StemStyle, // 棰樺共鏄剧ず绫诲瀷 + difficulty: item.Embedded_QuestionBank_Difficulty ? + 4 - item.Embedded_QuestionBank_Difficulty : 0, // 闅惧害绛夌骇 + userAnswer: item.Embedded_QuestionBank_QuestionType == "completion" || + item.Embedded_QuestionBank_QuestionType == "multipleChoice" ? [] : "", + isSubmit: false, // 鏌ョ湅瑙f瀽 + isRight: null, // 鏄惁姝g‘ + isComplete: false, + isCollect: true, + isUnfold:'' + }; + // 澶氶�夊拰濉┖绛旀鑲负鏁扮粍锛岃杞崲JSON鏍煎紡 + if ( + questionObj.questionType == "completion" || + questionObj.questionType == "multipleChoice" + ) { + try { + questionObj.answer = JSON.parse(questionObj.answer).toString(); + } catch (error) { + questionObj.answer = item.Embedded_QuestionBank_Answer; + } + } + // 濉┖棰樻敼閫� + if (questionObj.questionType == "completion") { + let index = 0; + for (let i = 0; i < questionObj.stem.length; i++) { + const item = questionObj.stem[i]; + if (item == "input") { + questionObj.stem[i] = { + num: index, + data: "input", + }; + questionObj.userAnswer[index] = ""; + index++; + } + } + } + // 鑾峰彇鍥剧墖 + if ( + questionObj.stemStyle == "Image" || + questionObj.stemStyle == "TxtAndImage" + ) { + questionObj.stem.stemImage = getPublicImage( + questionObj.stem.stemImage, + 150 + ); + } + if ( + questionObj.optionStyle == "Image" || + questionObj.optionStyle == "TxtAndImage" + ) { + questionObj.option.forEach((optionItem) => { + if (optionItem.img) + optionItem.img = getPublicImage(optionItem.img, 150); + }); + } + // 棰樺共瀵屾枃鏈鐞� + if (questionObj.stemStyle == "RichText") { + // questionObj.option.txt = '' + questionObj.stem.stemTxt = questionObj.stem.stemTxt + .replace( + /\<img/gi, + '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img" ' + ) + .replace(/\<p/gi, '<p class="stem-rich-p"').replace('../file', app.config.requestCtx + '/file'); + } + // 閫夐」瀵屾枃鏈鐞� + if ( + questionObj.optionStyle == "RichText" && + (questionObj.questionType == "singleChoice" || + questionObj.questionType == "judge" || + questionObj.questionType == "multipleChoice") + ) { + questionObj.option.forEach((item) => { + if (item.txt) + item.txt = item.txt + .replace(/\<img/gi, '<img class="option-rich-img"') + .replace(/\<p/gi, '<p class="stem-rich-p"').replace('../file', app.config.requestCtx + '/file'); + }); + } + // 瑙f瀽瀵屾枃鏈鐞� + if ( + questionObj.analysisCon && + typeof questionObj.analysisCon == "string" + ) { + questionObj.analysisCon = questionObj.analysisCon.replace( + /\<img/gi, + '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img" ' + ); + } + // 鍚姏棰樹慨鏀� + // if (questionObj.questionType == 'singleChoice') { + // const src = this.extractSourceSrc(questionObj.stem.stemTxt) + // if (src) { + // questionObj.src = src + // questionObj.stem.stemTxt = this.removeVideoAndAudioTags(questionObj.stem.stemTxt) + // } + // } + if (item.Embedded_QuestionBank_QuestionType == "judge") { + questionObj.type = "鍒ゆ柇棰�"; + judgeArr.push(questionObj); + } else if ( + item.Embedded_QuestionBank_QuestionType == "singleChoice" + ) { + questionObj.type = "鍗曢�夐"; + singleChoiceArr.push(questionObj); + } else if ( + item.Embedded_QuestionBank_QuestionType == "multipleChoice" + ) { + questionObj.type = "澶氶�夐"; + multipleChoiceArr.push(questionObj); + } else if (item.Embedded_QuestionBank_QuestionType == "completion") { + questionObj.type = "濉┖棰�"; + completionArr.push(questionObj); + } else if (item.Embedded_QuestionBank_QuestionType == "shortAnswer") { + questionObj.type = "绠�绛旈"; + shortArr.push(questionObj); + } + }); + }); + } + cardList[0].infoList = singleChoiceArr, + cardList[1].infoList = judgeArr + cardList[2].infoList = multipleChoiceArr + cardList[3].infoList = completionArr + cardList[4].infoList = shortArr + for (let index = 0; index < cardList.length; index++) { + const item = cardList[index]; + for (let cindex = 0; cindex < item.infoList.length; cindex++) { + const citem = item.infoList[cindex]; + citem.number = cindex + 1; + questionArr.push(citem); } } - MG.store.getProductDetail(query).then((res) => { - console.log('棰樼洰鍒楄〃',res); - // res.datas.cmsDatas[0].datas.forEach((item, index) => { - // let oldObj = ""; - // if (oldList) - // oldObj = oldList.find((oldItem) => oldItem.id == item.id); - // let questionObj = { - // // num: index, // 棰樺彿 - // id: item.id, - // type: pathitem.name, - // stem: - // item.Embedded_QuestionBank_QuestionType == "completion" - // ? JSON.parse(item.Embedded_QuestionBank_Stem) - // .stemTxt.replaceAll("<vacancy>", ",input,") - // .split(",") - // : JSON.parse(item.Embedded_QuestionBank_Stem), // 棰樺共 - // answer: item.Embedded_QuestionBank_Answer, // 绛旀 - // option: item.Embedded_QuestionBank_Option - // ? JSON.parse(item.Embedded_QuestionBank_Option) - // : "", // 閫夋嫨棰橀�夐」 - // analysisCon: item.Embedded_QuestionBank_AnalysisCon, // 瑙f瀽 - // questionType: item.Embedded_QuestionBank_QuestionType, // 棰樺瀷 - // optionStyle: item.Embedded_QuestionBank_OptionStyle, // 閫夐」鏄剧ず绫诲瀷 - // stemStyle: item.Embedded_QuestionBank_StemStyle, // 棰樺共鏄剧ず绫诲瀷 - // difficulty: item.Embedded_QuestionBank_Difficulty - // ? 4 - item.Embedded_QuestionBank_Difficulty - // : 0, // 闅惧害绛夌骇 - // userAnswer: oldObj - // ? oldObj.userAnswer - // : item.Embedded_QuestionBank_QuestionType == "completion" || - // item.Embedded_QuestionBank_QuestionType == "multipleChoice" - // ? [] - // : "", - // isUserAnswer: oldObj - // ? this.isHaveAnswer(oldObj.userAnswer) - // : false, - // isRight: oldObj ? oldObj.isRight : null, - // isComplete: oldObj ? oldObj.isComplete : false, - // isCollect: false, - // isUnfold: "", // 鎺у埗瑙f瀽鐨勬姌鍙犻潰鏉挎槸鍚﹀睍寮� - // }; - // // 澶氶�夊拰濉┖绛旀鑲负鏁扮粍锛岃杞崲JSON鏍煎紡 - // if ( - // questionObj.questionType == "completion" || - // questionObj.questionType == "multipleChoice" - // ) { - // try { - // questionObj.answer = JSON.parse(questionObj.answer).toString(); - // } catch (error) { - // questionObj.answer = item.Embedded_QuestionBank_Answer; - // } - // } - // // 濉┖棰樻敼閫� - // if (questionObj.questionType == "completion") { - // let index = 0; - // for (let i = 0; i < questionObj.stem.length; i++) { - // const item = questionObj.stem[i]; - // if (item == "input") { - // questionObj.stem[i] = { - // num: index, - // data: "input", - // }; - // if (!oldObj) questionObj.userAnswer[index] = ""; - // index++; - // } - // } - // } - // // 棰樺共瀵屾枃鏈鐞� - // if (questionObj.stemStyle == "RichText") { - // // questionObj.option.txt = '' - // questionObj.stem.stemTxt = questionObj.stem.stemTxt - // .replace( - // /\<img/gi, - // '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img" ' - // ) - // .replace(/\<p/gi, '<p class="stem-rich-p"') - // .replace("../file", app.config.requestCtx + "/file"); - // } - // // 閫夐」瀵屾枃鏈鐞� - // if ( - // questionObj.optionStyle == "RichText" && - // (questionObj.questionType == "singleChoice" || - // questionObj.questionType == "judge" || - // questionObj.questionType == "multipleChoice") - // ) { - // questionObj.option.forEach((item) => { - // if (item.txt) - // item.txt = item.txt - // .replace(/\<img/gi, '<img class="option-rich-img"') - // .replace(/\<p/gi, '<p class="stem-rich-p"') - // .replace("../file", app.config.requestCtx + "/file"); - // }); - // } - // // 瑙f瀽瀵屾枃鏈鐞� - // if ( - // questionObj.analysisCon && - // typeof questionObj.analysisCon == "string" - // ) { - // questionObj.analysisCon = questionObj.analysisCon.replace( - // /\<img/gi, - // '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img" ' - // ); - // } - // if ( - // questionObj.stemStyle == "Image" || - // questionObj.stemStyle == "TxtAndImage" - // ) { - // questionObj.stem.stemImage = getPublicImage( - // questionObj.stem.stemImage, - // 150 - // ); - // } - // if ( - // questionObj.optionStyle == "Image" || - // questionObj.optionStyle == "TxtAndImage" - // ) { - // questionObj.option.forEach((optionItem) => { - // if (optionItem.img) - // optionItem.img = getPublicImage(optionItem.img, 150); - // }); - // } - // return cardList - // }); - }) -} + console.log(cardList); + return cardList +}; -export default getQuestionList +export default getQuestionList; diff --git a/src/assets/methods/resources.js b/src/assets/methods/resources.js new file mode 100644 index 0000000..4a2db4f --- /dev/null +++ b/src/assets/methods/resources.js @@ -0,0 +1,6 @@ +import config from "../js/config" +const getResourcePath = (md5) => { + return config.requestCtx + '/file/api/ApiDownload?md5=' + md5 +} + +export default getResourcePath \ No newline at end of file diff --git a/src/books/childHealth/assets/examinationList.js b/src/books/childHealth/assets/examinationList.js new file mode 100644 index 0000000..d3c3716 --- /dev/null +++ b/src/books/childHealth/assets/examinationList.js @@ -0,0 +1,147 @@ + const testData = { + 1: { + 2: [63795, 63796, 63797, 63798, 63804], + 6:[65859, 65860, 65861, 65862], + 9:[65863, 65864, 65865, 65866, 65867, 65868, 65869], + 14:[65870, 65871, 65872, 65873, 65874], + 19:[65875, 65876, 65877, 65878, 65879, 65880, 65881, 65882], + 24:[65883, 65884, 65885, 65886], + 26:[65887, 65888, 65889, 65890, 65891, 65892], + 31:[65905, 65906, 65907, 65908, 65909], + 40:[ + 65910, 65911, 65912, 65913, 65914, 65915, 65916, 65917, 65918, 65919, + 65920 + ], + 42_1:[ + 65944, 65945, 65946, 65947, 65948, 65949, 65950, 65951, 65952, 65953, + 65954, 65955, 65956, 65957, 65958, 65959 + ], + 42_2:[ + 65962, 65963, 65964, 65965, 65966, 65967, 65968, 65969, 65970, 65971, + 65972, 65973, 65974, 65975, 65976, 65977 + ] + }, + 2:{ + 46:[65979, 65980, 65981], + 49:[65983, 65984], + 52:[65986, 65987], + 54_1:[65990, 65991, 65992, 65993, 65994, 65995, 65996, 65997, 65998, 65999, + 66000, 66001, 66002, 66003, 66004, 66005], + 54_2:[66008, 66009, 66010, 66011, 66012, 66013, 66014, 66015, 66016, 66017, + 66018, 66019, 66020, 66021, 66022, 66023] + }, + 3:{ + 64:[66025, 66026, 66027, 66028, 66029], + 73:[66031, 66032, 66033, 66034, 66035], + 78:[66037, 66038, 66039, 66040, 66041, 66042], + 80_1: [ + 66051, 66052, 66053, 66054, 66055, 66056, 66057, 66058, 66059, 66060, + 66045, 66046, 66047, 66048, 66049, 66050 + ], + 80_2:[ + 66063, 66064, 66065, 66066, 66067, 66068, 66069, 66070, 66071, 66072, + 66073, 66074, 66075, 66076, 66077, 66078 + ] + }, + 4:{ + 91:[66080, 66081, 66082], + 97:[66084, 66085], + 98_1:[ + 66102, 66103, 66104, 66105, 66106, 66107, 66108, 66109, 66110, 66111, + 66090, 66091, 66092, 66093, 66094, 66095 + ], + 98_2:[ + 66112, 66113, 66114, 66115, 66116, 66117, 66118, 66119, 66120, 66121, + 66096, 66097, 66098, 66099, 66100, 66101 + ] + }, + 5:{ + 119:[66125, 66126, 66127, 66128, 66129, 66130, 66131], + 124:[66134, 66135, 66136, 66137, 66138], + 129:[66144, 66145, 66146, 66147, 66148], + 133:[66150, 66151, 66152, 66153, 66154], + 134_1:[ + 66159, 66160, 66161, 66162, 66163, 66164, 66165, 66166, 66167, 66168, + 66179, 66180, 66181, 66182, 66183, 66184 + ], + 134_2:[ + 66169, 66170, 66171, 66172, 66173, 66174, 66175, 66176, 66177, 66178, + 66185, 66186, 66187, 66188, 66189, 66190 + ] + }, + 6:{ + 142:[66192, 66193, 66194, 66195, 66196], + 152:[66198, 66199, 66200, 66201, 66202], + 156:[66204, 66205, 66206, 66207, 66208], + 159:[66210, 66211, 66212], + 164:[66214, 66215, 66216, 66217, 66218], + 166_1:[ + 66223, 66224, 66225, 66226, 66227, 66228, 66229, 66230, 66231, 66232, + 66243, 66244, 66245, 66246, 66247, 66248 + ], + 166_2:[ + 66233, 66234, 66235, 66236, 66237, 66238, 66239, 66240, 66241, 66242, + 66249, 66250, 66251, 66252, 66253, 66254 + ] + }, + 7:{ + 169:[66261, 66262, 66263], + 174:[66265, 66266, 66267], + 177:[66269, 66270, 66271], + 188:[666273, 66274, 66275, 66276, 66277, 66278, 66279], + 207:[ + 66287, 66288, 66289, 66290, 66291, 66292, 66293, 66294, 66295, 66296, + 66297, 66298 + ], + 209_1:[ + 66303, 66304, 66305, 66306, 66307, 66308, 66309, 66310, 66311, 66312, + 66323, 66324, 66325, 66326, 66327, 66328 + ], + 209_2:[ + 66313, 66314, 66315, 66316, 66317, 66318, 66319, 66320, 66321, 66322, + 66329, 66330, 66331, 66332, 66333, 66334 + ] + }, + 8:{ + 215:[66336, 66337, 66338, 66339], + 227:[ + 66341, 66342, 66343, 66344, 66345, 66346, 66347, 66348, 66349, 66350, + 66351, 66352, 66353, 66354 + ], + 232:[66356, 66357, 66358], + 234_1:[ + 66363, 66364, 66365, 66366, 66367, 66368, 66369, 66370, 66371, 66372, + 66383, 66384, 66385, 66386, 66387, 66388 + ], + 234_2:[ + 66373, 66374, 66375, 66376, 66377, 66378, 66379, 66380, 66381, 66382, + 66389, 66390, 66391, 66392, 66393, 66394 + ] + }, + 9:{ + 243:[66396,66397,66398,66399,66400], + 255:[66412,66413,66414,66415,66416], + 256_1:[66418,66419,66420,66421,66422,66423,66424,66425,66426,66427,66438,66439,66440,66441,66442,66443], + 256_2:[66428,66429,66430,66431,66432,66433,66434,66435,66436,66437,66402,66403,66404,66405,66406,66407] + }, + 10:{ + 267:[66445,66446,66447,66448,66449,66450], + 272:[66455,66456,66457,66458,66459], + 273_1:[66469,66470,66471,66472,66473,66474,66475,66476,66477,66478,66502,66503,66504,66505,66506,66507], + 273_2:[66479,66480,66481,66482,66483,66484,66485,66486,66487,66488,66495,66496,66497,66498,66499,66500] + }, + 11:{ + 274_1:[66529,66530,66531,66532,66533,66534,66535,66536,66537,66538,66629,66630,66631,66632,66633,66634], + 274_2:[66539,66540,66541,66542,66543,66544,66545,66546,66547,66548,66635,66636,66637,66638,66639,66640], + 274_3:[66549,66550,66551,66552,66553,66554,66555,66556,66557,66558,66643,66644,66645,66646,66647,66648], + 274_4:[66559,66560,66561,66562,66563,66564,66565,66566,66567,66568,66650,66651,66652,66653,66654,66655], + 274_5:[66569,66570,66571,66572,66573,66574,66575,66576,66577,66578,66657,66658,66659,66660,66661,66662], + 274_6:[66579,66580,66581,66582,66583,66584,66585,66586,66587,66588,66663,66664,66665,66666,66667,66668], + 274_7:[66589,66590,66591,66592,66593,66594,66595,66596,66597,66598,66669,66670,66671,66672,66673,66674], + 274_8:[66599,66600,66601,66602,66603,66604,66605,66606,66607,66608,66675,66676,66677,66678,66679,66680], + 274_9:[66609,66610,66611,66612,66613,66614,66615,66616,66617,66618,66681,66682,66683,66684,66685,66686], + 274_10:[66619,66620,66621,66622,66623,66624,66625,66626,66627,66628,66688,66689,66690,66691,66692,66693], + } +} + +export default testData diff --git a/src/books/childHealth/assets/examinationList.json b/src/books/childHealth/assets/examinationList.json deleted file mode 100644 index bad4a45..0000000 --- a/src/books/childHealth/assets/examinationList.json +++ /dev/null @@ -1,145 +0,0 @@ - { - "1": { - "2": [63795, 63796, 63797, 63798, 63804], - "6":[65859, 65860, 65861, 65862], - "9":[65863, 65864, 65865, 65866, 65867, 65868, 65869], - "14":[65870, 65871, 65872, 65873, 65874], - "19":[65875, 65876, 65877, 65878, 65879, 65880, 65881, 65882], - "24":[65883, 65884, 65885, 65886], - "26":[65887, 65888, 65889, 65890, 65891, 65892], - "31":[65905, 65906, 65907, 65908, 65909], - "40":[ - 65910, 65911, 65912, 65913, 65914, 65915, 65916, 65917, 65918, 65919, - 65920 - ], - "42-1":[ - 65944, 65945, 65946, 65947, 65948, 65949, 65950, 65951, 65952, 65953, - 65954, 65955, 65956, 65957, 65958, 65959 - ], - "42-2":[ - 65962, 65963, 65964, 65965, 65966, 65967, 65968, 65969, 65970, 65971, - 65972, 65973, 65974, 65975, 65976, 65977 - ] - }, - "2":{ - "46":[65979, 65980, 65981], - "49":[65983, 65984], - "52":[65986, 65987], - "54-1":[65990, 65991, 65992, 65993, 65994, 65995, 65996, 65997, 65998, 65999, - 66000, 66001, 66002, 66003, 66004, 66005], - "54-2":[66008, 66009, 66010, 66011, 66012, 66013, 66014, 66015, 66016, 66017, - 66018, 66019, 66020, 66021, 66022, 66023] - }, - "3":{ - "64":[66025, 66026, 66027, 66028, 66029], - "73":[66031, 66032, 66033, 66034, 66035], - "78":[66037, 66038, 66039, 66040, 66041, 66042], - "80-1": [ - 66051, 66052, 66053, 66054, 66055, 66056, 66057, 66058, 66059, 66060, - 66045, 66046, 66047, 66048, 66049, 66050 - ], - "80-2":[ - 66063, 66064, 66065, 66066, 66067, 66068, 66069, 66070, 66071, 66072, - 66073, 66074, 66075, 66076, 66077, 66078 - ] - }, - "4":{ - "91":[66080, 66081, 66082], - "97":[66084, 66085], - "98-1":[ - 66102, 66103, 66104, 66105, 66106, 66107, 66108, 66109, 66110, 66111, - 66090, 66091, 66092, 66093, 66094, 66095 - ], - "98-2":[ - 66112, 66113, 66114, 66115, 66116, 66117, 66118, 66119, 66120, 66121, - 66096, 66097, 66098, 66099, 66100, 66101 - ] - }, - "5":{ - "119":[66125, 66126, 66127, 66128, 66129, 66130, 66131], - "124":[66134, 66135, 66136, 66137, 66138], - "129":[66144, 66145, 66146, 66147, 66148], - "133":[66150, 66151, 66152, 66153, 66154], - "134-1":[ - 66159, 66160, 66161, 66162, 66163, 66164, 66165, 66166, 66167, 66168, - 66179, 66180, 66181, 66182, 66183, 66184 - ], - "134-2":[ - 66169, 66170, 66171, 66172, 66173, 66174, 66175, 66176, 66177, 66178, - 66185, 66186, 66187, 66188, 66189, 66190 - ] - }, - "6":{ - "142":[66192, 66193, 66194, 66195, 66196], - "152":[66198, 66199, 66200, 66201, 66202], - "156":[66204, 66205, 66206, 66207, 66208], - "159":[66210, 66211, 66212], - "164":[66214, 66215, 66216, 66217, 66218], - "166-1":[ - 66223, 66224, 66225, 66226, 66227, 66228, 66229, 66230, 66231, 66232, - 66243, 66244, 66245, 66246, 66247, 66248 - ], - "166-2":[ - 66233, 66234, 66235, 66236, 66237, 66238, 66239, 66240, 66241, 66242, - 66249, 66250, 66251, 66252, 66253, 66254 - ] - }, - "7":{ - "169":[66261, 66262, 66263], - "174":[66265, 66266, 66267], - "177":[66269, 66270, 66271], - "188":[666273, 66274, 66275, 66276, 66277, 66278, 66279], - "207":[ - 66287, 66288, 66289, 66290, 66291, 66292, 66293, 66294, 66295, 66296, - 66297, 66298 - ], - "209-1":[ - 66303, 66304, 66305, 66306, 66307, 66308, 66309, 66310, 66311, 66312, - 66323, 66324, 66325, 66326, 66327, 66328 - ], - "209-2":[ - 66313, 66314, 66315, 66316, 66317, 66318, 66319, 66320, 66321, 66322, - 66329, 66330, 66331, 66332, 66333, 66334 - ] - }, - "8":{ - "215":[66336, 66337, 66338, 66339], - "227":[ - 66341, 66342, 66343, 66344, 66345, 66346, 66347, 66348, 66349, 66350, - 66351, 66352, 66353, 66354 - ], - "232":[66356, 66357, 66358], - "234-1":[ - 66363, 66364, 66365, 66366, 66367, 66368, 66369, 66370, 66371, 66372, - 66383, 66384, 66385, 66386, 66387, 66388 - ], - "234-2":[ - 66373, 66374, 66375, 66376, 66377, 66378, 66379, 66380, 66381, 66382, - 66389, 66390, 66391, 66392, 66393, 66394 - ] - }, - "9":{ - "243":[66396,66397,66398,66399,66400], - "255":[66412,66413,66414,66415,66416], - "256-1":[66418,66419,66420,66421,66422,66423,66424,66425,66426,66427,66438,66439,66440,66441,66442,66443], - "256-2":[66428,66429,66430,66431,66432,66433,66434,66435,66436,66437,66402,66403,66404,66405,66406,66407] - }, - "10":{ - "267":[66445,66446,66447,66448,66449,66450], - "272":[66455,66456,66457,66458,66459], - "273-1":[66469,66470,66471,66472,66473,66474,66475,66476,66477,66478,66502,66503,66504,66505,66506,66507], - "273-2":[66479,66480,66481,66482,66483,66484,66485,66486,66487,66488,66495,66496,66497,66498,66499,66500] - }, - "12":{ - "274-1":[66529,66530,66531,66532,66533,66534,66535,66536,66537,66538,66629,66630,66631,66632,66633,66634], - "274-2":[66539,66540,66541,66542,66543,66544,66545,66546,66547,66548,66635,66636,66637,66638,66639,66640], - "274-3":[66549,66550,66551,66552,66553,66554,66555,66556,66557,66558,66643,66644,66645,66646,66647,66648], - "274-4":[66559,66560,66561,66562,66563,66564,66565,66566,66567,66568,66650,66651,66652,66653,66654,66655], - "274-5":[66569,66570,66571,66572,66573,66574,66575,66576,66577,66578,66657,66658,66659,66660,66661,66662], - "274-6":[66579,66580,66581,66582,66583,66584,66585,66586,66587,66588,66663,66664,66665,66666,66667,66668], - "274-7":[66589,66590,66591,66592,66593,66594,66595,66596,66597,66598,66669,66670,66671,66672,66673,66674], - "274-8":[66599,66600,66601,66602,66603,66604,66605,66606,66607,66608,66675,66676,66677,66678,66679,66680], - "274-9":[66609,66610,66611,66612,66613,66614,66615,66616,66617,66618,66681,66682,66683,66684,66685,66686], - "274-10":[66619,66620,66621,66622,66623,66624,66625,66626,66627,66628,66688,66689,66690,66691,66692,66693], - } -} diff --git a/src/books/childHealth/view/content/components/chapter0004.vue b/src/books/childHealth/view/content/components/chapter0004.vue index 00f4f3c..fe6379d 100644 --- a/src/books/childHealth/view/content/components/chapter0004.vue +++ b/src/books/childHealth/view/content/components/chapter0004.vue @@ -678,7 +678,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0104-1.jpg" /><br /> --> - <span class="img">涓撻鍥� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻鍥� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[4][91]" /> </p> <h2 class="module_block" id="b017"> <div class="custom1">瀛︿範涓婚浜�</div> @@ -1086,7 +1087,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c center"> - <span class="img">涓撻鍥� 瀛︿範涓婚浜�</span> + <!-- <span class="img">涓撻鍥� 瀛︿範涓婚浜�</span> --> + <examinations :cardList="questionData[4][97]" /> </p> <h6 class="Conclusion-title4">涓撻灏忕粨</h6> <p class="blockh6"> @@ -1148,10 +1150,10 @@ </h6> <p class="blockh6-c"> 瀛︿範瀹屾湰涓撻锛屼綘鐨勫涔犳晥鏋滃浣曞憿锛熷挶浠竴璧锋潵鎵爜娴嬩竴娴嬪惂锛�<br /> - <!-- <img class="img-a" alt="" src="image/0111-1.jpg" /><br /> --> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級1</span><br /> - <!-- <img class="img-g" alt="" src="image/0111-2.jpg" /><br /> --> + <examinations :cardList="questionData[4][981]" /> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級2</span> + <examinations :cardList="questionData[4][982]" /> </p> <p class="custom_tag">鈥㈠簲鐢ㄤ笌鎺㈣鈥�</p> <p>1.娴嬮噺骞煎効鐨勮韩楂樸�佷綋閲嶃�佸ご鍥村拰鑳稿洿銆�</p> @@ -1184,16 +1186,21 @@ <script> import evenHeader from "../../components/pageHeader/evenHeader.vue"; import oddHeader from "../../components/pageHeader/oddHeader.vue"; +import examinations from "@/components/examinations/index.vue"; export default { - components: { evenHeader, oddHeader }, + components: { evenHeader, oddHeader,examinations }, data() { return { learn: require("../../../assets/images/chapterFour/0094-1.jpg"), taskOne: require("../../../assets/images/chapterFour/task-sheet1.png"), learnTableOne:true, learnTableTwo:true, + questionData:{} }; }, + mounted() { + this.$data.questionData = this.$store.state.questionData + }, methods:{ changeResources(type) { if (type == "learnTableOne") { diff --git a/src/books/childHealth/view/content/components/chapter001.vue b/src/books/childHealth/view/content/components/chapter001.vue index 3e2e9e4..519bd5e 100644 --- a/src/books/childHealth/view/content/components/chapter001.vue +++ b/src/books/childHealth/view/content/components/chapter001.vue @@ -236,8 +236,8 @@ <examinations v-if="testOne" ref="examinationOne" - :productLinkPath="productLinkPath" - ></examinations> + :cardList="questionData[1][2]" + /> </p> <h2 class="module_block" id="b001" style="margin: 0"> <div class="custom1">瀛︿範涓婚涓�</div> @@ -508,7 +508,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c"> - <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> + <examinations :cardList="questionData[1][6]" /> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> --> </p> <h4 id="d008">锛堜簲锛夋敞鎰忎繚鎶ゅソ鍏宠妭鍜岄煣甯�</h4> <p class="lh2"> @@ -720,7 +721,7 @@ </div> <div class="right" style="width: 60%"> <video - :src="config.resourceCtx + '/video/chapterOne/breathing-video.mp4'" + :src="pathOne" poster="../../../assets/images/chapterOne/people-video-img.jpg" webkit-playsinline="true" x-webkit-airplay="true" @@ -834,8 +835,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c"> - <!-- <img class="img-g" alt="" src="image/0022-1.jpg" /><br /> --> - <span class="img">涓撻涓� 瀛︿範涓婚浜�</span> + <examinations :cardList="questionData[1][9]" /> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚浜�</span> --> </p> <h4 id="d015">锛堜簲锛変繚鎶ゅ0甯�</h4> <p class="lh2">閫夋嫨閫傚悎瀛﹀墠鍎跨闊冲煙鐗圭偣鐨勬瓕鏇叉垨鏈楄鏉愭枡锛屾瘡娆″敱姝屾垨鏈楄鐨勬椂闂翠笉瀹滆繃闀匡紙鏈�澶�5鍒嗛挓锛夛紝鏇翠笉鑳介珮澹板枈鍙紝浠ラ槻澹板甫鍏呰銆佽偪鑳�銆佸彉鍘氾紝閫犳垚澹伴煶鍢跺搼銆傜粌涔犲彂澹扮殑</p> @@ -1026,7 +1027,7 @@ </div> <div class="right" style="width: 65%"> <video - :src="config.resourceCtx + '/video/chapterOne/blood-video.mp4'" + :src="pathThree" poster="../../../assets/images/chapterOne/people-video-img.jpg" webkit-playsinline="true" x-webkit-airplay="true" @@ -1176,8 +1177,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c"> - <!-- <img class="img-g" alt="" src="image/0032-1.jpg" /><br /> --> - <span class="img">涓撻涓� 瀛︿範涓婚鍥�</span> + <examinations :cardList="questionData[1][14]" /> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> --> </p> <h2 class="module_block" id="b004"> <div class="custom1">瀛︿範涓婚鍥�</div> @@ -1358,7 +1359,7 @@ </div> <div class="right" style="width: 65%"> <video - :src=" config.resourceCtx + '/video/chapterOne/teeth.mp4'" + :src="pathFour" poster="../../../assets/images/chapterOne/people-video-img.jpg" webkit-playsinline="true" x-webkit-airplay="true" @@ -1516,7 +1517,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c"> - <span class="img">涓撻涓� 瀛︿範涓婚鍥�</span> + <examinations :cardList="questionData[1][19]" /> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚鍥�</span> --> </p> <p class="custom_tag"><b>鈥㈣祫鏂欓摼鎺モ��</b></p> <div class="fieldset"> @@ -1951,7 +1953,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0036-3.jpg" /><br /> --> - <span class="img">涓撻涓� 瀛︿範涓婚浜斻�佸涔犱富棰樺叚</span> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚浜斻�佸涔犱富棰樺叚</span> --> + <examinations :cardList="questionData[1][24]" /> </p> <p class="custom_tag"><b>鈥㈣祫鏂欓摼鎺モ��</b></p> <div class="fieldset"> @@ -2197,7 +2200,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c"> - <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[1][26]" /> </p> <h2 class="module_block" id="b008"> <div class="custom1">瀛︿範涓婚鍏�</div> @@ -2536,7 +2540,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c"> - <span class="img">涓撻涓� 瀛︿範涓婚鍏�</span> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚鍏�</span> --> + <examinations :cardList="questionData[1][31]" /> </p> <h4 id="d065">锛堝叚锛夊畨鎺掍赴瀵岀殑娲诲姩鍙婇�傚綋鐨勪綋鑲查敾鐐�</h4> <p> @@ -2731,8 +2736,9 @@ </p> </div> <div class="right" style="width: 60%"> + <!-- config.resourceCtx + '/video/chapterOne/涓撻涓�锛氬鍓嶅効绔ョ溂鐫涚殑鐢熺悊鐗圭偣涓庝繚鍋�.mp4' --> <video - :src=" config.resourceCtx + '/video/chapterOne/涓撻涓�锛氬鍓嶅効绔ョ溂鐫涚殑鐢熺悊鐗圭偣涓庝繚鍋�.mp4'" + :src="pathTwo" poster="../../../assets/images/chapterOne/people-video-img.jpg" webkit-playsinline="true" x-webkit-airplay="true" @@ -3132,7 +3138,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0053-1.jpg" /><br /> --> - <span class="img">涓撻涓� 瀛︿範涓婚涔�</span> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚涔�</span> --> + <examinations :cardList="questionData[1][40]" /> </p> <h6 class="Conclusion-title4">涓撻灏忕粨</h6> <p class="blockh6"> @@ -3296,10 +3303,10 @@ </h6> <p class="blockh6-c"> 瀛︿範瀹屾湰涓撻锛屼綘鐨勫涔犳晥鏋滃浣曞憿锛熷挶浠竴璧锋潵鎵爜娴嬩竴娴嬪惂锛�<br /> - <!-- <img class="img-g" alt="" src="image/0054-1.jpg" /><br /> --> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級1</span><br /> - <!-- <img class="img-g" alt="" src="image/0054-2.jpg" /><br /> --> + <examinations :cardList="questionData[1][421]" /> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級2</span> + <examinations :cardList="questionData[1][422]" /> </p> <h6 class="Conclusion-title4">鈥㈠涔犲弽鎬濃��</h6> <p class="blockh6 fl fl-di fl-cn" style="text-indent: 0"> @@ -3332,6 +3339,7 @@ import examinations from "@/components/examinations/index.vue"; import evenHeaderVue from '../../components/pageHeader/evenHeader.vue'; import oddHeaderVue from '../../components/pageHeader/oddHeader.vue'; +import getResourcePath from '@/assets/methods/resources' export default { name: "chapter-one", components: { examinations,evenHeaderVue,oddHeaderVue }, @@ -3360,36 +3368,6 @@ require("../../../assets/images/chapterOne/posture-01.png"), require("../../../assets/images/chapterOne/posture-02.png"), require("../../../assets/images/chapterOne/posture-03.png"), - ], - questionList: [ - { - analysisCon: "璇﹁鏁欐潗P3銆�", - answer: "A", - difficulty: 0, - id: 47459, - isCollect: false, - isComplete: false, - isRight: null, - isUnfold: "", - isUserAnswer: false, - number: 1, - option: [ - { index: "6595", txt: "寰烽瞾鍏�", value: "A", img: "" }, - { index: "6660", txt: "娉板嫆", value: "B", img: "" }, - { index: "803B", txt: "娉曠害灏�", value: "C", img: "" }, - { index: "9887", txt: "瑗胯挋", value: "D", img: "" }, - ], - optionStyle: "Txt", - questionType: "singleChoice", - score: 2, - stem: { - stemTxt: - "1. 棣栨鎻愬嚭鈥滅鐞嗗鈥濇蹇碉紝璁や负鈥滅鐞嗘槸涓�闂ㄧ瀛︹�濅笖鈥滅鐞嗘槸涓�绉嶅疄璺碘�濈殑鏄紙 锛夈��", - }, - stemStyle: "Txt", - type: "鍗曢�夐", - userAnswer: "", - }, ], resourceState: "", type: "option", @@ -3434,10 +3412,21 @@ learnTableSix:true, learnTableSeven:true, learnTableEight:true, - learnTableNine:true + learnTableNine:true, + questionData:{}, + pathOne:'', + pathTWo:'', + pathThree:'', + pathFour:'', }; }, - mounted() {}, + mounted() { + this.$data.questionData = this.$store.state.questionData + this.$data.pathOne = getResourcePath('f6f6588a75086576b87bed2fb9ca1ec1') + this.$data.pathTwo = getResourcePath('e5993b62684fe55d13190cfe52bf00ed') + this.$data.pathThree = getResourcePath('6b6d42213aa85aa5ff7724aaf96ffee6') + this.$data.pathFour = getResourcePath('17fb1555f98c8fceabce5ff75077af58') + }, methods: { changeResources(type) { if (type == "learnTbaleOne") { diff --git a/src/books/childHealth/view/content/components/chapter002.vue b/src/books/childHealth/view/content/components/chapter002.vue index 3868f98..7387bb3 100644 --- a/src/books/childHealth/view/content/components/chapter002.vue +++ b/src/books/childHealth/view/content/components/chapter002.vue @@ -275,8 +275,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c"> - <!-- <img class="img-g" alt="" src="image/0058-1.jpg" /><br /> --> - <span class="img">涓撻浜� 瀛︿範涓婚涓�</span> + <examinations :cardList="questionData[2][46]" /> + <!-- <span class="img">涓撻浜� 瀛︿範涓婚涓�</span> --> </p> <h2 class="module_block" id="b011"> <div class="custom1">瀛︿範涓婚浜�</div> @@ -572,7 +572,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0062-1.jpg" /><br /> --> - <span class="img">涓撻浜� 瀛︿範涓婚浜�</span> + <!-- <span class="img">涓撻浜� 瀛︿範涓婚浜�</span> --> + <examinations :cardList="questionData[2][49]" /> </p> <p class="custom_tag"><b>鈥㈣祫鏂欓摼鎺モ��</b></p> <div class="fieldset"> @@ -844,7 +845,8 @@ </h6> <p class="blockh6-c center"> <!-- <img class="img-g" alt="" src="image/0065-1.jpg" /><br /> --> - <span class="img">涓撻浜� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻浜� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[2][52]" /> </p> </div> </div> @@ -980,10 +982,10 @@ </h6> <p class="blockh6-c"> 瀛︿範瀹屾湰涓撻锛屼綘鐨勫涔犳晥鏋滃浣曞憿锛熷挶浠竴璧锋潵鎵爜娴嬩竴娴嬪惂锛�<br /> - <!-- <img class="img-g" alt="" src="image/0067-1.jpg" /><br /> --> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級1</span><br /> - <!-- <img class="img-g" alt="" src="image/0067-2.jpg" /><br /> --> + <examinations :cardList="questionData[2][541]" /> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級2</span> + <examinations :cardList="questionData[2][542]" /> </p> <h6 class="Conclusion-title4">鈥㈠涔犲弽鎬濃��</h6> <p class="blockh6 m0-t0 fl fl-di fl-cn"> @@ -1000,9 +1002,11 @@ <script> import evenHeaderVue from '../../components/pageHeader/evenHeader.vue'; import oddHeaderVue from '../../components/pageHeader/oddHeader.vue'; +import examinations from "@/components/examinations/index.vue"; +import {mapState} from 'vuex' export default { name: "chapterTwo", - components:{evenHeaderVue,oddHeaderVue}, + components:{evenHeaderVue,oddHeaderVue,examinations}, data() { return { taskOne: require("../../../assets/images/chapterTwo/task-sheet1.png"), @@ -1015,8 +1019,13 @@ learnTableOne: true, learnTableTwo: true, learnTableThree: true, + questionData:{} }; }, + mounted() { + this.$data.questionData = this.$store.state.questionData + + }, methods: { changeResources(type) { if (type == "learnTableOne") { diff --git a/src/books/childHealth/view/content/components/chapter003.vue b/src/books/childHealth/view/content/components/chapter003.vue index cf167a5..da88fce 100644 --- a/src/books/childHealth/view/content/components/chapter003.vue +++ b/src/books/childHealth/view/content/components/chapter003.vue @@ -530,8 +530,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c"> - <!-- <img class="img-g" alt="" src="image/0077-1.jpg" /><br /> --> - <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> + <examinations :cardList="questionData[3][64]" /> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> --> </p> <h2 class="module_block" id="b014"> <div class="custom1">瀛︿範涓婚浜�</div> @@ -658,7 +658,6 @@ </td> </tr> </table> - <p class="img">鑷富瀛︿範浠诲姟鍗�</p> <p class="custom_tag"><b>鈥㈠涔犲垵浣撻獙鈥�</b></p> <div class="fieldset"> <p class="block"> @@ -959,7 +958,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c center"> - <span class="img">涓撻涓� 瀛︿範涓婚浜�</span> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚浜�</span> --> + <examinations :cardList="questionData[3][73]" /> </p> <h2 class="module_block" id="b015"> <div class="custom1">瀛︿範涓婚涓�</div> @@ -1347,7 +1347,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c center"> - <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[3][78]" /> </p> </div> </div> @@ -1470,10 +1471,10 @@ </h6> <p class="blockh6-c"> 瀛︿範瀹屾湰涓撻锛屼綘鐨勫涔犳晥鏋滃浣曞憿锛熷挶浠竴璧锋潵鎵爜娴嬩竴娴嬪惂锛�<br /> - <!-- <img class="img-g" alt="" src="image/0093-1.jpg" /><br /> --> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級1</span><br /> - <!-- <img class="img-g" alt="" src="image/0093-2.jpg" /><br /> --> + <examinations :cardList="questionData[3][801]" /> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級2</span> + <examinations :cardList="questionData[3][802]" /> </p> <h6 class="Conclusion-title4">鈥㈠涔犲弽鎬濃��</h6> <p class="blockh6 m0-t0 fl fl-di fl-cn"> @@ -1500,9 +1501,10 @@ <script> import evenHeaderVue from "../../components/pageHeader/evenHeader.vue"; import oddHeaderVue from "../../components/pageHeader/oddHeader.vue"; +import examinations from "@/components/examinations/index.vue"; export default { name: "chapterThree", - components: { evenHeaderVue, oddHeaderVue }, + components: { evenHeaderVue, oddHeaderVue,examinations }, data() { return { learn: require("../../../assets/images/chapterThree/0068-1.jpg"), @@ -1513,8 +1515,12 @@ learnTableOne: true, learnTableTwo: true, learnTableThree: true, + questionData:{} }; }, + mounted() { + this.$data.questionData = this.$store.state.questionData + }, methods: { changeResources(type) { if (type == "learnTableOne") { diff --git a/src/books/childHealth/view/content/components/chapter005.vue b/src/books/childHealth/view/content/components/chapter005.vue index a8068dd..bea47cb 100644 --- a/src/books/childHealth/view/content/components/chapter005.vue +++ b/src/books/childHealth/view/content/components/chapter005.vue @@ -1020,7 +1020,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0132-1.jpg" /><br /> --> - <span class="img">涓撻浜� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻浜� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[5][119]" /> </p> <h2 class="module_block" id="b019"> <div class="custom1">瀛︿範涓婚浜�</div> @@ -1365,7 +1366,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0137-1.jpg" /><br /> --> - <span class="img">涓撻浜� 瀛︿範涓婚浜�</span> + <!-- <span class="img">涓撻浜� 瀛︿範涓婚浜�</span> --> + <examinations :cardList="questionData[5][124]" /> </p> <h2 class="module_block" id="b020"> <div class="custom1">瀛︿範涓婚涓�</div> @@ -1737,7 +1739,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0141-2.jpg" /><br /> --> - <span class="img">涓撻浜� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻浜� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[5][129]" /> </p> <h2 class="module_block" id="b021"> <div class="custom1">瀛︿範涓婚鍥�</div> @@ -2026,7 +2029,8 @@ 浜戞祴璇� </h6> <p class="blockh6-c"> - <span class="img">涓撻浜� 瀛︿範涓婚鍥�</span> + <!-- <span class="img">涓撻浜� 瀛︿範涓婚鍥�</span> --> + <examinations :cardList="questionData[5][133]" /> </p> <h6 class="Conclusion-title4">涓撻灏忕粨</h6> <p class="blockh6"> @@ -2157,10 +2161,10 @@ </h6> <p class="blockh6-c"> 瀛︿範瀹屾湰涓撻锛屼綘鐨勫涔犳晥鏋滃浣曞憿锛熷挶浠竴璧锋潵鎵爜娴嬩竴娴嬪惂锛�<br /> - <!-- <img class="img-g" alt="" src="image/0147-1.jpg" /><br /> --> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級1</span><br /> - <!-- <img class="img-g" alt="" src="image/0147-2.jpg" /><br /> --> + <examinations :cardList="questionData[5][1341]" /> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級2</span> + <examinations :cardList="questionData[5][1342]" /> </p> <!-- <h6 class="Conclusion-title4">鈥㈠涔犲弽鎬濃��</h6> <p class="blockh6 fl fl-di fl-cn" style="text-indent: 0"> @@ -2181,9 +2185,10 @@ <script> import evenHeader from "../../components/pageHeader/evenHeader.vue"; import oddHeader from "../../components/pageHeader/oddHeader.vue"; +import examinations from "@/components/examinations/index.vue"; export default { name: "chapterFive", - components: { evenHeader, oddHeader }, + components: { evenHeader, oddHeader,examinations }, data() { return { learn: require("../../../assets/images/chapterFive/0112-1.jpg"), @@ -2201,9 +2206,13 @@ learnTableOne: true, learnTableTwo: true, learnTableThree: true, - learnTableFour:true + learnTableFour:true, + questionData:{} }; }, + mounted() { + this.$data.questionData = this.$store.state.questionData + }, methods: { changeResources(type) { if (type == "learnTableOne") { diff --git a/src/books/childHealth/view/content/components/chapter006.vue b/src/books/childHealth/view/content/components/chapter006.vue index 3f37a2f..df7fa80 100644 --- a/src/books/childHealth/view/content/components/chapter006.vue +++ b/src/books/childHealth/view/content/components/chapter006.vue @@ -392,7 +392,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-a" alt="" src="image/0155-1.jpg" /><br /> --> - <span class="img">涓撻鍏� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻鍏� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[6][142]" /> </p> <p class="custom_tag"><b>鈥㈡墿灞曞欢浼糕��</b></p> <div class="fieldset"> @@ -1005,7 +1006,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0165-1.jpg" /><br /> --> - <span class="img">涓撻鍏� 瀛︿範涓婚浜�</span> + <!-- <span class="img">涓撻鍏� 瀛︿範涓婚浜�</span> --> + <examinations :cardList="questionData[6][152]" /> </p> <h2 class="module_block" id="b024"> <div class="custom1">瀛︿範涓婚涓�</div> @@ -1263,7 +1265,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-a" alt="" src="image/0168-1.jpg" /><br /> --> - <span class="img">涓撻鍏� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻鍏� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[6][156]" /> </p> <p class="custom_tag"><b>鈥㈡墿灞曞欢浼糕��</b></p> <div class="fieldset"> @@ -1529,7 +1532,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0172-1.jpg" /><br /> --> - <span class="img">涓撻鍏� 瀛︿範涓婚鍥�</span> + <!-- <span class="img">涓撻鍏� 瀛︿範涓婚鍥�</span> --> + <examinations :cardList="questionData[6][159]" /> </p> <div class="annotation-border"></div> <p class="note"> @@ -1878,7 +1882,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0177-1.jpg" /><br /> --> - <span class="img">涓撻鍏� 瀛︿範涓婚浜�</span> + <!-- <span class="img">涓撻鍏� 瀛︿範涓婚浜�</span> --> + <examinations :cardList="questionData[6][164]" /> </p> <h6 class="Conclusion-title4">涓撻灏忕粨</h6> <p class="blockh6"> @@ -2058,10 +2063,10 @@ </h6> <p class="blockh6-c"> 瀛︿範瀹屾湰涓撻锛屼綘鐨勫涔犳晥鏋滃浣曞憿锛熷挶浠竴璧锋潵鎵爜娴嬩竴娴嬪惂锛�<br /> - <!-- <img class="img-g" alt="" src="image/" /><br /> --> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級1</span><br /> - <!-- <img class="img-g" alt="" src="image/0179-2.jpg" /><br /> --> + <examinations :cardList="questionData[6][1661]" /> <span class="img">>杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級2</span> + <examinations :cardList="questionData[6][1662]" /> </p> <h6 class="Conclusion-title4">鈥㈠涔犲弽鎬濃��</h6> <p class="blockh6 m0-t0 fl fl-di fl-cn"> @@ -2094,8 +2099,9 @@ <script> import evenHeader from "../../components/pageHeader/evenHeader.vue"; import oddHeader from "../../components/pageHeader/oddHeader.vue"; +import examinations from "@/components/examinations/index.vue"; export default { - components: { evenHeader, oddHeader }, + components: { evenHeader, oddHeader,examinations }, name: "chapterSix", data() { return { @@ -2114,8 +2120,12 @@ learnTableThree: true, learnTableFour: true, learnTableFive: true, + questionData:{} }; }, + mounted() { + this.$data.questionData = this.$store.state.questionData + }, methods: { changeResources(type) { if (type == "learnTableOne") { diff --git a/src/books/childHealth/view/content/components/chapter007.vue b/src/books/childHealth/view/content/components/chapter007.vue index 10d6b5d..f6e2ec1 100644 --- a/src/books/childHealth/view/content/components/chapter007.vue +++ b/src/books/childHealth/view/content/components/chapter007.vue @@ -240,7 +240,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0182-1.jpg" /><br /> --> - <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[7][169]" /> </p> <p class="custom_tag"><b>鈥㈣祫鏂欓摼鎺モ��</b></p> <div class="fieldset"> @@ -664,7 +665,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0187-1.jpg" /><br /> --> - <span class="img">涓撻涓� 瀛︿範涓婚浜�</span> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚浜�</span> --> + <examinations :cardList="questionData[7][174]" /> </p> <p class="custom_tag"><b>鈥㈣祫鏂欓摼鎺モ��</b></p> <div class="fieldset"> @@ -928,7 +930,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0189-1.jpg" /><br /> --> - <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[7][177]" /> </p> <p class="custom_tag"><b>鈥㈣祫鏂欓摼鎺モ��</b></p> <div class="fieldset"> @@ -1724,7 +1727,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0200-1.jpg" /><br /> --> - <span class="img">涓撻涓� 瀛︿範涓婚鍥�</span> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚鍥�</span> --> + <examinations :cardList="questionData[7][188]" /> </p> <h2 class="module_block" id="b031"> <div class="custom1">瀛︿範涓婚浜�</div> @@ -2763,7 +2767,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0220-1.jpg" /><br /> --> - <span class="img">涓撻涓� 瀛︿範涓婚浜�</span> + <!-- <span class="img">涓撻涓� 瀛︿範涓婚浜�</span> --> + <examinations :cardList="questionData[7][207]" /> </p> <p class="custom_tag"><b>鈥㈣祫鏂欓摼鎺モ��</b></p> <div class="fieldset"> @@ -2989,10 +2994,10 @@ </h6> <p class="blockh6-c"> 瀛︿範瀹屾湰涓撻锛屼綘鐨勫涔犳晥鏋滃浣曞憿锛熷挶浠竴璧锋潵鎵爜娴嬩竴娴嬪惂锛�<br /> - <!-- <img class="img-g" alt="" src="image/0222-1.jpg" /><br /> --> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級1</span><br /> - <!-- <img class="img-g" alt="" src="image/0222-2.jpg" /><br /> --> + <examinations :cardList="questionData[7][2091]" /> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級2</span> + <examinations :cardList="questionData[7][2092]" /> </p> <h6 class="Conclusion-title4">鈥㈠涔犲弽鎬濃��</h6> <p class="blockh6 m0-t0 fl fl-di fl-cn"> @@ -3019,9 +3024,10 @@ <script> import evenHeader from "../../components/pageHeader/evenHeader.vue"; import oddHeader from "../../components/pageHeader/oddHeader.vue"; +import examinations from "@/components/examinations/index.vue"; export default { name: "chapterSeven", - components: { evenHeader, oddHeader }, + components: { evenHeader, oddHeader,examinations }, data() { return { learn: require("../../../assets/images/chapterSeven/0180-1.jpg"), @@ -3039,8 +3045,12 @@ learnTableThree: true, learnTableFour: true, learnTableFive: true, + questionData:{} }; }, + mounted() { + this.$data.questionData = this.$store.state.questionData + }, methods: { changeResources(type) { if (type == "learnTableOne") { diff --git a/src/books/childHealth/view/content/components/chapter008.vue b/src/books/childHealth/view/content/components/chapter008.vue index c69399d..ef42bd8 100644 --- a/src/books/childHealth/view/content/components/chapter008.vue +++ b/src/books/childHealth/view/content/components/chapter008.vue @@ -492,7 +492,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0228-2.jpg" /><br /> --> - <span class="img">涓撻鍏� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻鍏� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[8][215]" /> </p> </div> </div> @@ -1350,7 +1351,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0240-2.jpg" /><br /> --> - <span class="img">涓撻鍏� 瀛︿範涓婚浜�</span> + <!-- <span class="img">涓撻鍏� 瀛︿範涓婚浜�</span> --> + <examinations :cardList="questionData[8][227]" /> </p> <p class="custom_tag"><b>鈥㈣祫鏂欓摼鎺モ��</b></p> <div class="fieldset"> @@ -1749,7 +1751,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0245-1.jpg" /><br /> --> - <span class="img">涓撻鍏� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻鍏� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[8][232]" /> </p> <p class="custom_tag"><b>鈥㈣祫鏂欓摼鎺モ��</b></p> <div class="fieldset"> @@ -1970,10 +1973,10 @@ </h6> <p class="blockh6-c"> 瀛︿範瀹屾湰涓撻锛屼綘鐨勫涔犳晥鏋滃浣曞憿锛熷挶浠竴璧锋潵鎵爜娴嬩竴娴嬪惂锛�<br /> - <!-- <img class="img-g" alt="" src="image/0247-1.jpg" /><br /> --> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級1</span><br /> - <!-- <img class="img-g" alt="" src="image/0247-2.jpg" /><br /> --> + <examinations :cardList="questionData[8][2431]" /> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級2</span> + <examinations :cardList="questionData[8][2342]" /> </p> </div> </div> @@ -1983,9 +1986,10 @@ <script> import evenHeader from "../../components/pageHeader/evenHeader.vue"; import oddHeader from "../../components/pageHeader/oddHeader.vue"; +import examinations from "@/components/examinations/index.vue"; export default { name: "chapterEight", - components: { evenHeader, oddHeader }, + components: { evenHeader, oddHeader,examinations }, data() { return { learn: require("../../../assets/images/chapterEight/0223-1.jpg"), @@ -2011,8 +2015,12 @@ learnTableThree: true, learnTableFour: true, learnTableFive: true, + questionData:{} }; }, + mounted() { + this.$data.questionData = this.$store.state.questionData + }, methods: { changeResources(type) { if (type == "learnTableOne") { diff --git a/src/books/childHealth/view/content/components/chapter009.vue b/src/books/childHealth/view/content/components/chapter009.vue index abb0ee8..e605064 100644 --- a/src/books/childHealth/view/content/components/chapter009.vue +++ b/src/books/childHealth/view/content/components/chapter009.vue @@ -532,7 +532,8 @@ </h6> <p class="blockh6-c center"> <!-- <img class="img-g" alt="" src="image/0256-2.jpg" /><br /> --> - <span class="img">涓撻涔� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻涔� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[9][243]" /> </p> </div> </div> @@ -1263,7 +1264,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0267-1.jpg" /><br /> --> - <span class="img">涓撻涔� 瀛︿範涓婚浜�</span> + <!-- <span class="img">涓撻涔� 瀛︿範涓婚浜�</span> --> + <examinations :cardList="questionData[9][255]" /> </p> <h6 class="Conclusion-title4">涓撻灏忕粨</h6> <p class="blockh6"> @@ -1386,10 +1388,10 @@ </h6> <p class="blockh6-c"> 瀛︿範瀹屾湰涓撻锛屼綘鐨勫涔犳晥鏋滃浣曞憿锛熷挶浠竴璧锋潵鎵爜娴嬩竴娴嬪惂锛�<br /> - <!-- <img class="img-g" alt="" src="image/0269-1.jpg" /><br /> --> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級1</span><br /> - <!-- <img class="img-g" alt="" src="image/0269-2.jpg" /><br /> --> + <examinations :cardList="questionData[9][2561]" /> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級2</span> + <examinations :cardList="questionData[9][2562]" /> </p> <h6 class="Conclusion-title4">鈥㈠涔犲弽鎬濃��</h6> <p class="blockh6 m0-t0 fl fl-di fl-cn"> @@ -1417,9 +1419,10 @@ <script> import evenHeader from "../../components/pageHeader/evenHeader.vue"; import oddHeader from "../../components/pageHeader/oddHeader.vue"; +import examinations from "@/components/examinations/index.vue"; export default { name: "chapterNine", - components: { evenHeader, oddHeader }, + components: { evenHeader, oddHeader,examinations }, data() { return { learn: require("../../../assets/images/chapterNine/0248-1.jpg"), @@ -1432,8 +1435,12 @@ learnTableThree: true, learnTableFour: true, learnTableFive: true, + questionData:{} }; }, + mounted() { + this.$data.questionData = this.$store.state.questionData + }, methods: { changeResources(type) { if (type == "learnTableOne") { diff --git a/src/books/childHealth/view/content/components/chapter010.vue b/src/books/childHealth/view/content/components/chapter010.vue index 90bc996..7a1ede0 100644 --- a/src/books/childHealth/view/content/components/chapter010.vue +++ b/src/books/childHealth/view/content/components/chapter010.vue @@ -584,7 +584,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0279-1.jpg" /><br /> --> - <span class="img">涓撻鍗� 瀛︿範涓婚涓�</span> + <!-- <span class="img">涓撻鍗� 瀛︿範涓婚涓�</span> --> + <examinations :cardList="questionData[10][267]" /> </p> <h2 class="module_block" id="b038"> <div class="custom1">瀛︿範涓婚浜�</div> @@ -933,7 +934,8 @@ </h6> <p class="blockh6-c"> <!-- <img class="img-g" alt="" src="image/0285-1.jpg" /><br /> --> - <span class="img">涓撻鍗� 瀛︿範涓婚浜�</span> + <!-- <span class="img">涓撻鍗� 瀛︿範涓婚浜�</span> --> + <examinations :cardList="questionData[10][272]" /> </p> <p class="custom_tag"><b>鈥㈣祫鏂欓摼鎺モ��</b></p> <div class="fieldset"> @@ -1058,10 +1060,10 @@ </h6> <p class="blockh6-c"> 瀛︿範瀹屾湰涓撻锛屼綘鐨勫涔犳晥鏋滃浣曞憿锛熷挶浠竴璧锋潵鎵爜娴嬩竴娴嬪惂锛�<br /> - <!-- <img class="img-g" alt="" src="image/0286-1.jpg" /><br /> --> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級1</span><br /> - <!-- <img class="img-g" alt="" src="image/0286-2.jpg" /><br /> --> + <examinations :cardList="questionData[10][2731]" /> <span class="img">杩囧叧妫�娴嬶紙璧勬牸鑰冭瘯妯℃嫙棰橈級2</span> + <examinations :cardList="questionData[10][2732]" /> </p> <h6 class="Conclusion-title4">鈥㈠涔犲弽鎬濃��</h6> <p class="blockh6 m0-t0 fl fl-di fl-cn"> @@ -1077,9 +1079,10 @@ <script> import evenHeader from "../../components/pageHeader/evenHeader.vue"; import oddHeader from "../../components/pageHeader/oddHeader.vue"; +import examinations from "@/components/examinations/index.vue"; export default { name: "chapterTen", - components: { evenHeader, oddHeader }, + components: { evenHeader, oddHeader,examinations }, data() { return { learn: require("../../../assets/images/chapterTen/0270-1.jpg"), @@ -1092,8 +1095,12 @@ learnTableThree: true, learnTableFour: true, learnTableFive: true, + questionData:{} }; }, + mounted() { + this.$data.questionData = this.$store.state.questionData + }, methods: { changeResources(type) { if (type == "learnTableOne") { diff --git a/src/books/childHealth/view/content/components/chapter011.vue b/src/books/childHealth/view/content/components/chapter011.vue index ad6554e..9c5d8e7 100644 --- a/src/books/childHealth/view/content/components/chapter011.vue +++ b/src/books/childHealth/view/content/components/chapter011.vue @@ -16,18 +16,57 @@ 濡傛灉浣犲叏浼氾紝閭f伃鍠滀綘锛佸鏋滀綘鏈兘鍏ㄩ儴绛斿锛屼篃娌℃湁鍏崇郴锛岃浠庢暀鏉愪腑鎵惧埌鐩稿簲鐨勫唴瀹瑰涔犱竴涓嬪惂銆� 杩欓噷涓�鍏辨湁鍗佸娴嬭瘯棰橈紝鐜板湪寮�濮嬭嚜鎴戞娴嬩箣鏃呭惂銆� </p> - - <p class="center"> + <!-- <p class="center"> <el-image :src="tableOne" :preview-src-list="[tableOne]" /> + </p> --> + <p class=" block3"> + <span class="block3 center dl-bl w100 mb-20">鍗蜂竴</span> + <examinations :cardList="questionData[11][2741]" /> + </p> + <p class=" block3"> + <span class="block3 center dl-bl w100 mb-20">鍗蜂簩</span> + <examinations :cardList="questionData[11][2742]" /> + </p> + <p class=" block3"> + <span class="block3 center dl-bl w100 mb-20">鍗蜂笁</span> + <examinations :cardList="questionData[11][2743]" /> + </p> + <p class=" block3"> + <span class="block3 center dl-bl w100 mb-20">鍗峰洓</span> + <examinations :cardList="questionData[11][2744]" /> + </p> + <p class=" block3"> + <span class="block3 center dl-bl w100 mb-20">鍗蜂簲</span> + <examinations :cardList="questionData[11][2745]" /> </p> </div> </div> <div class="page-box" page="275"> <odd-header :special="11" :num="275" /> <div class="padding-96"> - <p class="img">缁〃</p> + <!-- <p class="img">缁〃</p> <p class="center"> <el-image :src="tableTwo" :preview-src-list="[tableTwo]" /> + </p> --> + <p class=" block3"> + <span class="block3 center dl-bl w100 mb-20">鍗峰叚</span> + <examinations :cardList="questionData[11][2746]" /> + </p> + <p class=" block3"> + <span class="block3 center dl-bl w100 mb-20">鍗蜂竷</span> + <examinations :cardList="questionData[11][2747]" /> + </p> + <p class=" block3"> + <span class="block3 center dl-bl w100 mb-20">鍗峰叓</span> + <examinations :cardList="questionData[11][2748]" /> + </p> + <p class=" block3"> + <span class="block3 center dl-bl w100 mb-20">鍗蜂節</span> + <examinations :cardList="questionData[11][2749]" /> + </p> + <p class=" block3"> + <span class="block3 center dl-bl w100 mb-20">鍗峰崄</span> + <examinations :cardList="questionData[11][27410]" /> </p> </div> </div> @@ -36,15 +75,20 @@ <script> import oddHeader from '../../components/pageHeader/oddHeader.vue'; +import examinations from "@/components/examinations/index.vue"; export default { name: "chapterEleven", - components: {oddHeader}, + components: {oddHeader,examinations}, data() { return { tableOne: require("../../../assets/images/chapterEleven/0287-1.jpg"), tableTwo: require("../../../assets/images/chapterEleven/0288-1.jpg"), + questionData:{} }; }, + mounted() { + this.$data.questionData = this.$store.state.questionData + }, }; </script> diff --git a/src/books/childHealth/view/content/index.vue b/src/books/childHealth/view/content/index.vue index b47b0c3..6abe606 100644 --- a/src/books/childHealth/view/content/index.vue +++ b/src/books/childHealth/view/content/index.vue @@ -3,7 +3,6 @@ <div class="page-content"> <pageHeader v-if="showCatalogList.indexOf(0) > -1"></pageHeader> <chapterOne v-if="showCatalogList.indexOf(1) > -1"></chapterOne> - <chapterOne v-if="showCatalogList.indexOf(1) > -1"></chapterOne> <chapterTwo v-if="showCatalogList.indexOf(2) > -1"></chapterTwo> <chapterThree v-if="showCatalogList.indexOf(3) > -1"></chapterThree> <chapterFour v-if="showCatalogList.indexOf(4) > -1"></chapterFour> @@ -37,9 +36,7 @@ import chapterEleven from "./components/chapter011.vue"; import chapterTwelve from "./components/chapter012.vue"; import chapterThirteen from "./components/chapter013.vue"; - import _ from "lodash"; - export default { data() { return { @@ -55,9 +52,11 @@ showCatalogList: { handler(newVal) { console.log("鏄剧ず绔犺妭", newVal); - this.$store.state.qiankun.windowSelection({ - showCatalogList: newVal, - }); + if (this.$store.state.qiankun.windowSelection) { + this.$store.state.qiankun.windowSelection({ + showCatalogList: newVal, + }); + } }, }, }, @@ -72,10 +71,11 @@ ); // 鎻愪緵椤甸潰璺宠浆鍔熻兘 if (this.setGlobalState) { + console.log("setGlobalState"); this.setGlobalState({ gotoPage: (catalog, page) => { this.gotoPage(catalog, page); - } + }, }); } // 娴嬭瘯椤甸潰璺宠浆 @@ -138,7 +138,7 @@ this.showCatalogList = [ this.catalogLength - 2, this.catalogLength - 1, - this.catalogLength + this.catalogLength, ]; } else { this.showCatalogList = [catalog - 1, catalog, catalog + 1]; @@ -155,7 +155,7 @@ } else { console.log("绔犺妭閿欒锛�"); } - } + }, }, components: { pageHeader, diff --git a/src/books/childHealth/view/index.vue b/src/books/childHealth/view/index.vue index 7683b14..10af5bd 100644 --- a/src/books/childHealth/view/index.vue +++ b/src/books/childHealth/view/index.vue @@ -6,8 +6,9 @@ <script> import examinations from "./components/examinations/index.vue"; -import testData from '../assets/examinationList.json' import pageContent from "./content/index.vue"; +import testData from '../assets/examinationList' +import getQuestionData from '@/assets/methods/examination' export default { name: "child-health", components: { @@ -21,7 +22,6 @@ idPathList: [], cardList: [], isMouseDown: false, - showToolBox: false, move: false, }; }, @@ -66,9 +66,18 @@ }, }; this.MG.store.getProductDetail(query).then((res) => { - console.log("鍥句功淇℃伅",res.datas.cmsDatas[0].datas); + console.log("鍥句功淇℃伅",res.datas,testData); this.$data.bookData = res.datas.cmsDatas[0].datas - + const questiondata = testData + for(let key in testData) { + for(let tkey in testData[key]) { + console.log(testData[key][tkey]); + questiondata[key][tkey] = getQuestionData(res.datas.rootCmsItemId,testData[key][tkey]) + } + } + this.$store.commit('setQuestionData',questiondata) + console.log(this.$store); + // console.log(questiondata); }); }, getParentWithClass(element, className) { @@ -96,7 +105,6 @@ let chapterNum; if (chapterDom) chapterNum = chapterDom.getAttribute("num"); if (txt && pageHtml) { - this.$dsta.showToolBox = true; const page = pageHtml.getAttribute("page"); console.log( { @@ -131,7 +139,6 @@ handleMouseDown() { this.$data.isMouseDown = true; - this.$data.showToolBox = false; }, handleMousemove() { if (this.$data.isMouseDown) { @@ -160,3 +167,4 @@ </script> <style lang="less" scoped></style> +../assets/examinationList.js../assets/examinationList.js \ No newline at end of file diff --git a/src/components/examinations/index.vue b/src/components/examinations/index.vue index 0329a7c..8337923 100644 --- a/src/components/examinations/index.vue +++ b/src/components/examinations/index.vue @@ -1,6 +1,6 @@ <template> <div class="examination" v-loading="loading"> - <div v-for="(item, nindex) in cardList" :key="nindex" class="border-box"> + <div v-for="(item, nindex) in cardList" :key="nindex" class="border-box" v-show="item.infoList.length"> <p class="catalogName"> <span v-if="nindex == 0">涓�銆�</span> <span v-if="nindex == 1">浜屻��</span> @@ -206,6 +206,7 @@ " ></TEditorVue> --> <el-input + :disabled="value.isComplete" style="width: 90%; margin: 0 auto" v-else-if="value.questionType == 'shortAnswer'" type="textarea" @@ -298,7 +299,7 @@ class="subjective subjectiveItem" > <div class="questionAnalysis"> - <p class="difficulty"> + <p class="difficulty" v-if="value.difficulty"> <span style="color: #333">闅惧害绛夌骇锛�</span> <el-rate v-model="value.difficulty" @@ -313,7 +314,7 @@ >{{ value.isUnfold ? "鏀惰捣绛旀鍜岃В鏋�" : "鏌ョ湅绛旀涓庤В鏋�" }} </span - ><el-image :src="!value.isUnfold ? chakanIcon : packIcon" /> + > </p> </div> <!-- :class="['analysisDetailBox', value.isUnfold ? 'open' : 'close'].join(' ') --> @@ -381,7 +382,7 @@ import { getPublicImage } from "@/assets/js/middleGround/tool"; export default { name: "examination-option", - props: ["productLinkPath"], + props: ["cardList"], data() { return { type: "option", @@ -390,7 +391,6 @@ }; }, mounted() { - this.getIdPathList(); }, methods: { // 鏁扮粍杞负瀛楃涓叉柟娉� @@ -451,254 +451,256 @@ this.$data.loading = false; }, watchParsing(data) { + debugger + data.isUnfold = !data.isUnfold; }, - // 鑾峰彇璇曞嵎涓嬮鐩被鍨� - getIdPathList() { - this.$data.loading = true; - let query = { - path: "*", - queryType: "*", - productId: this.config.bookId, - cmsPath: "24080\\63791\\63792\\63807", - pading: { - start: 0, - size: 999, - }, - }; - this.MG.store.getProductDetail(query).then(async (res) => { - console.log(this.$props.productLinkPath, res.datas.cmsDatas[0].datas); - const idPathList = res.datas.cmsDatas[0].datas; - await this.getQuestionList(idPathList); - }); - }, - // 鑾峰彇棰樺簱棰樼洰 - async getQuestionList(idPathList, oldData) { - let cardList = []; - // 娓呯┖姝g‘棰樻暟璁板綍 - for (let index = 0; index < idPathList.length; index++) { - const pathitem = idPathList[index]; - const pathList = cardList; - pathList.push({ - path: pathitem.productLinkPath, - catalogName: pathitem.name, - infoList: [], - }); - cardList = pathList; - // 鑾峰彇棰樼洰 - let query = { - path: "*", - queryType: "*", - productId: this.config.bookId, - cmsPath: pathitem.productLinkPath, - itemFields: { - Embedded_QuestionBank_Stem: [], - Embedded_QuestionBank_AnalysisCon: [], - Embedded_QuestionBank_Answer: [], - Embedded_QuestionBank_Option: [], - Embedded_QuestionBank_QuestionType: [], - Embedded_QuestionBank_StemStyle: [], - Embedded_QuestionBank_OptionStyle: [], - Embedded_QuestionBank_KnowledgePoint: [], - Embedded_QuestionBank_Difficulty: [], - }, - pading: { - start: 0, - size: 999, - }, - }; - await this.MG.store.getProductDetail(query).then((res) => { - let oldList; - if (oldData) { - // 鎻愪氦杩囷紝瀛樺湪绛旈璁板綍 - oldList = oldData.find( - (item) => item.path == pathitem.productLinkPath - ).infoList; - this.setData({ - submitStatus: true, - }); - } - res.datas.cmsDatas[0].datas.forEach((item, index) => { - let oldObj = ""; - if (oldList) - oldObj = oldList.find((oldItem) => oldItem.id == item.id); - let questionObj = { - // num: index, // 棰樺彿 - id: item.id, - type: pathitem.name, - stem: - item.Embedded_QuestionBank_QuestionType == "completion" - ? JSON.parse(item.Embedded_QuestionBank_Stem) - .stemTxt.replaceAll("<vacancy>", ",input,") - .split(",") - : JSON.parse(item.Embedded_QuestionBank_Stem), // 棰樺共 - answer: item.Embedded_QuestionBank_Answer, // 绛旀 - option: item.Embedded_QuestionBank_Option - ? JSON.parse(item.Embedded_QuestionBank_Option) - : "", // 閫夋嫨棰橀�夐」 - analysisCon: item.Embedded_QuestionBank_AnalysisCon, // 瑙f瀽 - questionType: item.Embedded_QuestionBank_QuestionType, // 棰樺瀷 - optionStyle: item.Embedded_QuestionBank_OptionStyle, // 閫夐」鏄剧ず绫诲瀷 - stemStyle: item.Embedded_QuestionBank_StemStyle, // 棰樺共鏄剧ず绫诲瀷 - difficulty: item.Embedded_QuestionBank_Difficulty - ? 4 - item.Embedded_QuestionBank_Difficulty - : 0, // 闅惧害绛夌骇 - userAnswer: oldObj - ? oldObj.userAnswer - : item.Embedded_QuestionBank_QuestionType == "completion" || - item.Embedded_QuestionBank_QuestionType == "multipleChoice" - ? [] - : "", - isUserAnswer: oldObj - ? this.isHaveAnswer(oldObj.userAnswer) - : false, - isRight: oldObj ? oldObj.isRight : null, - isComplete: oldObj ? oldObj.isComplete : false, - isCollect: false, - isUnfold: "", // 鎺у埗瑙f瀽鐨勬姌鍙犻潰鏉挎槸鍚﹀睍寮� - }; - // 澶氶�夊拰濉┖绛旀鑲负鏁扮粍锛岃杞崲JSON鏍煎紡 - if ( - questionObj.questionType == "completion" || - questionObj.questionType == "multipleChoice" - ) { - try { - questionObj.answer = JSON.parse(questionObj.answer).toString(); - } catch (error) { - questionObj.answer = item.Embedded_QuestionBank_Answer; - } - } - // 濉┖棰樻敼閫� - if (questionObj.questionType == "completion") { - let index = 0; - for (let i = 0; i < questionObj.stem.length; i++) { - const item = questionObj.stem[i]; - if (item == "input") { - questionObj.stem[i] = { - num: index, - data: "input", - }; - if (!oldObj) questionObj.userAnswer[index] = ""; - index++; - } - } - } - // 棰樺共瀵屾枃鏈鐞� - if (questionObj.stemStyle == "RichText") { - // questionObj.option.txt = '' - questionObj.stem.stemTxt = questionObj.stem.stemTxt - .replace( - /\<img/gi, - '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img" ' - ) - .replace(/\<p/gi, '<p class="stem-rich-p"') - .replace("../file", app.config.requestCtx + "/file"); - } - // 閫夐」瀵屾枃鏈鐞� - if ( - questionObj.optionStyle == "RichText" && - (questionObj.questionType == "singleChoice" || - questionObj.questionType == "judge" || - questionObj.questionType == "multipleChoice") - ) { - questionObj.option.forEach((item) => { - if (item.txt) - item.txt = item.txt - .replace(/\<img/gi, '<img class="option-rich-img"') - .replace(/\<p/gi, '<p class="stem-rich-p"') - .replace("../file", app.config.requestCtx + "/file"); - }); - } - // 瑙f瀽瀵屾枃鏈鐞� - if ( - questionObj.analysisCon && - typeof questionObj.analysisCon == "string" - ) { - questionObj.analysisCon = questionObj.analysisCon.replace( - /\<img/gi, - '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img" ' - ); - } - // 鍚姏棰樹慨鏀� - // if (questionObj.questionType == 'singleChoice') { - // const src = this.extractSourceSrc(questionObj.stem.stemTxt) - // if (src) { - // questionObj.src = src - // questionObj.stem.stemTxt = this.removeVideoAndAudioTags(questionObj.stem.stemTxt) - // } - // } - // 鑾峰彇鍥剧墖 - if ( - questionObj.stemStyle == "Image" || - questionObj.stemStyle == "TxtAndImage" - ) { - questionObj.stem.stemImage = getPublicImage( - questionObj.stem.stemImage, - 150 - ); - } - if ( - questionObj.optionStyle == "Image" || - questionObj.optionStyle == "TxtAndImage" - ) { - questionObj.option.forEach((optionItem) => { - if (optionItem.img) - optionItem.img = getPublicImage(optionItem.img, 150); - }); - } - // 瀹㈣棰樻�诲垎璧嬪�� - if (questionObj.questionType !== "shortAnswer") { - // this.setData({ - // subjectiveGrade: this.data.subjectiveGrade + 2, - // }); - } - // 鏃ф暟鎹噷 棰樼洰姝g‘ 璁板綍姝g‘鏁伴噺 - if (questionObj.isRight) { - // this.setData({ - // correctNum: this.data.correctNum + 1, - // }); - } - if ( - pathitem.name == "鍒ゆ柇棰�" || - pathitem.name == "濉┖棰�" || - pathitem.name == "澶氶�夐" || - pathitem.name == "鍗曢�夐" || - pathitem.name == "鍚姏棰�" - ) { - if (oldObj) { - // this.setData({ - // subjectiveTotal: this.data.subjectiveTotal + 1, - // }); - } - } - // cardList璧嬪�� - let cardIndex = cardList.findIndex( - (item) => item.path == pathitem.productLinkPath - ); - let infoList = cardList[cardIndex].infoList; - infoList.push(questionObj); - cardList[cardIndex].infoList = infoList; - let questionList = []; - const cardUpdatedList = cardList; - cardUpdatedList.forEach((aitem) => { - aitem.infoList.forEach((bitem, bindex) => { - questionList.push(bitem); - bitem.number = bindex + 1; - bitem.score = 2; - }); - }); - cardList = cardUpdatedList; - this.$data.cardList = cardList; - this.$data.loading = false; - // console.log("棰樼洰鍛�", cardList); - // return cardList - }); - }); - } - }, + // // 鑾峰彇璇曞嵎涓嬮鐩被鍨� + // getIdPathList() { + // this.$data.loading = true; + // let query = { + // path: "*", + // queryType: "*", + // productId: this.config.bookId, + // cmsPath: "24080\\63791\\63792\\63807", + // pading: { + // start: 0, + // size: 999, + // }, + // }; + // this.MG.store.getProductDetail(query).then(async (res) => { + // console.log(this.$props.productLinkPath, res.datas.cmsDatas[0].datas); + // const idPathList = res.datas.cmsDatas[0].datas; + // await this.getQuestionList(idPathList); + // }); + // }, + // // 鑾峰彇棰樺簱棰樼洰 + // async getQuestionList(idPathList, oldData) { + // let cardList = []; + // // 娓呯┖姝g‘棰樻暟璁板綍 + // for (let index = 0; index < idPathList.length; index++) { + // const pathitem = idPathList[index]; + // const pathList = cardList; + // pathList.push({ + // path: pathitem.productLinkPath, + // catalogName: pathitem.name, + // infoList: [], + // }); + // cardList = pathList; + // // 鑾峰彇棰樼洰 + // let query = { + // path: "*", + // queryType: "*", + // productId: this.config.bookId, + // cmsPath: pathitem.productLinkPath, + // itemFields: { + // Embedded_QuestionBank_Stem: [], + // Embedded_QuestionBank_AnalysisCon: [], + // Embedded_QuestionBank_Answer: [], + // Embedded_QuestionBank_Option: [], + // Embedded_QuestionBank_QuestionType: [], + // Embedded_QuestionBank_StemStyle: [], + // Embedded_QuestionBank_OptionStyle: [], + // Embedded_QuestionBank_KnowledgePoint: [], + // Embedded_QuestionBank_Difficulty: [], + // }, + // pading: { + // start: 0, + // size: 999, + // }, + // }; + // await this.MG.store.getProductDetail(query).then((res) => { + // let oldList; + // if (oldData) { + // // 鎻愪氦杩囷紝瀛樺湪绛旈璁板綍 + // oldList = oldData.find( + // (item) => item.path == pathitem.productLinkPath + // ).infoList; + // this.setData({ + // submitStatus: true, + // }); + // } + // res.datas.cmsDatas[0].datas.forEach((item, index) => { + // let oldObj = ""; + // if (oldList) + // oldObj = oldList.find((oldItem) => oldItem.id == item.id); + // let questionObj = { + // // num: index, // 棰樺彿 + // id: item.id, + // type: pathitem.name, + // stem: + // item.Embedded_QuestionBank_QuestionType == "completion" + // ? JSON.parse(item.Embedded_QuestionBank_Stem) + // .stemTxt.replaceAll("<vacancy>", ",input,") + // .split(",") + // : JSON.parse(item.Embedded_QuestionBank_Stem), // 棰樺共 + // answer: item.Embedded_QuestionBank_Answer, // 绛旀 + // option: item.Embedded_QuestionBank_Option + // ? JSON.parse(item.Embedded_QuestionBank_Option) + // : "", // 閫夋嫨棰橀�夐」 + // analysisCon: item.Embedded_QuestionBank_AnalysisCon, // 瑙f瀽 + // questionType: item.Embedded_QuestionBank_QuestionType, // 棰樺瀷 + // optionStyle: item.Embedded_QuestionBank_OptionStyle, // 閫夐」鏄剧ず绫诲瀷 + // stemStyle: item.Embedded_QuestionBank_StemStyle, // 棰樺共鏄剧ず绫诲瀷 + // difficulty: item.Embedded_QuestionBank_Difficulty + // ? 4 - item.Embedded_QuestionBank_Difficulty + // : 0, // 闅惧害绛夌骇 + // userAnswer: oldObj + // ? oldObj.userAnswer + // : item.Embedded_QuestionBank_QuestionType == "completion" || + // item.Embedded_QuestionBank_QuestionType == "multipleChoice" + // ? [] + // : "", + // isUserAnswer: oldObj + // ? this.isHaveAnswer(oldObj.userAnswer) + // : false, + // isRight: oldObj ? oldObj.isRight : null, + // isComplete: oldObj ? oldObj.isComplete : false, + // isCollect: false, + // isUnfold: "", // 鎺у埗瑙f瀽鐨勬姌鍙犻潰鏉挎槸鍚﹀睍寮� + // }; + // // 澶氶�夊拰濉┖绛旀鑲负鏁扮粍锛岃杞崲JSON鏍煎紡 + // if ( + // questionObj.questionType == "completion" || + // questionObj.questionType == "multipleChoice" + // ) { + // try { + // questionObj.answer = JSON.parse(questionObj.answer).toString(); + // } catch (error) { + // questionObj.answer = item.Embedded_QuestionBank_Answer; + // } + // } + // // 濉┖棰樻敼閫� + // if (questionObj.questionType == "completion") { + // let index = 0; + // for (let i = 0; i < questionObj.stem.length; i++) { + // const item = questionObj.stem[i]; + // if (item == "input") { + // questionObj.stem[i] = { + // num: index, + // data: "input", + // }; + // if (!oldObj) questionObj.userAnswer[index] = ""; + // index++; + // } + // } + // } + // // 棰樺共瀵屾枃鏈鐞� + // if (questionObj.stemStyle == "RichText") { + // // questionObj.option.txt = '' + // questionObj.stem.stemTxt = questionObj.stem.stemTxt + // .replace( + // /\<img/gi, + // '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img" ' + // ) + // .replace(/\<p/gi, '<p class="stem-rich-p"') + // .replace("../file", app.config.requestCtx + "/file"); + // } + // // 閫夐」瀵屾枃鏈鐞� + // if ( + // questionObj.optionStyle == "RichText" && + // (questionObj.questionType == "singleChoice" || + // questionObj.questionType == "judge" || + // questionObj.questionType == "multipleChoice") + // ) { + // questionObj.option.forEach((item) => { + // if (item.txt) + // item.txt = item.txt + // .replace(/\<img/gi, '<img class="option-rich-img"') + // .replace(/\<p/gi, '<p class="stem-rich-p"') + // .replace("../file", app.config.requestCtx + "/file"); + // }); + // } + // // 瑙f瀽瀵屾枃鏈鐞� + // if ( + // questionObj.analysisCon && + // typeof questionObj.analysisCon == "string" + // ) { + // questionObj.analysisCon = questionObj.analysisCon.replace( + // /\<img/gi, + // '<img style="max-width: 300rpx !important;object-fit: contain;" class="stem-rich-img" ' + // ); + // } + // // 鍚姏棰樹慨鏀� + // // if (questionObj.questionType == 'singleChoice') { + // // const src = this.extractSourceSrc(questionObj.stem.stemTxt) + // // if (src) { + // // questionObj.src = src + // // questionObj.stem.stemTxt = this.removeVideoAndAudioTags(questionObj.stem.stemTxt) + // // } + // // } + // // 鑾峰彇鍥剧墖 + // if ( + // questionObj.stemStyle == "Image" || + // questionObj.stemStyle == "TxtAndImage" + // ) { + // questionObj.stem.stemImage = getPublicImage( + // questionObj.stem.stemImage, + // 150 + // ); + // } + // if ( + // questionObj.optionStyle == "Image" || + // questionObj.optionStyle == "TxtAndImage" + // ) { + // questionObj.option.forEach((optionItem) => { + // if (optionItem.img) + // optionItem.img = getPublicImage(optionItem.img, 150); + // }); + // } + // // 瀹㈣棰樻�诲垎璧嬪�� + // if (questionObj.questionType !== "shortAnswer") { + // // this.setData({ + // // subjectiveGrade: this.data.subjectiveGrade + 2, + // // }); + // } + // // 鏃ф暟鎹噷 棰樼洰姝g‘ 璁板綍姝g‘鏁伴噺 + // if (questionObj.isRight) { + // // this.setData({ + // // correctNum: this.data.correctNum + 1, + // // }); + // } + // if ( + // pathitem.name == "鍒ゆ柇棰�" || + // pathitem.name == "濉┖棰�" || + // pathitem.name == "澶氶�夐" || + // pathitem.name == "鍗曢�夐" || + // pathitem.name == "鍚姏棰�" + // ) { + // if (oldObj) { + // // this.setData({ + // // subjectiveTotal: this.data.subjectiveTotal + 1, + // // }); + // } + // } + // // cardList璧嬪�� + // let cardIndex = cardList.findIndex( + // (item) => item.path == pathitem.productLinkPath + // ); + // let infoList = cardList[cardIndex].infoList; + // infoList.push(questionObj); + // cardList[cardIndex].infoList = infoList; + // let questionList = []; + // const cardUpdatedList = cardList; + // cardUpdatedList.forEach((aitem) => { + // aitem.infoList.forEach((bitem, bindex) => { + // questionList.push(bitem); + // bitem.number = bindex + 1; + // bitem.score = 2; + // }); + // }); + // cardList = cardUpdatedList; + // this.$data.cardList = cardList; + // this.$data.loading = false; + // // console.log("棰樼洰鍛�", cardList); + // // return cardList + // }); + // }); + // } + // }, // 鎵规敼棰樼洰 (缁冧範,鎴戠殑鍋氶,鎴戠殑鏀惰棌妯″紡涓�) handleQuestion() { - const list = this.$data.cardList + const list = this.$props.cardList for (let index = 0; index < list.length; index++) { const item = list[index]; for (let cindex = 0; cindex < item.infoList.length; cindex++) { @@ -745,7 +747,8 @@ } } - this.$data.cardList = list + this.$props.cardList = list + console.log(this.$props.cardList); }, }, }; @@ -758,22 +761,23 @@ font-size: 16px; } .examination { + margin-top: 20px; min-height: 100px; ul { list-style: none; } } .border-box { + padding-top: 20px; border: 2px solid #e9e9e9; - border-top: 0; } .border-box:first-child { border-top:2px solid #e9e9e9 ; } .questionContent { // display: flex; - // justify-content: flex-start; - margin-left: -36px; + // justify-content: center; + margin-left: 20px; } .input { /deep/ .el-input__inner { @@ -843,7 +847,7 @@ /** 棰樺共 */ .questionTitle { display: flex; - justify-content: space-between; + justify-content: center; .titleContent { width: 95%; display: flex; @@ -875,6 +879,9 @@ width: 140px; height: 24px; border-top: 0; + } + /deep/ .el-textarea.is-disabled .el-textarea__inner { + background-color: #fff ; } /deep/.el-input__wrapper { border-top: 0 !important; @@ -937,7 +944,7 @@ .analysis { margin: 20px 0; width:550px; - margin-left: 48px; + // margin-left: 12px; } .el-collapse { width: 100%; diff --git a/src/store/index.js b/src/store/index.js index c3d62fd..2bb340c 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -14,13 +14,17 @@ }, setQiankun(state,value) { state.qiankun = value + }, + setQuestionData(state,value) { + state.questionData = value } }, state: { // 鐘舵�佹暟鎹畾涔� num:1, testList:[], - qiankun: {} + qiankun: {}, + questionData:{} }, getters: { // 璁$畻娲剧敓鐘舵�� -- Gitblit v1.9.1