index.vue 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872
  1. <template>
  2. <div id="keyTestSites">
  3. <search-box :formList="formList" @search="search" @init="init" />
  4. <table-list
  5. :tableSets="tableSet"
  6. :tableData="tableData"
  7. :navText="navText"
  8. @addClick="addClick"
  9. :loading="loading"
  10. >
  11. <template slot="btn" slot-scope="props">
  12. <el-button type="text" @click="infoMessage(props.scope.row)"
  13. >详情</el-button
  14. >
  15. <el-button type="text" @click="modify(props.scope.row)">修改</el-button>
  16. <el-button type="text" @click="del(props.scope.row)">删除</el-button>
  17. </template>
  18. </table-list>
  19. <pagination
  20. :total="total"
  21. :pageSize="pageSize"
  22. :currentPage="currentPage"
  23. @handleSizeChange="handleSizeChange"
  24. @handleCurrentChange="handleCurrentChange"
  25. />
  26. <el-dialog
  27. :visible.sync="dialogBox"
  28. width="920px"
  29. :show-close="false"
  30. :destroy-on-close="true"
  31. :fullscreen="fullscreen"
  32. :close-on-click-modal="false"
  33. >
  34. <div slot="title" class="hearders">
  35. <div class="leftTitle">
  36. {{ statusPop === 1 ? "添加" : statusPop === 0 ? "修改" : "详情" }}
  37. </div>
  38. <div class="rightBoxs">
  39. <img
  40. src="@/assets/images/Max@2x.png"
  41. alt=""
  42. @click="fullscreen = !fullscreen"
  43. />
  44. <img src="@/assets/images/Close@2x.png" alt="" @click="closeBefore" />
  45. </div>
  46. </div>
  47. <el-row class="contentBox" :span="24">
  48. <el-col :span="24">
  49. <el-col :span="12">
  50. <el-col :span="24">
  51. <header>重点考点分类</header>
  52. <el-cascader
  53. style="width: 100%"
  54. v-model="poppleData.categoryId"
  55. :options="optionsTion"
  56. :size="'medium'"
  57. :disabled="statusPop === 2"
  58. clearable
  59. :props="{
  60. label: 'categoryName',
  61. value: 'categoryId',
  62. checkStrictly: true,
  63. emitPath: false,
  64. }"
  65. ></el-cascader>
  66. </el-col>
  67. <el-col :span="24">
  68. <header>重点考点名称:</header>
  69. <el-input
  70. :disabled="statusPop === 2"
  71. placeholder="请输入重点考点名称:"
  72. v-model="poppleData.name"
  73. />
  74. </el-col>
  75. <el-col :span="24">
  76. <header>主讲名师</header>
  77. <el-select
  78. :disabled="statusPop === 2"
  79. style="width: 100%"
  80. multiple
  81. v-model="poppleData.teacherIds"
  82. placeholder="请选择主讲名师:"
  83. @change="changeTeacherlist"
  84. >
  85. <el-option
  86. v-for="item in optionsTeach"
  87. :key="item.teacherId"
  88. :label="item.teacherName"
  89. :value="item.teacherId"
  90. >
  91. </el-option>
  92. </el-select>
  93. </el-col>
  94. <el-col :span="24">
  95. <header>价格:</header>
  96. <el-input
  97. placeholder="请输入价格:"
  98. :disabled="statusPop === 2"
  99. v-model="poppleData.price"
  100. >
  101. <template slot="append">元</template>
  102. </el-input>
  103. </el-col>
  104. <el-col :span="12">
  105. <header>排序:</header>
  106. <el-input-number
  107. style="width: 150px"
  108. placeholder="请输入排序:"
  109. :disabled="statusPop === 2"
  110. v-model="poppleData.sort"
  111. controls-position="right"
  112. :min="0"
  113. :max="999"
  114. ></el-input-number>
  115. </el-col>
  116. <el-col :span="12">
  117. <header>是否启用:</header>
  118. <el-radio-group
  119. v-model="poppleData.status"
  120. :disabled="statusPop === 2"
  121. >
  122. <el-radio :label="1">是</el-radio>
  123. <el-radio :label="0">否</el-radio>
  124. </el-radio-group>
  125. </el-col>
  126. </el-col>
  127. <el-col :span="12">
  128. <el-col :span="24">
  129. <header>重点考点封面:</header>
  130. <div class="imgBox">
  131. <label class="imgLabel" for="inputs">
  132. <div class="msPhoto" v-if="poppleData.coverUrl">
  133. <img
  134. :src="$methodsTools.splitImgHost(poppleData.coverUrl)"
  135. alt="图片加载失败"
  136. />
  137. </div>
  138. <div class="imgbbx" v-else>
  139. <p style="margin-top: 49px">
  140. 点击添加或将图片拖拽到这里上传
  141. </p>
  142. <i class="el-icon-plus"></i>
  143. <p style="margin-bottom: 37px">
  144. 图片格式:.jpg/.png/jpeg/bmp
  145. </p>
  146. </div>
  147. <input
  148. :disabled="statusPop === 2"
  149. id="inputs"
  150. type="file"
  151. ref="file"
  152. style="display: none"
  153. @change="getImgFile"
  154. />
  155. </label>
  156. <p style="color: #999999">请上传比例为16:9且小于2m的图片</p>
  157. </div>
  158. </el-col>
  159. <el-col :span="24">
  160. <header>重点考点文件:</header>
  161. <div class="imgBox">
  162. <label
  163. class="imgLabel"
  164. for="inputsFile"
  165. style="margin-bottom: 5px"
  166. >
  167. <div class="msPhoto" v-if="poppleData.fileUrls">
  168. <img
  169. style="width: 150px; height: 150px"
  170. src="http://iconfont.alicdn.com/t/657bb17a-f0f1-4dc2-9727-45df2b1ac4d9.png"
  171. alt="文件加载失败"
  172. />
  173. </div>
  174. <div class="imgbbx" v-else>
  175. <p style="margin-top: 49px">
  176. 点击添加或将文件拖拽到这里上传
  177. </p>
  178. <i class="el-icon-plus"></i>
  179. <p style="margin-bottom: 37px">支持扩展名:pdf</p>
  180. </div>
  181. <input
  182. :disabled="statusPop === 2"
  183. id="inputsFile"
  184. type="file"
  185. ref="filePdf"
  186. style="display: none"
  187. @change="getImgFilePDF"
  188. />
  189. </label>
  190. <p
  191. style="color: #999999"
  192. v-if="statusPop === 2 && poppleData.fileUrls"
  193. >
  194. <el-button type="success" size="mini"
  195. ><a
  196. style="color: #fff"
  197. :href="poppleData.fileUrls"
  198. target="_blank"
  199. >预览PDF</a
  200. ></el-button
  201. >
  202. </p>
  203. </div>
  204. </el-col>
  205. </el-col>
  206. <el-col :span="24">
  207. <el-col :span="24">
  208. <header>重点考点简介:</header>
  209. <div
  210. style="
  211. max-height: 300px;
  212. overflow-y: auto;
  213. border: 1px solid #e2e2e2;
  214. border-radius: 8px;
  215. padding: 13px;
  216. "
  217. v-if="statusPop === 2"
  218. v-html="poppleData.introduction"
  219. ></div>
  220. <editor
  221. v-else
  222. v-model="poppleData.introduction"
  223. :min-height="100"
  224. :max-height="300"
  225. :uploadStatus="uploadStatus"
  226. /> </el-col
  227. ></el-col>
  228. </el-col>
  229. </el-row>
  230. <div slot="footer" class="dialog-footer">
  231. <el-button @click="closeBefore">取 消</el-button>
  232. <el-button type="primary" @click="submitTabel">确 定</el-button>
  233. </div>
  234. </el-dialog>
  235. </div>
  236. </template>
  237. <script>
  238. import searchBox from "@/components/searchBox";
  239. import tableList from "@/components/tableList";
  240. import pagination from "@/components/pagination";
  241. import Editor from "@/components/Editor";
  242. export default {
  243. components: { searchBox, tableList, pagination, Editor },
  244. data() {
  245. return {
  246. uploadStatus: 2, //富文本组件传值
  247. loading: false, //当前表单加载是否加载动画
  248. navText: {
  249. title: "重点考点合计",
  250. index: 0,
  251. ch: "个",
  252. num: true,
  253. choice: true,
  254. backFatherBtn: {
  255. status: false,
  256. title: "未定义",
  257. },
  258. },
  259. tableSet: [
  260. {
  261. label: "重点考点名称",
  262. prop: "name",
  263. hidden: true,
  264. width: "180px",
  265. },
  266. {
  267. label: "类型",
  268. prop: "categoryName",
  269. hidden: true,
  270. width: "180px",
  271. },
  272. {
  273. label: "排序",
  274. prop: "sort",
  275. hidden: true,
  276. },
  277. {
  278. label: "启用状态",
  279. prop: "status",
  280. hidden: true,
  281. scope: "status",
  282. },
  283. ], //表头信息
  284. tableData: [], //表单数据
  285. total: 0, //一共多少条
  286. pageSize: 10, //每页多少条数据
  287. currentPage: 1, //当前页码
  288. formList: [
  289. {
  290. label: "重点考点名称",
  291. prop: "name",
  292. placeholder: "输入重点考点名称",
  293. },
  294. {
  295. label: "启用状态",
  296. prop: "status",
  297. scope: "select",
  298. placeholder: "选择启用状态",
  299. options: [
  300. {
  301. label: "启用",
  302. value: 1,
  303. },
  304. {
  305. label: "关闭",
  306. value: 0,
  307. },
  308. ],
  309. },
  310. {
  311. label: "重点考点类型",
  312. prop: "categoryId",
  313. scope: "cascader",
  314. placeholder: "选择重点考点类型",
  315. options: [],
  316. props: {
  317. label: "categoryName",
  318. value: "categoryId",
  319. },
  320. },
  321. ], //搜索栏
  322. optionsTion: [],
  323. optionsTeach: [],
  324. poppleData: {},
  325. fullscreen: false,
  326. fullscreenChild: false,
  327. dialogBox: false,
  328. innerVisible: false,
  329. statusPop: 0,
  330. beif: "", //备份数据
  331. beifpdf: "", //备份pdf
  332. int: -1,
  333. treeObj: {},
  334. priceTest: /(^[1-9]\d*(\.\d{1,2})?$)|(^0(\.\d{1,2})?$)/,
  335. };
  336. },
  337. computed: {
  338. numTime: function () {
  339. return function (res) {
  340. return Number(res / 3600).toFixed(2);
  341. };
  342. },
  343. },
  344. mounted() {
  345. this.search();
  346. this.initCascader();
  347. this.initTeacherList();
  348. },
  349. methods: {
  350. changeTeacherlist(options) {
  351. console.log(this.poppleData);
  352. },
  353. // 初始化教师列表
  354. initTeacherList() {
  355. var data = {
  356. status: "0,1",
  357. };
  358. this.$api.inquireCourseTeacher(data).then((res) => {
  359. console.log(res);
  360. this.optionsTeach = res.rows;
  361. });
  362. },
  363. //级联选择器数据
  364. initCascader() {
  365. this.$api
  366. .inquireProfessionClassification()
  367. .then((res) => {
  368. this.arrayChangeType(res.rows);
  369. })
  370. .catch((err) => {
  371. console.log(err);
  372. });
  373. },
  374. // 接口数据转换级联类型
  375. arrayChangeType(options) {
  376. let result = [];
  377. if (!Array.isArray(options)) {
  378. return result;
  379. }
  380. options.forEach((item) => {
  381. delete item.children;
  382. });
  383. let map = {};
  384. options.forEach((item) => {
  385. map[item.categoryId] = item;
  386. });
  387. options.forEach((item) => {
  388. let parent = map[item.pid];
  389. if (parent) {
  390. (parent.children || (parent.children = [])).push(item);
  391. } else {
  392. result.push(item);
  393. }
  394. });
  395. result = result.sort(this.sortBy("sort", true));
  396. result.forEach((item, index) => {
  397. if (item.children) {
  398. item.children.sort(this.sortBy("sort", true));
  399. }
  400. });
  401. this.formList.forEach((item, index) => {
  402. if (item.prop === "categoryId") {
  403. item.options = result;
  404. this.optionsTion = result;
  405. }
  406. });
  407. return result;
  408. },
  409. sortBy(attr, rev) {
  410. //第二个参数没有传递 默认升序排列
  411. if (rev == undefined) {
  412. rev = 1;
  413. } else {
  414. rev = rev ? 1 : -1;
  415. }
  416. return function (a, b) {
  417. a = a[attr];
  418. b = b[attr];
  419. if (a < b) {
  420. return rev * -1;
  421. }
  422. if (a > b) {
  423. return rev * 1;
  424. }
  425. return 0;
  426. };
  427. },
  428. getImgFile() {
  429. var self = this;
  430. var file = this.$refs.file.files[0];
  431. if (file === undefined) {
  432. self.$set(self.poppleData, "coverUrl", "");
  433. return;
  434. }
  435. if (file.size > 2 * 1024 * 1024) {
  436. this.$message.error("图片不得大于2MB");
  437. return;
  438. }
  439. var type = this.$refs.file.value.toLowerCase().split(".").splice(-1);
  440. if (
  441. type[0] != "jpg" &&
  442. type[0] != "png" &&
  443. type[0] != "jpeg" &&
  444. type[0] != "bmp"
  445. ) {
  446. this.$message.error("上传格式需为:.jpg/.png/.jpeg/bmp");
  447. this.$refs.file.value = "";
  448. return;
  449. }
  450. var reader = new FileReader();
  451. reader.readAsDataURL(file);
  452. reader.onload = function (ev) {
  453. self.$set(self.poppleData, "coverUrl", ev.target.result);
  454. };
  455. },
  456. getImgFilePDF() {
  457. var self = this;
  458. var file = this.$refs.filePdf.files[0];
  459. if (file === undefined) {
  460. self.$set(self.poppleData, "fileUrls", "");
  461. return;
  462. }
  463. var type = this.$refs.filePdf.value.toLowerCase().split(".").splice(-1);
  464. if (type[0] != "pdf") {
  465. this.$message.error("上传格式需为:pdf");
  466. this.$refs.filePdf.value = "";
  467. return;
  468. }
  469. var reader = new FileReader();
  470. reader.readAsDataURL(file);
  471. reader.onload = function (ev) {
  472. console.log(ev);
  473. self.$set(self.poppleData, "fileUrls", ev.target.result);
  474. };
  475. },
  476. // 详情
  477. infoMessage(options) {
  478. var data = options.fileId;
  479. this.$api.obtainExamNote(data).then((res) => {
  480. this.poppleData = res.data;
  481. this.beif = res.data.coverUrl;
  482. this.beifpdf = res.data.beifpdf;
  483. this.poppleData.teacherIds = res.data.teacherIds.split(",").map(Number);
  484. });
  485. this.statusPop = 2;
  486. this.dialogBox = true;
  487. },
  488. //确定提交
  489. async submitTabel() {
  490. if (this.statusPop === 2) {
  491. this.dialogBox = false;
  492. return;
  493. }
  494. var self = this;
  495. if (
  496. this.poppleData.categoryId === undefined ||
  497. this.poppleData.categoryId === null
  498. ) {
  499. this.$message.error("请选择重点考点分类");
  500. return;
  501. }
  502. if (!this.poppleData.name) {
  503. this.$message.error("请输入重点考点名称");
  504. return;
  505. }
  506. if (
  507. this.poppleData.teacherIds === undefined ||
  508. this.poppleData.teacherIds.length === 0
  509. ) {
  510. this.$message.error("请选择主讲名师");
  511. return;
  512. }
  513. if (this.poppleData.price === undefined) {
  514. this.$message.error("请输入价格");
  515. return;
  516. }
  517. if (!this.priceTest.test(this.poppleData.price)) {
  518. this.$message.error("请输入正确价格");
  519. this.poppleData.price = "";
  520. return;
  521. }
  522. if (this.poppleData.sort === undefined) {
  523. this.$message.error("请输入排序");
  524. return;
  525. }
  526. if (!this.poppleData.introduction) {
  527. this.$message.error("请输入重点考点简介");
  528. return;
  529. }
  530. if (this.poppleData.status === undefined) {
  531. this.$message.error("请选择是否启用该重点考点");
  532. return;
  533. }
  534. if (!this.poppleData.coverUrl || this.poppleData.coverUrl.length === 0) {
  535. this.$message.error("请上传重点考点封面");
  536. return;
  537. }
  538. if (!this.poppleData.fileUrls || this.poppleData.fileUrls.length === 0) {
  539. this.$message.error("请上传重点考点PDF文件");
  540. return;
  541. }
  542. var data = {
  543. categoryId: this.poppleData.categoryId,
  544. name: this.poppleData.name,
  545. introduction: this.poppleData.introduction,
  546. price: this.poppleData.price,
  547. status: this.poppleData.status,
  548. teacherIds: this.poppleData.teacherIds.join(","),
  549. sort: this.poppleData.sort,
  550. };
  551. if (this.statusPop === 1) {
  552. const awtimg = await this.imgUpload(2);
  553. data.coverUrl = this.poppleData.coverUrl;
  554. data.fileUrls = this.poppleData.fileUrls;
  555. this.$api
  556. .addExamNote(data)
  557. .then((res) => {
  558. this.$message.success("新增成功!");
  559. this.search();
  560. this.dialogBox = false;
  561. })
  562. .catch((err) => {
  563. this.$message.error(err);
  564. });
  565. } else if (this.statusPop === 0) {
  566. data.fileId = this.poppleData.fileId;
  567. if (
  568. this.poppleData.coverUrl === this.beif &&
  569. this.poppleData.coverUrl.length !== 0 &&
  570. this.poppleData.fileUrls === this.beifpdf &&
  571. this.poppleData.fileUrls.length !== 0
  572. ) {
  573. this.submitFun(data);
  574. } else {
  575. if (this.poppleData.coverUrl !== this.beif) {
  576. const awtimg = await this.imgUpload(2);
  577. data.coverUrl = this.poppleData.coverUrl;
  578. }
  579. if (this.poppleData.fileUrls !== this.beifpdf) {
  580. console.log(this.poppleData.fileUrls);
  581. console.log(this.beifpdf);
  582. const awtimg = await this.pdfUpload(6);
  583. data.fileUrls = this.poppleData.fileUrls;
  584. }
  585. this.submitFun(data);
  586. }
  587. }
  588. },
  589. submitFun(data) {
  590. this.$api
  591. .editExamNote(data)
  592. .then((res) => {
  593. this.$message.success("修改成功!");
  594. this.dialogBox = false;
  595. this.search();
  596. })
  597. .catch((err) => {
  598. this.$message.error(err);
  599. });
  600. },
  601. imgUpload(int) {
  602. var self = this;
  603. return new Promise((resolve, reject) => {
  604. this.$upload
  605. .upload(this.$refs.file.files[0], int)
  606. .then((res) => {
  607. self.poppleData.coverUrl = res;
  608. resolve();
  609. })
  610. .catch((err) => {
  611. self.$message.error("图片上传错误");
  612. });
  613. });
  614. },
  615. pdfUpload(int) {
  616. var self = this;
  617. return new Promise((resolve, reject) => {
  618. this.$upload
  619. .upload(this.$refs.filePdf.files[0], int)
  620. .then((res) => {
  621. self.poppleData.fileUrls = res;
  622. resolve();
  623. })
  624. .catch((err) => {
  625. self.$message.error("文件上传错误");
  626. });
  627. });
  628. },
  629. //添加
  630. addClick() {
  631. this.poppleData = {};
  632. this.statusPop = 1;
  633. this.dialogBox = true;
  634. },
  635. // 修改
  636. modify(options) {
  637. var data = options.fileId;
  638. this.$api.obtainExamNote(data).then((res) => {
  639. this.poppleData = res.data;
  640. this.beif = res.data.coverUrl;
  641. this.beifpdf = res.data.fileUrls;
  642. this.poppleData.teacherIds = res.data.teacherIds.split(",").map(Number);
  643. });
  644. this.statusPop = 0;
  645. this.dialogBox = true;
  646. },
  647. //删除
  648. del(options) {
  649. var self = this;
  650. this.$confirm("此操作将删除该考试重点, 是否继续?", "提示", {
  651. confirmButtonText: "确定",
  652. cancelButtonText: "取消",
  653. type: "warning",
  654. })
  655. .then(() => {
  656. console.log(options);
  657. var data = {
  658. categoryId: options.categoryId,
  659. fileId: options.fileId,
  660. name: options.name,
  661. sort: options.sort,
  662. introduction: options.introduction,
  663. teacherIds: options.teacherIds,
  664. status: -1,
  665. };
  666. this.$api
  667. .editExamNote(data)
  668. .then(() => {
  669. this.$message.success("删除成功!");
  670. this.search();
  671. })
  672. .catch((err) => {
  673. this.$message.error("删除失败:" + err);
  674. });
  675. })
  676. .catch(() => {
  677. this.$message({
  678. type: "info",
  679. message: "已取消删除",
  680. });
  681. });
  682. },
  683. sortBy(attr, rev) {
  684. //第二个参数没有传递 默认升序排列
  685. if (rev == undefined) {
  686. rev = 1;
  687. } else {
  688. rev = rev ? 1 : -1;
  689. }
  690. return function (a, b) {
  691. a = a[attr];
  692. b = b[attr];
  693. if (a < b) {
  694. return rev * -1;
  695. }
  696. if (a > b) {
  697. return rev * 1;
  698. }
  699. return 0;
  700. };
  701. },
  702. search(v) {
  703. if (v === undefined) {
  704. v = {
  705. status: "0,1",
  706. pageSize: this.pageSize,
  707. pageNum: this.currentPage,
  708. };
  709. }
  710. var data = {
  711. name: v.name,
  712. categoryId: v.categoryId,
  713. status: v.status === undefined ? "0,1" : v.status,
  714. pageSize: this.pageSize,
  715. pageNum: this.currentPage,
  716. };
  717. this.loading = true;
  718. this.$api
  719. .inquireExamNote(data)
  720. .then((res) => {
  721. res.rows.sort(this.sortBy("sort", true));
  722. this.tableData = res.rows;
  723. this.total = res.total;
  724. this.navText.index = res.total;
  725. this.loading = false;
  726. })
  727. .catch((err) => {
  728. this.loading = false;
  729. });
  730. },
  731. init() {
  732. this.search();
  733. },
  734. //窗口关闭
  735. closeBefore() {
  736. this.dialogBox = false;
  737. this.fullscreen = false;
  738. this.poppleData = {};
  739. },
  740. handleSizeChange(v) {
  741. this.pageSize = v;
  742. this.currentPage = 1;
  743. this.search();
  744. },
  745. handleCurrentChange(v) {
  746. this.currentPage = v;
  747. this.search();
  748. },
  749. },
  750. };
  751. </script>
  752. <style lang="less" scoped>
  753. /deep/.el-button {
  754. border-radius: 8px;
  755. }
  756. /deep/.el-dialog {
  757. border-radius: 8px;
  758. .el-dialog__header {
  759. padding: 0;
  760. .hearders {
  761. height: 40px;
  762. display: flex;
  763. align-items: center;
  764. justify-content: space-between;
  765. padding: 0px 18px 0px 20px;
  766. border-bottom: 1px solid #e2e2e2;
  767. .leftTitle {
  768. font-size: 14px;
  769. font-weight: bold;
  770. color: #2f4378;
  771. }
  772. .rightBoxs {
  773. display: flex;
  774. align-items: center;
  775. img {
  776. width: 14px;
  777. height: 14px;
  778. margin-left: 13px;
  779. cursor: pointer;
  780. }
  781. }
  782. }
  783. }
  784. .el-dialog__body {
  785. padding: 0;
  786. .contentBox {
  787. padding: 20px 20px 5px;
  788. .el-col {
  789. padding: 0px 20px;
  790. margin-bottom: 30px;
  791. header {
  792. margin-bottom: 6px;
  793. color: #2f4378;
  794. font-size: 14px;
  795. }
  796. }
  797. .juscon {
  798. float: none;
  799. width: 50%;
  800. margin: 0 auto;
  801. }
  802. }
  803. }
  804. .el-dialog__footer {
  805. padding: 0;
  806. .dialog-footer {
  807. padding: 0px 40px;
  808. height: 70px;
  809. border-top: 1px solid #e2e2e2;
  810. display: flex;
  811. align-items: center;
  812. justify-content: flex-end;
  813. }
  814. }
  815. }
  816. .imgBox {
  817. width: 100%;
  818. // height: 210px;
  819. border: 1px solid #e2e2e2;
  820. border-radius: 8px;
  821. padding: 8px 8px 3px;
  822. display: flex;
  823. flex-direction: column;
  824. align-items: center;
  825. .imgLabel {
  826. flex: 1;
  827. width: 100%;
  828. border: 1px dotted #e2e2e2;
  829. color: #999;
  830. font-size: 14px;
  831. cursor: pointer;
  832. border-radius: 8px;
  833. .msPhoto {
  834. display: flex;
  835. justify-content: center;
  836. align-items: center;
  837. max-width: 100%;
  838. max-height: 270px;
  839. img {
  840. max-width: 100%;
  841. max-height: 270px;
  842. }
  843. }
  844. .imgbbx {
  845. display: flex;
  846. flex-direction: column;
  847. align-items: center;
  848. justify-content: center;
  849. width: 100%;
  850. height: 100%;
  851. i {
  852. font-weight: bold;
  853. margin: 14px 0;
  854. font-size: 24px;
  855. }
  856. }
  857. }
  858. p {
  859. margin: 5px 0px;
  860. }
  861. }
  862. .el-radio-group {
  863. height: 40px;
  864. display: flex;
  865. align-items: center;
  866. }
  867. </style>