QuestionManage.vue 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773
  1. <template>
  2. <div class="content question-manage">
  3. <!-- 正文信息 -->
  4. <div class="part-box">
  5. <!-- <h2 class="part-box-title">题库列表</h2> -->
  6. <div class="search-box">
  7. <el-form class="part-filter-form" :inline="true" :model="filter">
  8. <el-form-item label="课程">
  9. <course-select v-model="filter.courseId" @change="courseChange">
  10. </course-select>
  11. </el-form-item>
  12. <el-form-item label="题型">
  13. <source-detail-select v-model="filter" :course-id="filter.courseId">
  14. </source-detail-select>
  15. </el-form-item>
  16. <el-form-item label="题目内容">
  17. <el-input
  18. v-model="filter.questionBody"
  19. placeholder="题目内容"
  20. ></el-input>
  21. </el-form-item>
  22. <el-form-item label="知识点">
  23. <!-- <property-tree-select
  24. v-model="filter.questionProperty"
  25. :course-id="filter.courseId"
  26. ></property-tree-select> -->
  27. <property-tree-select
  28. v-model="filter.questionProperty"
  29. :course-id="filter.courseId"
  30. ></property-tree-select>
  31. </el-form-item>
  32. <el-form-item>
  33. <el-button type="primary" @click="toPage(1)">查询</el-button>
  34. </el-form-item>
  35. </el-form>
  36. </div>
  37. <!-- <div class="part-box-action"> -->
  38. <!-- <div> -->
  39. <!-- <el-button
  40. type="primary"
  41. plain
  42. icon="el-icon-data-analysis"
  43. @click="toStatistics"
  44. >试题统计</el-button
  45. > -->
  46. <!-- <el-button
  47. v-if="authButtons.includes('import_test_paper-safe')"
  48. type="danger"
  49. plain
  50. icon="el-icon-lock"
  51. @click="toSafetySet"
  52. >安全设置</el-button
  53. > -->
  54. <!-- <el-button
  55. type="primary"
  56. plain
  57. icon="el-icon-setting"
  58. @click="toSourceDetailManage"
  59. >题型管理</el-button
  60. > -->
  61. <!-- <el-button
  62. type="danger"
  63. plain
  64. icon="el-icon-delete"
  65. @click="toRecycle"
  66. >回收站</el-button
  67. > -->
  68. <!-- </div> -->
  69. <!-- <div> -->
  70. <!-- <el-button
  71. type="primary"
  72. plain
  73. icon="el-icon-position"
  74. @click="toBatchMove"
  75. >移动</el-button
  76. >
  77. <el-button
  78. type="primary"
  79. plain
  80. icon="el-icon-copy-document"
  81. @click="toBatchCopy"
  82. >复制</el-button
  83. >
  84. <el-button
  85. type="danger"
  86. plain
  87. icon="el-icon-circle-close"
  88. @click="toBatchDelete"
  89. >删除</el-button
  90. > -->
  91. <!-- <el-button
  92. type="primary"
  93. plain
  94. icon="el-icon-folder-opened"
  95. @click="toAddFolder"
  96. >新建文件夹</el-button
  97. > -->
  98. <!-- <el-button
  99. v-if="!gptQuestionEnable"
  100. type="primary"
  101. icon="el-icon-circle-plus-outline"
  102. plain
  103. @click="toCreateQuestion"
  104. >创建试题</el-button
  105. >
  106. <el-dropdown v-if="gptQuestionEnable">
  107. <el-button type="primary" plain icon="el-icon-circle-plus-outline"
  108. >创建试题</el-button
  109. >
  110. <el-dropdown-menu slot="dropdown" class="action-dropdown">
  111. <el-dropdown-item>
  112. <el-button
  113. size="mini"
  114. type="primary"
  115. plain
  116. @click="toCreateQuestion"
  117. >手动创建</el-button
  118. >
  119. </el-dropdown-item>
  120. <el-dropdown-item>
  121. <el-button
  122. size="mini"
  123. type="primary"
  124. plain
  125. @click="toGPTQuestion"
  126. >AI命题</el-button
  127. >
  128. </el-dropdown-item>
  129. </el-dropdown-menu>
  130. </el-dropdown> -->
  131. <!-- <el-button
  132. type="primary"
  133. plain
  134. icon="el-icon-upload2"
  135. @click="toImportQuestion"
  136. >批量导入</el-button
  137. > -->
  138. <!-- </div> -->
  139. <!-- </div> -->
  140. </div>
  141. <div class="folder-question">
  142. <div class="folder-list" :class="{ collapse: treeCollapse }">
  143. <question-folder
  144. ref="QuestionFolder"
  145. is-edit
  146. @selected="folderFilterSelected"
  147. ></question-folder>
  148. </div>
  149. <div class="collapse-icon-box">
  150. <div class="icon-circle" @click="treeCollapse = !treeCollapse">
  151. <i class="el-icon-arrow-right" v-if="treeCollapse"></i>
  152. <i class="el-icon-arrow-left" v-else></i>
  153. </div>
  154. </div>
  155. <div class="question-list">
  156. <div class="icon-btn-group box-justify">
  157. <!-- <svg-btn
  158. name="xinzeng"
  159. @click="toCreateQuestion"
  160. v-if="!gptQuestionEnable"
  161. >创建试题</svg-btn
  162. > -->
  163. <div>
  164. <el-dropdown>
  165. <svg-btn name="xinzeng">创建试题</svg-btn>
  166. <el-dropdown-menu slot="dropdown" class="action-dropdown">
  167. <el-dropdown-item>
  168. <el-button
  169. size="mini"
  170. type="primary"
  171. plain
  172. @click="toCreateQuestion"
  173. >手动创建</el-button
  174. >
  175. </el-dropdown-item>
  176. <el-dropdown-item>
  177. <el-button
  178. v-if="authButtons.includes('import_test_paper-ai')"
  179. size="mini"
  180. type="primary"
  181. plain
  182. @click="toGPTQuestion"
  183. >AI命题</el-button
  184. >
  185. </el-dropdown-item>
  186. </el-dropdown-menu>
  187. </el-dropdown>
  188. <svg-btn name="daoru" @click="toImportQuestion">批量导入</svg-btn>
  189. <svg-btn name="yidong" @click="toBatchMove">移动</svg-btn>
  190. <svg-btn name="fuzhi" @click="toBatchCopy">复制</svg-btn>
  191. <svg-btn name="shanchu" @click="toBatchDelete">删除</svg-btn>
  192. </div>
  193. <div>
  194. <svg-btn name="shititongji" @click="toStatistics">试题统计</svg-btn>
  195. <svg-btn name="tixingguanli" @click="toSourceDetailManage"
  196. >题型管理</svg-btn
  197. >
  198. </div>
  199. </div>
  200. <el-table
  201. v-loading="loading"
  202. element-loading-text="加载中"
  203. :data="questionList"
  204. @selection-change="tableSelectChange"
  205. >
  206. <el-table-column
  207. type="selection"
  208. width="50"
  209. align="center"
  210. ></el-table-column>
  211. <el-table-column label="题干" min-width="200">
  212. <div slot-scope="scope" @click="toViewQuestion(scope.row)">
  213. <rich-text
  214. class="row-question-body"
  215. title="点击查看试题"
  216. :text-json="scope.row.quesBody"
  217. ></rich-text>
  218. </div>
  219. </el-table-column>
  220. <el-table-column label="课程" width="120">
  221. <template slot-scope="scope">
  222. <span>{{ scope.row.course.name }}</span>
  223. </template>
  224. </el-table-column>
  225. <el-table-column label="题型" prop="sourceDetailName" width="100">
  226. </el-table-column>
  227. <el-table-column label="难度" prop="difficulty" width="80">
  228. </el-table-column>
  229. <el-table-column label="使用量" prop="usageAmount" width="80">
  230. </el-table-column>
  231. <el-table-column label="创建人" prop="creator" width="120">
  232. </el-table-column>
  233. <el-table-column label="创建时间" width="170" prop="creationTime">
  234. </el-table-column>
  235. <el-table-column label="操作" width="180" fixed="right">
  236. <template slot-scope="scope">
  237. <div class="operate_left">
  238. <el-button
  239. size="medium"
  240. type="text"
  241. class="normal"
  242. @click="toEditQuestion(scope.row)"
  243. >编辑</el-button
  244. >
  245. <el-dropdown>
  246. <el-button type="text" size="medium" class="normal">
  247. 更多<i class="el-icon-arrow-down el-icon--right"></i>
  248. </el-button>
  249. <el-dropdown-menu slot="dropdown" class="action-dropdown">
  250. <el-dropdown-item>
  251. <el-button
  252. size="mini"
  253. type="primary"
  254. plain
  255. @click="toMoveQuestion(scope.row)"
  256. >移动</el-button
  257. >
  258. </el-dropdown-item>
  259. <el-dropdown-item>
  260. <el-button
  261. size="mini"
  262. type="primary"
  263. plain
  264. @click="toCopyQuestion(scope.row)"
  265. >复制</el-button
  266. >
  267. </el-dropdown-item>
  268. <el-dropdown-item>
  269. <el-button
  270. size="mini"
  271. type="danger"
  272. plain
  273. @click="toDeleteQuestion(scope.row)"
  274. >删除</el-button
  275. >
  276. </el-dropdown-item>
  277. </el-dropdown-menu>
  278. </el-dropdown>
  279. </div>
  280. </template>
  281. </el-table-column>
  282. </el-table>
  283. <div class="part-page">
  284. <el-pagination
  285. :current-page="currentPage"
  286. :page-size="pageSize"
  287. :page-sizes="[10, 20, 50, 100, 200, 300]"
  288. layout="total, sizes, prev, pager, next, jumper"
  289. :total="total"
  290. @current-change="toPage"
  291. @size-change="handleSizeChange"
  292. >
  293. </el-pagination>
  294. </div>
  295. </div>
  296. </div>
  297. <!-- QuestionEditDialog -->
  298. <question-edit-dialog
  299. ref="QuestionEditDialog"
  300. :question="curQuestion"
  301. @modified="getList"
  302. ></question-edit-dialog>
  303. <!-- QuestionPreviewDialog -->
  304. <question-preview-dialog
  305. ref="QuestionPreviewDialog"
  306. :question="curQuestion"
  307. ></question-preview-dialog>
  308. <!-- QuestionStatisticsDialog -->
  309. <question-statistics-dialog
  310. ref="QuestionStatisticsDialog"
  311. :course-id="filter.courseId"
  312. ></question-statistics-dialog>
  313. <!-- QuestionSafetySetDialog -->
  314. <question-safety-set-dialog
  315. ref="QuestionSafetySetDialog"
  316. ></question-safety-set-dialog>
  317. <!-- QuestionFolderDialog -->
  318. <question-folder-dialog
  319. ref="QuestionFolderDialog"
  320. :is-edit="false"
  321. @selected="folderSelected"
  322. ></question-folder-dialog>
  323. <!-- QuestionImportDialog -->
  324. <question-import-dialog
  325. ref="QuestionImportDialog"
  326. @modified="questionImported"
  327. ></question-import-dialog>
  328. <!-- FolderQuestionManageDialog -->
  329. <folder-question-manage-dialog
  330. ref="FolderQuestionManageDialog"
  331. ></folder-question-manage-dialog>
  332. <!-- QuestionImportEdit -->
  333. <question-import-edit
  334. ref="QuestionImportEdit"
  335. :data="questionImportData"
  336. @modified="toPage(1)"
  337. ></question-import-edit>
  338. <!-- GptQuestionDialog -->
  339. <gpt-question-dialog
  340. ref="GptQuestionDialog"
  341. :course="{
  342. courseId: curCourse.id,
  343. courseCode: curCourse.code,
  344. courseName: curCourse.name,
  345. }"
  346. @modified="getList"
  347. ></gpt-question-dialog>
  348. <router-view></router-view>
  349. </div>
  350. </template>
  351. <script>
  352. import {
  353. // questionPageListApi,
  354. deleteQuestionApi,
  355. moveQuestionApi,
  356. copyQuestionApi,
  357. checkGptQuestionEnableApi,
  358. aiQuestionConfirmApi,
  359. classifyQuestionPageListApi,
  360. getAiNums,
  361. checkOptionRepeatApi,
  362. } from "../api";
  363. import QuestionStatisticsDialog from "../components/QuestionStatisticsDialog.vue";
  364. import QuestionSafetySetDialog from "../components/QuestionSafetySetDialog.vue";
  365. import QuestionFolderDialog from "../components/QuestionFolderDialog.vue";
  366. import QuestionImportDialog from "../components/QuestionImportDialog.vue";
  367. import QuestionEditDialog from "../components/QuestionEditDialog.vue";
  368. import QuestionPreviewDialog from "../components/QuestionPreviewDialog.vue";
  369. import FolderQuestionManageDialog from "../components/FolderQuestionManageDialog.vue";
  370. import PropertyTreeSelect from "../components/PropertyTreeSelect.vue";
  371. import QuestionImportEdit from "../components/QuestionImportEdit.vue";
  372. import GptQuestionDialog from "../components/GptQuestionDialog.vue";
  373. import { mapActions, mapGetters, mapMutations } from "vuex";
  374. import { USER_SIGNIN } from "../../portal/store/user";
  375. import QuestionFolder from "@/modules/question/components/QuestionFolder.vue";
  376. export default {
  377. name: "QuestionMamage",
  378. components: {
  379. QuestionStatisticsDialog,
  380. QuestionSafetySetDialog,
  381. QuestionFolderDialog,
  382. QuestionImportDialog,
  383. QuestionEditDialog,
  384. QuestionPreviewDialog,
  385. FolderQuestionManageDialog,
  386. PropertyTreeSelect,
  387. QuestionImportEdit,
  388. GptQuestionDialog,
  389. QuestionFolder,
  390. },
  391. data() {
  392. return {
  393. treeCollapse: true,
  394. filter: {
  395. courseId: "",
  396. questionType: "",
  397. sourceDetailId: "",
  398. questionBody: "",
  399. // questionProperty: [],
  400. questionProperty: [],
  401. classifyId: "",
  402. // courseId: "",
  403. // questionType: "",
  404. // sourceDetailId: "",
  405. // questionProperty: [],
  406. },
  407. curFolderAction: "",
  408. folderList: [],
  409. questionList: [],
  410. selectedQuestionIds: [],
  411. currentPage: 1,
  412. pageSize: 10,
  413. total: 0,
  414. loading: false,
  415. curQuestion: {},
  416. curFolder: {},
  417. curCourse: {},
  418. curMoveType: "",
  419. questionImportData: {},
  420. gptQuestionEnable: false,
  421. curActionQids: [],
  422. aiWarningMsg: "",
  423. };
  424. },
  425. computed: {
  426. user() {
  427. return this.$store.state.user;
  428. },
  429. ...mapGetters(["authButtons"]),
  430. },
  431. mounted() {
  432. this.$refs.QuestionFolder.selectDefaultNode();
  433. this.checkGptEnable();
  434. this.checkRepeatEnable();
  435. this.toPage(1);
  436. },
  437. methods: {
  438. ...mapMutations(["setCheckOptionRepeat"]),
  439. folderFilterSelected(folder) {
  440. console.log("left tree choose folder:", folder);
  441. if (!folder) return;
  442. this.curFolder = folder;
  443. this.filter = {
  444. classifyId: folder.id,
  445. courseId: "",
  446. questionType: "",
  447. sourceDetailId: "",
  448. questionProperty: [],
  449. };
  450. this.toPage(1);
  451. },
  452. ...mapActions([USER_SIGNIN]),
  453. async checkRepeatEnable() {
  454. let res = await checkOptionRepeatApi();
  455. this.setCheckOptionRepeat(res.data);
  456. },
  457. async checkGptEnable() {
  458. const res = await checkGptQuestionEnableApi();
  459. // this.gptQuestionEnable = res.data;
  460. if (res.data) {
  461. let result = await getAiNums({
  462. rootOrgId: this.$store.state.user.rootOrgId,
  463. });
  464. if (result?.data?.leftCount == 0) {
  465. this.aiWarningMsg =
  466. "AI命题出题包已经用完,请联系教务处老师购买试题包后再出题";
  467. }
  468. console.log("result", result);
  469. } else {
  470. this.aiWarningMsg = "未开通AI命题功能,请联系教务处老师进行开通";
  471. }
  472. },
  473. toPage(page) {
  474. this.currentPage = page;
  475. this.getList();
  476. },
  477. async getList() {
  478. this.loading = true;
  479. this.selectedQuestionIds = [];
  480. let data = {
  481. ...this.filter,
  482. // pageNumber: this.currentPage,
  483. pageNumber: this.currentPage,
  484. pageSize: this.pageSize,
  485. };
  486. // data.questionProperty = data.questionProperty.join();
  487. data.questionProperty = data.questionProperty.join();
  488. // const res = await questionPageListApi(data).catch(() => {});
  489. const res = await classifyQuestionPageListApi(data).catch(() => {});
  490. this.loading = false;
  491. if (!res) return;
  492. this.questionList = res.data.content;
  493. this.total = res.data.totalElements;
  494. },
  495. handleSizeChange(val) {
  496. this.pageSize = val;
  497. this.toPage(1);
  498. },
  499. tableSelectChange(selections) {
  500. this.selectedQuestionIds = selections.map((item) => item.id);
  501. },
  502. courseChange(val) {
  503. this.curCourse = val || {};
  504. },
  505. toStatistics() {
  506. if (!this.filter.courseId) {
  507. this.$message.error("请先选择课程!");
  508. return;
  509. }
  510. // this.$refs.QuestionStatisticsDialog.open();
  511. this.$router.push({
  512. name: "QuestionTypeStatistics",
  513. query: {
  514. courseId: this.filter.courseId,
  515. courseName: this.curCourse.name,
  516. },
  517. });
  518. },
  519. toSafetySet() {
  520. this.$refs.QuestionSafetySetDialog.open();
  521. },
  522. toSourceDetailManage() {
  523. if (!this.filter.courseId) {
  524. this.$message.error("请先选择课程!");
  525. return;
  526. }
  527. window.sessionStorage.setItem(
  528. "courseInfo",
  529. JSON.stringify(this.curCourse)
  530. );
  531. this.$router.push({
  532. name: "SourceDetailManage",
  533. });
  534. },
  535. toCreateQuestion() {
  536. if (!this.filter.courseId) {
  537. this.$message.error("请先选择课程!");
  538. return;
  539. }
  540. this.curQuestion = {
  541. courseId: this.curCourse.id,
  542. courseCode: this.curCourse.code,
  543. courseName: this.curCourse.name,
  544. };
  545. this.$refs.QuestionEditDialog.open();
  546. },
  547. toImportQuestion() {
  548. this.$refs.QuestionImportDialog.open();
  549. // this.questionImportData = {
  550. // importData: {
  551. // courseId: 9,
  552. // courseName: "化学",
  553. // },
  554. // };
  555. // this.$refs.QuestionImportEdit.open();
  556. },
  557. toViewQuestion(row) {
  558. this.curQuestion = row;
  559. this.$refs.QuestionPreviewDialog.open();
  560. },
  561. toEditQuestion(row) {
  562. this.curQuestion = row;
  563. this.$refs.QuestionEditDialog.open();
  564. },
  565. toMoveQuestion(row) {
  566. // this.curQuestion = row;
  567. this.curActionQids = [row.id];
  568. this.curFolderAction = "move";
  569. this.$refs.QuestionFolderDialog.open();
  570. },
  571. toCopyQuestion(row) {
  572. // this.curQuestion = row;
  573. this.curActionQids = [row.id];
  574. this.curFolderAction = "copy";
  575. this.$refs.QuestionFolderDialog.open();
  576. },
  577. async folderSelected(folder) {
  578. if (folder.id === this.curFolder.id && this.curFolderAction === "move") {
  579. this.$message.error("内容就在当前当前文件中");
  580. return;
  581. }
  582. let res = null;
  583. // if (this.curFolderAction === "move") {
  584. // res = await moveQuestionApi(this.curQuestion.id, folder.id).catch(
  585. // () => {}
  586. // );
  587. // } else {
  588. // res = await copyQuestionApi(this.curQuestion.id, folder.id).catch(
  589. // () => {}
  590. // );
  591. // }
  592. if (this.curFolderAction === "move") {
  593. res = await moveQuestionApi(this.curActionQids.join(), folder.id).catch(
  594. () => {}
  595. );
  596. } else {
  597. res = await copyQuestionApi(this.curActionQids.join(), folder.id).catch(
  598. () => {}
  599. );
  600. }
  601. if (!res) return;
  602. this.$message.success("操作成功!");
  603. this.getList();
  604. },
  605. async deleteQuestion(ids) {
  606. this.loading = true;
  607. const res = await deleteQuestionApi(ids.join()).catch(() => {});
  608. this.loading = false;
  609. if (!res) return;
  610. this.$notify({
  611. message: "删除成功",
  612. type: "success",
  613. });
  614. this.getList();
  615. },
  616. async toDeleteQuestion(row) {
  617. const confirm = await this.$confirm("确认删除试题吗?", "提示", {
  618. type: "warning",
  619. }).catch(() => {});
  620. if (confirm !== "confirm") return;
  621. this.deleteQuestion([row.id]);
  622. },
  623. toBatchMove() {
  624. if (!this.selectedQuestionIds.length) {
  625. this.$message.error("请选择试题!");
  626. return;
  627. }
  628. this.curActionQids = [...this.selectedQuestionIds];
  629. this.curFolderAction = "move";
  630. this.$refs.QuestionFolderDialog.open();
  631. },
  632. toBatchCopy() {
  633. if (!this.selectedQuestionIds.length) {
  634. this.$message.error("请选择试题!");
  635. return;
  636. }
  637. this.curActionQids = [...this.selectedQuestionIds];
  638. this.curFolderAction = "copy";
  639. this.$refs.QuestionFolderDialog.open();
  640. },
  641. async toBatchDelete() {
  642. if (!this.selectedQuestionIds.length) {
  643. this.$message.error("请选择试题!");
  644. return;
  645. }
  646. const confirm = await this.$confirm("确认删除选中试题吗?", "提示", {
  647. type: "warning",
  648. }).catch(() => {});
  649. if (confirm !== "confirm") return;
  650. this.deleteQuestion(this.selectedQuestionIds);
  651. },
  652. toRecycle() {
  653. this.$router.push({
  654. name: "QuestionRecycle",
  655. });
  656. },
  657. toAddFolder() {
  658. this.$refs.FolderQuestionManageDialog.open();
  659. },
  660. questionImported(data) {
  661. if (data.importType !== "word") {
  662. this.getList();
  663. return;
  664. }
  665. console.log("questionImported data", data);
  666. this.questionImportData = data;
  667. this.$refs.QuestionImportEdit.open();
  668. },
  669. async toGPTQuestion() {
  670. if (this.aiWarningMsg) {
  671. this.$message.error(this.aiWarningMsg);
  672. return;
  673. }
  674. if (!this.filter.courseId) {
  675. this.$message.error("请先选择课程!");
  676. return;
  677. }
  678. if (!this.user.aiQuestionConfirm) {
  679. const confirm = await this.$confirm(
  680. `请务必仔细阅读本协议内容,若您不同意本协议的任何内容,将无法使用该功能,AI命题功能借助AI工具来辅助出题,提高出题效率,减轻命题老师工作量,并不确保出题的正确性及适用性,请在出题后务必仔细检查核对,以免将有问题的试题加入试卷,用于考试。`,
  681. "提示",
  682. {
  683. type: "warning",
  684. }
  685. ).catch(() => {});
  686. if (confirm !== "confirm") return;
  687. await aiQuestionConfirmApi();
  688. this.USER_SIGNIN(
  689. Object.assign({}, this.user, { aiQuestionConfirm: true })
  690. );
  691. }
  692. this.$refs.GptQuestionDialog.open();
  693. },
  694. },
  695. };
  696. </script>
  697. <style lang="scss" scoped>
  698. .question-manage {
  699. .question-list {
  700. :deep(.row-question-body) {
  701. img {
  702. max-height: 100px;
  703. width: auto !important;
  704. }
  705. }
  706. }
  707. .collapse-icon-box {
  708. width: 0;
  709. position: relative;
  710. overflow: visible;
  711. .icon-circle {
  712. width: 16px;
  713. height: 16px;
  714. border-radius: 50%;
  715. display: flex;
  716. justify-content: center;
  717. align-items: center;
  718. border: 2px solid #6d5ff6;
  719. position: absolute;
  720. left: 50%;
  721. top: 30px;
  722. transform: translateX(-50%) translateY(-50%);
  723. cursor: pointer;
  724. background-color: #6d5ff6;
  725. i {
  726. font-size: 10px;
  727. color: #fff;
  728. }
  729. }
  730. }
  731. .folder-question {
  732. min-height: calc(100vh - 306px);
  733. }
  734. .search-box {
  735. display: flex;
  736. align-items: center;
  737. justify-content: space-between;
  738. .right-btns {
  739. display: flex;
  740. align-items: center;
  741. }
  742. }
  743. }
  744. </style>
  745. <style lang="scss">
  746. @media screen and (max-width: 1366px) {
  747. .question-manage {
  748. .part-filter-form {
  749. .el-form-item {
  750. // width: 180px !important;
  751. }
  752. }
  753. }
  754. }
  755. </style>