import{g as c,u as d,r as i,o as v,e as f}from"./vendor-39c32a1b.js";import{a as m,T as Q,b as T}from"./TestQuestionOptions-f4be709e.js";import{T as y,L as P}from"./LJDivider-2382bbe3.js";import{u as b}from"./TestQuestionsServers-5f17a3d3.js";import{n as x}from"./index-8fa791df.js";/* empty css                                                                  */const g={__name:"testPaperDetails",setup(l){const s=c(),t=d(),e=i(s.query.id||null),a=i({}),r=i([]),o=()=>{if(!e.value)return f.exports.Message.error("\u7F3A\u5931\u8BD5\u5377ID");HTTP.getReadById("test_paper",e.value).then(p=>{const n=p.data;for(const _ of n.test_paper_Questions)_.options=JSON.parse(_.option);b(n.test_paper_Questions,n.total_score),r.value=n.test_paper_Questions,a.value=n}).catch(p=>{})};function u(){t.back(-1)}return v(()=>{o()}),{__sfc:!0,route:s,router:t,testPaperId:e,testPapers:a,test_paper_Questions:r,getTestQuestions:o,back:u,TestQuestionTitle:m,TestQuestions:Q,TestQuestionOptions:T,TestQuestionAnalysis:y,LJDivider:P}}};var k=function(){var s=this,t=s._self._c,e=s._self._setupProxy;return t("div",{staticClass:"test-paper-details"},[t("div",{staticClass:"back"},[t("el-button",{attrs:{type:"primary",plain:""},on:{click:e.back}},[s._v("\u5173\u95ED")])],1),t("div",{staticClass:"test-paper-header"},[t("div",{staticClass:"test-paper-name"},[s._v(s._s(e.testPapers.name))]),t("div",{staticClass:"test-paper-info"},[t("div",[s._v("\u603B\u5206"+s._s(e.testPapers.total_score))]),t("div",[s._v("\u5171"+s._s(e.testPapers.total_num)+"\u9898")]),t("div",[s._v(" \u8003\u8BD5\u65F6\u95F4\uFF1A"+s._s(e.testPapers.start_date)+" ~ "+s._s(e.testPapers.end_date)+" ")])])]),t(e.LJDivider,{attrs:{padding:"24px 0"}}),t("div",{staticClass:"test-questions-lists"},s._l(e.test_paper_Questions,function(a,r){return t(e.TestQuestions,{key:a.id,attrs:{item:r}},[t(e.TestQuestionTitle,{attrs:{type:"details",score:a.score,index:r},model:{value:a.content,callback:function(o){s.$set(a,"content",o)},expression:"item.content"}}),t(e.TestQuestionOptions,{attrs:{type:"details",options:a.options,padding:"5px 2em"},model:{value:a.answer,callback:function(o){s.$set(a,"answer",o)},expression:"item.answer"}}),t(e.TestQuestionAnalysis,{attrs:{type:"details",value:a.analysis}}),t(e.LJDivider,{attrs:{padding:"24px 0"}})],1)}),1)],1)},C=[],D=x(g,k,C,!1,null,"b8ab498a",null,null);const I=D.exports;export{I as default};
