index.vue 81 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478
  1. <template>
  2. <div class="pb_content" style="height: auto; width: calc(100% - 40px); margin: 0 auto;background: unset;">
  3. <backPage v-if="$route.query.gotype == 1" tit="智能表单"></backPage>
  4. <div style="width:100%;padding:0;box-sizing: border-box;">
  5. <div class="pb_head top" v-if="!$route.query.gotype">
  6. <div style="display: flex;align-items: center;">
  7. <span class="sub_head">表单管理</span>
  8. <!-- v-show="oid == '4c686762-1d0a-11ed-8c78-005056b86db5'" -->
  9. <span class="subClick" @click="
  10. goTo(
  11. '/trainCourse?userid=' +
  12. userid +
  13. '&oid=' +
  14. oid +
  15. '&org=' +
  16. org +
  17. '&role=' +
  18. role
  19. )
  20. ">培训管理</span>
  21. <span class="subClick" v-if="examineData.length" @click="
  22. goTo(
  23. '/testDataBoard?userid=' +
  24. userid +
  25. '&oid=' +
  26. oid +
  27. '&org=' +
  28. org +
  29. '&role=' +
  30. role
  31. )
  32. ">数据看板</span>
  33. <span class="subClick" @click="
  34. goTo(
  35. '/testSmarter?userid=' +
  36. userid +
  37. '&oid=' +
  38. oid +
  39. '&org=' +
  40. org +
  41. '&role=' +
  42. role +
  43. '&cid=' +
  44. cid
  45. )
  46. ">智能助手</span>
  47. </div>
  48. </div>
  49. </div>
  50. <div class="bbox_nav">
  51. <span :class="{ active: cutNumber == 0}" @click="cutNumber = 0">个人总览</span>
  52. <span :class="{ active: cutNumber == 1}" v-if="examineData.length" @click="cutNumber = 1">年度考核</span>
  53. </div>
  54. <div class="bbox" v-if="cutNumber==0">
  55. <div v-if="!oidArray.includes(oid)" class="test_data_box" v-loading="isLoadingData">
  56. <div class="data_box">
  57. <div class="left">
  58. <div class="title">表单状态总览</div>
  59. <div class="box">
  60. <span class="color1">{{ dataJ.doing }}个进行中</span>
  61. <span class="color5">{{ dataJ.nodo }}个未进行</span>
  62. <span class="color2">{{ dataJ.noLook }}个未发布</span>
  63. <span class="color3">{{ dataJ.is }}个已完成</span>
  64. <span class="color4">{{ dataJ.no }}个逾期</span>
  65. </div>
  66. </div>
  67. <div class="right">
  68. <pie-1 :dataJ="dataJ"></pie-1>
  69. </div>
  70. </div>
  71. <div class="data_box" v-show="false">
  72. <div class="left">
  73. <div class="title">教师完成情况</div>
  74. <div class="box">
  75. <span class="color1">{{ 10 }}个未完成</span>
  76. <span class="color2">{{ 8 }}个进行中</span>
  77. <span class="color3">{{ 6 }}个已完成</span>
  78. <span class="color4">{{ 7 }}个逾期</span>
  79. </div>
  80. </div>
  81. <div class="right">
  82. <pie-2></pie-2>
  83. </div>
  84. </div>
  85. <div class="data_box" v-if="typeArray.length">
  86. <div class="left">
  87. <div class="title">综合平均分</div>
  88. <div class="box2">
  89. <span>{{ zscore.toFixed(0) }}</span>
  90. </div>
  91. </div>
  92. <div class="right">
  93. <randar-1 :typeJArray="typeJArray"></randar-1>
  94. </div>
  95. </div>
  96. <div class="data_box" v-if="typeArray.length" style="flex-direction: column;">
  97. <div class="left" style="height: fit-content;text-align: left;width: 100%;">
  98. <div class="title" style="margin: 0;">逾期情况</div>
  99. <!-- <div class="box2">
  100. <span>{{ 12 }}%</span>
  101. </div> -->
  102. </div>
  103. <div class="right" style="height: calc(100% - 20px);">
  104. <randar-2 :typeJArray="typeJArray"></randar-2>
  105. </div>
  106. </div>
  107. </div>
  108. <div class="search_nav">
  109. <div class="right">
  110. <span :class="{ active: stype == 3 }" v-show="orgArray2.includes(org) || oidArray.includes(oid)" @click="checkDataType(3)">数据汇总</span>
  111. <span :class="{ active: stype == 1 }" @click="checkDataType(1)">按问卷查看</span>
  112. <span :class="{ active: stype == 2 }" @click="checkDataType(2)">按人员查看</span>
  113. </div>
  114. <div class="left">
  115. <span class="list" :class="{ active: stype2 == 1 }" @click="checkStype2(1)"></span>
  116. <span class="table" :class="{ active: stype2 == 2 }" @click="checkStype2(2)"></span>
  117. </div>
  118. </div>
  119. <div style="width: calc(100% - 20px);margin: 0 auto;">
  120. <div class="student_head">
  121. <div class="choose">
  122. <div class="student_search" v-if="typeArray.length && stype == 1">
  123. <el-select v-model="typeCheck" placeholder="请选择类型" clearable @change="search">
  124. <el-option v-for="(item, index) in typeArray" :key="index" :label="item.name"
  125. :value="item.id"></el-option>
  126. </el-select>
  127. </div>
  128. <div class="student_search" style="width:100px" v-if="stype == 1">
  129. <!-- <span></span> -->
  130. <el-select v-model="groupA" @change="search">
  131. <el-option value="0" label="我的"></el-option>
  132. <el-option value="2" label="他人"></el-option>
  133. <el-option value="4" label="所有人"></el-option>
  134. </el-select>
  135. </div>
  136. <!-- <div @click="clear" class="clear" v-if="CourseType.length">重置</div> -->
  137. </div>
  138. <div class="student_right">
  139. <div class="head_left">
  140. <div style="margin-right: 10px;position: relative;">
  141. <el-input v-model="courseName" class="student_input" placeholder="请输入项目名称"></el-input>
  142. <span class="serach_icon" @click="searchCourse"></span>
  143. </div>
  144. <!-- <el-button type="primary" @click="searchCourse">查询</el-button> -->
  145. <el-button type="primary" class="bgColor" @click="openTestDataBoard()"
  146. v-if="oid == '4c686762-1d0a-11ed-8c78-005056b86db5'">表单看板</el-button>
  147. <el-button type="primary" class="bgColor" @click="goToCourse()">新建表单</el-button>
  148. <!-- <el-button type="primary" class="bgColor" v-if="stype==1" @click="aiAnalysis()">AI分析</el-button> -->
  149. </div>
  150. </div>
  151. </div>
  152. </div>
  153. <div class="pb_content_body" style="height: 100%;width: 100%;">
  154. <aggregate v-if="stype == 3"></aggregate>
  155. <div class="student_table" v-loading="isLoading" v-if="stype == 1 && stype2 == 1">
  156. <div class="course_box">
  157. <div class="test_box" v-for="(item, index) in course" :key="index">
  158. <div class="test_top">
  159. <div class="test_top_img" v-if="!item.typeN"></div>
  160. <el-tooltip :content="item.typeN" placement="top" effect="dark" v-else>
  161. <div class="test_top_img"
  162. :class="{ gr: item.typeid == 'afc3f97f-2429-408d-8dcd-5e63a44d355a', md: item.typeid == '478bcccd-e3a1-472b-aa29-3ed7bc479469', js: item.typeid == '178a377a-b4f1-4a75-b3c3-2787a7c98784', yy: item.typeid == 'dda9728e-5f11-469e-89ee-aca518daf223', bj: item.typeid == 'afc3f97f-2429-408d-8dcd-5e63a44d355c' }">
  163. </div>
  164. </el-tooltip>
  165. <div class="test_top_title">
  166. <span>{{ item.title }}</span>
  167. <!-- <span>创建人:{{ item.uname }}</span> -->
  168. <span>提交数量:{{ item.worksCount }}</span>
  169. </div>
  170. <div class="test_top_chose" v-if="item.worksCount>0" @click.stop="choseCourse(item.courseId)">
  171. <div class="test_top_chose_checkbox" :class="{test_top_chose_checkbox_active:checkList.includes(item.courseId)}">
  172. <svg t="1728873838936" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="4300" width="200" height="200"><path d="M817.728 198.72l111.744 114.56-545.216 532.128-285.92-273.024 110.528-115.712 174.176 166.336z" p-id="4301"></path></svg>
  173. </div>
  174. <!-- <el-checkbox class="test_top_chose_checkbox" :checked="checkList.includes(item.courseId)"></el-checkbox> -->
  175. </div>
  176. </div>
  177. <div class="test_time">
  178. <span><span>创建人</span></span><span>{{ item.uname }}</span>
  179. </div>
  180. <div class="test_time">
  181. <span><span>创建日期</span></span><span>{{ item.time }}</span>
  182. </div>
  183. <div class="test_time">
  184. <span><span>修改日期</span></span><span>{{ item.utime }}</span>
  185. </div>
  186. <div class="test_time">
  187. <span><span>截止日期</span></span><span>{{ item.overtime ? item.overtime : '未设置' }}</span>
  188. </div>
  189. <div class="test_time">
  190. <span><span>填写范围</span></span><el-tooltip :content="item.juriP ? item.juriP : '所有人'"
  191. placement="top" effect="dark">
  192. <!-- content to trigger tooltip here -->
  193. <span>{{ item.juriP ? item.juriP : '所有人' }}</span>
  194. </el-tooltip>
  195. </div>
  196. <div class="test_time tset_type" v-if="typeArray.length">
  197. <span><span>类型</span></span>
  198. <span v-if="!item.typeN">未设置类型</span>
  199. <span v-else>{{ item.typeN }}</span>
  200. </div>
  201. <!-- <div class="test_time">
  202. <span><span>分类</span></span>
  203. <span v-if="!item.typename">未设置分类</span>
  204. <el-tooltip :content="item.typename" placement="top" effect="dark" v-else>
  205. <span>{{ item.typename }}</span>
  206. </el-tooltip>
  207. </div> -->
  208. <div class="test_btn">
  209. <div class="test_o_btn">
  210. <el-tooltip content="编辑" placement="top" effect="dark">
  211. <span class="edit" @click="goToCourse2(item)" v-if="((item.userid == userid) ||
  212. (item.course_teacher &&
  213. item.course_teacher.indexOf(userid) !== -1) || role == '1')"></span>
  214. </el-tooltip>
  215. <el-tooltip content="查看" placement="top" effect="dark">
  216. <span class="check" @click="checkToTest(item.courseId)"></span>
  217. </el-tooltip>
  218. <el-tooltip content="复制" placement="top" effect="dark">
  219. <span class="copy" @click="copyTest(item.courseId)"></span>
  220. </el-tooltip>
  221. <el-tooltip content="提醒" placement="top" effect="dark">
  222. <span class="share" @click="shareTest(item)" v-if="((item.userid == userid) ||
  223. (item.course_teacher &&
  224. item.course_teacher.indexOf(userid) !== -1) || role == '1')"></span>
  225. </el-tooltip>
  226. <el-tooltip content="删除" placement="top" effect="dark">
  227. <span class="delete" @click="deleteCourse(item.courseId)" v-if="((item.userid == userid) ||
  228. (item.course_teacher &&
  229. item.course_teacher.indexOf(userid) !== -1) || role == '1')"></span>
  230. </el-tooltip>
  231. </div>
  232. <!-- <div class="test_type" :class="{ no: item.look == '1', is: item.look == '2' }"> -->
  233. <div class="test_type" :class="getLookType(item)">
  234. <!-- <span>{{ item.look == '1' ? '未发布' : '已发布' }}</span> -->
  235. <span>{{ getLook(item) }}</span>
  236. </div>
  237. </div>
  238. </div>
  239. <div class="course_empty" v-if="course.length == 0">暂无数据</div>
  240. </div>
  241. </div>
  242. <el-table ref="table" :data="course" border v-loading="isLoading" :key="1"
  243. :header-cell-style="{ color: '#00000066', fontSize: '16px', fontWeight: 'unset' }"
  244. :row-class-name="tableRowClassName2" v-if="stype == 1 && stype2 == 2" class="tableClass">
  245. <el-table-column label="序号" width="100px" align="center">
  246. <template slot-scope="scope">
  247. {{ scope.$index + 1 }}
  248. </template>
  249. </el-table-column>
  250. <el-table-column prop="title" label="问卷名称" min-width="150" align="center">
  251. </el-table-column>
  252. <el-table-column prop="uname" label="创建者" min-width="80" align="center">
  253. </el-table-column>
  254. <el-table-column v-if="typeArray.length" prop="typeN" label="问卷类型" min-width="80" align="center">
  255. <template slot-scope="scope">
  256. {{ scope.row.typeN ? scope.row.typeN : '未设置类型' }}
  257. </template>
  258. </el-table-column>
  259. <el-table-column prop="worksCount" label="已提交数量" min-width="80" align="center">
  260. </el-table-column>
  261. <el-table-column label="表单状态" min-width="80" align="center">
  262. <template slot-scope="scope">
  263. <!-- <div class="test_type2" style="width: fit-content;margin: 0 auto;" :class="{ no: scope.row.look == '1', is: scope.row.look == '2' }"> -->
  264. <div class="test_type2" style="width: fit-content;margin: 0 auto;"
  265. :class="getLookType(scope.row)">
  266. <!-- <span>{{ scope.row.look == '1' ? '未发布' : '已发布' }}</span> -->
  267. <span>{{ getLook(scope.row) }}</span>
  268. </div>
  269. </template>
  270. </el-table-column>
  271. <el-table-column label="操作" width="350px">
  272. <template slot-scope="scope">
  273. <el-button @click="goToCourse2(scope.row)" type="text" size="small" v-if="((scope.row.userid == userid) ||
  274. (scope.row.course_teacher &&
  275. scope.row.course_teacher.indexOf(userid) !== -1) || role == '1')">编辑</el-button>
  276. <el-button @click="checkToTest(scope.row.courseId)" type="text" size="small">查看</el-button>
  277. <el-button @click="copyTest(scope.row.courseId)" type="text" size="small">复制</el-button>
  278. <el-button @click="shareTest(scope.row)" type="text" size="small" v-if="((scope.row.userid == userid) ||
  279. (scope.row.course_teacher &&
  280. scope.row.course_teacher.indexOf(userid) !== -1) || role == '1')">提醒</el-button>
  281. <el-button @click="deleteCourse(scope.row.courseId)" type="text" size="small"
  282. style="color: #EE3E3E;"
  283. v-if="((scope.row.userid == userid) ||
  284. (scope.row.course_teacher &&
  285. scope.row.course_teacher.indexOf(userid) !== -1) || role == '1')">删除</el-button>
  286. </template>
  287. </el-table-column>
  288. </el-table>
  289. <div class="student_table" v-loading="isLoading" v-if="stype == 2 && stype2 == 1">
  290. <div class="course_box">
  291. <div class="test_box" v-for="(item, index) in course2" :key="index">
  292. <div class="test_top">
  293. <div class="test_top_img"></div>
  294. <div class="test_top_title">
  295. <span>{{ item.name }}</span>
  296. <!-- <span>创建人:{{ item.uname }}</span> -->
  297. <span>提交数量:{{ item.worksCount }}</span>
  298. </div>
  299. </div>
  300. <div class="test_time">
  301. <span><span>已完成表单</span></span><span>{{ item.testCount }}</span>
  302. </div>
  303. <div class="test_time">
  304. <span><span>教研室</span></span><el-tooltip :content="item.className ? item.className : '无'"
  305. placement="top" effect="dark">
  306. <!-- content to trigger tooltip here -->
  307. <span>{{ item.className ? item.className : '无' }}</span>
  308. </el-tooltip>
  309. </div>
  310. <div class="test_btn">
  311. <div class="test_o_btn">
  312. <el-tooltip content="查看" placement="top" effect="dark">
  313. <span class="check" @click="checkToTest2(item.userid)"></span>
  314. </el-tooltip>
  315. </div>
  316. </div>
  317. </div>
  318. <div class="course_empty" v-if="stype == 1 && course.length == 0">暂无数据</div>
  319. <div class="course_empty" v-if="stype == 2 && course2.length == 0">暂无数据</div>
  320. </div>
  321. </div>
  322. <el-table ref="table" :data="course2" border v-loading="isLoading" :key="2"
  323. :header-cell-style="{ color: '#00000066', fontSize: '16px', fontWeight: 'unset' }"
  324. :row-class-name="tableRowClassName2" v-if="stype == 2 && stype2 == 2" class="tableClass">
  325. <el-table-column label="序号" width="100px" align="center">
  326. <template slot-scope="scope">
  327. {{ scope.$index + 1 }}
  328. </template>
  329. </el-table-column>
  330. <el-table-column prop="name" label="教师姓名" min-width="80" align="center">
  331. </el-table-column>
  332. <el-table-column label="教研室" min-width="80" align="center">
  333. <template slot-scope="scope">
  334. {{ scope.row.className ? scope.row.className : '无' }}
  335. </template>
  336. </el-table-column>
  337. <el-table-column prop="worksCount" label="已提交数量" min-width="80" align="center">
  338. </el-table-column>
  339. <el-table-column prop="testCount" label="已完成表单" min-width="80" align="center">
  340. </el-table-column>
  341. <el-table-column label="操作" width="350px">
  342. <template slot-scope="scope">
  343. <el-button @click="checkToTest2(scope.row.userid)" type="text" size="small">详情</el-button>
  344. </template>
  345. </el-table-column>
  346. </el-table>
  347. </div>
  348. <div class="student_page">
  349. <el-pagination background layout="prev, pager, next" :page-size="pageSize" :total="total"
  350. v-if="stype == 1 && page && course.length" style="padding: 0 0 20px 0;"
  351. @current-change="handleCurrentChange"></el-pagination>
  352. <el-pagination background layout="prev, pager, next" :page-size="pageSize2" :total="total2"
  353. v-if="stype == 2 && page2 && course2.length" style="padding: 0 0 20px 0;"
  354. @current-change="handleCurrentChange2"></el-pagination>
  355. </div>
  356. </div>
  357. <div class="bbox" v-if="cutNumber==1">
  358. <examine></examine>
  359. </div>
  360. <el-dialog :visible.sync="dialogVisible1" size="tiny">
  361. <img width="100%" :src="dialogImageUrl" alt />
  362. </el-dialog>
  363. <el-dialog title="查看提问" :visible.sync="dialogVisible" :append-to-body="true" width="750px"
  364. :before-close="handleClose" class="dialog_diy">
  365. <div>
  366. <div class="a_addBox">
  367. <CourseProblem :problemCourse="problemCourse"></CourseProblem>
  368. </div>
  369. </div>
  370. <span slot="footer" class="dialog-footer">
  371. <el-button @click="dialogVisible = false">关 闭</el-button>
  372. </span>
  373. </el-dialog>
  374. <el-dialog title="查看协同项目" :visible.sync="dialogVisibleCourse" :append-to-body="true" width="850px"
  375. :before-close="handleClose" class="dialog_diy">
  376. <div class="ct_box">
  377. <div class="out_box" v-for="(item, index) in courseTeam" :key="index" style="margin-left: 15px">
  378. <div class="tup">
  379. <img :src="item.cover != null && item.cover != ''
  380. ? JSON.parse(item.cover).length > 0
  381. ? JSON.parse(item.cover)[0].url
  382. : mr
  383. : mr
  384. " alt />
  385. </div>
  386. <div class="bottom_box">
  387. <div>{{ item.title }}</div>
  388. <div class="kc_t">创建人:{{ item.uname }}</div>
  389. <div class="kc_time">{{ item.time }}</div>
  390. </div>
  391. <div class="three_bottom">
  392. <!-- <div @click="jump(item.courseId)">查看内容</div> -->
  393. <div @click="
  394. goTo(
  395. '/studentAddCourse?cid=' +
  396. item.courseId +
  397. '&userid=' +
  398. userid +
  399. '&oid=' +
  400. oid +
  401. '&org=' +
  402. org +
  403. '&role=' +
  404. role
  405. )
  406. ">
  407. 编辑
  408. </div>
  409. </div>
  410. </div>
  411. <div class="course_empty" v-if="courseTeam.length == 0">暂无数据</div>
  412. </div>
  413. <span slot="footer" class="dialog-footer">
  414. <el-button @click="dialogVisibleCourse = false">关 闭</el-button>
  415. </span>
  416. </el-dialog>
  417. <share-box :testJson="scid" :dialogVisibleShare.sync="dialogVisibleShare"></share-box>
  418. </div>
  419. </template>
  420. <script>
  421. import "../../../common/aws-sdk-2.235.1.min";
  422. import EditorBar from "../../../components/tools/wangEnduit";
  423. import CourseProblem from "../components/courseProblem";
  424. import pie2 from "./data/pie2.vue";
  425. import pie1 from "./data/pie1.vue";
  426. import randar1 from "./data/randar1.vue";
  427. import randar2 from "./data/randar2.vue";
  428. import shareBox from './shareBox/index.vue'
  429. import examine from './examine/index.vue'
  430. import aggregate from './aggregate/index'
  431. import backPage from "../liyuan/components/backPage.vue";
  432. export default {
  433. name: 'test',
  434. components: { EditorBar, CourseProblem, pie1, pie2, randar1, randar2, shareBox, examine, aggregate,backPage },
  435. data() {
  436. return {
  437. examineData: [],
  438. cutNumber: 0,
  439. itemCount: 1,
  440. courseTitle: "",
  441. courseText: "",
  442. courseTime: "",
  443. isLoading: false,
  444. isLoadingData: false,
  445. fileList: [],
  446. fileList1: [],
  447. homeworkList: [{ name: "" }],
  448. formLabelWidth: "100px",
  449. dialogVisible: false,
  450. dialogVisible1: false,
  451. dialogVisibleCourse: false,
  452. dialogImageUrl: "",
  453. group: "",
  454. userid: this.$route.query.userid,
  455. oid: this.$route.query.oid,
  456. org: this.$route.query.org,
  457. role: this.$route.query.role,
  458. cid: this.$route.query.cid,
  459. orgArray: ["150e3120-9195-11ed-b13d-005056b86db5"],
  460. orgArray2: ["0fec3a8a-ad04-11ed-b13d-005056b86db5"],
  461. oidArray: ["d67940a5-510c-40ea-9c9a-2631ab03013a"],
  462. Juri: "",
  463. groupList: [],
  464. JuriList: [],
  465. page: 1,
  466. total: 0,
  467. pageSize: 20,
  468. tableData: [],
  469. now: "",
  470. courseDetail: {},
  471. addCourse: {},
  472. groupA: "4",
  473. classX: "",
  474. course: [],
  475. courseName: "",
  476. mr: require("../../../assets/icon/kc1.png"),
  477. CourseType: [],
  478. CourseTypeJson: {},
  479. courseTypeId: {},
  480. courseTypeSon: [],
  481. isChoose: 0,
  482. problemCourse: null, //查看提问的项目
  483. courseTeam: [],
  484. typeArray: [],
  485. typeCheck: "",
  486. stype: 1,
  487. stype2: 1,
  488. scid: {},
  489. dialogVisibleShare: false,
  490. page2: 1,
  491. total2: 0,
  492. pageSize2: 20,
  493. course2: [],
  494. dataJ: {},
  495. typeJArray: [],
  496. zscore: 0,
  497. checkList:[],
  498. };
  499. },
  500. computed: {
  501. getLook() {
  502. return function (item) {
  503. let content = "";
  504. if (item.look == '1' || item.look == '') {
  505. content = '未发布'
  506. }
  507. let now = new Date().getTime()
  508. let isTime = item.over_at && new Date(item.over_at).getTime()
  509. if (item.over_at && item.look == '2' && now > isTime && ((item.isUserCount > 0 && item.isUserCount > item.worksPerson) || item.isUserCount == 0)) {
  510. content = '逾期'
  511. }
  512. if (((item.over_at && item.look == '2' && isTime > now) || (!item.over_at && item.look == '2')) && ((item.isUserCount == 0 && item.worksPerson > 0) || (item.isUserCount > 0 && 0 < item.worksPerson && item.worksPerson < item.isUserCount))) {
  513. content = '进行中'
  514. }
  515. if (((item.over_at && item.look == '2' && isTime > now) || (!item.over_at && item.look == '2')) && item.worksPerson == 0) {
  516. content = '未进行'
  517. }
  518. if (item.look == '2' && (item.isUserCount > 0 && item.isUserCount <= item.worksPerson)) {
  519. content = '已完成'
  520. }
  521. return content;
  522. };
  523. },
  524. getLookType() {
  525. return function (item) {
  526. let content = "";
  527. if (item.look == '1' || item.look == '') {
  528. // content = '未发布'
  529. content = 'no'
  530. }
  531. let now = new Date().getTime()
  532. let isTime = item.over_at && new Date(item.over_at).getTime()
  533. if (item.over_at && item.look == '2' && now > isTime && ((item.isUserCount > 0 && item.isUserCount > item.worksPerson) || item.isUserCount == 0)) {
  534. // content = '逾期'
  535. content = 'noTime'
  536. }
  537. if (((item.over_at && item.look == '2' && isTime > now) || (!item.over_at && item.look == '2')) && ((item.isUserCount == 0 && item.worksPerson > 0) || (item.isUserCount > 0 && 0 < item.worksPerson && item.worksPerson < item.isUserCount))) {
  538. // content = '进行中'
  539. content = 'doing'
  540. }
  541. if (((item.over_at && item.look == '2' && isTime > now) || (!item.over_at && item.look == '2')) && item.worksPerson == 0) {
  542. // content = '未进行'
  543. content = 'nodo'
  544. }
  545. if (item.look == '2' && (item.isUserCount > 0 && item.isUserCount <= item.worksPerson)) {
  546. // content = '已完成'
  547. content = 'is'
  548. }
  549. return content;
  550. };
  551. }
  552. },
  553. methods: {
  554. // 获取基础页面数据
  555. getPageBase(type = 1) {
  556. let params = {
  557. typ: type,
  558. org: this.org,
  559. oid: this.oid
  560. };
  561. this.ajax
  562. .get(this.$store.state.api + "selectTestExamineBase", params)
  563. .then(res => {
  564. this.examineData = res.data[0];
  565. if(type == 1 && !res.data[0].length){
  566. this.getPageBase(2)
  567. }
  568. // console.log("selectTestExamineBase", res.data);
  569. })
  570. .catch(error => {
  571. console.log(error);
  572. });
  573. },
  574. random() {
  575. return Math.random().toString(36).substr(2);
  576. },
  577. tableRowClassName2({ row, rowIndex }) {
  578. if ((rowIndex + 1) % 2 === 0) {
  579. return "rowClass";
  580. } else {
  581. return "rowClass";
  582. }
  583. },
  584. change(val) {
  585. console.log(val);
  586. },
  587. time() {
  588. if (!this.now) {
  589. this.now = new Date().getTime();
  590. return true;
  591. } else {
  592. let time = new Date().getTime();
  593. if (time - this.now > 3000) {
  594. this.now = time;
  595. return true;
  596. } else {
  597. return false;
  598. }
  599. }
  600. },
  601. addHomeworkBox() {
  602. this.homeworkList.push({ name: "" });
  603. this.itemCount++;
  604. },
  605. reduceHomeworkBox() {
  606. var a = this.homeworkList;
  607. a.splice(a.length - 1);
  608. this.itemCount--;
  609. },
  610. goTo(path) {
  611. this.$router.push(path);
  612. },
  613. goToCourse(courseId) {
  614. if (courseId) {
  615. this.$router.push(
  616. "/addTest?cid=" +
  617. courseId +
  618. "&userid=" +
  619. this.userid +
  620. "&oid=" +
  621. this.oid +
  622. "&org=" +
  623. this.org +
  624. "&role=" +
  625. this.role
  626. );
  627. } else {
  628. this.$router.push(
  629. "/addTest?userid=" +
  630. this.userid +
  631. "&oid=" +
  632. this.oid +
  633. "&org=" +
  634. this.org +
  635. "&role=" +
  636. this.role
  637. );
  638. }
  639. // this.$router.push(path);
  640. },
  641. goToCourse2(item) {
  642. if (item.worksCount > 0) {
  643. this.$confirm("该表单已存在数据,如果修改题目可能会清空已提交数据,是否重新编辑?", "提示", {
  644. confirmButtonText: "确定",
  645. cancelButtonText: "取消",
  646. type: "warning",
  647. })
  648. .then(() => {
  649. this.$router.push(
  650. "/addTest?cid=" +
  651. item.courseId +
  652. "&userid=" +
  653. this.userid +
  654. "&oid=" +
  655. this.oid +
  656. "&org=" +
  657. this.org +
  658. "&type=2" +
  659. "&role=" +
  660. this.role
  661. );
  662. })
  663. .catch(() => {
  664. return;
  665. });
  666. } else {
  667. this.$router.push(
  668. "/addTest?cid=" +
  669. item.courseId +
  670. "&userid=" +
  671. this.userid +
  672. "&oid=" +
  673. this.oid +
  674. "&org=" +
  675. this.org +
  676. "&type=2" +
  677. "&role=" +
  678. this.role
  679. );
  680. }
  681. },
  682. checkToTest(cid) {
  683. this.$router.push(
  684. "/checkToTest?cid=" +
  685. cid +
  686. "&userid=" +
  687. this.userid +
  688. "&oid=" +
  689. this.oid +
  690. "&org=" +
  691. this.org +
  692. "&type=2" +
  693. "&role=" +
  694. this.role
  695. );
  696. },
  697. checkToTest2(uid) {
  698. this.$router.push(
  699. "/checkToTest2?uid=" +
  700. uid +
  701. "&userid=" +
  702. this.userid +
  703. "&oid=" +
  704. this.oid +
  705. "&org=" +
  706. this.org +
  707. "&type=2" +
  708. "&role=" +
  709. this.role
  710. );
  711. },
  712. tableRowClassName({ row, rowIndex }) {
  713. if ((rowIndex + 1) % 2 === 0) {
  714. return "even_row";
  715. } else {
  716. return "";
  717. }
  718. },
  719. jump(cid) {
  720. // window.open(
  721. // "//pbl.cocorobo.cn/pbl-student-table/dist/#/courseDetail?courseId=" +
  722. // cid +
  723. // "&userid=" +
  724. // this.userid
  725. // );
  726. window.topU.postMessage({ cid: cid, screenType: "2s" }, "*");
  727. },
  728. get(cid) {
  729. window.topU.postMessage({ cid: cid, screenType: "3s" }, "*");
  730. },
  731. openTestDataBoard() {
  732. window.topU.postMessage({ tools: "dataBoardTest" }, "*");
  733. },
  734. getA(cid) {
  735. this.$router.push("/courseProgress?cid=" + cid + "&userid=" +
  736. this.userid +
  737. "&oid=" +
  738. this.oid +
  739. "&org=" +
  740. this.org)
  741. },
  742. handle_remove(file, fileList) {
  743. var _tmp = this.fileList;
  744. for (var i = 0, len = _tmp.length; i < len; i++) {
  745. if (_tmp[i].uid == file.uid) {
  746. _tmp.splice(i, 1);
  747. break;
  748. }
  749. this.fileList = _tmp;
  750. }
  751. },
  752. handle_remove1(file, fileList) {
  753. var _tmp = this.fileList1;
  754. for (var i = 0, len = _tmp.length; i < len; i++) {
  755. if (_tmp[i].uid == file.uid) {
  756. _tmp.splice(i, 1);
  757. break;
  758. }
  759. this.fileList1 = _tmp;
  760. }
  761. },
  762. handleCurrentChange(val) {
  763. // console.log(`当前页: ${val}`);
  764. this.page = val;
  765. this.getCourse();
  766. },
  767. handleCurrentChange2(val) {
  768. this.page2 = val
  769. this.getCourse2();
  770. },
  771. init() { },
  772. handleClose(done) {
  773. done();
  774. },
  775. handleRemove(file, fileList) {
  776. console.log(file, fileList);
  777. },
  778. handlePictureCardPreview(file) {
  779. this.dialogImageUrl = file.url;
  780. this.dialogVisible1 = true;
  781. },
  782. onExceed() {
  783. this.$message.error("项目海报仅支持上传一张,请删除后再进行上传");
  784. },
  785. //uuid生成
  786. guid() {
  787. return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(
  788. /[xy]/g,
  789. function (c) {
  790. var r = (Math.random() * 16) | 0,
  791. v = c == "x" ? r : (r & 0x3) | 0x8;
  792. return v.toString(16);
  793. }
  794. );
  795. },
  796. time() {
  797. if (!this.now) {
  798. this.now = new Date().getTime();
  799. return true;
  800. } else {
  801. let time = new Date().getTime();
  802. if (time - this.now > 3000) {
  803. this.now = time;
  804. return true;
  805. } else {
  806. return false;
  807. }
  808. }
  809. },
  810. searchCourse() {
  811. if (this.stype == 1) {
  812. this.page = 1
  813. this.getCourse();
  814. } else if (this.stype == 2) {
  815. this.page2 = 1
  816. this.getCourse2();
  817. }
  818. },
  819. clear() {
  820. if (this.CourseType.length) {
  821. for (var i = 0; i < this.CourseType[0].length; i++) {
  822. this.courseTypeId[this.CourseType[0][i].id] = "";
  823. }
  824. }
  825. this.typeCheck = ''
  826. if (this.stype == 1) {
  827. this.page = 1
  828. this.getCourse();
  829. } else if (this.stype == 2) {
  830. this.page2 = 1
  831. this.getCourse2();
  832. }
  833. },
  834. getCourse() {
  835. var typeE = [];
  836. var typea, typeb, typec, typed, typef;
  837. if (this.isChoose == 1) {
  838. for (var i = 0; i < this.CourseType[0].length; i++) {
  839. if (this.courseTypeId[this.CourseType[0][i].id] == "1") {
  840. typeE.push(this.CourseType[0][i].id);
  841. } else if (this.courseTypeId[this.CourseType[0][i].id] != "") {
  842. if (this.CourseType[0][i].name == "年级") {
  843. typea = this.courseTypeId[this.CourseType[0][i].id];
  844. } else if (this.CourseType[0][i].name == "学科") {
  845. typeb = this.courseTypeId[this.CourseType[0][i].id];
  846. } else if (this.CourseType[0][i].name == "栏目") {
  847. typeb = this.courseTypeId[this.CourseType[0][i].id];
  848. } else if (this.CourseType[0][i].name == "学院") {
  849. typeb = this.courseTypeId[this.CourseType[0][i].id];
  850. } else if (this.CourseType[0][i].name == "新技能") {
  851. typec = this.courseTypeId[this.CourseType[0][i].id];
  852. } else if (this.CourseType[0][i].name == "赛道") {
  853. typed = this.courseTypeId[this.CourseType[0][i].id];
  854. } else if (this.CourseType[0][i].name == "项目类型") {
  855. typed = this.courseTypeId[this.CourseType[0][i].id];
  856. } else if (this.CourseType[0][i].name == "主题") {
  857. // typef = this.courseTypeId[this.CourseType[0][i].id];
  858. }
  859. this.courseTypeSon.push(
  860. this.courseTypeId[this.CourseType[0][i].id]
  861. );
  862. }
  863. }
  864. }
  865. this.isLoading = true;
  866. let params = {
  867. type: this.groupA,
  868. uid: this.userid,
  869. oid: this.oid,
  870. org: this.org,
  871. typea: typea != undefined ? typea : "",
  872. typeb: typeb != undefined ? typeb : "",
  873. typec: typec != undefined ? typec : "",
  874. typed: typed != undefined ? typed : "",
  875. typef: this.typeCheck,
  876. typeE: typeE.join(","),
  877. cu: "",
  878. cn: this.courseName,
  879. page: this.page,
  880. pageSize: this.pageSize,
  881. };
  882. this.ajax
  883. .get(this.$store.state.api + "selectTesttCourse", params)
  884. .then((res) => {
  885. this.isLoading = false;
  886. this.total = res.data[0].length > 0 ? res.data[0][0].num : 0;
  887. this.course = res.data[0];
  888. for(var i = 0; i < this.course.length; i++) {
  889. let a = ''
  890. if(this.course[i].juriP){
  891. a = this.course[i].juriP
  892. }
  893. if(this.course[i].juriP2){
  894. if(a){
  895. a = this.course[i].juriP+','+this.course[i].juriP2
  896. }else {
  897. a = this.course[i].juriP2
  898. }
  899. }
  900. this.course[i].juriP = a
  901. }
  902. })
  903. .catch((err) => {
  904. this.isLoading = false;
  905. console.error(err);
  906. });
  907. },
  908. getCourse2() {
  909. this.isLoading = true;
  910. let params = {
  911. oid: this.oid,
  912. org: this.org,
  913. type: this.typeCheck,
  914. cn: this.courseName,
  915. page: this.page2,
  916. pageSize: this.pageSize2,
  917. };
  918. this.ajax
  919. .get(this.$store.state.api + "selectTesttCourse2", params)
  920. .then((res) => {
  921. this.isLoading = false;
  922. this.total2 = res.data[0].length > 0 ? res.data[0][0].num : 0;
  923. this.course2 = res.data[0];
  924. })
  925. .catch((err) => {
  926. this.isLoading = false;
  927. console.error(err);
  928. });
  929. },
  930. getData() {
  931. let params = {
  932. oid: this.oid,
  933. org: this.org,
  934. };
  935. this.ajax
  936. .get(this.$store.state.api + "testDataBoard", params)
  937. .then((res) => {
  938. this.isLoadingData = false;
  939. let test = res.data[0]
  940. let work = res.data[1]
  941. let dataJ = {
  942. doing: 0,
  943. nodo: 0,
  944. noLook: 0,
  945. is: 0,
  946. no: 0
  947. }
  948. for (var i = 0; i < test.length; i++) {
  949. if (test[i].look == '1') {
  950. dataJ.noLook++
  951. console.log('index-----------', i)
  952. }
  953. let now = new Date().getTime()
  954. let isTime = test[i].over_at && new Date(test[i].over_at).getTime()
  955. if (test[i].over_at && test[i].look == '2' && now > isTime && ((test[i].isUserCount > 0 && test[i].isUserCount > test[i].isWorkCount) || test[i].isUserCount == 0)) {
  956. dataJ.no++
  957. console.log('index-----------', i)
  958. }
  959. if (((test[i].over_at && test[i].look == '2' && isTime > now) || (!test[i].over_at && test[i].look == '2')) && ((test[i].isUserCount == 0 && test[i].isWorkCount > 0) || (test[i].isUserCount > 0 && 0 < test[i].isWorkCount && test[i].isWorkCount < test[i].isUserCount))) {
  960. dataJ.doing++
  961. console.log('index-----------', i)
  962. }
  963. if (((test[i].over_at && test[i].look == '2' && isTime > now) || (!test[i].over_at && test[i].look == '2')) && test[i].isWorkCount == 0) {
  964. dataJ.nodo++
  965. console.log('index-----------', i)
  966. }
  967. if (test[i].look == '2' && (test[i].isUserCount > 0 && test[i].isUserCount <= test[i].isWorkCount)) {
  968. dataJ.is++
  969. console.log('index-----------', i)
  970. }
  971. }
  972. this.dataJ = dataJ
  973. if (this.typeArray.length) {
  974. let typeJ = {}
  975. for (var i = 0; i < this.typeArray.length; i++) {
  976. typeJ[this.typeArray[i].id] = {
  977. name: this.typeArray[i].name,
  978. count: 0,
  979. scroe: 0,
  980. zcount: 0,
  981. kcount: 0
  982. }
  983. }
  984. typeJ['qita'] = {
  985. name: '其他',
  986. count: 0,
  987. scroe: 0,
  988. zcount: 0,
  989. kcount: 0
  990. }
  991. for (var i = 0; i < work.length; i++) {
  992. if (work[i].typeid) {
  993. let score = this.getScore(work[i].courseJson)
  994. typeJ[work[i].typeid].count++
  995. typeJ[work[i].typeid].scroe += score
  996. } else {
  997. let score = this.getScore(work[i].courseJson)
  998. typeJ['qita'].count++
  999. typeJ['qita'].scroe += score
  1000. }
  1001. }
  1002. let typeJArray = Object.values(typeJ)
  1003. let zscore = 0
  1004. for (var i = 0; i < typeJArray.length; i++) {
  1005. typeJArray[i].zcount = typeJArray[i].scroe ? Math.round(typeJArray[i].scroe / typeJArray[i].count) : 0
  1006. zscore += typeJArray[i].zcount
  1007. }
  1008. this.zscore = zscore ? zscore / typeJArray.length : 0
  1009. for (var i = 0; i < test.length; i++) {
  1010. let now = new Date().getTime()
  1011. let isTime = test[i].over_at && new Date(test[i].over_at).getTime()
  1012. if (test[i].over_at && test[i].look == '2' && now > isTime && test[i].typeid && ((test[i].isUserCount > 0 && test[i].isUserCount > test[i].isWorkCount) || test[i].isUserCount == 0)) {
  1013. typeJ[test[i].typeid].kcount++
  1014. } else if (test[i].over_at && test[i].look == '1' && now > isTime && ((test[i].isUserCount > 0 && test[i].isUserCount > test[i].isWorkCount) || test[i].isUserCount == 0)) {
  1015. typeJ['qita'].kcount++
  1016. }
  1017. }
  1018. this.typeJArray = typeJArray
  1019. }
  1020. })
  1021. .catch((err) => {
  1022. this.isLoadingData = false;
  1023. console.error(err);
  1024. });
  1025. },
  1026. getScore(courseJson) {
  1027. // let _array = JSON.parse(array)
  1028. let _score = 0;
  1029. let _array = JSON.parse(courseJson);
  1030. for (var j = 0; j < _array.length; j++) {
  1031. let el = _array[j];
  1032. if ((el.ttype == 3 || el.ttype == 2) && el.array.length > 0) {
  1033. for (var k = 0; k < el.array.length; k++) {
  1034. let item = el.array[k];
  1035. if (item.ttype == 2 && item.array.length > 0) {
  1036. for (var z = 0; z < item.array.length; z++) {
  1037. let item2 = item.array[z];
  1038. if (item2.ttype == 1 && item2.json && item2.json.score2) {
  1039. _score += parseInt(item2.json.score2);
  1040. }
  1041. }
  1042. } else if (item.ttype == 1 && item.json && item.json.score2) {
  1043. _score += parseInt(item.json.score2);
  1044. }
  1045. }
  1046. } else if (el.ttype == 1 && el.json && el.json.score2) {
  1047. _score += parseInt(el.json.score2);
  1048. }
  1049. }
  1050. return _score ? _score : 0;
  1051. },
  1052. getTypeName() {
  1053. this.$forceUpdate();
  1054. this.page = 1;
  1055. this.isChoose = 1;
  1056. this.getCourse();
  1057. },
  1058. // searchCourse() {
  1059. // this.isLoading = true;
  1060. // let params = {
  1061. // cu: "",
  1062. // cn: this.courseName,
  1063. // page: this.page,
  1064. // };
  1065. // this.ajax
  1066. // .get(this.$store.state.api + "searchCourse", params)
  1067. // .then((res) => {
  1068. // this.isLoading = false;
  1069. // this.total = res.data[0].length > 0 ? res.data[0][0].num : 0;
  1070. // this.course = res.data[0];
  1071. // })
  1072. // .catch((err) => {
  1073. // this.isLoading = false;
  1074. // console.error(err);
  1075. // });
  1076. // },
  1077. shareTest(cid) {
  1078. this.scid = cid
  1079. this.dialogVisibleShare = true
  1080. },
  1081. deleteCourse(cid) {
  1082. // if (this.time()) {
  1083. this.$confirm("确定删除此表单吗?", "提示", {
  1084. confirmButtonText: "确定",
  1085. cancelButtonText: "取消",
  1086. type: "warning",
  1087. })
  1088. .then(() => {
  1089. this.isLoading = true;
  1090. let params = [{
  1091. cid: cid,
  1092. }];
  1093. this.ajax
  1094. .post(this.$store.state.api + "deleteTestCourse", params)
  1095. .then((res) => {
  1096. this.isLoading = false;
  1097. this.$message.success("删除成功");
  1098. this.getCourse();
  1099. })
  1100. .catch((err) => {
  1101. loading.close();
  1102. this.isLoading = false;
  1103. console.error(err);
  1104. });
  1105. })
  1106. .catch(() => {
  1107. return;
  1108. });
  1109. // }
  1110. },
  1111. selectAllType() {
  1112. let params = {
  1113. org: this.org && this.org != "" ? this.org : "",
  1114. oid: this.oid && this.oid != "" ? this.oid : "",
  1115. };
  1116. this.ajax
  1117. .get(this.$store.state.api + "selectAllTypeT", params)
  1118. .then((res) => {
  1119. this.CourseType = res.data;
  1120. for (var i = 0; i < res.data[0].length; i++) {
  1121. if (res.data[0][i].id == "34629907-d02f-11ec-8c78-005056b86db5") {
  1122. res.data[0][i].name = "学科";
  1123. } else if (res.data[0][i].id == "34628934-d02f-11ec-8c78-005056b86db5") {
  1124. res.data[0][i].name = "年级";
  1125. }
  1126. if (!this.cid) {
  1127. this.courseTypeId[res.data[0][i].id] = '';
  1128. }
  1129. if (!this.CourseTypeJson[res.data[0][i].id]) {
  1130. this.CourseTypeJson[res.data[0][i].id] = [];
  1131. }
  1132. if (res.data[2].length == 0 && res.data[3].length == 0) {
  1133. // for (var j = 0; j < res.data[1].length; j++) {
  1134. // if (res.data[0][i].id == res.data[1][j].pid) {
  1135. // this.CourseTypeJson[res.data[0][i].id].push(res.data[1][j]); // 去除公共分类
  1136. // }
  1137. // }
  1138. // if(this.org == '150e3120-9195-11ed-b13d-005056b86db5'){
  1139. for (var j = 0; j < res.data[1].length; j++) {
  1140. if (res.data[0][i].id == res.data[1][j].pid) {
  1141. this.CourseTypeJson[res.data[0][i].id].push(res.data[1][j]); // 去除公共分类
  1142. }
  1143. }
  1144. // }else{
  1145. // this.CourseType = []
  1146. // }
  1147. } else {
  1148. if (res.data[2].length > 0) {
  1149. for (var j = 0; j < res.data[2].length; j++) {
  1150. if (res.data[0][i].id == res.data[2][j].pid) {
  1151. this.CourseTypeJson[res.data[0][i].id].push(res.data[2][j]); // 去除公共分类
  1152. }
  1153. }
  1154. }
  1155. if (res.data[3].length > 0) {
  1156. for (var j = 0; j < res.data[3].length; j++) {
  1157. if (res.data[0][i].id == res.data[3][j].pid) {
  1158. this.CourseTypeJson[res.data[0][i].id].push(res.data[3][j]); // 去除公共分类
  1159. }
  1160. }
  1161. }
  1162. }
  1163. }
  1164. })
  1165. .catch((err) => {
  1166. console.error(err);
  1167. });
  1168. },
  1169. selectTestType() {
  1170. this.isLoadingData = true
  1171. let params = {
  1172. oid: this.oid,
  1173. };
  1174. this.ajax
  1175. .get(this.$store.state.api + "selectTestType", params)
  1176. .then((res) => {
  1177. this.typeArray = res.data[0];
  1178. this.getData()
  1179. })
  1180. .catch((err) => {
  1181. console.error(err);
  1182. });
  1183. },
  1184. selectType() {
  1185. this.ajax
  1186. .get(this.$store.state.api + "selectStudentType")
  1187. .then((res) => {
  1188. this.CourseType = res.data;
  1189. for (var i = 0; i < res.data[0].length; i++) {
  1190. if (!this.cid) {
  1191. this.courseTypeId[res.data[0][i].id] = "";
  1192. }
  1193. if (this.oid == "69893dca-1d47-11ed-8c78-005056b86db5") {
  1194. if (res.data[0][i].name == "栏目") {
  1195. this.CourseType[0][i].name = "主题";
  1196. }
  1197. }
  1198. for (var j = 0; j < res.data[1].length; j++) {
  1199. if (res.data[0][i].id == res.data[1][j].pid) {
  1200. if (!this.CourseTypeJson[res.data[0][i].id]) {
  1201. this.CourseTypeJson[res.data[0][i].id] = [];
  1202. }
  1203. this.CourseTypeJson[res.data[0][i].id].push(res.data[1][j]); //去除公共分类
  1204. }
  1205. }
  1206. }
  1207. this.selectTypeByOid();
  1208. this.selectTypeByOrg();
  1209. })
  1210. .catch((err) => {
  1211. console.error(err);
  1212. });
  1213. },
  1214. selectTypeByOid() {
  1215. let params = {
  1216. oid: this.oid,
  1217. };
  1218. this.ajax
  1219. .get(this.$store.state.api + "selectStudentTypeByOid", params)
  1220. .then((res) => {
  1221. for (var i = 0; i < res.data[0].length; i++) {
  1222. for (var j = 0; j < res.data[1].length; j++) {
  1223. if (res.data[0][i].id == res.data[1][j].pid) {
  1224. if (!this.CourseTypeJson[res.data[0][i].id]) {
  1225. this.CourseTypeJson[res.data[0][i].id] = [];
  1226. }
  1227. this.CourseTypeJson[res.data[0][i].id].push(res.data[1][j]);
  1228. }
  1229. }
  1230. }
  1231. this.$forceUpdate();
  1232. })
  1233. .catch((err) => {
  1234. console.error(err);
  1235. });
  1236. },
  1237. selectTypeByOrg() {
  1238. let params = {
  1239. oid: this.org,
  1240. };
  1241. this.ajax
  1242. .get(this.$store.state.api + "selectStudentTypeByOid", params)
  1243. .then((res) => {
  1244. for (var i = 0; i < res.data[0].length; i++) {
  1245. for (var j = 0; j < res.data[1].length; j++) {
  1246. if (res.data[0][i].id == res.data[1][j].pid) {
  1247. if (!this.CourseTypeJson[res.data[0][i].id]) {
  1248. this.CourseTypeJson[res.data[0][i].id] = [];
  1249. }
  1250. this.CourseTypeJson[res.data[0][i].id].push(res.data[1][j]);
  1251. }
  1252. }
  1253. }
  1254. this.$forceUpdate();
  1255. })
  1256. .catch((err) => {
  1257. console.error(err);
  1258. });
  1259. },
  1260. openCourse() {
  1261. this.dialogVisibleCourse = true;
  1262. this.getTeamCourse();
  1263. },
  1264. getTeamCourse() {
  1265. let params = {
  1266. uid: this.userid,
  1267. oid: this.oid,
  1268. };
  1269. this.ajax
  1270. .get(this.$store.state.api + "selectCourseTeam", params)
  1271. .then((res) => {
  1272. this.courseTeam = res.data[0];
  1273. })
  1274. .catch((err) => {
  1275. console.error(err);
  1276. });
  1277. },
  1278. checkStype2(type) {
  1279. if (this.stype2 != type) {
  1280. this.stype2 = type
  1281. }
  1282. },
  1283. checkDataType(type) {
  1284. if (this.stype != type) {
  1285. this.stype = type
  1286. if (type == 1) {
  1287. this.page = 1
  1288. this.getCourse()
  1289. } else {
  1290. this.page2 = 1
  1291. this.getCourse2()
  1292. }
  1293. }
  1294. },
  1295. search() {
  1296. if (this.stype == 1) {
  1297. this.page = 1
  1298. this.getCourse();
  1299. } else if (this.stype == 2) {
  1300. this.page2 = 1
  1301. this.getCourse2();
  1302. }
  1303. },
  1304. checkProblem(res) {
  1305. this.problemCourse = res;
  1306. this.dialogVisible = true;
  1307. },
  1308. copyTest(cid) {
  1309. let params = [{
  1310. cid: cid,
  1311. uid: this.userid
  1312. }]
  1313. this.ajax
  1314. .post(this.$store.state.api + "copyTest", params)
  1315. .then((res) => {
  1316. this.page = 1
  1317. if (this.role == "1") {
  1318. this.groupA = "0";
  1319. } else {
  1320. this.groupA = "0";
  1321. }
  1322. this.$message.success("复制成功")
  1323. this.clear()
  1324. })
  1325. .catch((err) => {
  1326. console.error(err);
  1327. });
  1328. },
  1329. choseCourse(courseId){//多选表单
  1330. console.log("测试测试")
  1331. if(this.checkList.includes(courseId)){
  1332. this.checkList = this.checkList.filter(item=>item != courseId)
  1333. }else{
  1334. if(this.checkList.length<10){
  1335. this.checkList.push(courseId)
  1336. }else{
  1337. this.$message.error("最多选择10个表单")
  1338. }
  1339. }
  1340. console.log(this.checkList)
  1341. this.$forceUpdate()
  1342. },
  1343. aiAnalysis(){
  1344. if(this.checkList.length == 0){
  1345. this.$message.error("请先选择表单")
  1346. return;
  1347. }
  1348. this.$router.push(
  1349. "/choseCheckTest?cid=" +
  1350. this.checkList.join(',') +
  1351. "&userid=" +
  1352. this.userid +
  1353. "&oid=" +
  1354. this.oid +
  1355. "&org=" +
  1356. this.org +
  1357. "&type=2" +
  1358. "&role=" +
  1359. this.role
  1360. );
  1361. }
  1362. },
  1363. activated() {
  1364. console.log(1);
  1365. this.selectAllType();
  1366. if (this.stype == 1) {
  1367. this.getCourse();
  1368. } else if (this.stype == 2) {
  1369. this.getCourse2();
  1370. }
  1371. this.selectTestType();
  1372. },
  1373. mounted() {
  1374. this.getPageBase()
  1375. console.log(2);
  1376. if (this.orgArray2.includes(this.org) || this.oidArray.includes(this.oid)) {
  1377. this.stype = 3
  1378. }
  1379. if (this.role == '1') {
  1380. this.groupA = '0'
  1381. }
  1382. this.page = 1;
  1383. this.selectAllType();
  1384. if (this.stype == 1) {
  1385. this.getCourse();
  1386. } else if (this.stype == 2) {
  1387. this.getCourse2();
  1388. }
  1389. this.selectTestType();
  1390. window.onbeforeunload = function(event) {
  1391. event.preventDefault();
  1392. event.returnValue = false;
  1393. return false
  1394. }
  1395. },
  1396. };
  1397. </script>
  1398. <style scoped>
  1399. @media screen and (max-width: 1380px) {
  1400. .test_box {
  1401. width: calc(100% / 4 - (15px * 3) / 4) !important;
  1402. }
  1403. .test_box:nth-child(5n) {
  1404. margin-right: 15px !important;
  1405. }
  1406. .test_box:nth-child(4n) {
  1407. margin-right: 0 !important;
  1408. }
  1409. }
  1410. @media screen and (max-width: 1080px) {
  1411. .test_box {
  1412. width: calc(100% / 3 - (15px * 2) / 3) !important;
  1413. }
  1414. .test_box:nth-child(5n) {
  1415. margin-right: 15px !important;
  1416. }
  1417. .test_box:nth-child(4n) {
  1418. margin-right: 15px !important;
  1419. }
  1420. .test_box:nth-child(3n) {
  1421. margin-right: 0 !important;
  1422. }
  1423. }
  1424. .dialog_diy>>>.el-dialog__header {
  1425. background: #3d67bc !important;
  1426. padding: 15px 20px;
  1427. }
  1428. .dialog_diy>>>.el-dialog__title {
  1429. color: #fff;
  1430. }
  1431. .dialog_diy>>>.el-dialog__headerbtn {
  1432. top: 19px;
  1433. }
  1434. .dialog_diy>>>.el-dialog__headerbtn .el-dialog__close {
  1435. color: #fff;
  1436. }
  1437. .dialog_diy>>>.el-dialog__headerbtn .el-dialog__close:hover {
  1438. color: #fff;
  1439. }
  1440. .student_head>>>.el-button--primary {
  1441. background-color: #3681fc;
  1442. }
  1443. .xls_button {
  1444. font-size: 14px;
  1445. cursor: pointer;
  1446. text-decoration: underline;
  1447. color: rgb(34, 104, 188);
  1448. }
  1449. .student_head {
  1450. display: flex;
  1451. justify-content: space-between;
  1452. align-items: baseline;
  1453. flex-direction: row;
  1454. flex-wrap: wrap;
  1455. padding: 0 0 0;
  1456. }
  1457. .top {
  1458. display: flex;
  1459. justify-content: space-between;
  1460. width: 100% !important;
  1461. box-sizing: border-box;
  1462. margin: 0px auto;
  1463. padding: 10px 0;
  1464. height: 54px;
  1465. }
  1466. .bgColor {
  1467. background: #3681fc;
  1468. }
  1469. .student_search {
  1470. display: flex;
  1471. align-items: center;
  1472. /* width: calc(100% / 3); */
  1473. width: 190px;
  1474. }
  1475. .student_search span {
  1476. margin: 0 10px 0 0;
  1477. min-width: 50px;
  1478. text-align-last: justify;
  1479. }
  1480. .student_button {
  1481. display: flex;
  1482. overflow: hidden;
  1483. height: 40px;
  1484. }
  1485. .upload-demo {
  1486. display: flex;
  1487. flex-direction: column;
  1488. align-items: end;
  1489. /* position: relative; */
  1490. width: 100px;
  1491. overflow: hidden;
  1492. }
  1493. .student_table {
  1494. padding: 0 0;
  1495. height: 100%;
  1496. /* overflow: auto; */
  1497. min-height: 360px;
  1498. width: calc(100% - 20px);
  1499. margin: 0 auto;
  1500. }
  1501. .student_empty {
  1502. display: flex;
  1503. justify-content: center;
  1504. align-items: center;
  1505. }
  1506. .el-table>>>.even_row {
  1507. background-color: #f1f1f1;
  1508. }
  1509. .time {
  1510. font-size: 13px;
  1511. color: #999;
  1512. }
  1513. .course_button {
  1514. padding: 10px 20px;
  1515. }
  1516. .course_button_box {
  1517. display: flex;
  1518. margin-top: 5px;
  1519. justify-content: space-between;
  1520. }
  1521. .course_rate {
  1522. margin-top: 5px;
  1523. }
  1524. .course_view {
  1525. display: flex;
  1526. align-items: center;
  1527. margin: 5px 0 0 0;
  1528. }
  1529. .course_view i {
  1530. background-image: url("../../../assets/liulan.png");
  1531. width: 25px;
  1532. height: 25px;
  1533. background-size: 100% 100%;
  1534. /* margin-top: 1px; */
  1535. line-height: 25px;
  1536. vertical-align: text-top;
  1537. background-repeat: no-repeat;
  1538. }
  1539. .image {
  1540. width: 100%;
  1541. height: 150px;
  1542. display: block;
  1543. }
  1544. .course_box {
  1545. display: flex;
  1546. flex-wrap: wrap;
  1547. }
  1548. .student_page {
  1549. width: calc(100% - 20px);
  1550. margin: 0 auto;
  1551. display: flex;
  1552. justify-content: flex-end;
  1553. }
  1554. .course_create_box {
  1555. font-size: 18px;
  1556. }
  1557. .course_name {
  1558. margin-top: 10px;
  1559. }
  1560. .course_name span {
  1561. margin-bottom: 10px;
  1562. display: block;
  1563. }
  1564. .homework_box {
  1565. display: flex;
  1566. align-items: center;
  1567. flex-wrap: wrap;
  1568. }
  1569. .course_homework {
  1570. width: 130px;
  1571. display: flex;
  1572. justify-content: center;
  1573. flex-direction: column;
  1574. align-items: center;
  1575. margin: 0 10px 10px 0;
  1576. }
  1577. .course_type {
  1578. margin-top: 10px;
  1579. display: flex;
  1580. }
  1581. .course_type1 span {
  1582. margin-bottom: 10px;
  1583. display: block;
  1584. }
  1585. .course_type2 {
  1586. margin-left: 20px;
  1587. }
  1588. .course_type2 span {
  1589. margin-bottom: 10px;
  1590. display: block;
  1591. }
  1592. .course_empty {
  1593. color: rgb(110, 110, 110);
  1594. width: 100%;
  1595. height: 100%;
  1596. display: flex;
  1597. align-items: center;
  1598. justify-content: center;
  1599. }
  1600. .el_cards>>>.el-card__body {
  1601. height: 100%;
  1602. }
  1603. .courseBtnBox {
  1604. display: flex;
  1605. flex-direction: column;
  1606. justify-content: space-between;
  1607. height: calc(100% - 170px);
  1608. padding: 10px;
  1609. }
  1610. .wordUpload {
  1611. display: flex;
  1612. }
  1613. .wordUpload>.buttonUp {
  1614. margin-right: 5px;
  1615. }
  1616. .out_box {
  1617. display: flex;
  1618. flex-direction: column;
  1619. flex-wrap: nowrap;
  1620. width: 250px;
  1621. background: #fff;
  1622. margin-right: 25px;
  1623. border: 1px solid #ccc;
  1624. height: fit-content;
  1625. box-sizing: border-box;
  1626. border-radius: 0px 0px 5px 5px;
  1627. /* overflow: hidden; */
  1628. margin-bottom: 15px;
  1629. position: relative;
  1630. padding-top: 30px;
  1631. }
  1632. .bottom_box {
  1633. display: flex;
  1634. padding: 0 0 10px 10px;
  1635. flex-direction: column;
  1636. box-sizing: border-box;
  1637. height: 140px;
  1638. flex-wrap: nowrap;
  1639. justify-content: space-evenly;
  1640. }
  1641. .bottom_box>div:nth-child(1) {
  1642. width: 230px;
  1643. overflow: hidden;
  1644. display: flex;
  1645. align-items: center;
  1646. }
  1647. .bottom_box>div:nth-child(1) span:nth-child(1) {
  1648. font-weight: bold;
  1649. font-size: 18px;
  1650. overflow: hidden;
  1651. text-overflow: ellipsis;
  1652. white-space: nowrap;
  1653. max-width: 100%;
  1654. }
  1655. .bottom_box>div:nth-child(1) span:nth-child(2) {
  1656. font-size: 14px;
  1657. min-width: fit-content;
  1658. margin-left: 5px;
  1659. color: #0074ff;
  1660. }
  1661. .tup {
  1662. width: 100%;
  1663. height: 141.06px;
  1664. margin: 0 auto;
  1665. overflow: hidden;
  1666. display: flex;
  1667. align-items: center;
  1668. }
  1669. .tup>img {
  1670. width: 100%;
  1671. height: 100%;
  1672. object-fit: contain;
  1673. }
  1674. .kc_time {
  1675. margin-top: 8px;
  1676. font-size: 14px;
  1677. color: #999;
  1678. }
  1679. .kc_t {
  1680. margin-top: 5px;
  1681. width: 100%;
  1682. white-space: nowrap;
  1683. overflow: hidden;
  1684. text-overflow: ellipsis;
  1685. }
  1686. .three_bottom {
  1687. display: flex;
  1688. flex-direction: row;
  1689. justify-content: space-around;
  1690. height: 40px;
  1691. align-items: center;
  1692. background: #f5f4f4;
  1693. font-size: 14px;
  1694. }
  1695. .three_bottom>div {
  1696. cursor: pointer;
  1697. }
  1698. .three_bottom>div:hover {
  1699. color: #79a2ff;
  1700. }
  1701. .head_left {
  1702. display: flex;
  1703. margin-top: 15px;
  1704. }
  1705. .student_input>>>.el-input__inner {
  1706. height: 40px;
  1707. width: 190px;
  1708. font-size: 13px;
  1709. padding: 0 10px;
  1710. }
  1711. .course_button {
  1712. color: #fff;
  1713. background: #3681fc;
  1714. width: 75px;
  1715. height: 40px;
  1716. padding: 0 !important;
  1717. font-size: 12px;
  1718. line-height: 40px;
  1719. }
  1720. .all_choose {
  1721. /* margin: 15px 0 10px; */
  1722. /* height: 20%; */
  1723. display: flex;
  1724. flex-direction: row;
  1725. align-items: center;
  1726. max-width: 180px;
  1727. width: 180px;
  1728. }
  1729. .all_choose>span {
  1730. min-width: 50px;
  1731. display: block;
  1732. margin-right: 10px;
  1733. text-align-last: justify;
  1734. }
  1735. .choose {
  1736. display: flex;
  1737. flex-direction: row;
  1738. flex-wrap: wrap;
  1739. align-content: space-between;
  1740. height: 100%;
  1741. justify-content: flex-start;
  1742. /* width: 60%; */
  1743. /* min-width: 868px; */
  1744. align-items: center;
  1745. }
  1746. .choose>div {
  1747. /* margin-left: 10px; */
  1748. width: 180px;
  1749. /* margin-top: 15px; */
  1750. }
  1751. .choose>div+div {
  1752. margin-left: 10px;
  1753. }
  1754. .choose>.clear {
  1755. width: 70px
  1756. }
  1757. .clear {
  1758. width: 70px;
  1759. max-width: 70px;
  1760. height: 35px;
  1761. background: #3681fc;
  1762. color: #fff;
  1763. text-align: center;
  1764. border-radius: 5px;
  1765. line-height: 35px;
  1766. cursor: pointer;
  1767. margin-left: 20px;
  1768. }
  1769. .ct_box {
  1770. height: 500px;
  1771. overflow: auto;
  1772. display: flex;
  1773. flex-wrap: wrap;
  1774. }
  1775. .myCourse {
  1776. position: absolute;
  1777. background: #3c3c3c;
  1778. width: 65px;
  1779. height: 25px;
  1780. color: #fff;
  1781. font-size: 12px;
  1782. text-align: center;
  1783. line-height: 25px;
  1784. top: 0;
  1785. right: 0;
  1786. }
  1787. .xtCourse {
  1788. position: absolute;
  1789. background: #3681fc;
  1790. width: 70px;
  1791. height: 30px;
  1792. border-radius: 30px;
  1793. color: #fff;
  1794. font-size: 14px;
  1795. text-align: center;
  1796. line-height: 30px;
  1797. top: 5px;
  1798. left: 5px;
  1799. }
  1800. .subClick {
  1801. font-size: 16px;
  1802. cursor: pointer;
  1803. margin-left: 10px;
  1804. /* color: #ab582f; */
  1805. color: #409eff;
  1806. }
  1807. .more {
  1808. position: relative;
  1809. }
  1810. .more:hover div {
  1811. display: block;
  1812. color: #000;
  1813. }
  1814. .more div {
  1815. position: absolute;
  1816. bottom: 0px;
  1817. transform: translate(-50%, 100%);
  1818. background: #f5f4f4;
  1819. padding: 10px 20px;
  1820. z-index: 99;
  1821. width: 40px;
  1822. border-radius: 5px;
  1823. box-shadow: 0 0 3px 3px #80808020;
  1824. display: none;
  1825. }
  1826. .more div>span+span {
  1827. margin-top: 10px;
  1828. }
  1829. .more div>span {
  1830. display: block;
  1831. width: 100%;
  1832. text-align: center;
  1833. }
  1834. .more div>span:hover {
  1835. color: #79a2ff;
  1836. }
  1837. .test_box {
  1838. width: calc(100% / 5 - (15px * 4) / 5);
  1839. /* width: 250px; */
  1840. background: #fff;
  1841. border-radius: 5px;
  1842. padding: 20px;
  1843. margin: 5px 15px 10px 0;
  1844. box-sizing: border-box;
  1845. border: 1px solid #e7e7e7;
  1846. }
  1847. .test_box:nth-child(5n) {
  1848. margin-right: 0;
  1849. }
  1850. .test_top {
  1851. width: 100%;
  1852. display: flex;
  1853. align-items: center;
  1854. position: relative;
  1855. }
  1856. .test_top>.test_top_img {
  1857. height: 40px;
  1858. width: 40px;
  1859. background: rgb(108 150 217);
  1860. margin-right: 10px;
  1861. border-radius: 5px;
  1862. display: flex;
  1863. align-items: center;
  1864. justify-content: center;
  1865. }
  1866. .test_top>.gr {
  1867. background: rgb(142, 189, 176);
  1868. }
  1869. .test_top>.md {
  1870. background: rgb(139, 174, 227);
  1871. }
  1872. .test_top>.js {
  1873. background: rgb(64, 149, 174);
  1874. }
  1875. .test_top>.yy {
  1876. background: rgb(98, 102, 188);
  1877. }
  1878. .test_top>.bj {
  1879. background: rgb(98, 158, 188);
  1880. }
  1881. .test_top>.test_top_img:after {
  1882. content: '';
  1883. display: block;
  1884. width: 23px;
  1885. height: 23px;
  1886. background-size: 100% 100%;
  1887. background-image: url('../../../assets/icon/test/all_icon_b.png');
  1888. }
  1889. .test_top>.gr:after {
  1890. background-image: url('../../../assets/icon/test/gr_icon_b.png');
  1891. }
  1892. .test_top>.md:after {
  1893. background-image: url('../../../assets/icon/test/md_icon_b.png');
  1894. }
  1895. .test_top>.js:after {
  1896. background-image: url('../../../assets/icon/test/js_icon_b.png');
  1897. }
  1898. .test_top>.yy:after {
  1899. background-image: url('../../../assets/icon/test/yy_icon_b.png');
  1900. }
  1901. .test_top>.bj:after {
  1902. background-image: url('../../../assets/icon/test/bj_icon_b.png');
  1903. }
  1904. .test_top>.test_top_title {
  1905. display: flex;
  1906. flex-direction: column;
  1907. justify-content: space-between;
  1908. height: 40px;
  1909. width: calc(100% - 40px - 10px)
  1910. }
  1911. .test_top>.test_top_title>span {
  1912. width: 100;
  1913. display: block;
  1914. word-break: break-all;
  1915. overflow: hidden;
  1916. text-overflow: ellipsis;
  1917. white-space: nowrap;
  1918. }
  1919. .test_top>.test_top_title>span:nth-child(1) {
  1920. font-size: 15px;
  1921. }
  1922. .test_top>.test_top_title>span:nth-child(2) {
  1923. font-size: 14px;
  1924. color: rgb(58, 131, 252);
  1925. }
  1926. .test_top_chose{
  1927. min-width: 18px;
  1928. min-height: 18px;
  1929. max-width: 18px;
  1930. max-height: 18px;
  1931. position: absolute;
  1932. right: 0px;
  1933. top: 0px;
  1934. display: flex;
  1935. align-items: center;
  1936. justify-content: center;
  1937. }
  1938. .test_top_chose_checkbox{
  1939. min-width: 18px;
  1940. min-height: 18px;
  1941. max-width: 18px;
  1942. max-height: 18px;
  1943. background-color: #fff;
  1944. border-radius: 2px;
  1945. border: 1px solid #DCDFE6;
  1946. display: flex;
  1947. justify-content: center;
  1948. align-items: center;
  1949. cursor: pointer;
  1950. color: #fff;
  1951. font-weight: bold;
  1952. position: relative;
  1953. font-size: 14px;
  1954. }
  1955. .test_top_chose_checkbox>svg{
  1956. fill: #fff;
  1957. width: 80%;
  1958. height: 80%;
  1959. }
  1960. .test_top_chose_checkbox_active{
  1961. background-color: #3681fc;
  1962. }
  1963. .test_box>.test_time {
  1964. margin-top: 10px;
  1965. font-size: 14px;
  1966. color: #a7a7a7;
  1967. display: flex;
  1968. }
  1969. .test_box>.test_time>span:nth-child(1) {
  1970. width: 85px;
  1971. display: flex;
  1972. }
  1973. .test_box>.test_time>span:nth-child(1)>span {
  1974. width: 100%;
  1975. text-align-last: justify;
  1976. }
  1977. .test_box>.test_time>span:nth-child(1)::after {
  1978. content: ':';
  1979. }
  1980. .test_box>.test_time>span:nth-child(2) {
  1981. max-width: calc(100% - 70px);
  1982. overflow: hidden;
  1983. display: block;
  1984. text-overflow: ellipsis;
  1985. white-space: nowrap;
  1986. word-break: break-all;
  1987. }
  1988. .test_box>.test_btn {
  1989. margin-top: 10px;
  1990. display: flex;
  1991. align-items: center;
  1992. justify-content: space-between;
  1993. }
  1994. .test_box>.test_btn>.test_o_btn {
  1995. display: flex;
  1996. align-items: center;
  1997. }
  1998. .test_box>.test_btn>.test_o_btn>span {
  1999. display: block;
  2000. width: 18px;
  2001. height: 18px;
  2002. background-size: 100% 100%;
  2003. cursor: pointer;
  2004. }
  2005. .test_box>.test_btn>.test_o_btn>.edit {
  2006. background-image: url('../../../assets/icon/test/edit_test_icon.png');
  2007. margin-right: 20px;
  2008. }
  2009. .test_box>.test_btn>.test_o_btn>.check {
  2010. background-image: url('../../../assets/icon/test/check_test_icon.png');
  2011. margin-right: 20px;
  2012. }
  2013. .test_box>.test_btn>.test_o_btn>.copy {
  2014. background-image: url('../../../assets/icon/test/paste-icon.png');
  2015. margin-right: 20px;
  2016. }
  2017. .test_box>.test_btn>.test_o_btn>.share {
  2018. background-image: url('../../../assets/icon/test/share_test_icon.png');
  2019. margin-right: 20px;
  2020. }
  2021. .test_box>.test_btn>.test_o_btn>.delete {
  2022. background-image: url('../../../assets/icon/test/delete_test_icon.png');
  2023. }
  2024. .test_type {
  2025. font-size: 12px;
  2026. border-radius: 5px;
  2027. border: 1.5px solid;
  2028. padding: 3px 8px;
  2029. }
  2030. .is {
  2031. color: rgb(57, 204, 127);
  2032. background-color: rgba(57, 204, 127, .1);
  2033. }
  2034. .no {
  2035. color: rgb(235, 154, 96);
  2036. background-color: rgba(235, 154, 96, .1);
  2037. }
  2038. .noTime {
  2039. color: rgb(77, 77, 77);
  2040. background-color: rgba(77, 77, 77, .1);
  2041. }
  2042. .doing {
  2043. color: rgb(54, 116, 231);
  2044. background-color: rgba(54, 116, 231, .1);
  2045. }
  2046. .nodo {
  2047. color: rgb(97, 184, 255);
  2048. background-color: rgba(97, 184, 255, .1);
  2049. }
  2050. .test_type2 {
  2051. font-size: 14px;
  2052. border-radius: 5px;
  2053. /* border: 1.5px solid; */
  2054. padding: 3px 8px;
  2055. }
  2056. .sub_head {
  2057. position: relative;
  2058. font-size: 20px;
  2059. font-weight: bold;
  2060. padding: 0 15px;
  2061. }
  2062. .sub_head::after {
  2063. content: "";
  2064. width: 100%;
  2065. background: #3681FC;
  2066. height: 2px;
  2067. position: absolute;
  2068. left: 0;
  2069. bottom: -8px;
  2070. }
  2071. .subClick {
  2072. /* font-size: 16px; */
  2073. font-size: 20px;
  2074. cursor: pointer;
  2075. /* margin-left: 17.5px; */
  2076. /* color: #ab582f; */
  2077. /* color: #409eff; */
  2078. color: #999;
  2079. padding: 0 15px;
  2080. }
  2081. .subClick:hover {
  2082. color: #000;
  2083. }
  2084. .sub_head+.subClick,
  2085. .subClick+.subClick,
  2086. .subClick+.sub_head {
  2087. margin-left: 17.5px;
  2088. }
  2089. .bbox_nav {
  2090. width: 100%;
  2091. display: flex;
  2092. align-items: center;
  2093. margin-top: 10px;
  2094. }
  2095. .bbox_nav>span {
  2096. height: 40px;
  2097. line-height: 40px;
  2098. text-align: center;
  2099. background: #e0eafb;
  2100. font-size: 18px;
  2101. color: #41506D;
  2102. padding: 0 35px;
  2103. margin-right: 15px;
  2104. cursor: pointer;
  2105. border-radius: 5px 5px 0 0;
  2106. }
  2107. .bbox_nav>.active {
  2108. background: #3681fc;
  2109. color: #fff;
  2110. }
  2111. .bbox {
  2112. background: #fff;
  2113. border-radius: 0 5px 5px 5px;
  2114. padding: 15px 0;
  2115. box-sizing: border-box;
  2116. }
  2117. .search_nav {
  2118. border-bottom: 1px solid #E7E7E7;
  2119. width: 100%;
  2120. box-sizing: border-box;
  2121. padding: 0 15px;
  2122. display: flex;
  2123. align-items: center;
  2124. }
  2125. .search_nav>.right {
  2126. display: flex;
  2127. align-items: center;
  2128. }
  2129. .search_nav>.right>span {
  2130. height: 30px;
  2131. font-size: 14px;
  2132. color: #000;
  2133. cursor: pointer;
  2134. position: relative;
  2135. }
  2136. .search_nav>.right>span+span {
  2137. margin-left: 35px;
  2138. }
  2139. .search_nav>.right>span.active {
  2140. color: #3681FC;
  2141. font-weight: 600;
  2142. }
  2143. .search_nav>.right>span.active::before {
  2144. content: "";
  2145. position: absolute;
  2146. bottom: 0;
  2147. width: 15px;
  2148. height: 3px;
  2149. background: #3681fc;
  2150. left: 50%;
  2151. transform: translateX(-50%);
  2152. }
  2153. .search_nav>.left {
  2154. display: flex;
  2155. align-items: center;
  2156. margin-left: auto;
  2157. }
  2158. .search_nav>.left>span {
  2159. height: 25px;
  2160. width: 25px;
  2161. display: flex;
  2162. align-items: center;
  2163. justify-content: center;
  2164. border-radius: 5px;
  2165. cursor: pointer;
  2166. }
  2167. .search_nav>.left>span+span {
  2168. margin-left: 10px;
  2169. }
  2170. .search_nav>.left>span.active {
  2171. background: #E0EAFB;
  2172. }
  2173. .search_nav>.left>span::before {
  2174. content: "";
  2175. width: 12px;
  2176. height: 12px;
  2177. background-size: 100% 100%;
  2178. }
  2179. .search_nav>.left>span.list::before {
  2180. background-image: url("../../../assets/icon/test/test_list.png");
  2181. }
  2182. .search_nav>.left>span.table::before {
  2183. background-image: url("../../../assets/icon/test/test_table.png");
  2184. }
  2185. .search_nav>.left>span.table.active::before {
  2186. background-image: url("../../../assets/icon/test/test_table_active.png");
  2187. }
  2188. .search_nav>.left>span.list.active::before {
  2189. background-image: url("../../../assets/icon/test/test_list_active.png");
  2190. }
  2191. .serach_icon {
  2192. position: absolute;
  2193. right: 12px;
  2194. top: 50%;
  2195. transform: translateY(-50%);
  2196. width: 13px;
  2197. height: 13px;
  2198. background: url("../../../assets/icon/test/test_search.png") no-repeat;
  2199. background-size: 100% 100%;
  2200. cursor: pointer;
  2201. }
  2202. .student_input>>>.el-input__inner {
  2203. padding-right: 35px;
  2204. }
  2205. .test_data_box {
  2206. display: flex;
  2207. width: calc(100% - 20px);
  2208. margin: 0 auto 15px;
  2209. flex-wrap: wrap;
  2210. }
  2211. .test_data_box>.data_box {
  2212. width: calc(100% / 4 - (45px / 4));
  2213. height: 150px;
  2214. border: 1px solid #e7e7e7;
  2215. border-radius: 5px;
  2216. box-sizing: border-box;
  2217. padding: 10px;
  2218. display: flex;
  2219. align-items: center;
  2220. }
  2221. .test_data_box>.data_box+.data_box {
  2222. margin-left: 15px;
  2223. }
  2224. .test_data_box>.data_box>.left {
  2225. /* width: 110px; */
  2226. min-width: fit-content;
  2227. height: 100%;
  2228. }
  2229. .test_data_box>.data_box>.left>.title {
  2230. font-size: 16px;
  2231. color: #00000099;
  2232. margin-bottom: 10px;
  2233. }
  2234. .test_data_box>.data_box>.left>.box {
  2235. display: flex;
  2236. flex-direction: column;
  2237. font-size: 14px;
  2238. height: calc(100% - 30px);
  2239. justify-content: space-between;
  2240. }
  2241. .test_data_box>.data_box>.left>.box2 {
  2242. display: flex;
  2243. flex-direction: column;
  2244. font-size: 30px;
  2245. font-weight: 600;
  2246. height: calc(100% - 60px);
  2247. /* align-items:center; */
  2248. justify-content: center;
  2249. }
  2250. .test_data_box>.data_box>.left>.box>span {
  2251. display: flex;
  2252. align-items: center;
  2253. }
  2254. .test_data_box>.data_box>.left>.box>span::before {
  2255. content: '';
  2256. width: 10px;
  2257. height: 10px;
  2258. border-radius: 50%;
  2259. /* background: #000; */
  2260. margin-right: 5px;
  2261. }
  2262. .test_data_box>.data_box>.left>.box>.color1::before {
  2263. background: #3673e8;
  2264. }
  2265. .test_data_box>.data_box>.left>.box>.color2::before {
  2266. background: #61b8ff;
  2267. }
  2268. .test_data_box>.data_box>.left>.box>.color3::before {
  2269. background: #96d8a8;
  2270. }
  2271. .test_data_box>.data_box>.left>.box>.color4::before {
  2272. background: #f5b763;
  2273. }
  2274. .test_data_box>.data_box>.left>.box>.color5::before {
  2275. background: #b362ff;
  2276. }
  2277. .test_data_box>.data_box>.right {
  2278. /* width: calc(100% - 110px); */
  2279. width: calc(100%);
  2280. height: 100%;
  2281. }
  2282. .el-table>>>.rowClass>td {
  2283. padding: 7px 0;
  2284. }
  2285. .tableClass {
  2286. width: calc(100% - 20px);
  2287. margin: 0 auto;
  2288. }
  2289. </style>