operation.vue 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753
  1. <template>
  2. <div class="m-container">
  3. <h2>
  4. <el-page-header @back="onCancel" :content="titleName"></el-page-header>
  5. </h2>
  6. <div class="m-core">
  7. <el-form ref="form" :model="form" label-width="140px">
  8. <el-row>
  9. <el-col :xs="24" :sm="24" :md="24" :lg="18" :xl="18">
  10. <el-form-item
  11. label="问卷名称"
  12. prop="title"
  13. :rules="[
  14. { required: true, message: '请输入问卷名称', trigger: 'blur' },
  15. ]"
  16. >
  17. <el-input
  18. v-model="form.title"
  19. placeholder="请输入问卷名称"
  20. :disabled="disabled"
  21. ></el-input>
  22. </el-form-item>
  23. </el-col>
  24. </el-row>
  25. <el-row :gutter="20">
  26. <el-col :xs="12" :sm="12" :md="12" :lg="9" :xl="9">
  27. <el-form-item
  28. label="是否需要登录"
  29. prop="loginFlag"
  30. class="memoWrapItem"
  31. :rules="[
  32. {
  33. required: true,
  34. message: '请选择是否需要登录',
  35. trigger: 'change',
  36. },
  37. ]"
  38. >
  39. <template slot="label">
  40. <p style="position: relative" class="titleCell">
  41. <span style="color: #f56c6c; margin-right: 4px">*</span>
  42. 是否需要登录
  43. <el-tooltip placement="top" popper-class="mTooltip">
  44. <div slot="content">
  45. 若选"是",学员登录才可填写问卷,提交详情中自动展示学员姓名、年龄、手机号信息
  46. </div>
  47. <i
  48. class="el-icon-question"
  49. style="
  50. font-size: 18px;
  51. color: #f56c6c;
  52. position: relative;
  53. top: 2px;
  54. "
  55. ></i>
  56. </el-tooltip>
  57. </p>
  58. </template>
  59. <el-select
  60. v-model="form.loginFlag"
  61. placeholder="请选择是否需要登录"
  62. :disabled="disabled"
  63. @change="changeLoginFlag"
  64. style="width: 100% !important"
  65. >
  66. <el-option label="是" :value="1"></el-option>
  67. <el-option label="否" :value="0"></el-option>
  68. </el-select>
  69. </el-form-item>
  70. </el-col>
  71. <el-col
  72. :xs="12"
  73. :sm="12"
  74. :md="12"
  75. :lg="9"
  76. :xl="9"
  77. v-if="form.loginFlag"
  78. >
  79. <el-form-item
  80. label="是否逐题提交"
  81. prop="commitType"
  82. class="memoWrapItem"
  83. :rules="[
  84. {
  85. required: true,
  86. message: '请选择是否逐题提交',
  87. trigger: 'change',
  88. },
  89. ]"
  90. >
  91. <template slot="label">
  92. <p style="position: relative" class="titleCell">
  93. <!-- <span style="color: #f56c6c; margin-right: 4px">*</span> -->
  94. 是否逐题提交
  95. <el-tooltip placement="top" popper-class="mTooltip">
  96. <div slot="content">逐题模式下,所有问题默认必填</div>
  97. <i
  98. class="el-icon-question"
  99. style="
  100. font-size: 18px;
  101. color: #f56c6c;
  102. position: relative;
  103. top: 2px;
  104. "
  105. ></i>
  106. </el-tooltip>
  107. </p>
  108. </template>
  109. <el-select
  110. v-model="form.commitType"
  111. placeholder="请选择是否逐题提交"
  112. :disabled="disabled"
  113. style="width: 100% !important"
  114. >
  115. <el-option label="是" :value="1"></el-option>
  116. <el-option label="否" :value="0"></el-option>
  117. </el-select>
  118. </el-form-item>
  119. </el-col>
  120. </el-row>
  121. <el-row>
  122. <el-col :xs="24" :sm="24" :md="24" :lg="18" :xl="18">
  123. <el-form-item
  124. label="分享标题"
  125. prop="shareTitle"
  126. :rules="[
  127. { required: true, message: '请输入分享标题', trigger: 'blur' },
  128. ]"
  129. >
  130. <template slot="label">
  131. <p style="position: relative" class="titleCell">
  132. <!-- <span style="color: #f56c6c; margin-right: 4px">*</span> -->
  133. 分享标题
  134. <el-tooltip placement="top" popper-class="mTooltip">
  135. <div slot="content">
  136. 问卷链接分享到微信时,显示的链接标题
  137. </div>
  138. <i
  139. class="el-icon-question"
  140. style="
  141. font-size: 18px;
  142. color: #f56c6c;
  143. position: relative;
  144. top: 2px;
  145. "
  146. ></i>
  147. </el-tooltip>
  148. </p>
  149. </template>
  150. <el-input
  151. v-model="form.shareTitle"
  152. placeholder="请输入分享标题"
  153. :disabled="disabled"
  154. ></el-input>
  155. </el-form-item>
  156. </el-col>
  157. </el-row>
  158. <el-row>
  159. <el-col :xs="24" :sm="24" :md="24" :lg="18" :xl="18">
  160. <el-form-item
  161. label="分享描述"
  162. prop="shareDescribe"
  163. :rules="[
  164. { required: true, message: '请输入分享描述', trigger: 'blur' },
  165. ]"
  166. >
  167. <template slot="label">
  168. <p style="position: relative" class="titleCell">
  169. <!-- <span style="color: #f56c6c; margin-right: 4px">*</span> -->
  170. 分享描述
  171. <el-tooltip placement="top" popper-class="mTooltip">
  172. <div slot="content">
  173. 问卷链接分享到微信时,显示的链接描述
  174. </div>
  175. <i
  176. class="el-icon-question"
  177. style="
  178. font-size: 18px;
  179. color: #f56c6c;
  180. position: relative;
  181. top: 2px;
  182. "
  183. ></i>
  184. </el-tooltip>
  185. </p>
  186. </template>
  187. <el-input
  188. v-model="form.shareDescribe"
  189. placeholder="请输入分享描述"
  190. :disabled="disabled"
  191. ></el-input>
  192. </el-form-item>
  193. </el-col>
  194. </el-row>
  195. <el-row>
  196. <el-form-item
  197. label="问卷模板"
  198. prop="templateType"
  199. :rules="[{ required: true, message: '请选择问卷模板' }]"
  200. >
  201. <el-checkbox-group v-model="checkList" @change="bindCheckBox">
  202. <div class="chioseWrap">
  203. <div class="chioseItem" @click="settemplateType(1)">
  204. <img src="./images/img1.png" alt="" />
  205. <!-- v-model="form.templateType" -->
  206. <div class="remberBox">
  207. <div class="wrap"></div>
  208. <el-checkbox
  209. class="chioseBox"
  210. :label="1"
  211. :checked="form.templateType == 1"
  212. :disabled="disabled"
  213. ><br
  214. /></el-checkbox>
  215. <!-- <div
  216. class="dotWrap"
  217. :class="[form.templateType == 1 ? 'checked' : '']"
  218. ></div> -->
  219. </div>
  220. </div>
  221. <div class="chioseItem" @click="settemplateType(2)">
  222. <img src="./images/img2.png" alt="" />
  223. <div class="remberBox">
  224. <!-- v-model="form.templateType" -->
  225. <div class="wrap"></div>
  226. <el-checkbox
  227. name="2"
  228. class="chioseBox"
  229. :label="2"
  230. :checked="form.templateType == 2"
  231. :disabled="disabled"
  232. ><br
  233. /></el-checkbox>
  234. <!-- <div
  235. class="dotWrap"
  236. :class="[form.templateType == 2 ? 'checked' : '']"
  237. ></div> -->
  238. </div>
  239. </div>
  240. <div class="chioseItem" @click="settemplateType(3)">
  241. <img src="./images/img3.png" alt="" />
  242. <div class="remberBox">
  243. <div class="wrap"></div>
  244. <el-checkbox
  245. class="chioseBox"
  246. :label="3"
  247. :checked="form.templateType == 3"
  248. :disabled="disabled"
  249. ><br
  250. /></el-checkbox>
  251. <!-- <div
  252. class="dotWrap"
  253. :class="[form.templateType == 3 ? 'checked' : '']"
  254. ></div> -->
  255. </div>
  256. </div>
  257. <div class="chioseItem" @click="settemplateType(4)">
  258. <img src="./images/img4.png" alt="" />
  259. <div class="remberBox">
  260. <div class="wrap"></div>
  261. <el-checkbox
  262. class="chioseBox"
  263. :label="4"
  264. :checked="form.templateType == 4"
  265. :disabled="disabled"
  266. ><br
  267. /></el-checkbox>
  268. <!-- <div
  269. class="dotWrap"
  270. :class="[form.templateType == 3 ? 'checked' : '']"
  271. ></div> -->
  272. </div>
  273. </div>
  274. </div>
  275. </el-checkbox-group>
  276. </el-form-item>
  277. </el-row>
  278. </el-form>
  279. <el-row>
  280. <el-col
  281. :xs="24"
  282. :sm="24"
  283. :md="24"
  284. :lg="18"
  285. :xl="18"
  286. v-for="(item, index) in form.questionnaireQuestionList"
  287. :key="index"
  288. style="
  289. padding: 15px 22px;
  290. background-color: #eef4f9;
  291. margin-bottom: 10px;
  292. "
  293. >
  294. <el-row
  295. type="flex"
  296. align="middle"
  297. style="flex: 1 auto; padding-bottom: 15px"
  298. >
  299. <el-col :span="12">
  300. <span
  301. style="
  302. font-size: 18px;
  303. width: 80px;
  304. text-align: right;
  305. display: inline-block;
  306. "
  307. >问题{{ index + 1 }}</span
  308. >
  309. </el-col>
  310. <el-col :span="12" style="text-align: right; padding-right: 15px">
  311. <el-tooltip
  312. key="moveDown"
  313. class="item"
  314. effect="dark"
  315. content="向下移动"
  316. placement="top"
  317. >
  318. <el-button
  319. icon="el-icon-top"
  320. circle
  321. @click.stop="moveDown(form.questionnaireQuestionList, index)"
  322. :disabled="index == 0 || disabled"
  323. ></el-button>
  324. </el-tooltip>
  325. <el-tooltip
  326. key="moveUp"
  327. class="item"
  328. effect="dark"
  329. content="向上移动"
  330. placement="top"
  331. >
  332. <el-button
  333. icon="el-icon-bottom"
  334. circle
  335. @click.stop="moveUp(form.questionnaireQuestionList, index)"
  336. :disabled="
  337. form.questionnaireQuestionList.length <= 1 ||
  338. form.questionnaireQuestionList.length == index + 1 ||
  339. disabled
  340. "
  341. ></el-button>
  342. </el-tooltip>
  343. <el-tooltip
  344. class="item"
  345. effect="dark"
  346. content="删除"
  347. placement="top"
  348. >
  349. <el-button
  350. icon="el-icon-delete"
  351. circle
  352. @click.stop="onDelete(form.questionnaireQuestionList, index)"
  353. :disabled="
  354. form.questionnaireQuestionList.length <= 1 || disabled
  355. "
  356. ></el-button>
  357. </el-tooltip>
  358. </el-col>
  359. </el-row>
  360. <question-list
  361. ref="questions"
  362. :type="type"
  363. :form="item"
  364. :commitType="form.commitType"
  365. :disabled="disabled"
  366. />
  367. </el-col>
  368. <!-- <el-collapse v-model="activeName">
  369. <el-col :xs="24" :sm="24" :md="24" :lg="18" :xl="18" v-for="(item, index) in form.questionnaireQuestionList" :key="index" style="padding: 15px 22px; background-color: #eef4f9; margin-bottom: 10px;">
  370. <el-collapse-item style="background-color: #eef4f9;" :name="index">
  371. <template slot="title">
  372. <el-row type="flex" align="middle" style="flex: 1 auto;">
  373. <el-col :span="12">
  374. <span style="font-size: 18px;width: 80px; text-align: right;display: inline-block;">问题{{ index + 1 }}</span>
  375. </el-col>
  376. <el-col :span="12" style="text-align: right; padding-right: 15px;">
  377. <el-tooltip class="item" effect="dark" content="向下移动" placement="top">
  378. <el-button icon="el-icon-top" circle @click.stop="moveDown(form.questionnaireQuestionList, index)" :disabled="index == 0"></el-button>
  379. </el-tooltip>
  380. <el-tooltip class="item" effect="dark" content="向下移动" placement="top">
  381. <el-button icon="el-icon-bottom" circle @click.stop="moveUp(form.questionnaireQuestionList, index)" :disabled="form.questionnaireQuestionList.length <= 1 || form.questionnaireQuestionList.length == (index + 1)"></el-button>
  382. </el-tooltip>
  383. <el-tooltip class="item" effect="dark" content="删除" placement="top">
  384. <el-button icon="el-icon-delete" circle @click.stop="onDelete(form.questionnaireQuestionList, index)" :disabled="form.questionnaireQuestionList.length <= 1"></el-button>
  385. </el-tooltip>
  386. </el-col>
  387. </el-row>
  388. </template>
  389. <question-list ref="questions" :type="type" :form="item" />
  390. </el-collapse-item>
  391. </el-col>
  392. </el-collapse> -->
  393. </el-row>
  394. <el-row style="padding-bottom: 15px">
  395. <el-col
  396. :xs="24"
  397. :sm="24"
  398. :md="24"
  399. :lg="18"
  400. :xl="18"
  401. style="text-align: center"
  402. >
  403. <el-button
  404. style="width: 100%"
  405. type="default"
  406. :disabled="disabled"
  407. @click="addQuestionItem(form.questionnaireQuestionList)"
  408. icon="el-icon-plus"
  409. >新增问题</el-button
  410. >
  411. </el-col>
  412. </el-row>
  413. <el-row>
  414. <el-col :xs="24" :sm="24" :md="24" :lg="18" :xl="18">
  415. <el-alert
  416. v-if="disabled"
  417. style="margin: 10px 0"
  418. title="该问卷已存在提交数据,不可修改"
  419. :closable="false"
  420. type="error"
  421. >
  422. </el-alert>
  423. </el-col>
  424. </el-row>
  425. <el-button type="primary" :disabled="disabled" @click="onSubmit">{{
  426. type == "create" ? "生成问卷" : "修改问卷"
  427. }}</el-button>
  428. <el-button type="primary" @click="onPreview">预览</el-button>
  429. <el-button @click="onReset" :disabled="disabled">重置</el-button>
  430. <!-- -->
  431. <el-dialog
  432. title="问卷题目"
  433. :close-on-click-modal="false"
  434. :visible.sync="questionStatus"
  435. width="415px"
  436. v-if="questionStatus"
  437. >
  438. <questionManger :form="form" @close="questionStatus = false" />
  439. <!-- <iframe
  440. src="http://192.168.3.8:9001/#/question"
  441. width="375px"
  442. height="667px"
  443. frameborder="0"
  444. ref="question"
  445. @load="loadfrom"
  446. ></iframe> -->
  447. </el-dialog>
  448. </div>
  449. </div>
  450. </template>
  451. <script>
  452. import questionList from "./components/questionList";
  453. import {
  454. questionnaireTopicAdd,
  455. questionnaireTopicGetDetail,
  456. questionnaireTopicUpdate,
  457. } from "./api";
  458. import questionManger from "./questionManger";
  459. import AnswerList from "./components/answerList";
  460. export default {
  461. name: "operationQuestion",
  462. components: { questionList, AnswerList, questionManger },
  463. data() {
  464. let query = this.$route.query;
  465. let titleName = "问卷";
  466. if (query.type == "create") {
  467. titleName = "添加" + titleName;
  468. } else if (query.type == "update") {
  469. titleName = "修改" + titleName;
  470. } else if (query.type == "look") {
  471. titleName = "查看" + titleName;
  472. }
  473. return {
  474. type: query.type,
  475. titleName: titleName,
  476. id: query.id,
  477. questionList: [],
  478. activeName: [],
  479. form: {
  480. title: null,
  481. againCommitFlag: 1,
  482. questionnaireQuestionList: [{ questionnaireQuestionItemList: [{}] }],
  483. commitType: null,
  484. },
  485. disabled: false,
  486. questionStatus: false,
  487. checkList: [],
  488. };
  489. },
  490. async mounted() {
  491. if (this.type == "update" || this.type == "look") {
  492. try {
  493. let res = await questionnaireTopicGetDetail({ id: this.id });
  494. this.form = res.data;
  495. this.questionList = res.data;
  496. this.settemplateType(res.data.templateType);
  497. this.disabled = !res.data.modifyFlag;
  498. // let list = res.data.questionnaireQuestionList || []
  499. // list.forEach((item, index) => {
  500. // this.activeName.push(index)
  501. // })
  502. } catch {
  503. //
  504. }
  505. }
  506. },
  507. methods: {
  508. getForms() {
  509. const { $refs: refs } = this;
  510. return [refs.form, ...(refs.questions || [])]
  511. .filter((item) => !!item)
  512. .map((item) => item.$refs.form || item);
  513. },
  514. setResultSort() {
  515. // 给问答结果排序
  516. let form = this.form;
  517. form.questionnaireQuestionList.forEach((item, index) => {
  518. item.sort = index;
  519. let itemList = item.questionnaireQuestionItemList;
  520. if (item.type != "textarea") {
  521. itemList.forEach((child, index) => {
  522. child.sort = index;
  523. });
  524. } else {
  525. itemList = [];
  526. }
  527. });
  528. },
  529. onSubmit() {
  530. const forms = this.getForms();
  531. Promise.all(forms.map(this.getFormPromise)).then(async (res) => {
  532. const validateResult = res.every((item) => !!item);
  533. console.log(validateResult);
  534. if (validateResult) {
  535. this.setResultSort();
  536. console.log(this.form);
  537. try {
  538. if (this.type == "create") {
  539. await questionnaireTopicAdd(this.form);
  540. this.$message.success("添加成功");
  541. } else {
  542. await questionnaireTopicUpdate(this.form);
  543. this.$message.success("修改成功");
  544. }
  545. this.onCancel();
  546. } catch {
  547. //
  548. }
  549. } else {
  550. this.$nextTick(() => {
  551. let isError = document.getElementsByClassName("is-error");
  552. isError[0].scrollIntoView({
  553. block: "center",
  554. behavior: "smooth",
  555. });
  556. });
  557. return false;
  558. }
  559. });
  560. },
  561. getFormPromise(form) {
  562. return new Promise((resolve) => {
  563. form.validate((res) => {
  564. resolve(res);
  565. });
  566. });
  567. },
  568. onPreview() {
  569. const forms = this.getForms();
  570. Promise.all(forms.map(this.getFormPromise)).then(async (res) => {
  571. const validateResult = res.every((item) => !!item);
  572. if (validateResult) {
  573. this.questionStatus = true;
  574. // 验证通过 我现在的问题是如何在h5 拿到题目 不然就得复制一套过来
  575. }
  576. });
  577. },
  578. onReset() {
  579. this.form = {
  580. title: null,
  581. questionnaireQuestionList: [{ questionnaireQuestionItemList: [{}] }],
  582. };
  583. setTimeout(() => {
  584. const forms = this.getForms();
  585. for (let form of forms) {
  586. form.clearValidate();
  587. }
  588. }, 30);
  589. },
  590. // 添加题目选项
  591. addQuestionItem(questionnaireQuestionList) {
  592. questionnaireQuestionList.push({ questionnaireQuestionItemList: [{}] });
  593. },
  594. // 向上移动
  595. moveUp(arr, index) {
  596. console.log("向上移动");
  597. arr.splice(index, 1, ...arr.splice(index + 1, 1, arr[index]));
  598. },
  599. // 向下移动
  600. moveDown(arr, index) {
  601. console.log("向下移动");
  602. arr.splice(index - 1, 1, ...arr.splice(index, 1, arr[index - 1]));
  603. },
  604. // 删除选项
  605. onDelete(arr, index) {
  606. if (!this.disabled) {
  607. if (this.form.delQuestionnaireQuestionIdList) {
  608. this.form.delQuestionnaireQuestionIdList.push(arr[index].id);
  609. console.log(this.form.delQuestionnaireQuestionIdList);
  610. } else {
  611. this.form.delQuestionnaireQuestionIdList = [arr[index].id];
  612. console.log(this.form.delQuestionnaireQuestionIdList);
  613. }
  614. }
  615. arr.splice(index, 1);
  616. },
  617. onCancel() {
  618. this.$store.dispatch("delVisitedViews", this.$route);
  619. this.$router.push({ path: "/operateManager/setQuestions" });
  620. },
  621. loadfrom() {
  622. let questWindow = this.$refs.question?.contentWindow;
  623. console.log(questWindow, "questWindow");
  624. questWindow.postMessage(
  625. {
  626. cmd: "getFormJson",
  627. data: { ...this.form },
  628. },
  629. "*"
  630. );
  631. },
  632. settemplateType(index) {
  633. if (this.disabled) return;
  634. this.$set(this.form, "templateType", index);
  635. if (this.checkList.indexOf(index) == -1) {
  636. this.checkList.push(index);
  637. } else {
  638. this.checkList.splice(this.checkList.indexOf(index), 1);
  639. }
  640. this.bindCheckBox();
  641. },
  642. bindCheckBox() {
  643. if (this.checkList.length > 1) {
  644. this.checkList.splice(0, 1);
  645. }
  646. this.$set(this.form, "templateType", this.checkList[0] || null);
  647. },
  648. changeLoginFlag(val) {
  649. if (!val) {
  650. this.form.commitType = 0;
  651. }
  652. },
  653. },
  654. };
  655. </script>
  656. <style lang="scss" scoped>
  657. /deep/.el-date-editor.el-input {
  658. width: 100% !important;
  659. }
  660. /deep/.el-select {
  661. width: 98% !important;
  662. }
  663. /deep/.el-collapse {
  664. border: 0;
  665. }
  666. /deep/.el-collapse-item__wrap,
  667. /deep/.el-collapse-item__header {
  668. background-color: #eef4f9;
  669. }
  670. .titleCell {
  671. display: inline-block;
  672. }
  673. /deep/.memoWrapItem {
  674. label {
  675. &:before {
  676. display: none;
  677. }
  678. }
  679. }
  680. .chioseWrap {
  681. display: flex;
  682. flex-direction: row;
  683. justify-content: flex-start;
  684. .chioseItem {
  685. border-radius: 4px;
  686. overflow: hidden;
  687. position: relative;
  688. margin-right: 10px;
  689. width: 188px;
  690. height: 188px;
  691. cursor: pointer;
  692. img {
  693. width: 100%;
  694. }
  695. .remberBox {
  696. .wrap {
  697. width: 100px;
  698. height: 100px;
  699. z-index: 100;
  700. position: absolute;
  701. // background-color: red;
  702. }
  703. display: flex;
  704. flex-direction: row;
  705. justify-content: flex-start;
  706. margin-bottom: 30px;
  707. padding-top: 10px;
  708. align-items: center;
  709. position: relative;
  710. color: #6d7278;
  711. font-size: 16px;
  712. position: absolute;
  713. top: 1px;
  714. right: 1px;
  715. .chioseBox {
  716. /deep/.el-checkbox__inner {
  717. width: 20px;
  718. height: 20px;
  719. border-radius: 50%;
  720. &::after {
  721. height: 8px;
  722. left: 6px;
  723. position: absolute;
  724. top: 3px;
  725. width: 4px;
  726. }
  727. }
  728. }
  729. .dotWrap {
  730. width: 21px;
  731. height: 21px;
  732. background: url("../../assets/images/icon_checkbox_default.png")
  733. no-repeat center;
  734. background-size: contain;
  735. margin-right: 8px;
  736. position: relative;
  737. overflow: hidden;
  738. &.checked {
  739. background: url("../../assets/images/icon_checkbox.png") no-repeat
  740. center;
  741. background-size: contain;
  742. }
  743. }
  744. }
  745. }
  746. }
  747. </style>