liveRoom.vue 55 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952
  1. <template>
  2. <div
  3. style="
  4. background: #d0d6e4;
  5. width: 100%;
  6. height: 100%;
  7. margin: 0;
  8. position: relative;
  9. "
  10. >
  11. <!-- <div class="pb_content_body" style="height: 100%">
  12. </div>-->
  13. <div class="blackBottom">
  14. <div
  15. style="
  16. display: flex;
  17. flex-direction: row;
  18. flex-wrap: nowrap;
  19. align-items: stretch;
  20. padding-left: 10px;
  21. "
  22. >
  23. <div class="logoLive">
  24. <img src="../../assets/icon/logo.png" alt />
  25. </div>
  26. <div style="color: #fff; line-height: 45px; padding-left: 15px">introduce a festival (Final)</div>
  27. </div>
  28. </div>
  29. <div class="isNoOther">
  30. <div class="imgMiddle" :class="isBlock > 0 ? 'imghalf' : 'imgMiddle'" v-show="!full">
  31. <!-- <img src="../../assets/icon/kc1.png" alt /> -->
  32. <!-- <iframe
  33. style="width: 100%; height: 100%; border: none"
  34. src="https://view.officeapps.live.com/op/view.aspx?src=https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/0701%E5%AE%9E%E6%97%B6%E8%AF%BE%E5%A0%82%E6%A8%A1%E6%8B%9F%E6%BC%94%E7%A4%BA%E8%AF%BE%E4%BB%B61656644341323.pptx"
  35. ></iframe>-->
  36. <pdf
  37. :pdfUrl="pdfUrl"
  38. style="width: 100%; height: 100%"
  39. :getPage="getPage"
  40. @getWidth="getWidth"
  41. ></pdf>
  42. <div class="workd_media" v-if="videoBlock == 9" :style="{ width: Vwidth }">
  43. <video-player
  44. class="video-player vjs-custom-skin"
  45. :playsinline="true"
  46. :options="playerO[0]"
  47. @play="onPlayerPlay($event)"
  48. style="width: 100%; height: 100%;"
  49. ></video-player>
  50. </div>
  51. </div>
  52. <div
  53. style="
  54. background: #d0d6e4;
  55. height: 100%;
  56. min-width: 40%;
  57. max-width: 40%;
  58. overflow: auto;
  59. padding: 0px 0 50px;
  60. "
  61. v-if="isBlock == 1 || isBlock == 6"
  62. >
  63. <div style="background: #fff; height: 92%; width: 96%; margin: 10px auto">
  64. <div style="color: #bfbfbf; padding: 15px 0 20px 25px; font-size: 20px">答题查看</div>
  65. <div class="answerBox" v-if="isBlock == 1 || isBlock == 6">
  66. <div class="memberBox" v-if="isBlock == 1">
  67. <div
  68. :class="{ pAnswer: item.is == 2 }"
  69. v-for="(item, index) in studentArray"
  70. @click="getOAnswer(item.answer, item.name)"
  71. :key="index"
  72. >{{ item.name }}</div>
  73. </div>
  74. <div class="memberBox" v-if="isBlock == 6">
  75. <div
  76. v-show="studentArray2.length > 0"
  77. :class="{ pAnswer: item.is == 2 }"
  78. v-for="(item, index) in studentArray2"
  79. :key="index"
  80. @click="whoAnswer(item, index)"
  81. >{{ item.name }}</div>
  82. <div v-if="studentArray2.length == 0">暂无学生</div>
  83. </div>
  84. <!-- <div style="color: #948bdc; padding-top: 15px" v-if="isBlock == 1">
  85. 共有四个选项,正在答题......
  86. </div>-->
  87. <div
  88. class="viewSta"
  89. @click="isBlock = 3"
  90. v-if="
  91. isBlock == 1 &&
  92. tools[steps].tools &&
  93. tools[steps].tools.indexOf(9) != -1
  94. "
  95. >查看数据统计</div>
  96. <div
  97. class="viewSta"
  98. @click="isBlock = 14"
  99. v-else-if="
  100. isBlock == 1 &&
  101. tools[steps].tools &&
  102. tools[steps].tools.indexOf(27) != -1
  103. "
  104. >查看所有学生答题情况</div>
  105. <span slot="footer" class="dialog-footer sztFooter" v-if="isBlock == 6">
  106. <el-button type="primary" @click="isBlock = 0">结束</el-button>
  107. <!-- <el-button type="primary" @click="isBlock = 2">返回</el-button> -->
  108. </span>
  109. </div>
  110. </div>
  111. </div>
  112. <div
  113. style="
  114. background: #d0d6e4;
  115. height: 92%;
  116. min-width: 40%;
  117. max-width: 40%;
  118. overflow: auto;
  119. padding: 0px 0 50px;
  120. "
  121. v-if="isBlock == 3"
  122. >
  123. <div
  124. style="
  125. background: #fff;
  126. width: 96%;
  127. margin: 10px auto;
  128. position: relative;
  129. "
  130. >
  131. <div class="close" @click="isBlock = 0">
  132. <img src="../../assets/icon/close.png" alt />
  133. </div>
  134. <div style="color: #bfbfbf; padding: 15px 0 20px 25px">数据统计</div>
  135. <div style="padding-left: 25px">
  136. 目前A选项
  137. <span class>{{ answerJson.A }}票</span>、B选项
  138. <span>{{ answerJson.B }}票</span>、C选项
  139. <span>{{ answerJson.C }}票</span>、D选项
  140. <span>{{ answerJson.D }}票</span>
  141. </div>
  142. <div class="szt">
  143. <AnswerData :problemJson="answerJson"></AnswerData>
  144. </div>
  145. <span slot="footer" class="dialog-footer sztFooter">
  146. <!-- <el-button type="primary" @click="isBlock = 0">关闭</el-button> -->
  147. <el-button type="primary" @click="isBlock = 1">返回</el-button>
  148. </span>
  149. </div>
  150. </div>
  151. <div class="answerBox tools_box" v-if="isBlock == 2" style="padding: 10px 0 0 25px">
  152. <div style="color: #d1d1d1; font-size: 24px">课堂实践</div>
  153. <div
  154. style="
  155. margin: 20px 0 20px 0;
  156. border-bottom: 4px solid #3e86f3;
  157. width: 75px;
  158. text-align: center;
  159. padding-bottom: 3px;
  160. "
  161. >选择工具</div>
  162. <div
  163. style="
  164. display: flex;
  165. flex-direction: row;
  166. flex-wrap: wrap;
  167. width: 100%;
  168. justify-content: flex-start;
  169. align-items: center;
  170. "
  171. >
  172. <div
  173. v-if="tools[steps].tools && tools[steps].tools.indexOf(1) != -1"
  174. @click="(isBlock = 5), (toolCount = 1)"
  175. class="toolCss"
  176. >
  177. <div class="toolImg">
  178. <img src="../../assets/icon/secondToolList/whiteBoard.png" alt />
  179. <div>电子白板</div>
  180. </div>
  181. </div>
  182. <div
  183. v-if="tools[steps].tools && tools[steps].tools.indexOf(3) != -1"
  184. @click="(isBlock = 5), (toolCount = 3)"
  185. class="toolCss"
  186. >
  187. <div class="toolImg">
  188. <img src="../../assets/icon/secondToolList/mindMapping.png" alt />
  189. <div>思维导图</div>
  190. </div>
  191. </div>
  192. <div
  193. v-if="tools[steps].tools && tools[steps].tools.indexOf(28) != -1"
  194. @click="(isBlock = 5), (toolCount = 28)"
  195. class="toolCss"
  196. >
  197. <div class="toolImg">
  198. <img src="../../assets/icon/thirdToolList/translation.png" alt />
  199. <div>翻译</div>
  200. </div>
  201. </div>
  202. <div
  203. v-if="tools[steps].tools && tools[steps].tools.indexOf(4) != -1"
  204. @click="(isBlock = 5), (toolCount = 4)"
  205. class="toolCss"
  206. >
  207. <div class="toolImg">
  208. <img src="../../assets/icon/thirdToolList/ask.png" alt />
  209. <div>问卷调查</div>
  210. </div>
  211. </div>
  212. <div
  213. v-if="tools[steps].tools && tools[steps].tools.indexOf(6) != -1"
  214. @click="(isBlock = 5), (toolCount = 6)"
  215. class="toolCss"
  216. >
  217. <div class="toolImg">
  218. <img src="../../assets/icon/secondToolList/doc.png" alt />
  219. <div>协同文档</div>
  220. </div>
  221. </div>
  222. <div
  223. v-if="tools[steps].tools && tools[steps].tools.indexOf(7) != -1"
  224. @click="(isBlock = 5), (toolCount = 7)"
  225. class="toolCss"
  226. >
  227. <div class="toolImg">
  228. <img src="../../assets/icon/secondToolList/mindNetwork.png" alt />
  229. <div>思维网格</div>
  230. </div>
  231. </div>
  232. <div v-if="tools[steps].tools && tools[steps].tools.indexOf(10) != -1" class="toolCss">
  233. <div class="toolImg" @click="timeDialogVisible = true">
  234. <img src="../../assets/icon/thirdToolList/time.png" alt />
  235. <div>倒计时</div>
  236. </div>
  237. </div>
  238. </div>
  239. <div class="nextStepBox">
  240. <div class="nextStepOne" @click="isBlock = 0">关闭</div>
  241. </div>
  242. </div>
  243. <div class="answerBox tools_box" :class="{ fullStyle: full }" v-if="isBlock == 5">
  244. <div style="height: 100%; width: 100%">
  245. <div v-if="toolCount == 1" class="tools_child_box">
  246. <div class="tools_title">
  247. <span>电子白板</span>
  248. <div>
  249. <img src="../../assets/full.png" class="full" @click="fullTools" />
  250. <img src="../../assets/close1.png" class="closeImg" @click="closeTools" />
  251. </div>
  252. </div>
  253. <iframe
  254. webkitallowfullscreen
  255. mozallowfullscreen
  256. allowfullscreen
  257. style="width: 100%; height: 100%; border: none"
  258. src="https://iwb.cocorobo.cn/"
  259. ></iframe>
  260. </div>
  261. <div v-if="toolCount == 3" class="tools_child_box">
  262. <div class="tools_title">
  263. <span>思维导图</span>
  264. <div>
  265. <img src="../../assets/full.png" class="full" @click="fullTools" />
  266. <img src="../../assets/close1.png" class="closeImg" @click="closeTools" />
  267. </div>
  268. </div>
  269. <iframe
  270. webkitallowfullscreen
  271. mozallowfullscreen
  272. allowfullscreen
  273. style="width: 100%; height: 100%; border: none"
  274. src="//cloud.cocorobo.cn/mind/"
  275. ></iframe>
  276. </div>
  277. <div v-if="toolCount == 28" class="tools_child_box">
  278. <div class="tools_title">
  279. <span>翻译</span>
  280. <div>
  281. <img src="../../assets/full.png" class="full" @click="fullTools" />
  282. <img src="../../assets/close1.png" class="closeImg" @click="closeTools" />
  283. </div>
  284. </div>
  285. <iframe
  286. webkitallowfullscreen
  287. mozallowfullscreen
  288. allowfullscreen
  289. style="width: 100%; height: 100%; border: none"
  290. src="//dict.youdao.com/"
  291. ></iframe>
  292. </div>
  293. <div v-if="toolCount == 6" class="tools_child_box">
  294. <div class="tools_title">
  295. <span>协同文档</span>
  296. <div>
  297. <img src="../../assets/full.png" class="full" @click="fullTools" />
  298. <img src="../../assets/close1.png" class="closeImg" @click="closeTools" />
  299. </div>
  300. </div>
  301. <iframe
  302. webkitallowfullscreen
  303. mozallowfullscreen
  304. allowfullscreen
  305. style="width: 100%; height: 100%; border: none"
  306. src="https://cloud.cocorobo.cn/Office/Word/WordEditArea.htm"
  307. ></iframe>
  308. </div>
  309. <div v-if="toolCount == 7" class="tools_child_box">
  310. <div class="tools_title">
  311. <span>思维网格</span>
  312. <div>
  313. <img src="../../assets/full.png" class="full" @click="fullTools" />
  314. <img src="../../assets/close1.png" class="closeImg" @click="closeTools" />
  315. </div>
  316. </div>
  317. <iframe
  318. webkitallowfullscreen
  319. mozallowfullscreen
  320. allowfullscreen
  321. style="width: 100%; height: 100%; border: none"
  322. src="https://pbl.cocorobo.cn/pbl-teacher-table/dist/#/Grid"
  323. ></iframe>
  324. </div>
  325. <div class="nextStepBox">
  326. <div class="nextStepOne" @click="(isBlock = 2), (full = false)">返回</div>
  327. </div>
  328. </div>
  329. </div>
  330. <div
  331. class="answerBox"
  332. style="
  333. width: 38.5%;
  334. max-width: 38.5%;
  335. overflow: auto;
  336. background: rgb(255, 255, 255);
  337. height: 91.5%;
  338. position: relative;
  339. margin: 10px 15px;
  340. "
  341. v-if="isBlock == 4"
  342. >
  343. <div
  344. style="
  345. color: #b7b7b7;
  346. border-left: 5px solid #a5b6e2;
  347. padding-left: 7px;
  348. height: 25px;
  349. line-height: 25px;
  350. "
  351. >查看作业</div>
  352. <div class="workBox">
  353. <div class="works" v-for="(w, wIndex) in worksList" :key="wIndex">
  354. <div class="workImg">
  355. <img
  356. v-if="
  357. tools[steps].tools && tools[steps].tools.indexOf(29) != -1
  358. "
  359. :src="require('../../assets/icon/stuVedio.png')"
  360. @click="lookvideo(w.upload)"
  361. alt
  362. />
  363. <img
  364. v-else
  365. :src="w.upload ? w.upload : mr"
  366. @click="previewImg(w.upload ? w.upload : mr)"
  367. alt
  368. />
  369. </div>
  370. <div class="workDetail">
  371. <div class="workLeft">
  372. <div class="workTx">
  373. <img src="../../assets/avatar.png" alt />
  374. </div>
  375. <div class="workName">{{ w.sName }}</div>
  376. </div>
  377. <div class="workRight">{{ w.time }}</div>
  378. <!-- <div class="workBtn" @click="isBlock = 7">查看评价</div> -->
  379. </div>
  380. </div>
  381. </div>
  382. <div class="returnButton" @click="isBlock = 0">关闭</div>
  383. </div>
  384. <div
  385. class="answerBox"
  386. v-if="isBlock == 7"
  387. style="
  388. padding: 0 0 0 25px;
  389. width: 38.5%;
  390. max-width: 38.5%;
  391. overflow: auto;
  392. background: rgb(255, 255, 255);
  393. height: 91.5%;
  394. position: relative;
  395. margin: 10px 15px;
  396. "
  397. >
  398. <div style="color: #bfbfbf; padding: 15px 0 15px 0; font-size: 20px">课堂评价</div>
  399. <div>
  400. <div class="score_box">
  401. <span>自我评价</span>
  402. <el-rate v-model="rateList.ca"></el-rate>
  403. </div>
  404. <div class="score_box">
  405. <span>他人评价</span>
  406. <el-rate v-model="rateList.sia"></el-rate>
  407. </div>
  408. </div>
  409. <div>
  410. <div style="padding-bottom: 15px; sont-size: 14px">备注</div>
  411. <div class="bz">
  412. <el-input
  413. type="textarea"
  414. placeholder="请输入备注…"
  415. :rows="6"
  416. resize="none"
  417. v-model="rateList.content"
  418. ></el-input>
  419. </div>
  420. </div>
  421. <span
  422. slot="footer"
  423. class="dialog-footer sztFooter"
  424. style="
  425. padding: 0 0 30px 0px;
  426. position: absolute;
  427. right: 20px;
  428. bottom: 0;
  429. "
  430. >
  431. <el-button type="primary" @click="isBlock = 4">返回</el-button>
  432. </span>
  433. </div>
  434. <div class="answerBox tools_box" v-if="isBlock == 8" style="padding: 10px 0 0 25px">
  435. <div style="color: #d1d1d1; font-size: 24px">课堂实践</div>
  436. <div
  437. style="
  438. margin: 20px 0 20px 0;
  439. border-bottom: 4px solid #3e86f3;
  440. width: 75px;
  441. text-align: center;
  442. padding-bottom: 3px;
  443. "
  444. >选择附件</div>
  445. <div
  446. style="
  447. display: flex;
  448. flex-direction: row;
  449. flex-wrap: wrap;
  450. width: 100%;
  451. justify-content: flex-start;
  452. align-items: center;
  453. "
  454. >
  455. <div v-if="tools[steps].file && tools[steps].file.length" class="fileBox">
  456. <div class="fileListCss" v-for="(v, vIndex) in videoList" :key="vIndex">
  457. <div class="fileCss" @click="playVideo(v.src, vIndex)">
  458. <img src="../../assets/uploadMp4.png" alt />
  459. </div>
  460. <div>{{ v.name }}</div>
  461. </div>
  462. <div class="fileListCss" v-for="(v, vIndex) in videoList2" :key="vIndex">
  463. <div class="fileCss" @click="playVideo2(v.src, vIndex)">
  464. <img src="../../assets/uploadMp4.png" alt />
  465. </div>
  466. <div>{{ v.name }}</div>
  467. </div>
  468. <div class="fileListCss" v-for="(f, fIndex) in fileList" :key="fIndex">
  469. <div class="fileCss" @click="openFile(f.src)">
  470. <img src="../../assets/file.png" alt />
  471. </div>
  472. <div>{{ f.name }}</div>
  473. </div>
  474. </div>
  475. </div>
  476. <div class="nextStepBox">
  477. <div class="nextStepOne" @click="isBlock = 0">关闭</div>
  478. </div>
  479. </div>
  480. <!-- <div class="answerBox tools_box" :class="{ fullStyle: full }" v-if="isBlock == 9">
  481. <div style="height: 70%; width: 100%">
  482. <div class="wheel">
  483. <div class="workd_media" style="height: 100%">
  484. <video-player
  485. class="video-player vjs-custom-skin"
  486. :playsinline="true"
  487. :options="playerO[0]"
  488. @play="onPlayerPlay($event)"
  489. style="width: 90%; height: 100%; margin: 0 0 0 30px"
  490. ></video-player>
  491. </div>
  492. </div>
  493. <div class="nextStepBox" style="margin-top: 5%">
  494. <div class="nextStepOne" @click="isBlock = 8">返回</div>
  495. </div>
  496. </div>
  497. </div>-->
  498. <div class="answerBox tools_box" :class="{ fullStyle: full }" v-if="isBlock == 10">
  499. <div style="height: 70%; width: 100%">
  500. <div class="wheel" style="height: 520px; width: 100%; margin: 0 0 20px 30px">
  501. <iframe
  502. webkitallowfullscreen
  503. mozallowfullscreen
  504. allowfullscreen
  505. style="width: 100%; height: 100%; border: none"
  506. :src="pptImgUrl"
  507. ></iframe>
  508. </div>
  509. <div class="nextStepBox" style="margin-top: 5%">
  510. <div class="nextStepOne" @click="isBlock = 8">返回</div>
  511. </div>
  512. </div>
  513. </div>
  514. <div class="answerBox tools_box" v-if="isBlock == 11">
  515. <div style="height: 100%; width: 100%">
  516. <div class="wheel" style="height: 80%; width: 100%">
  517. <div class="memberBox" style="max-height: 100%" v-if="worksList.length">
  518. <div
  519. v-for="(item, index) in worksList"
  520. :key="index"
  521. @click="getEv(item.upload, item.sName)"
  522. >{{ item.sName }}</div>
  523. </div>
  524. <div v-else>暂无学生评价</div>
  525. </div>
  526. <div class="nextStepBox" style="margin-top: 5%">
  527. <div class="nextStepOne" @click="isBlock = 0">关闭</div>
  528. </div>
  529. </div>
  530. </div>
  531. <div class="answerBox tools_box" v-if="isBlock == 12">
  532. <div style="height: 100%; width: 100%">
  533. <div class="wheel" style="height: 80%; width: 100%">
  534. <div style="height: 100%; overflow: auto">
  535. <div style="margin-bottom: 20px">{{ Sname }}</div>
  536. <div class="score_box">
  537. <span>聚焦主题</span>
  538. <el-rate v-model="rate.ca" disabled></el-rate>
  539. </div>
  540. <div class="score_box">
  541. <span>有开头结尾</span>
  542. <el-rate v-model="rate.sia" disabled></el-rate>
  543. </div>
  544. <div class="score_box">
  545. <span>语言正确,流畅</span>
  546. <el-rate v-model="rate.zia" disabled></el-rate>
  547. </div>
  548. <div class="score_box">
  549. <span>书写规范,美观</span>
  550. <el-rate v-model="rate.qia" disabled></el-rate>
  551. </div>
  552. </div>
  553. </div>
  554. <div class="nextStepBox" style="margin-top: 5%">
  555. <div class="nextStepOne" @click="isBlock = 11">返回</div>
  556. </div>
  557. </div>
  558. </div>
  559. <div class="answerBox tools_box" v-if="isBlock == 13">
  560. <div style="height: 100%; width: 100%">
  561. <div class="wheel" style="height: 80%; width: 100%">
  562. <div style="height: 100%; overflow: auto">
  563. <div style="margin-bottom: 20px">{{ Sname }}</div>
  564. <div
  565. v-if="
  566. tools[steps].tools && tools[steps].tools.indexOf(27) != -1
  567. "
  568. >
  569. <div v-for="(tk, tIndex) in 7" :key="tIndex" class="tkCss">
  570. <div style="margin-right: 10px; font-size: 18px">{{ tIndex + 1 }}、</div>
  571. <el-select v-model="tkAnswer[tIndex]" placeholder="请选择答案" disabled>
  572. <el-option
  573. v-for="(tkA, tkAIndex) in tkAnswerBox"
  574. :key="tkAIndex"
  575. :label="tkA"
  576. :value="tkA"
  577. ></el-option>
  578. </el-select>
  579. <span
  580. v-if="tiankongAnswer.length"
  581. class="tiankongAnswer"
  582. :class="{
  583. tfalse: tiankongAnswer[tIndex] != tkAnswer[tIndex],
  584. }"
  585. >正确答案:{{ tiankongAnswer[tIndex] }}</span>
  586. </div>
  587. </div>
  588. <div v-if="tools[steps].tools && tools[steps].tools.indexOf(9) != -1">
  589. <div class="choose_style">
  590. <span :class="tkAnswer.indexOf(1) != -1 ? 'isChoose' : ''">A</span>
  591. <span :class="tkAnswer.indexOf(2) != -1 ? 'isChoose' : ''">B</span>
  592. <span :class="tkAnswer.indexOf(3) != -1 ? 'isChoose' : ''">C</span>
  593. <span :class="tkAnswer.indexOf(4) != -1 ? 'isChoose' : ''">D</span>
  594. </div>
  595. </div>
  596. </div>
  597. </div>
  598. <div class="nextStepBox" style="margin-top: 5%">
  599. <div class="nextStepOne" @click="selectStudentByScoolPPt(1)">返回</div>
  600. </div>
  601. </div>
  602. </div>
  603. <div class="answerBox tools_box" v-if="isBlock == 14">
  604. <div style="height: 100%; width: 100%">
  605. <div class="wheel" style="height: 80%; width: 100%">
  606. <div style="height: 100%; overflow: auto">
  607. <div v-for="(item, index) in worksList" :key="index" class="fill_box">
  608. <span>{{ index + 1 }}、{{ item.sName }}</span>
  609. <span
  610. v-for="(item, index) in JSON.parse(item.upload)"
  611. :key="index"
  612. >{{ index + 1 }}、{{ item }}</span>
  613. </div>
  614. </div>
  615. </div>
  616. <div class="nextStepBox" style="margin-top: 5%">
  617. <div class="nextStepOne" @click="selectStudentByScoolPPt(1)">返回</div>
  618. </div>
  619. </div>
  620. </div>
  621. <div class="answerBox tools_box" v-if="isBlock == 15">
  622. <div style="height: 100%; width: 100%">
  623. <div class="wheel" style="height: 80%; width: 100%">
  624. <div style="height: 100%; overflow: auto">
  625. <audio
  626. style="margin: 0 auto; display: block"
  627. :src="audioUrl"
  628. controls="controls"
  629. ref="audio"
  630. >Your browser does not support the audio element.</audio>
  631. </div>
  632. </div>
  633. <div class="nextStepBox" style="margin-top: 5%">
  634. <div class="nextStepOne" @click="isBlock = 8">返回</div>
  635. </div>
  636. </div>
  637. </div>
  638. <div class="answerBox tools_box" :class="{ fullStyle: full }" v-if="isBlock == 16">
  639. <div style="height: 70%; width: 100%">
  640. <div class="wheel">
  641. <div style="height: 100%">
  642. <video-player
  643. class="video-player vjs-custom-skin"
  644. :playsinline="true"
  645. :options="playerO[0]"
  646. @play="onPlayerPlay($event)"
  647. style="width: 90%; height: 100%; margin: 0 0 0 30px"
  648. ></video-player>
  649. </div>
  650. </div>
  651. <div class="nextStepBox" style="margin-top: 5%">
  652. <div class="nextStepOne" @click="isBlock = 4">返回</div>
  653. </div>
  654. </div>
  655. </div>
  656. </div>
  657. <div class="blackBottomB">
  658. <div style="display: flex">
  659. <div
  660. class="blackButton"
  661. @click="selectStudentByScoolPPt(1)"
  662. v-if="
  663. (tools[steps].tools && tools[steps].tools.indexOf(9) != -1) ||
  664. (tools[steps].tools && tools[steps].tools.indexOf(27) != -1)
  665. "
  666. >查看学生答题情况</div>
  667. <div
  668. class="blackButton"
  669. @click="isBlock = 2"
  670. v-if="
  671. (tools[steps].tools && tools[steps].tools.indexOf(1) != -1) ||
  672. (tools[steps].tools && tools[steps].tools.indexOf(3) != -1) ||
  673. (tools[steps].tools && tools[steps].tools.indexOf(6) != -1) ||
  674. (tools[steps].tools && tools[steps].tools.indexOf(7) != -1) ||
  675. (tools[steps].tools && tools[steps].tools.indexOf(10) != -1) ||
  676. (tools[steps].tools && tools[steps].tools.indexOf(13) != -1)
  677. "
  678. >查看工具</div>
  679. <div
  680. class="blackButton"
  681. @click="selectStudentByScoolPPt(2)"
  682. v-if="tools[steps].tools && tools[steps].tools.indexOf(12) != -1"
  683. >选择学生回答</div>
  684. <div
  685. class="blackButton"
  686. @click="selectSWork2(4)"
  687. v-if="
  688. (tools[steps].tools && tools[steps].tools.indexOf(1) != -1) ||
  689. (tools[steps].tools && tools[steps].tools.indexOf(3) != -1) ||
  690. (tools[steps].tools && tools[steps].tools.indexOf(6) != -1) ||
  691. (tools[steps].tools && tools[steps].tools.indexOf(7) != -1) ||
  692. (tools[steps].tools && tools[steps].tools.indexOf(10) != -1) ||
  693. (tools[steps].tools && tools[steps].tools.indexOf(16) != -1) ||
  694. (tools[steps].tools && tools[steps].tools.indexOf(29) != -1) ||
  695. (tools[steps].tools && tools[steps].tools.indexOf(13) != -1)
  696. "
  697. >查看作业</div>
  698. <div
  699. class="blackButton"
  700. @click="selectSWork2(6)"
  701. v-if="tools[steps].tools && tools[steps].tools.indexOf(14) != -1"
  702. >查看评价</div>
  703. <!-- <div
  704. class="blackButton"
  705. @click="selectFile"
  706. v-if="tools[steps].file && tools[steps].file.length"
  707. >查看附件</div>-->
  708. </div>
  709. </div>
  710. <el-dialog
  711. title="选择答题"
  712. :visible.sync="dialogVisible"
  713. :append-to-body="true"
  714. width="500px"
  715. :before-close="handleClose"
  716. class="dialog_diy"
  717. >
  718. <div
  719. style="text-align: center; padding: 20px 0 50px 0; font-size: 18px"
  720. >是否让“{{ answerStudent.name }}”同学进行单独答题?</div>
  721. <div
  722. style="
  723. width: 200px;
  724. background: #4d8ae0;
  725. height: 35px;
  726. margin: 0 auto;
  727. text-align: center;
  728. line-height: 35px;
  729. color: #fff;
  730. border-radius: 5px;
  731. cursor: pointer;
  732. "
  733. @click="pick"
  734. >确定</div>
  735. </el-dialog>
  736. <el-dialog
  737. :visible.sync="dialogVisible1"
  738. :append-to-body="true"
  739. width="500px"
  740. :before-close="handleClose"
  741. class="dialog_diy"
  742. >
  743. <div style="text-align: center; padding: 20px 0 50px 0; font-size: 18px">正在开发中!</div>
  744. <div
  745. style="
  746. width: 200px;
  747. background: #4d8ae0;
  748. height: 35px;
  749. margin: 0 auto;
  750. text-align: center;
  751. line-height: 35px;
  752. color: #fff;
  753. border-radius: 5px;
  754. cursor: pointer;
  755. "
  756. @click="dialogVisible1 = false"
  757. >确定</div>
  758. </el-dialog>
  759. <el-dialog
  760. :visible.sync="dialogVisible2"
  761. :append-to-body="true"
  762. width="500px"
  763. :before-close="handleClose"
  764. class="dialog_diy"
  765. >
  766. <div style="text-align: center; padding: 20px 0 50px 0; font-size: 18px">课程结束后才有报告!</div>
  767. <div
  768. style="
  769. width: 200px;
  770. background: #4d8ae0;
  771. height: 35px;
  772. margin: 0 auto;
  773. text-align: center;
  774. line-height: 35px;
  775. color: #fff;
  776. border-radius: 5px;
  777. cursor: pointer;
  778. "
  779. @click="dialogVisible2 = false"
  780. >确定</div>
  781. </el-dialog>
  782. <el-dialog
  783. title="倒计时"
  784. :visible.sync="timeDialogVisible"
  785. :append-to-body="true"
  786. width="800px"
  787. :before-close="handleClose"
  788. class="dialog_diy"
  789. >
  790. <div>
  791. <Time v-if="timeDialogVisible"></Time>
  792. </div>
  793. <div slot="footer">
  794. <el-button @click="timeDialogVisible = false">关 闭</el-button>
  795. </div>
  796. </el-dialog>
  797. <ImgDraw :drawShow="drawShow" @closeDraw="closeDraw" :bg="bg"></ImgDraw>
  798. <img id="img1" ref="img1" hidden="hidden" />
  799. </div>
  800. </template>
  801. <script>
  802. import "../../common/aws-sdk-2.235.1.min";
  803. import EditorBar from "../../components/tools/wangEnduit";
  804. import AnswerData from "./components/answerData";
  805. import pdf from "./components/pdf";
  806. import ImgDraw from "./components/imgDraw/imgDraw";
  807. import Time from "../tools/time.vue";
  808. export default {
  809. components: { EditorBar, AnswerData, pdf, ImgDraw, Time },
  810. data() {
  811. return {
  812. pdfUrl:
  813. "https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E4%B8%8A%E8%AF%BE%E8%AF%BE%E4%BB%B6---%E4%BA%94%E4%B8%8Bintroduce%20a%20festival%20%28Final%20%29%281%291661829428281.pdf",
  814. pptImgUrl: "",
  815. isLoading: false,
  816. full: false,
  817. drawShow: false,
  818. bg: null,
  819. formLabelWidth: "100px",
  820. userid: this.$route.query.userid,
  821. cid: this.$route.query.cid,
  822. oid: this.$route.query.oid,
  823. mr: require("../../assets/icon/kc1.png"),
  824. timu: [],
  825. // a: false,
  826. // b: false,
  827. // c: false,
  828. steps: 0,
  829. isBlock: 0,
  830. timeDialogVisible: false,
  831. dialogVisible: false,
  832. dialogVisible1: false,
  833. dialogVisible2: false,
  834. toolCount: 0,
  835. answerBox: "",
  836. answer: [
  837. { name: "A.1568" },
  838. { name: "B.720" },
  839. { name: "C.1728" },
  840. { name: "D.480" },
  841. ],
  842. studentArray: [],
  843. studentArray2: [],
  844. askCount: 0,
  845. answerJson: {
  846. A: 0,
  847. B: 0,
  848. C: 0,
  849. D: 0,
  850. },
  851. answerStudent: "",
  852. // {
  853. // file: [
  854. // {
  855. // name: "音频1.MP3",
  856. // src: "https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E6%9F%B3%E8%BD%BB%E9%A2%82%20-%20%E6%BA%AF%EF%BC%88%E9%92%A2%E7%90%B4%E7%89%88%EF%BC%891661673251415.mp3",
  857. // },
  858. // ],
  859. // }
  860. tools: [
  861. "",
  862. "",
  863. {
  864. file: [
  865. {
  866. name: "视频1.mp4",
  867. src:
  868. "https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%AA%92%E4%BD%9311661413782505.mp4",
  869. },
  870. ],
  871. },
  872. "",
  873. { tools: [9] },
  874. { tools: [9] },
  875. { tools: [9] },
  876. { tools: [9] },
  877. { tools: [9] },
  878. { tools: [12] },
  879. {
  880. tools: [27],
  881. answer: [
  882. "Time",
  883. "Weather",
  884. "Activities before the festival",
  885. "Activities during the festival",
  886. "Food",
  887. "Reason",
  888. "Feelings",
  889. ],
  890. },
  891. {
  892. file: [
  893. {
  894. name: "视频2.mp4",
  895. src:
  896. "https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/%E5%AA%92%E4%BD%9321661413797366.mp4",
  897. },
  898. ],
  899. },
  900. { tools: [9] },
  901. { tools: [3, 28] },
  902. { tools: [16] },
  903. { tools: [14] },
  904. "",
  905. "",
  906. { tools: [29] },
  907. "",
  908. "",
  909. ],
  910. //1、电子白板 2、便签 3、思维导图 4、问卷调查 5、量规评分 6、协同文档 7、思维网格 8、素材库 9、选择题 10、倒计时 11、问答题 12、选人回答 13、分小组 14、老师对提交作业进行评价 15、问答 16、作业提交 17、学习资料 18、训练平台 19、目标管理 20、课程设计 21、编程平台 22、AI体验 23、python 24、AI平台
  911. howTools: 0,
  912. worksDetail: [],
  913. worksList: [],
  914. toolsList: [],
  915. isNext: false,
  916. rateList: {
  917. ca: 5,
  918. sia: 5,
  919. content: "老师讲得真好",
  920. },
  921. videoList: [],
  922. videoList2: [], //音频
  923. fileList: [],
  924. playerOptions: {
  925. playbackRates: [0.7, 1.0, 1.5, 2.0], //播放速度
  926. autoplay: false, //如果true,浏览器准备好时开始回放。
  927. muted: false, // 默认情况下将会消除任何音频。
  928. loop: false, // 导致视频一结束就重新开始。
  929. preload: "auto", // 建议浏览器在<video>加载元素后是否应该开始下载视频数据。auto浏览器选择最佳行为,立即开始加载视频(如果浏览器支持)
  930. language: "zh-CN",
  931. aspectRatio: "16:9", // 将播放器置于流畅模式,并在计算播放器的动态大小时使用该值。值应该代表一个比例 - 用冒号分隔的两个数字(例如"16:9"或"4:3")
  932. fluid: true, // 当true时,Video.js player将拥有流体大小。换句话说,它将按比例缩放以适应其容器。
  933. sources: [
  934. {
  935. type: "video/mp4", //这里的种类支持很多种:基本视频格式、直播、流媒体等,具体可以参看git网址项目 || "video/ogg"|| "video/webm"
  936. src: "", //url地址require("../../assets/media/aaa.mp4")
  937. },
  938. ],
  939. // poster: require("../../assets/tu31.png"), //你的封面地址
  940. // poster: dataRes.imgUrl, //你的封面地址
  941. notSupportedMessage: "此视频暂无法播放,请稍后再试", //允许覆盖Video.js无法播放媒体源时显示的默认信息。
  942. controlBar: {
  943. timeDivider: true, //当前时间和持续时间的分隔符
  944. durationDisplay: true, //显示持续时间
  945. remainingTimeDisplay: false, //是否显示剩余时间功能
  946. fullscreenToggle: true, //全屏按钮
  947. },
  948. },
  949. playerO: {},
  950. videoindex: 0,
  951. rate: {},
  952. tkAnswerBox: [
  953. "Feelings",
  954. "Weather",
  955. "Activities before the festival",
  956. "Origin",
  957. "Food",
  958. "Time",
  959. "Activities during the festival",
  960. "Reason",
  961. ],
  962. tkAnswer: [],
  963. Sname: "",
  964. audioUrl: "",
  965. timerAnswer: null,
  966. videoBlock: 0,
  967. Vwidth: 0,
  968. tiankongAnswer: [],
  969. };
  970. },
  971. methods: {
  972. change(val) {
  973. console.log(val);
  974. },
  975. goTo(path) {
  976. this.$router.push(path);
  977. },
  978. tableRowClassName({ row, rowIndex }) {
  979. if ((rowIndex + 1) % 2 === 0) {
  980. return "even_row";
  981. } else {
  982. return "";
  983. }
  984. },
  985. jump(cid) {
  986. window.parent.postMessage({ cid: cid, type: "1" }, "*");
  987. },
  988. handleCurrentChange(val) {
  989. // console.log(`当前页: ${val}`);
  990. this.page = val;
  991. },
  992. init() {},
  993. handleClose(done) {
  994. done();
  995. },
  996. //uuid生成
  997. guid() {
  998. return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function (
  999. c
  1000. ) {
  1001. var r = (Math.random() * 16) | 0,
  1002. v = c == "x" ? r : (r & 0x3) | 0x8;
  1003. return v.toString(16);
  1004. });
  1005. },
  1006. time() {
  1007. if (!this.now) {
  1008. this.now = new Date().getTime();
  1009. return true;
  1010. } else {
  1011. let time = new Date().getTime();
  1012. if (time - this.now > 3000) {
  1013. this.now = time;
  1014. return true;
  1015. } else {
  1016. return false;
  1017. }
  1018. }
  1019. },
  1020. randomNum(minNum, maxNum) {
  1021. switch (arguments.length) {
  1022. case 1:
  1023. return parseInt(Math.random() * minNum + 1, 10);
  1024. break;
  1025. case 2:
  1026. return parseInt(Math.random() * (maxNum - minNum + 1) + minNum, 10);
  1027. break;
  1028. default:
  1029. return 0;
  1030. break;
  1031. }
  1032. },
  1033. addTool(t) {
  1034. if (t == 1) {
  1035. window.parent.postMessage({ tools: "1" }, "*");
  1036. } else if (t == 3) {
  1037. window.parent.postMessage({ tools: "3" }, "*");
  1038. } else if (t == 7) {
  1039. window.parent.postMessage({ tools: "7" }, "*");
  1040. }
  1041. },
  1042. checkStudentAnswer() {
  1043. // this.isBlock = 6;
  1044. for (var i = 0; i < this.studentArray2.length; i++) {
  1045. this.studentArray2[i].is = 1;
  1046. }
  1047. },
  1048. showMember() {
  1049. let _type = 0;
  1050. if (this.tools[this.steps].tools) {
  1051. if (
  1052. this.tools[this.steps].tools.indexOf(1) != -1 ||
  1053. this.tools[this.steps].tools.indexOf(3) != -1 ||
  1054. this.tools[this.steps].tools.indexOf(6) != -1 ||
  1055. this.tools[this.steps].tools.indexOf(7) != -1 ||
  1056. this.tools[this.steps].tools.indexOf(10) != -1 ||
  1057. this.tools[this.steps].tools.indexOf(16) != -1 ||
  1058. this.tools[this.steps].tools.indexOf(13) != -1
  1059. ) {
  1060. _type = 4;
  1061. } else if (this.tools[this.steps].tools.indexOf(9) != -1) {
  1062. _type = 1;
  1063. } else if (this.tools[this.steps].tools.indexOf(27) != -1) {
  1064. _type = 5;
  1065. } else if (this.tools[this.steps].tools.indexOf(14) != -1) {
  1066. _type = 6;
  1067. } else if (this.tools[this.steps].tools.indexOf(29) != -1) {
  1068. _type = 7;
  1069. }
  1070. }
  1071. let params = {
  1072. uid: "",
  1073. cid: this.cid,
  1074. p: this.steps,
  1075. type: _type,
  1076. };
  1077. this.ajax
  1078. .get(this.$store.state.api + "selectSWork", params)
  1079. .then((res) => {
  1080. let _res = res.data[0];
  1081. let _this = this;
  1082. // this.isBlock = 1;
  1083. for (var i = 0; i < _this.studentArray.length; i++) {
  1084. for (var j = 0; j < _res.length; j++) {
  1085. if (_res[j].userid == _this.studentArray[i].id) {
  1086. _this.studentArray[i].is = 2;
  1087. _this.studentArray[i].answer = _res[j].upload;
  1088. }
  1089. }
  1090. }
  1091. if (
  1092. this.tools[this.steps].tools &&
  1093. this.tools[this.steps].tools.indexOf(9) != -1
  1094. ) {
  1095. this.answerJson = {
  1096. A: 0,
  1097. B: 0,
  1098. C: 0,
  1099. D: 0,
  1100. };
  1101. for (var i = 0; i < _res.length; i++) {
  1102. var a = JSON.parse(_res[i].upload);
  1103. if (a.indexOf(1) != -1) {
  1104. _this.answerJson.A++;
  1105. }
  1106. if (a.indexOf(2) != -1) {
  1107. _this.answerJson.B++;
  1108. }
  1109. if (a.indexOf(3) != -1) {
  1110. _this.answerJson.C++;
  1111. }
  1112. if (a.indexOf(4) != -1) {
  1113. _this.answerJson.D++;
  1114. }
  1115. }
  1116. }
  1117. if (
  1118. this.tools[this.steps].tools &&
  1119. this.tools[this.steps].tools.indexOf(27) != -1
  1120. ) {
  1121. this.worksList = [];
  1122. for (var i = 0; i < _res.length; i++) {
  1123. this.worksList.push({
  1124. upload: _res[i].upload,
  1125. sName: _res[i].username,
  1126. time: _res[i].time,
  1127. });
  1128. }
  1129. }
  1130. })
  1131. .catch((err) => {
  1132. // this.$message.error("查询失败");
  1133. console.error(err);
  1134. });
  1135. },
  1136. getOAnswer(answer, name) {
  1137. if (!answer) {
  1138. return;
  1139. }
  1140. this.tkAnswer = JSON.parse(answer);
  1141. this.Sname = name;
  1142. if (this.tools[this.steps].answer) {
  1143. this.tiankongAnswer = this.tools[this.steps].answer;
  1144. }
  1145. this.isBlock = 13;
  1146. },
  1147. whoAnswer(item, index) {
  1148. for (var i = 0; i < this.studentArray2.length; i++) {
  1149. this.studentArray2[i].is = 1;
  1150. }
  1151. this.studentArray2[index].is = 2;
  1152. this.answerStudent = item;
  1153. this.dialogVisible = true;
  1154. },
  1155. pick() {
  1156. let params = [
  1157. {
  1158. h: JSON.stringify({ type: 2, userid: this.answerStudent.id }),
  1159. cid: this.cid,
  1160. },
  1161. ];
  1162. this.ajax
  1163. .post(this.$store.state.api + "updatePPTHandle", params)
  1164. .then((res) => {
  1165. this.answerStudent = "";
  1166. this.dialogVisible = false;
  1167. })
  1168. .catch((err) => {
  1169. console.error(err);
  1170. });
  1171. },
  1172. getWidth(total) {
  1173. this.Vwidth = total;
  1174. },
  1175. getPage(page) {
  1176. console.log(page);
  1177. let params = [
  1178. {
  1179. page: page,
  1180. id: this.cid,
  1181. },
  1182. ];
  1183. this.ajax
  1184. .post(this.$store.state.api + "updatePptPage", params)
  1185. .then((res) => {
  1186. this.steps = page - 1;
  1187. this.isBlock = 0;
  1188. if (
  1189. this.tools[this.steps].file &&
  1190. this.tools[this.steps].file.length
  1191. ) {
  1192. this.selectFile();
  1193. } else {
  1194. this.videoBlock = 0;
  1195. }
  1196. })
  1197. .catch((err) => {
  1198. console.error(err);
  1199. });
  1200. },
  1201. selectStudentByScoolPPt(type) {
  1202. let params = {
  1203. oid: this.oid,
  1204. cid: this.cid,
  1205. };
  1206. this.ajax
  1207. .get(this.$store.state.api + "selectStudentByScoolPPt", params)
  1208. .then((res) => {
  1209. if (res.data[0].length > 0) {
  1210. this.studentArray = [];
  1211. this.studentArray2 = [];
  1212. for (var i = 0; i < res.data[0].length; i++) {
  1213. this.studentArray.push({
  1214. id: res.data[0][i].userid,
  1215. name: res.data[0][i].name,
  1216. is: 1,
  1217. });
  1218. this.studentArray2.push({
  1219. id: res.data[0][i].userid,
  1220. name: res.data[0][i].name,
  1221. is: 1,
  1222. });
  1223. }
  1224. }
  1225. if (this.timerAnswer) {
  1226. clearInterval(this.timerAnswer);
  1227. this.timerAnswer;
  1228. }
  1229. if (type == 1) {
  1230. this.showMember();
  1231. this.timerAnswer = setInterval(() => {
  1232. this.showMember();
  1233. }, 5000);
  1234. this.isBlock = 1;
  1235. } else if (type == 2) {
  1236. this.checkStudentAnswer();
  1237. this.timerAnswer = setInterval(() => {
  1238. this.checkStudentAnswer();
  1239. }, 5000);
  1240. this.isBlock = 6;
  1241. }
  1242. })
  1243. .catch((err) => {
  1244. // this.$message.error("查询失败");
  1245. console.error(err);
  1246. });
  1247. },
  1248. selectSWork2(type) {
  1249. let _type = type;
  1250. if (this.timerAnswer) {
  1251. clearInterval(this.timerAnswer);
  1252. this.timerAnswer = null;
  1253. }
  1254. this.selectSWork(_type);
  1255. this.timerAnswer = setInterval(() => {
  1256. this.selectSWork(_type);
  1257. }, 5000);
  1258. if (_type == 4) {
  1259. this.isBlock = 4;
  1260. } else {
  1261. this.isBlock = 11;
  1262. }
  1263. },
  1264. selectSWork(type) {
  1265. let _type = 0;
  1266. if (this.tools[this.steps].tools) {
  1267. if (
  1268. this.tools[this.steps].tools.indexOf(1) != -1 ||
  1269. this.tools[this.steps].tools.indexOf(3) != -1 ||
  1270. this.tools[this.steps].tools.indexOf(6) != -1 ||
  1271. this.tools[this.steps].tools.indexOf(7) != -1 ||
  1272. this.tools[this.steps].tools.indexOf(10) != -1 ||
  1273. this.tools[this.steps].tools.indexOf(16) != -1 ||
  1274. this.tools[this.steps].tools.indexOf(13) != -1
  1275. ) {
  1276. _type = 4;
  1277. } else if (this.tools[this.steps].tools.indexOf(9) != -1) {
  1278. _type = 1;
  1279. } else if (this.tools[this.steps].tools.indexOf(27) != -1) {
  1280. _type = 5;
  1281. } else if (this.tools[this.steps].tools.indexOf(14) != -1) {
  1282. _type = 6;
  1283. } else if (this.tools[this.steps].tools.indexOf(29) != -1) {
  1284. _type = 7;
  1285. }
  1286. }
  1287. this.worksList = [];
  1288. let params = {
  1289. uid: "",
  1290. cid: this.cid,
  1291. p: this.steps,
  1292. type: _type,
  1293. };
  1294. this.ajax
  1295. .get(this.$store.state.api + "selectSWork", params)
  1296. .then((res) => {
  1297. this.worksDetail = res.data[0];
  1298. for (var i = 0; i < this.worksDetail.length; i++) {
  1299. this.worksList.push({
  1300. upload: this.worksDetail[i].upload,
  1301. sName: this.worksDetail[i].username,
  1302. time: this.worksDetail[i].time,
  1303. });
  1304. }
  1305. })
  1306. .catch((err) => {
  1307. // this.$message.error("查询失败");
  1308. console.error(err);
  1309. });
  1310. },
  1311. getEv(rate, name) {
  1312. this.rate = JSON.parse(rate);
  1313. this.Sname = name;
  1314. this.isBlock = 12;
  1315. },
  1316. selectFile() {
  1317. this.fileList = [];
  1318. this.videoList = [];
  1319. this.videoList2 = [];
  1320. var a = ["PDF", "DOC", "DOCX", "PPT", "PPTX", "XLSX", "XLS"];
  1321. var b = this.tools[this.steps].file;
  1322. for (var i = 0; i < b.length; i++) {
  1323. if (
  1324. a.indexOf(
  1325. b[i].src
  1326. .split(".")
  1327. [b[i].src.split(".").length - 1].toLocaleUpperCase()
  1328. ) != -1
  1329. ) {
  1330. this.fileList.push(b[i]);
  1331. } else if (
  1332. b[i].src
  1333. .split(".")
  1334. [b[i].src.split(".").length - 1].toLocaleUpperCase() == "MP3"
  1335. ) {
  1336. this.videoList2.push(b[i]);
  1337. } else {
  1338. this.videoList.push(b[i]);
  1339. }
  1340. }
  1341. if (this.videoList.length) {
  1342. this.playVideo();
  1343. } else {
  1344. this.isBlock = 8;
  1345. }
  1346. },
  1347. openFile(u) {
  1348. this.pptImgUrl = "https://view.officeapps.live.com/op/view.aspx?src=" + u;
  1349. this.isBlock = 10;
  1350. },
  1351. playVideo() {
  1352. // u, i
  1353. var d = JSON.parse(JSON.stringify(this.playerOptions));
  1354. // d.sources[0].src = u;
  1355. d.sources[0].src = this.videoList[0].src;
  1356. this.playerO[0] = d;
  1357. // this.isBlock = 9;
  1358. this.videoBlock = 9;
  1359. },
  1360. playVideo2(u, i) {
  1361. this.audioUrl = u;
  1362. this.isBlock = 15;
  1363. },
  1364. switchVideo(media) {
  1365. this.playerO = {};
  1366. this.playerOptions.poster = "";
  1367. this.playerOptions.sources[0].src = media;
  1368. this.playerO = this.playerOptions;
  1369. },
  1370. onPlayerPlay() {},
  1371. previewImg(url) {
  1372. // this.$hevueImgPreview(url);
  1373. // this.$hevueImgPreview(url);
  1374. this.drawShow = true;
  1375. this.bg = url;
  1376. // this.setAvatarBase64(url, (base64) => {
  1377. // this.$nextTick(() => {
  1378. // this.drawShow = true;
  1379. // this.bg = base64;
  1380. // });
  1381. // });
  1382. },
  1383. lookvideo(u) {
  1384. var d = JSON.parse(JSON.stringify(this.playerOptions));
  1385. d.sources[0].src = u;
  1386. this.playerO[0] = d;
  1387. this.isBlock = 16;
  1388. },
  1389. closeDraw() {
  1390. this.bg = null;
  1391. this.drawShow = false;
  1392. },
  1393. fullTools() {
  1394. this.full = !this.full;
  1395. },
  1396. closeTools() {
  1397. this.full = false;
  1398. this.isBlock = 2;
  1399. },
  1400. // 将网络图片转换成base64格式
  1401. transBase64FromImage(image) {
  1402. let canvas = document.createElement("canvas");
  1403. canvas.width = image.width;
  1404. canvas.height = image.height;
  1405. let ctx = canvas.getContext("2d");
  1406. ctx.drawImage(image, 0, 0, image.width, image.height);
  1407. // 可选其他值 image/jpeg
  1408. return canvas.toDataURL("image/jpeg");
  1409. },
  1410. // 设置需要展示的图片 base64
  1411. setAvatarBase64(src, callback) {
  1412. let _this = this;
  1413. let image = new Image();
  1414. // let image = this.$refs.img1;
  1415. // 处理缓存
  1416. // image.src = src + "?v=" + Math.random();
  1417. image.src = src;
  1418. // 支持跨域图片
  1419. // image.crossOrigin = "anonymous";
  1420. // crossorigin="anonymous"
  1421. image.onload = function () {
  1422. let base64 = _this.transBase64FromImage(image);
  1423. callback && callback(base64);
  1424. // console.log(base64);
  1425. // return base64
  1426. };
  1427. },
  1428. },
  1429. created() {},
  1430. };
  1431. </script>
  1432. <style scoped>
  1433. .dialog_diy >>> .el-dialog__header {
  1434. background: #3d67bc !important;
  1435. padding: 15px 20px;
  1436. }
  1437. .dialog_diy >>> .el-dialog__title {
  1438. color: #fff;
  1439. }
  1440. .dialog_diy >>> .el-dialog__headerbtn {
  1441. top: 9px;
  1442. }
  1443. .dialog_diy >>> .el-dialog__headerbtn .el-dialog__close {
  1444. color: #fff;
  1445. }
  1446. .dialog_diy >>> .el-dialog__headerbtn .el-dialog__close:hover {
  1447. color: #fff;
  1448. }
  1449. .blackBottom {
  1450. background: rgb(0, 0, 0);
  1451. height: 45px;
  1452. width: 100%;
  1453. }
  1454. .imgMiddle {
  1455. width: 100%;
  1456. height: calc(100% - 45px);
  1457. position: relative;
  1458. /* max-height: 920px; */
  1459. }
  1460. .imgMiddle > img,
  1461. .imghalf > img,
  1462. .szt > img,
  1463. .logoLive > img,
  1464. .close > img {
  1465. width: 100%;
  1466. height: 100%;
  1467. /* max-height: 920px; */
  1468. }
  1469. .blackBottomB {
  1470. position: sticky;
  1471. bottom: 0px;
  1472. left: 0px;
  1473. display: flex;
  1474. flex-direction: row;
  1475. flex-wrap: wrap;
  1476. align-content: center;
  1477. justify-content: space-between;
  1478. align-items: center;
  1479. background: rgb(0, 0, 0);
  1480. height: 45px;
  1481. width: 100%;
  1482. }
  1483. .blackBottomB > div:nth-child(1) {
  1484. margin-left: 10px !important;
  1485. }
  1486. .blackButton {
  1487. color: #fff;
  1488. background: #066ebe;
  1489. /* width: 100px; */
  1490. height: 30px;
  1491. line-height: 30px;
  1492. text-align: center;
  1493. margin: 0 5px;
  1494. border-radius: 5px;
  1495. font-size: 15px;
  1496. cursor: pointer;
  1497. padding: 0 10px;
  1498. }
  1499. .isNoOther {
  1500. width: 100%;
  1501. /* height: 100%; */
  1502. height: calc(100% - 45px);
  1503. display: flex;
  1504. }
  1505. .imghalf {
  1506. width: 60% !important;
  1507. height: calc(100% - 45px);
  1508. /* max-height: 920px; */
  1509. }
  1510. .answerBox {
  1511. padding-left: 25px;
  1512. padding: 25px;
  1513. box-sizing: border-box;
  1514. height: calc(100% - 60px);
  1515. /* max-height: 800px;
  1516. overflow: auto; */
  1517. }
  1518. .answerTimuBox {
  1519. display: flex;
  1520. flex-direction: column;
  1521. flex-wrap: nowrap;
  1522. align-items: flex-start;
  1523. justify-content: flex-start;
  1524. padding-bottom: 15px;
  1525. }
  1526. .memberBox {
  1527. display: flex;
  1528. flex-direction: row;
  1529. flex-wrap: wrap;
  1530. align-items: center;
  1531. max-height: 80%;
  1532. overflow: auto;
  1533. }
  1534. .memberBox > div {
  1535. background: rgb(79 213 163);
  1536. width: 120px;
  1537. color: #fff;
  1538. height: 40px;
  1539. text-align: center;
  1540. line-height: 40px;
  1541. border-radius: 5px;
  1542. margin: 0 15px 15px 0;
  1543. cursor: pointer;
  1544. white-space: nowrap;
  1545. overflow: hidden;
  1546. text-overflow: ellipsis;
  1547. padding: 0 10px;
  1548. box-sizing: border-box;
  1549. }
  1550. .memberBox .pAnswer {
  1551. background: rgb(0 115 72);
  1552. }
  1553. .viewSta {
  1554. background: rgb(97, 97, 97);
  1555. color: #bebebe;
  1556. margin: 20px auto 20px;
  1557. width: 300px;
  1558. height: 40px;
  1559. text-align: center;
  1560. line-height: 40px;
  1561. border-radius: 5px;
  1562. cursor: pointer;
  1563. }
  1564. .szt {
  1565. width: 100%;
  1566. margin: 20px auto;
  1567. }
  1568. .sztFooter {
  1569. padding: 20px 10px 50px 0;
  1570. display: flex;
  1571. flex-direction: row;
  1572. flex-wrap: nowrap;
  1573. justify-content: flex-end;
  1574. align-items: center;
  1575. }
  1576. .toolList {
  1577. display: flex;
  1578. flex-direction: row;
  1579. flex-wrap: wrap;
  1580. justify-content: flex-start;
  1581. align-items: center;
  1582. }
  1583. .tools {
  1584. display: flex;
  1585. flex-direction: column;
  1586. align-items: center;
  1587. margin-right: 20px;
  1588. }
  1589. .tools > div:nth-child(1) {
  1590. width: 60px;
  1591. }
  1592. .tools > div:nth-child(1) > img,
  1593. .workImg > img,
  1594. .workTx > img {
  1595. width: 100%;
  1596. height: 100%;
  1597. /* object-fit: cover; */
  1598. object-fit: contain;
  1599. cursor: pointer;
  1600. margin: 0;
  1601. }
  1602. .nextStepBox {
  1603. display: flex;
  1604. justify-content: center;
  1605. margin-top: 10px;
  1606. }
  1607. .nextStepOne {
  1608. background: #6b92c9;
  1609. color: #fff;
  1610. width: 110px;
  1611. text-align: center;
  1612. height: 35px;
  1613. line-height: 35px;
  1614. font-size: 14px;
  1615. border-radius: 5px;
  1616. cursor: pointer;
  1617. }
  1618. .nextStepOne,
  1619. .nextStepOne {
  1620. margin-left: 10px;
  1621. }
  1622. .logoLive {
  1623. width: 35px;
  1624. }
  1625. .anserBoxCss {
  1626. box-sizing: border-box;
  1627. padding: 20px 0;
  1628. }
  1629. .anserBoxCss >>> .el-radio__label {
  1630. font-size: 18px;
  1631. }
  1632. .anserBoxCss >>> .el-radio__inner {
  1633. border-radius: 0px !important;
  1634. }
  1635. .choose_style {
  1636. display: flex;
  1637. justify-content: center;
  1638. align-items: center;
  1639. width: 100%;
  1640. margin: 10px 0 30px;
  1641. }
  1642. .choose_style span {
  1643. background: #f8f9ff;
  1644. color: #677fff;
  1645. border: 1px solid #95b5ff;
  1646. padding: 15px 20px;
  1647. font-size: 25px;
  1648. border-radius: 18px;
  1649. cursor: pointer;
  1650. }
  1651. .choose_style span + span {
  1652. margin-left: 25px;
  1653. }
  1654. .choose_style .active {
  1655. color: #fff;
  1656. background: #5e78fa;
  1657. }
  1658. .close {
  1659. position: absolute;
  1660. right: 10px;
  1661. top: 10px;
  1662. width: 20px;
  1663. cursor: pointer;
  1664. }
  1665. .workBox {
  1666. margin-top: 20px;
  1667. display: flex;
  1668. flex-direction: row;
  1669. flex-wrap: wrap;
  1670. width: 100%;
  1671. height: 700px;
  1672. overflow: auto;
  1673. }
  1674. .works {
  1675. width: 31%;
  1676. border: 1px solid #ececec;
  1677. /* height: 160px; */
  1678. margin: 0 10px 10px 0;
  1679. /* cursor: pointer; */
  1680. min-width: 180px;
  1681. border-radius: 3px;
  1682. overflow: hidden;
  1683. height: 183px;
  1684. }
  1685. .workImg {
  1686. width: 100%;
  1687. height: 117px;
  1688. }
  1689. .workDetail {
  1690. display: flex;
  1691. flex-direction: row;
  1692. flex-wrap: nowrap;
  1693. align-items: flex-start;
  1694. justify-content: space-between;
  1695. padding: 8px 0 0;
  1696. flex-direction: column;
  1697. }
  1698. .workLeft {
  1699. display: flex;
  1700. flex-direction: row;
  1701. flex-wrap: nowrap;
  1702. align-items: center;
  1703. width: 100%;
  1704. padding: 0px 5px;
  1705. box-sizing: border-box;
  1706. }
  1707. .workTx {
  1708. width: 25px;
  1709. }
  1710. .workName {
  1711. font-size: 14px;
  1712. padding-left: 13px;
  1713. }
  1714. .workRight {
  1715. font-size: 14px;
  1716. color: #ccc;
  1717. margin: 0 0 3px;
  1718. padding: 0 5px;
  1719. width: 100%;
  1720. box-sizing: border-box;
  1721. }
  1722. .workBtn {
  1723. width: 100%;
  1724. background: rgb(110 145 203);
  1725. color: #fff;
  1726. cursor: pointer;
  1727. text-align: center;
  1728. padding: 5px 0;
  1729. }
  1730. .returnButton {
  1731. position: absolute;
  1732. bottom: 20px;
  1733. width: 230px;
  1734. background: #616161;
  1735. left: 35%;
  1736. color: #ababab;
  1737. text-align: center;
  1738. border-radius: 5px;
  1739. height: 30px;
  1740. font-size: 14px;
  1741. line-height: 30px;
  1742. cursor: pointer;
  1743. }
  1744. .tools_title {
  1745. background: #000;
  1746. position: absolute;
  1747. width: 100%;
  1748. top: 0;
  1749. left: 0;
  1750. display: flex;
  1751. align-items: center;
  1752. height: 40px;
  1753. justify-content: space-between;
  1754. padding: 0 15px;
  1755. box-sizing: border-box;
  1756. }
  1757. .tools_title span {
  1758. color: #fff;
  1759. }
  1760. .tools_title div {
  1761. display: flex;
  1762. align-items: center;
  1763. }
  1764. .full,
  1765. .closeImg {
  1766. height: 22px;
  1767. cursor: pointer;
  1768. }
  1769. .tools_title img,
  1770. img {
  1771. margin-left: 10px;
  1772. }
  1773. .tools_box {
  1774. width: 38.5%;
  1775. max-width: 38.5%;
  1776. overflow: auto;
  1777. background: rgb(255, 255, 255);
  1778. height: 91.5%;
  1779. position: relative;
  1780. margin: 10px 15px;
  1781. }
  1782. .tools_child_box {
  1783. width: 100%;
  1784. height: calc(90% - 40px);
  1785. padding-top: 40px;
  1786. }
  1787. .fullStyle {
  1788. width: 100% !important;
  1789. max-width: 100% !important;
  1790. }
  1791. .toolCss {
  1792. display: flex;
  1793. flex-direction: column;
  1794. flex-wrap: wrap;
  1795. width: 150px;
  1796. align-items: center;
  1797. text-align: center;
  1798. }
  1799. .toolImg {
  1800. width: 70px;
  1801. /* height: 70px; */
  1802. cursor: pointer;
  1803. }
  1804. .toolImg > img {
  1805. width: 100%;
  1806. height: 100%;
  1807. margin: 0 !important;
  1808. }
  1809. .toolImg > div {
  1810. font-size: 14px;
  1811. }
  1812. .score_box {
  1813. font-size: 14px;
  1814. }
  1815. .score_box >>> .el-rate {
  1816. margin: 10px 0 20px 0;
  1817. }
  1818. .score_box >>> .el-rate__icon {
  1819. font-size: 23px;
  1820. }
  1821. .bz >>> .el-textarea__inner {
  1822. width: 40%;
  1823. background: #f9f9f9;
  1824. border: 1px solid #afafaf;
  1825. border-radius: 0px;
  1826. }
  1827. .fileBox {
  1828. display: flex;
  1829. flex-direction: row;
  1830. flex-wrap: wrap;
  1831. align-items: center;
  1832. justify-content: flex-start;
  1833. align-content: center;
  1834. width: 100%;
  1835. }
  1836. .fileListCss {
  1837. display: flex;
  1838. flex-direction: column;
  1839. flex-wrap: nowrap;
  1840. align-items: center;
  1841. margin: 0 15px 15px 0;
  1842. }
  1843. .fileCss {
  1844. width: 70px;
  1845. height: 70px;
  1846. cursor: pointer;
  1847. margin: 0 0 10px 0;
  1848. }
  1849. .fileCss > img {
  1850. width: 100%;
  1851. height: 100%;
  1852. margin: 0;
  1853. }
  1854. .wheel {
  1855. width: 100%;
  1856. height: 100%;
  1857. }
  1858. .video-player >>> .video-js {
  1859. height: 100%;
  1860. }
  1861. .tkCss {
  1862. display: flex;
  1863. flex-direction: row;
  1864. align-items: center;
  1865. flex-wrap: nowrap;
  1866. margin-bottom: 15px;
  1867. }
  1868. .fill_box + .fill_box {
  1869. margin-top: 10px;
  1870. }
  1871. .fill_box span + span {
  1872. margin-left: 10px;
  1873. }
  1874. .choose_style {
  1875. display: flex;
  1876. justify-content: center;
  1877. align-items: center;
  1878. width: 100%;
  1879. margin: 10px 0 30px;
  1880. }
  1881. .choose_style span {
  1882. background: #f8f9ff;
  1883. color: #677fff;
  1884. border: 1px solid #95b5ff;
  1885. padding: 15px 20px;
  1886. font-size: 25px;
  1887. border-radius: 18px;
  1888. cursor: pointer;
  1889. }
  1890. .choose_style span + span {
  1891. margin-left: 25px;
  1892. }
  1893. .isChoose {
  1894. color: #fff !important;
  1895. background: #5e78fa !important;
  1896. }
  1897. .workd_media {
  1898. /* width: 1497.42px; */
  1899. /* width: auto; */
  1900. height: calc(100% - 100px);
  1901. position: absolute;
  1902. top: 0;
  1903. left: 50%;
  1904. transform: translateX(-50%);
  1905. }
  1906. .tiankongAnswer {
  1907. margin-left: 10px;
  1908. color: #1834c0;
  1909. }
  1910. .tfalse {
  1911. color: rgb(189, 30, 30) !important;
  1912. }
  1913. </style>