liveRoom.vue 28 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066
  1. <template>
  2. <div style="background: #d0d6e4; width: 100%; margin: 0; position: relate">
  3. <!-- <div class="pb_content_body" style="height: 100%">
  4. </div>-->
  5. <div class="blackBottom">
  6. <div
  7. style="
  8. display: flex;
  9. flex-direction: row;
  10. flex-wrap: nowrap;
  11. align-items: stretch;
  12. padding-left: 10px;
  13. "
  14. >
  15. <div class="logoLive">
  16. <img src="../../assets/icon/logo.png" alt />
  17. </div>
  18. <div style="color: #fff; line-height: 45px; padding-left: 15px">
  19. 湖心亭看雪可可乐博模拟展示课件
  20. </div>
  21. </div>
  22. </div>
  23. <div class="isNoOther">
  24. <div class="imgMiddle" :class="isBlock > 0 ? 'imghalf' : 'imgMiddle'">
  25. <!-- <img src="../../assets/icon/kc1.png" alt /> -->
  26. <!-- <iframe
  27. style="width: 100%; height: 100%; border: none"
  28. 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"
  29. ></iframe>-->
  30. <pdf
  31. :pdfUrl="pdfUrl"
  32. style="width: 100%; height: 100%"
  33. :getPage="getPage"
  34. ></pdf>
  35. </div>
  36. <div
  37. style="
  38. background: #d0d6e4;
  39. height: 100%;
  40. min-width: 40%;
  41. max-width: 40%;
  42. overflow: auto;
  43. padding: 0px 0 50px;
  44. "
  45. v-if="isBlock == 1 || isBlock == 2 || isBlock == 6"
  46. >
  47. <div
  48. style="background: #fff; height: 92%; width: 96%; margin: 10px auto"
  49. >
  50. <div
  51. style="color: #bfbfbf; padding: 15px 0 20px 25px; font-size: 20px"
  52. >
  53. 答题查看
  54. </div>
  55. <div class="answerBox" v-if="isBlock == 1">
  56. <div class="answerTimuBox" v-for="item in 1" :key="item">
  57. <div class="choose_style">
  58. <!-- {{
  59. item
  60. }}、小明有3本不同的语文书,2本不同的数学书,4本不同的英语书,小明整理书架时,要把这些书放在同一层,且相同科目的书要相邻摆放,问共有多少种摆放方式?-->
  61. <span>A</span>
  62. <span>B</span>
  63. <span>C</span>
  64. <span>D</span>
  65. </div>
  66. <el-button style="margin: 0 auto" @click="showMember(item)"
  67. >开始答题</el-button
  68. >
  69. </div>
  70. </div>
  71. <div class="answerBox" v-if="isBlock == 2 || isBlock == 6">
  72. <div class="memberBox" v-if="isBlock == 2">
  73. <div
  74. :class="{ pAnswer: item.is == 2 }"
  75. v-for="(item, index) in studentArray"
  76. :key="index"
  77. >
  78. {{ item.name }}
  79. </div>
  80. </div>
  81. <div class="memberBox" v-if="isBlock == 6">
  82. <div
  83. :class="{ pAnswer: item.is == 2 }"
  84. v-for="(item, index) in studentArray2"
  85. :key="index"
  86. @click="whoAnswer(item, index)"
  87. >
  88. {{ item.name }}
  89. </div>
  90. </div>
  91. <div style="color: #948bdc; padding-top: 15px" v-if="isBlock == 2">正在答题......</div>
  92. <div class="viewSta" @click="isBlock = 3" v-if="isBlock == 2">查看数据统计</div>
  93. <span slot="footer" class="dialog-footer sztFooter" v-if="isBlock == 6">
  94. <el-button type="primary" @click="isBlock = 0">关闭</el-button>
  95. <!-- <el-button type="primary" @click="isBlock = 2">返回</el-button> -->
  96. </span>
  97. </div>
  98. </div>
  99. </div>
  100. <div
  101. style="
  102. background: #d0d6e4;
  103. height: 92%;
  104. min-width: 40%;
  105. max-width: 40%;
  106. overflow: auto;
  107. padding: 0px 0 50px;
  108. "
  109. v-if="isBlock == 3"
  110. >
  111. <div
  112. style="
  113. background: #fff;
  114. width: 96%;
  115. margin: 10px auto;
  116. position: relative;
  117. "
  118. >
  119. <div class="close" @click="isBlock = 0">
  120. <img src="../../assets/icon/close.png" alt />
  121. </div>
  122. <div style="color: #bfbfbf; padding: 15px 0 20px 25px">数据统计</div>
  123. <div style="padding-left: 25px">
  124. 目前A选项
  125. <span class>{{ answerJson.A }}票</span>、B选项
  126. <span>{{ answerJson.B }}票</span>、C选项
  127. <span>{{ answerJson.C }}票</span>、D选项
  128. <span>{{ answerJson.D }}票</span>
  129. </div>
  130. <div class="szt">
  131. <!-- <img src="../../assets/szt.png" alt /> -->
  132. <AnswerData :problemJson="answerJson"></AnswerData>
  133. </div>
  134. <span slot="footer" class="dialog-footer sztFooter">
  135. <el-button type="primary" @click="isBlock = 0">关闭</el-button>
  136. <el-button type="primary" @click="isBlock = 2">返回</el-button>
  137. </span>
  138. </div>
  139. </div>
  140. <div
  141. class="answerBox"
  142. style="
  143. width: 38.5%;
  144. max-width: 38.5%;
  145. overflow: auto;
  146. background: rgb(255, 255, 255);
  147. height: 91.5%;
  148. position: relative;
  149. margin: 10px 15px;
  150. "
  151. v-if="isBlock == 5"
  152. >
  153. <!-- <div
  154. style="
  155. border-bottom: 3px solid rgb(44, 131, 238);
  156. width: 70px;
  157. padding-bottom: 3px;
  158. text-align: center;
  159. margin-bottom: 20px;
  160. "
  161. >
  162. 选择工具
  163. </div>-->
  164. <div
  165. v-if="toolsList[0].tools.length == 1"
  166. style="height: 100%; width: 100%"
  167. >
  168. <div
  169. v-if="toolsList[0].tools[0] == 9"
  170. style="height: 90%; width: 100%"
  171. >
  172. 选择题
  173. </div>
  174. <div
  175. v-if="toolsList[0].tools[0] == 10"
  176. style="height: 90%; width: 100%"
  177. >
  178. 倒计时
  179. </div>
  180. <div
  181. v-if="toolsList[0].tools[0] == 11"
  182. style="height: 90%; width: 100%"
  183. >
  184. 问答题
  185. </div>
  186. <div
  187. v-if="toolsList[0].tools[0] == 12"
  188. style="height: 90%; width: 100%"
  189. >
  190. 选人回答
  191. </div>
  192. <div
  193. v-if="toolsList[0].tools[0] == 13"
  194. style="height: 90%; width: 100%"
  195. >
  196. 分小组
  197. </div>
  198. <div
  199. v-if="toolsList[0].tools[0] == 14"
  200. style="height: 90%; width: 100%"
  201. >
  202. 作业评价
  203. </div>
  204. <div class="nextStepOne" @click="isBlock = 0">关闭</div>
  205. </div>
  206. <div v-else style="height: 100%; width: 100%">
  207. <div
  208. v-if="toolsList[0].tools[howTools] == 1"
  209. style="height: 90%; width: 100%"
  210. >
  211. <iframe
  212. style="width: 100%; height: 100%; border: none"
  213. src="https://iwb.cocorobo.cn/"
  214. ></iframe>
  215. </div>
  216. <div
  217. v-if="toolsList[0].tools[howTools] == 2"
  218. style="height: 90%; width: 100%"
  219. >
  220. <iframe
  221. style="width: 100%; height: 100%; border: none"
  222. src="https://pbl.cocorobo.cn/pbl-teacher-table/dist/#/note"
  223. ></iframe>
  224. </div>
  225. <div
  226. v-if="toolsList[0].tools[howTools] == 3"
  227. style="height: 90%; width: 100%"
  228. >
  229. <iframe
  230. style="width: 100%; height: 100%; border: none"
  231. src="https://cloud.cocorobo.cn/kityminder-editor/dist/index.html"
  232. ></iframe>
  233. </div>
  234. <div
  235. v-if="toolsList[0].tools[howTools] == 4"
  236. style="height: 90%; width: 100%"
  237. >
  238. <iframe
  239. style="width: 100%; height: 100%; border: none"
  240. src="https://pbl.cocorobo.cn/pbl-teacher-table/dist/#/ask"
  241. ></iframe>
  242. </div>
  243. <div
  244. v-if="toolsList[0].tools[howTools] == 6"
  245. style="height: 90%; width: 100%"
  246. >
  247. <iframe
  248. style="width: 100%; height: 100%; border: none"
  249. src="https://cloud.cocorobo.cn/Office/Word/WordEditArea.htm"
  250. ></iframe>
  251. </div>
  252. <div
  253. v-if="toolsList[0].tools[howTools] == 7"
  254. style="height: 90%; width: 100%"
  255. >
  256. <iframe
  257. style="width: 100%; height: 100%; border: none"
  258. src="https://pbl.cocorobo.cn/pbl-teacher-table/dist/#/Grid"
  259. ></iframe>
  260. </div>
  261. <div
  262. v-if="toolsList[0].tools[howTools] == 8"
  263. style="height: 90%; width: 100%"
  264. >
  265. <iframe
  266. style="width: 100%; height: 100%; border: none"
  267. src="https://pbl.cocorobo.cn/pbl-teacher-table/dist/#/library"
  268. ></iframe>
  269. </div>
  270. <div
  271. v-if="toolsList[0].tools[howTools] == 10"
  272. style="height: 90%; width: 100%"
  273. >
  274. <div>倒计时</div>
  275. </div>
  276. <div
  277. v-if="toolsList[0].tools[howTools] == 13"
  278. style="height: 90%; width: 100%"
  279. >
  280. <div>分小组</div>
  281. </div>
  282. <div class="nextStepOne" @click="nextTool">下一步</div>
  283. </div>
  284. <!-- <div v-if="toolCount == 0" style="height: 90%">
  285. <iframe
  286. style="width: 100%; height: 100%; border: none"
  287. src="https://pbl.cocorobo.cn/pbl-teacher-table/dist/#/Grid"
  288. ></iframe>
  289. </div>
  290. <div v-if="toolCount == 1" style="height: 90%">
  291. <iframe
  292. style="width: 100%; height: 100%; border: none"
  293. src="https://iwb.cocorobo.cn/"
  294. ></iframe>
  295. </div>
  296. <div v-if="toolCount == 2" style="height: 90%">
  297. <iframe
  298. style="width: 100%; height: 100%; border: none"
  299. src="https://cloud.cocorobo.cn/kityminder-editor/dist/index.html"
  300. ></iframe>
  301. </div> -->
  302. <!-- <div class="nextStepOne" @click="nextTool">下一步</div> -->
  303. </div>
  304. <div
  305. class="answerBox"
  306. style="
  307. width: 38.5%;
  308. max-width: 38.5%;
  309. overflow: auto;
  310. background: rgb(255, 255, 255);
  311. height: 91.5%;
  312. position: relative;
  313. margin: 10px 15px;
  314. "
  315. v-if="isBlock == 4"
  316. >
  317. <div
  318. style="
  319. color: #b7b7b7;
  320. border-left: 5px solid #a5b6e2;
  321. padding-left: 7px;
  322. height: 25px;
  323. line-height: 25px;
  324. "
  325. >
  326. 查看作业
  327. </div>
  328. <div class="workBox">
  329. <div class="works" v-for="(w, wIndex) in worksList" :key="wIndex">
  330. <div class="workImg">
  331. <img :src="w.upload.upImg ? w.upload.upImg[0].url : mr" alt />
  332. </div>
  333. <div class="workDetail">
  334. <div class="workLeft">
  335. <div class="workTx">
  336. <img src="../../assets/avatar.png" alt />
  337. </div>
  338. <div class="workName">{{ w.sName }}</div>
  339. </div>
  340. <div class="workRight">{{ w.time }}</div>
  341. </div>
  342. </div>
  343. </div>
  344. <div class="returnButton" @click="isBlock = 0">关闭</div>
  345. </div>
  346. </div>
  347. <div class="blackBottomB">
  348. <div style="display: flex">
  349. <div class="blackButton" @click="answerWork" v-if="steps == 3">
  350. 开始答题
  351. </div>
  352. <div
  353. class="blackButton"
  354. @click="isBlock = 5"
  355. v-if="4 <= steps && steps <= 12 && steps != 8 && steps != 11 && steps != 12"
  356. >
  357. 查看工具
  358. </div>
  359. <div class="blackButton" @click="checkStudentAnswer" v-if="steps == 8">选择学生回答</div>
  360. <div class="blackButton" @click="isBlock = 4" v-if="steps == 11 || steps == 12">查看作业</div>
  361. </div>
  362. <!-- <div
  363. class="blackButton"
  364. style="margin-right: 10px"
  365. @click="dialogVisible2 = true"
  366. >
  367. 查看报告
  368. </div>-->
  369. </div>
  370. <el-dialog
  371. title="选择答题"
  372. :visible.sync="dialogVisible"
  373. :append-to-body="true"
  374. width="500px"
  375. :before-close="handleClose"
  376. class="dialog_diy"
  377. >
  378. <div style="text-align: center; padding: 20px 0 50px 0; font-size: 18px">
  379. 是否让“{{ answerStudent }}”同学进行单独答题?
  380. </div>
  381. <div
  382. style="
  383. width: 200px;
  384. background: #4d8ae0;
  385. height: 35px;
  386. margin: 0 auto;
  387. text-align: center;
  388. line-height: 35px;
  389. color: #fff;
  390. border-radius: 5px;
  391. cursor: pointer;
  392. "
  393. @click="dialogVisible = false"
  394. >
  395. 确定
  396. </div>
  397. </el-dialog>
  398. <el-dialog
  399. :visible.sync="dialogVisible1"
  400. :append-to-body="true"
  401. width="500px"
  402. :before-close="handleClose"
  403. class="dialog_diy"
  404. >
  405. <div style="text-align: center; padding: 20px 0 50px 0; font-size: 18px">
  406. 正在开发中!
  407. </div>
  408. <div
  409. style="
  410. width: 200px;
  411. background: #4d8ae0;
  412. height: 35px;
  413. margin: 0 auto;
  414. text-align: center;
  415. line-height: 35px;
  416. color: #fff;
  417. border-radius: 5px;
  418. cursor: pointer;
  419. "
  420. @click="dialogVisible1 = false"
  421. >
  422. 确定
  423. </div>
  424. </el-dialog>
  425. <el-dialog
  426. :visible.sync="dialogVisible2"
  427. :append-to-body="true"
  428. width="500px"
  429. :before-close="handleClose"
  430. class="dialog_diy"
  431. >
  432. <div style="text-align: center; padding: 20px 0 50px 0; font-size: 18px">
  433. 课程结束后才有报告!
  434. </div>
  435. <div
  436. style="
  437. width: 200px;
  438. background: #4d8ae0;
  439. height: 35px;
  440. margin: 0 auto;
  441. text-align: center;
  442. line-height: 35px;
  443. color: #fff;
  444. border-radius: 5px;
  445. cursor: pointer;
  446. "
  447. @click="dialogVisible2 = false"
  448. >
  449. 确定
  450. </div>
  451. </el-dialog>
  452. </div>
  453. </template>
  454. <script>
  455. import "../../common/aws-sdk-2.235.1.min";
  456. import EditorBar from "../../components/tools/wangEnduit";
  457. import AnswerData from "./components/answerData";
  458. import pdf from "./components/pdf";
  459. export default {
  460. components: { EditorBar, AnswerData, pdf },
  461. data() {
  462. return {
  463. pdfUrl:
  464. "https://ccrb.s3.cn-northwest-1.amazonaws.com.cn/0629%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%B61656920880446.pdf",
  465. isLoading: false,
  466. formLabelWidth: "100px",
  467. userid: this.$route.query.userid,
  468. cid: this.$route.query.cid,
  469. oid: this.$route.query.oid,
  470. mr: require("../../assets/icon/kc1.png"),
  471. timu: [],
  472. // a: false,
  473. // b: false,
  474. // c: false,
  475. steps: 0,
  476. isBlock: 0,
  477. dialogVisible: false,
  478. dialogVisible1: false,
  479. dialogVisible2: false,
  480. toolCount: 0,
  481. answerBox: "",
  482. answer: [
  483. { name: "A.1568" },
  484. { name: "B.720" },
  485. { name: "C.1728" },
  486. { name: "D.480" },
  487. ],
  488. studentArray: [
  489. { name: "张可松", is: 1 },
  490. { name: "陈佳佳", is: 1 },
  491. { name: "许琦基", is: 1 },
  492. { name: "洛维奇", is: 1 },
  493. { name: "罗伟", is: 1 },
  494. { name: "李孝雄", is: 1 },
  495. { name: "李琪琪", is: 1 },
  496. { name: "黄子韬", is: 1 },
  497. { name: "张嘉琪", is: 1 },
  498. { name: "陈家", is: 1 },
  499. { name: "张可", is: 1 },
  500. { name: "庄小小", is: 1 },
  501. { name: "梁思成", is: 1 },
  502. { name: "房小玲", is: 1 },
  503. { name: "李卫涛", is: 1 },
  504. { name: "李玫儿", is: 1 },
  505. { name: "张可梦", is: 1 },
  506. { name: "李琦", is: 1 },
  507. { name: "梁惠", is: 1 },
  508. { name: "许佳琪", is: 1 },
  509. ],
  510. studentArray2: [
  511. { name: "张可松", is: 1 },
  512. { name: "陈佳佳", is: 1 },
  513. { name: "许琦基", is: 1 },
  514. { name: "洛维奇", is: 1 },
  515. { name: "罗伟", is: 1 },
  516. { name: "李孝雄", is: 1 },
  517. { name: "李琪琪", is: 1 },
  518. { name: "黄子韬", is: 1 },
  519. { name: "张嘉琪", is: 1 },
  520. { name: "陈家", is: 1 },
  521. { name: "张可", is: 1 },
  522. { name: "庄小小", is: 1 },
  523. { name: "梁思成", is: 1 },
  524. { name: "房小玲", is: 1 },
  525. { name: "李卫涛", is: 1 },
  526. { name: "李玫儿", is: 1 },
  527. { name: "张可梦", is: 1 },
  528. { name: "李琦", is: 1 },
  529. { name: "梁惠", is: 1 },
  530. { name: "许佳琪", is: 1 },
  531. ],
  532. askCount: 0,
  533. answerJson: {
  534. A: 0,
  535. B: 0,
  536. C: 0,
  537. D: 0,
  538. },
  539. answerStudent: "",
  540. tools: [
  541. "",
  542. "",
  543. { tools: [9] }, //选择题
  544. { tools: [10] }, //倒计时
  545. { tools: [11] }, //问答题
  546. { tools: [11] }, //问答题
  547. { tools: [3, 1] }, //思维导图/电子白板
  548. { tools: [12] }, //选人回答
  549. { tools: [10, 13] }, //倒计时、分小组
  550. { tools: [3, 1, 7] }, //思维导图/电子白板/思维网格
  551. { tools: [14] }, //查看作业
  552. { tools: [14] }, //查看作业
  553. "", //查看作业
  554. //1、电子白板 2、便签 3、思维导图 4、问卷调查 5、量规评分 6、协同文档 7、思维网格 8、素材库 9、选择题 10、倒计时 11、问答题 12、选人回答 13、分小组 14、老师对提交作业进行评价
  555. ],
  556. howTools: 0,
  557. worksDetail: [],
  558. worksList: [],
  559. toolsList: [],
  560. };
  561. },
  562. methods: {
  563. change(val) {
  564. console.log(val);
  565. },
  566. goTo(path) {
  567. this.$router.push(path);
  568. },
  569. tableRowClassName({ row, rowIndex }) {
  570. if ((rowIndex + 1) % 2 === 0) {
  571. return "even_row";
  572. } else {
  573. return "";
  574. }
  575. },
  576. jump(cid) {
  577. window.parent.postMessage({ cid: cid, type: "1" }, "*");
  578. },
  579. handleCurrentChange(val) {
  580. // console.log(`当前页: ${val}`);
  581. this.page = val;
  582. },
  583. init() {},
  584. handleClose(done) {
  585. done();
  586. },
  587. //uuid生成
  588. guid() {
  589. return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(
  590. /[xy]/g,
  591. function (c) {
  592. var r = (Math.random() * 16) | 0,
  593. v = c == "x" ? r : (r & 0x3) | 0x8;
  594. return v.toString(16);
  595. }
  596. );
  597. },
  598. time() {
  599. if (!this.now) {
  600. this.now = new Date().getTime();
  601. return true;
  602. } else {
  603. let time = new Date().getTime();
  604. if (time - this.now > 3000) {
  605. this.now = time;
  606. return true;
  607. } else {
  608. return false;
  609. }
  610. }
  611. },
  612. randomNum(minNum, maxNum) {
  613. switch (arguments.length) {
  614. case 1:
  615. return parseInt(Math.random() * minNum + 1, 10);
  616. break;
  617. case 2:
  618. return parseInt(Math.random() * (maxNum - minNum + 1) + minNum, 10);
  619. break;
  620. default:
  621. return 0;
  622. break;
  623. }
  624. },
  625. addTool(t) {
  626. if (t == 1) {
  627. window.parent.postMessage({ tools: "1" }, "*");
  628. } else if (t == 3) {
  629. window.parent.postMessage({ tools: "3" }, "*");
  630. } else if (t == 7) {
  631. window.parent.postMessage({ tools: "7" }, "*");
  632. }
  633. },
  634. nextTool() {
  635. if (this.howTools < this.toolsList[0].tools.length - 1) {
  636. this.howTools++;
  637. } else if (this.howTools == this.toolsList[0].tools.length - 1) {
  638. this.isBlock = 0;
  639. }
  640. // if (this.toolCount < 2) {
  641. // this.toolCount++;
  642. // } else {
  643. // this.steps = 0;
  644. // this.type = 0;
  645. // this.toolCount = 0;
  646. // }
  647. },
  648. answerWork() {
  649. this.isBlock = 1;
  650. },
  651. checkStudentAnswer() {
  652. this.isBlock = 6;
  653. for (var i = 0; i < this.studentArray.length; i++) {
  654. this.studentArray2[i].is = 1;
  655. }
  656. },
  657. showMember(i) {
  658. let _this = this;
  659. this.isBlock = 2;
  660. setTimeout(() => {
  661. for (var i = 0; i < 10; i++) {
  662. var a = _this.randomNum(0, _this.studentArray.length - 1);
  663. _this.studentArray[a].is = 2;
  664. }
  665. this.askCount = 0;
  666. for (var i in _this.studentArray) {
  667. if (_this.studentArray[i].is == 2) {
  668. _this.askCount++;
  669. }
  670. }
  671. i = 0;
  672. this.answerJson = {
  673. A: 0,
  674. B: 0,
  675. C: 0,
  676. D: 0,
  677. };
  678. for (var i = 0; i < _this.askCount; i++) {
  679. var a = _this.randomNum(0, 3);
  680. if (a === 0) {
  681. _this.answerJson.A++;
  682. } else if (a === 1) {
  683. _this.answerJson.B++;
  684. } else if (a === 2) {
  685. _this.answerJson.C++;
  686. } else if (a === 3) {
  687. _this.answerJson.D++;
  688. }
  689. }
  690. }, 2000);
  691. },
  692. whoAnswer(item, index) {
  693. for (var i = 0; i < this.studentArray.length; i++) {
  694. this.studentArray2[i].is = 1;
  695. }
  696. this.studentArray2[index].is = 2;
  697. this.answerStudent = item.name;
  698. this.dialogVisible = true;
  699. },
  700. howPage(page) {
  701. this.howTools = 0;
  702. if (this.toolsList.length > 0) {
  703. this.toolsList = [];
  704. this.toolsList.push({ tools: this.tools[page - 1].tools });
  705. } else {
  706. this.toolsList.push({ tools: this.tools[page - 1].tools });
  707. }
  708. },
  709. getPage(page) {
  710. console.log(page);
  711. let params = [
  712. {
  713. page: page,
  714. },
  715. ];
  716. this.ajax
  717. .post(this.$store.state.api + "updatePptPage", params)
  718. .then((res) => {
  719. this.steps = page;
  720. this.isBlock = 0;
  721. if (page == 3) {
  722. this.howPage(page);
  723. } else if (page == 4) {
  724. this.howPage(page);
  725. } else if (page == 5) {
  726. this.howPage(page);
  727. } else if (page == 6) {
  728. this.howPage(page);
  729. } else if (page == 7) {
  730. this.howPage(page);
  731. } else if (page == 8) {
  732. this.howPage(page);
  733. } else if (page == 9) {
  734. this.howPage(page);
  735. } else if (page == 10) {
  736. this.howPage(page);
  737. } else if (page == 11) {
  738. this.howPage(page);
  739. } else if (page == 12) {
  740. this.howPage(page);
  741. }
  742. })
  743. .catch((err) => {
  744. console.error(err);
  745. });
  746. },
  747. selectSWork() {
  748. let params = {
  749. uid: "",
  750. cid: this.cid,
  751. };
  752. this.ajax
  753. .get(this.$store.state.api + "selectSWork", params)
  754. .then((res) => {
  755. this.worksDetail = res.data[0];
  756. for (var i = 0; i < this.worksDetail.length; i++) {
  757. this.worksList.push({
  758. upload: JSON.parse(this.worksDetail[i].upload)[0],
  759. sName: this.worksDetail[i].username,
  760. time: this.worksDetail[i].time,
  761. });
  762. }
  763. })
  764. .catch((err) => {
  765. this.$message.error("查询失败");
  766. console.error(err);
  767. });
  768. },
  769. },
  770. created() {
  771. this.selectSWork();
  772. },
  773. };
  774. </script>
  775. <style scoped>
  776. .dialog_diy >>> .el-dialog__header {
  777. background: #3d67bc !important;
  778. padding: 15px 20px;
  779. }
  780. .dialog_diy >>> .el-dialog__title {
  781. color: #fff;
  782. }
  783. .dialog_diy >>> .el-dialog__headerbtn {
  784. top: 9px;
  785. }
  786. .dialog_diy >>> .el-dialog__headerbtn .el-dialog__close {
  787. color: #fff;
  788. }
  789. .dialog_diy >>> .el-dialog__headerbtn .el-dialog__close:hover {
  790. color: #fff;
  791. }
  792. .blackBottom {
  793. background: rgb(0, 0, 0);
  794. height: 45px;
  795. width: 100%;
  796. }
  797. .imgMiddle {
  798. width: 100%;
  799. height: calc(100% - 45px);
  800. max-height: 920px;
  801. }
  802. .imgMiddle > img,
  803. .imghalf > img,
  804. .szt > img,
  805. .logoLive > img,
  806. .close > img {
  807. width: 100%;
  808. height: 100%;
  809. max-height: 920px;
  810. }
  811. .blackBottomB {
  812. position: sticky;
  813. bottom: 0px;
  814. left: 0px;
  815. display: flex;
  816. flex-direction: row;
  817. flex-wrap: wrap;
  818. align-content: center;
  819. justify-content: space-between;
  820. align-items: center;
  821. background: rgb(0, 0, 0);
  822. height: 45px;
  823. width: 100%;
  824. }
  825. .blackBottomB > div:nth-child(1) {
  826. margin-left: 10px !important;
  827. }
  828. .blackButton {
  829. color: #fff;
  830. background: #066ebe;
  831. width: 100px;
  832. height: 30px;
  833. line-height: 30px;
  834. text-align: center;
  835. margin: 0 5px;
  836. border-radius: 5px;
  837. font-size: 15px;
  838. cursor: pointer;
  839. }
  840. .isNoOther {
  841. width: 100%;
  842. height: 100%;
  843. display: flex;
  844. }
  845. .imghalf {
  846. width: 60% !important;
  847. height: calc(100% - 45px);
  848. max-height: 920px;
  849. }
  850. .answerBox {
  851. padding-left: 25px;
  852. padding: 25px;
  853. box-sizing: border-box;
  854. /* max-height: 800px;
  855. overflow: auto; */
  856. }
  857. .answerTimuBox {
  858. display: flex;
  859. flex-direction: column;
  860. flex-wrap: nowrap;
  861. align-items: flex-start;
  862. justify-content: flex-start;
  863. padding-bottom: 15px;
  864. }
  865. .memberBox {
  866. display: flex;
  867. flex-direction: row;
  868. flex-wrap: wrap;
  869. align-items: center;
  870. }
  871. .memberBox > div {
  872. background: rgb(79 213 163);
  873. width: 120px;
  874. color: #fff;
  875. height: 40px;
  876. text-align: center;
  877. line-height: 40px;
  878. border-radius: 5px;
  879. margin: 0 15px 15px 0;
  880. cursor: pointer;
  881. }
  882. .memberBox .pAnswer {
  883. background: rgb(55 197 144);
  884. }
  885. .viewSta {
  886. background: rgb(97, 97, 97);
  887. color: #bebebe;
  888. margin: 20% auto 20px;
  889. width: 300px;
  890. height: 40px;
  891. text-align: center;
  892. line-height: 40px;
  893. border-radius: 5px;
  894. cursor: pointer;
  895. }
  896. .szt {
  897. width: 100%;
  898. margin: 20px auto;
  899. }
  900. .sztFooter {
  901. padding: 20px 10px 50px 0;
  902. display: flex;
  903. flex-direction: row;
  904. flex-wrap: nowrap;
  905. justify-content: flex-end;
  906. align-items: center;
  907. }
  908. .toolList {
  909. display: flex;
  910. flex-direction: row;
  911. flex-wrap: wrap;
  912. justify-content: flex-start;
  913. align-items: center;
  914. }
  915. .tools {
  916. display: flex;
  917. flex-direction: column;
  918. align-items: center;
  919. margin-right: 20px;
  920. }
  921. .tools > div:nth-child(1) {
  922. width: 60px;
  923. }
  924. .tools > div:nth-child(1) > img,
  925. .workImg > img,
  926. .workTx > img {
  927. width: 100%;
  928. height: 100%;
  929. }
  930. .nextStepOne {
  931. background: #6b92c9;
  932. color: #fff;
  933. width: 110px;
  934. text-align: center;
  935. height: 35px;
  936. line-height: 35px;
  937. font-size: 14px;
  938. border-radius: 5px;
  939. position: absolute;
  940. bottom: 50px;
  941. left: 40%;
  942. cursor: pointer;
  943. }
  944. .logoLive {
  945. width: 35px;
  946. }
  947. .anserBoxCss {
  948. box-sizing: border-box;
  949. padding: 20px 0;
  950. }
  951. .anserBoxCss >>> .el-radio__label {
  952. font-size: 18px;
  953. }
  954. .anserBoxCss >>> .el-radio__inner {
  955. border-radius: 0px !important;
  956. }
  957. .choose_style {
  958. display: flex;
  959. justify-content: center;
  960. align-items: center;
  961. width: 100%;
  962. margin: 10px 0 30px;
  963. }
  964. .choose_style span {
  965. background: #f8f9ff;
  966. color: #677fff;
  967. border: 1px solid #95b5ff;
  968. padding: 15px 20px;
  969. font-size: 25px;
  970. border-radius: 18px;
  971. cursor: pointer;
  972. }
  973. .choose_style span + span {
  974. margin-left: 25px;
  975. }
  976. .choose_style .active {
  977. color: #fff;
  978. background: #5e78fa;
  979. }
  980. .close {
  981. position: absolute;
  982. right: 10px;
  983. top: 10px;
  984. width: 20px;
  985. cursor: pointer;
  986. }
  987. .workBox {
  988. margin-top: 20px;
  989. display: flex;
  990. flex-direction: row;
  991. flex-wrap: wrap;
  992. width: 100%;
  993. }
  994. .works {
  995. width: 31%;
  996. border: 1px solid #ececec;
  997. height: 160px;
  998. margin: 0 10px 10px 0;
  999. /* cursor: pointer; */
  1000. }
  1001. .workImg {
  1002. width: 214px;
  1003. height: 117px;
  1004. }
  1005. .workDetail {
  1006. display: flex;
  1007. flex-direction: row;
  1008. flex-wrap: nowrap;
  1009. align-items: center;
  1010. justify-content: space-between;
  1011. padding-top: 8px;
  1012. }
  1013. .workLeft {
  1014. display: flex;
  1015. flex-direction: row;
  1016. flex-wrap: nowrap;
  1017. align-items: center;
  1018. margin-left: 5px;
  1019. }
  1020. .workTx {
  1021. width: 25px;
  1022. }
  1023. .workName {
  1024. font-size: 14px;
  1025. padding-left: 5px;
  1026. }
  1027. .workRight {
  1028. font-size: 14px;
  1029. color: #ccc;
  1030. padding-right: 10px;
  1031. }
  1032. .returnButton {
  1033. position: absolute;
  1034. bottom: 20px;
  1035. width: 230px;
  1036. background: #616161;
  1037. left: 35%;
  1038. color: #ababab;
  1039. text-align: center;
  1040. border-radius: 5px;
  1041. height: 30px;
  1042. font-size: 14px;
  1043. line-height: 30px;
  1044. cursor: pointer;
  1045. }
  1046. </style>