processSubmitDialog.vue 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751
  1. <template>
  2. <ele-modal
  3. custom-class="ele-dialog-form long-dialog-form"
  4. :centered="true"
  5. :visible="processSubmitDialogFlag"
  6. :title="title"
  7. append-to-body
  8. :close-on-click-modal="false"
  9. :width="isRight ? '800px' : '450px'"
  10. :before-close="cancel"
  11. :maxable="true"
  12. :resizable="true"
  13. >
  14. <div style="display: flex; height: 100%; justify-content: space-between">
  15. <div class="form-box">
  16. <!-- <div style="text-align: center; padding: 5px">-->
  17. <!-- {{ form.name }}-->
  18. <!-- </div>-->
  19. <fm-generate-form
  20. :preview="true"
  21. class="el-form-box"
  22. v-if="Object.keys(form?.formJson || {}).length !== 0"
  23. :data="jsonData"
  24. :value="form.valueJson"
  25. ref="generateForm"
  26. >
  27. <template v-slot:blank_adopzrdd="scope">
  28. <el-button
  29. type="primary"
  30. size="small"
  31. @click="addNewRow('blank_adopzrdd')"
  32. style="margin-bottom: 10px"
  33. >添加报销事项</el-button
  34. >
  35. <div
  36. v-for="(item, index) in scope.model.blank_adopzrdd"
  37. :key="index"
  38. >
  39. <div class="blank_adopzrdd">
  40. <span>{{ index + 1 }}报销事项:</span>
  41. <el-input
  42. v-model="scope.model.blank_adopzrdd[index].remark"
  43. type="textarea"
  44. style="width: calc(100% - 80px)"
  45. ></el-input>
  46. </div>
  47. <div class="blank_adopzrdd">
  48. <span @click="delNewRow('blank_adopzrdd', index)"
  49. ><i
  50. class="el-icon-delete"
  51. style="color: #f56c6c; cursor: pointer"
  52. ></i
  53. >金额:</span
  54. >
  55. <el-input
  56. v-model="scope.model.blank_adopzrdd[index].price"
  57. type="number"
  58. style="width: calc(100% - 80px)"
  59. @change="changePrice(scope.model.blank_adopzrdd)"
  60. ></el-input>
  61. </div>
  62. </div>
  63. </template>
  64. </fm-generate-form>
  65. </div>
  66. <div
  67. style="
  68. align-self: center;
  69. display: flex;
  70. color: #1890ff;
  71. cursor: pointer;
  72. width: 15px;
  73. "
  74. @click="() => (isRight = !isRight)"
  75. >
  76. <span
  77. style="
  78. align-self: center;
  79. transform: scale(1.5);
  80. "
  81. :class="isRight ? 'el-icon-caret-left' : 'el-icon-caret-right'"
  82. >
  83. </span>
  84. <span style="writing-mode: vertical-rl">选择流程</span>
  85. </div>
  86. <div style="flex: 1" v-if="isRight">
  87. <el-form
  88. ref="form"
  89. :rules="rules"
  90. class="el-form-box"
  91. :model="form"
  92. label-width="80px"
  93. >
  94. <el-row>
  95. <el-col :span="12">
  96. <el-form-item label="流程分类">
  97. <ele-tree-select
  98. @change="changeLCFL"
  99. clearable
  100. ref="processTypeRef"
  101. filterable
  102. :data="LCFLList"
  103. v-model="form.LCFL"
  104. childrenKey="children"
  105. valueKey="id"
  106. labelKey="name"
  107. placeholder="请选择"
  108. default-expand-all
  109. />
  110. </el-form-item>
  111. </el-col>
  112. <el-col :span="12">
  113. <el-form-item label="发起流程">
  114. <el-select
  115. filterable
  116. v-model="form.FQLC"
  117. @change="changeFQLC"
  118. style="width: 100%"
  119. >
  120. <el-option
  121. v-for="item in processList"
  122. :key="item.id"
  123. :value="item.id"
  124. :label="item.name"
  125. ></el-option>
  126. </el-select>
  127. </el-form-item>
  128. </el-col>
  129. </el-row>
  130. <el-row>
  131. <el-col :span="12">
  132. <el-form-item label="流程名称">
  133. <el-input v-model="form.name" clearable></el-input>
  134. </el-form-item>
  135. </el-col>
  136. <el-col :span="12">
  137. <el-form-item label="流程标识">
  138. <el-input v-model="form.key" disabled></el-input>
  139. </el-form-item>
  140. </el-col>
  141. </el-row>
  142. <headerTitle
  143. title="流程执行人/流程图"
  144. style="margin-top: 30px"
  145. ></headerTitle>
  146. <el-table
  147. :data="datasource"
  148. height="150px"
  149. border
  150. style="margin-bottom: 10px"
  151. >
  152. <el-table-column
  153. label="任务节点"
  154. align="center"
  155. prop="taskDefinitionName"
  156. width="140"
  157. fixed
  158. />
  159. <el-table-column
  160. label="执行人"
  161. align="center"
  162. prop="options"
  163. min-width="140px"
  164. >
  165. <template v-slot="scope">
  166. <div
  167. v-if="scope.row.type !== 60 && scope.row.options.length > 0"
  168. >
  169. <el-tag
  170. size="medium"
  171. :key="option"
  172. v-for="option in scope.row.options"
  173. >
  174. {{ getAssignRuleOptionName(scope.row, option) }}
  175. </el-tag>
  176. </div>
  177. <el-tag size="medium" v-if="scope.row.type === 60">
  178. {{ getAssignRuleOptionName(scope.row) }}
  179. </el-tag>
  180. </template>
  181. </el-table-column>
  182. </el-table>
  183. <my-process-viewer
  184. style="min-width: 100%; height: 200px"
  185. key="designer"
  186. v-model="bpmnXML"
  187. />
  188. </el-form>
  189. </div>
  190. </div>
  191. <div slot="footer">
  192. <el-form :model="form">
  193. <el-form-item label="通知人:">
  194. <el-button
  195. style="float: left; margin-top: 5px"
  196. icon="el-icon-circle-plus-outline"
  197. round
  198. @click="handleEditDataScope"
  199. ></el-button>
  200. <div style="display: flex; flex-direction: row; flex-wrap: wrap">
  201. <el-tag
  202. style="float: left; margin: 5px 5px 0 5px"
  203. v-for="(item, index) in form.noticeScope"
  204. :key="item.name"
  205. effect="plain"
  206. closable
  207. :title="item.name"
  208. @close="handleCloseTag(index)"
  209. >
  210. {{
  211. item.name.length > 3
  212. ? item.name[0] + item.name[1] + item.name[2] + '...'
  213. : item.name
  214. }}
  215. </el-tag>
  216. </div>
  217. <!-- <ele-tree-select-->
  218. <!-- @change="handleTreeChange"-->
  219. <!-- filterable-->
  220. <!-- style="width: 100%"-->
  221. <!-- ref="treeSelect"-->
  222. <!-- multiple-->
  223. <!-- clearable-->
  224. <!-- :data="treeData"-->
  225. <!-- v-model="treeList"-->
  226. <!-- placeholder="请选择"-->
  227. <!-- valueKey="id"-->
  228. <!-- labelKey="name"-->
  229. <!-- :checkStrictly="true"-->
  230. <!-- />-->
  231. </el-form-item>
  232. </el-form>
  233. <!-- <el-button-->
  234. <!-- type="primary"-->
  235. <!-- size="small"-->
  236. <!-- v-if="active == 0"-->
  237. <!-- @click="() => ((active = 1), (isRight = true))"-->
  238. <!-- >下一步-->
  239. <!-- </el-button>-->
  240. <!-- <el-button-->
  241. <!-- type="primary"-->
  242. <!-- size="small"-->
  243. <!-- v-if="active == 1"-->
  244. <!-- @click="() => (active = 0)"-->
  245. <!-- >上一步-->
  246. <!-- </el-button>-->
  247. <el-button type="primary" size="small" @click="submit">提交</el-button>
  248. <el-button size="small" @click="cancel">关闭</el-button>
  249. <!-- <visibility-range-dialog-->
  250. <!-- :visibilityRangeDialogFlag.sync="visibilityRangeDialogFlag"-->
  251. <!-- v-if="visibilityRangeDialogFlag"-->
  252. <!-- @getTreeList="getTreeList"-->
  253. <!-- ref="visibilityRangeDialogRef"-->
  254. <!-- ></visibility-range-dialog>-->
  255. <staffSelection
  256. ref="staffSelection"
  257. @confirm="getTreeList"
  258. ></staffSelection>
  259. </div>
  260. </ele-modal>
  261. </template>
  262. <script>
  263. import {
  264. getModelPage,
  265. getProcessDefinitionBpmnXML,
  266. getProcessDefinitionInfo,
  267. getTaskAssignRuleList,
  268. listAllUserBind,
  269. listSimpleUserGroups,
  270. processInstanceCreateAPI
  271. } from './api';
  272. import { treeClassifyCodeEnum } from '@/enum/dict';
  273. import { listRoles } from '@/api/system/role';
  274. import { listOrganizations } from '@/api/system/organization';
  275. import dictMixins from '@/mixins/dictMixins';
  276. import { getByCode } from '@/api/system/dictionary-data';
  277. import { getGroupUserTree, getProduceTreeByCode } from '@/api/main';
  278. import visibilityRangeDialog from './visibilityRangeDialog.vue';
  279. import { getModel } from '@/api/bpm/model';
  280. import { getProcessDefinitionList } from '@/api/bpm/definition';
  281. import { getToken } from '@/utils/token-util';
  282. import { mapGetters } from 'vuex';
  283. import staffSelection from '@/components/staffSelection/staffSelection.vue';
  284. import dayjs from 'dayjs';
  285. import { number } from 'echarts';
  286. import { del } from 'vue';
  287. export default {
  288. name: 'processSubmitDialog',
  289. components: { visibilityRangeDialog, staffSelection },
  290. mixins: [dictMixins],
  291. props: {
  292. processSubmitDialogFlag: {
  293. type: Boolean,
  294. default: false
  295. }
  296. },
  297. watch: {
  298. filterText(val) {
  299. this.$refs.tree.filter(val);
  300. }
  301. },
  302. data() {
  303. return {
  304. visibilityRangeDialogFlag: false,
  305. isRight: false,
  306. jsonData: {},
  307. form: {
  308. LCFL: '',
  309. FQLC: '',
  310. processDefinitionId: '',
  311. name: '',
  312. businessId: '',
  313. noticeScope: [],
  314. formJson: {},
  315. valueJson: {},
  316. businessKey: ''
  317. },
  318. title: '',
  319. active: 0,
  320. bpmnXML: null,
  321. filterText: null,
  322. treeList: [],
  323. treeData: [],
  324. defaultProps: {
  325. children: 'children',
  326. label: 'name'
  327. },
  328. LCFLList: [],
  329. processList: [],
  330. datasource: [],
  331. roleOptions: [],
  332. deptOptions: [],
  333. deptTreeOptions: [],
  334. postOptions: [],
  335. userOptions: [],
  336. userGroupOptions: [],
  337. dictList: {},
  338. rules: {},
  339. editForm: {
  340. start: '',
  341. end: '',
  342. days: ''
  343. }
  344. };
  345. },
  346. computed: {
  347. ...mapGetters(['user'])
  348. },
  349. async created() {
  350. let typeObj = await getProduceTreeByCode(
  351. treeClassifyCodeEnum['PROCESSTYPE']
  352. );
  353. // await this.getTreeData();
  354. this.LCFLList = typeObj[0].children;
  355. // 获得角色列表
  356. this.roleOptions = [];
  357. listRoles({
  358. current: 1,
  359. size: 9999
  360. }).then((data) => {
  361. this.roleOptions.push(...data.list);
  362. });
  363. // 获得部门列表
  364. this.deptOptions = [];
  365. this.deptTreeOptions = [];
  366. listOrganizations().then((data) => {
  367. this.deptOptions.push(...data);
  368. this.deptTreeOptions.push(...this.handleTree(data, 'id'));
  369. });
  370. // 获得岗位列表 暂无岗位概念
  371. this.postOptions = [];
  372. /*listSimplePosts().then(response => {
  373. this.postOptions.push(...response.data);
  374. });*/
  375. // 获得用户列表
  376. this.userOptions = [];
  377. listAllUserBind().then((data) => {
  378. this.userOptions.push(...data);
  379. });
  380. // 获得用户组列表
  381. this.userGroupOptions = [];
  382. listSimpleUserGroups().then((response) => {
  383. this.userGroupOptions.push(...response);
  384. });
  385. //this.dictEnum['工作流任务分配自定义脚本']
  386. await this.getDictList(this.dictEnum['工作流任务分配自定义脚本']);
  387. await this.getDictList(this.dictEnum['工种类型']);
  388. },
  389. mounted() {
  390. //this.isRight = false
  391. },
  392. methods: {
  393. async addNewRow(key) {
  394. console.log(key);
  395. let data = await this.$refs.generateForm.getData(false);
  396. data[key].push({
  397. price: '',
  398. remark: ''
  399. });
  400. this.$refs.generateForm.setData({
  401. key: data[key]
  402. });
  403. },
  404. async delNewRow(key, index) {
  405. let data = await this.$refs.generateForm.getData(false);
  406. data[key] = data[key].filter((item, index1) => index1 != index);
  407. this.$refs.generateForm.setData({
  408. [key]: data[key]
  409. });
  410. this.changePrice(data[key]);
  411. },
  412. changePrice(data) {
  413. let num = 0;
  414. data.forEach((item) => {
  415. num += Number(item.price);
  416. });
  417. this.$refs.generateForm.setData({
  418. input_jd9ouzyh: num
  419. });
  420. },
  421. async init(row = {}) {
  422. this.title = row.name; //'新建' + row.name + '单';
  423. this.form = _.cloneDeep(row);
  424. this.form.formId = row.id;
  425. this.$set(this.form, 'noticeScope', []);
  426. this.$set(this.form, 'LCFL', '');
  427. this.$set(this.form, 'FQLC', '');
  428. this.$set(this.form, 'name', '');
  429. this.$set(this.form, 'key', '');
  430. this.$set(this.form, 'valueJson', {});
  431. this.jsonData = JSON.parse(this.form.formJson.makingJson);
  432. console.log(this.jsonData);
  433. this.jsonData.config.dataSource &&
  434. this.jsonData.config.dataSource.forEach((item) => {
  435. item.headers = {
  436. Authorization: getToken()
  437. };
  438. // item.url = item.url && item.url.replace('/api', this.APIUrl);
  439. });
  440. this.jsonData.list.forEach((item) => {
  441. if (item.type == 'deptAndUserCascader') {
  442. }
  443. if (item.type == 'deptCascader') {
  444. if (item.options.isDefaultLoginUser) {
  445. this.form.valueJson[item.model] = this.user.info.groupIdList;
  446. }
  447. }
  448. if (item.type == 'userSelect') {
  449. if (item.options.isDefaultLoginUser) {
  450. this.form.valueJson[item.model] = this.user.info.userId;
  451. }
  452. }
  453. if (item.type == 'imgupload') {
  454. // this.form.valueJson[item.model].length &&
  455. // this.form.valueJson[item.model].forEach((item) => {
  456. // //item.objectUrl = this.APIUrl +'/kd-aiot' + item.storePath
  457. // // item.objectUrl = item.url;
  458. // // console.log(item);
  459. // });
  460. }
  461. });
  462. await this.getProcessDefinitionBpmnXMLInfo(this.form.processModelId);
  463. await this.getTaskAssignRuleListInfo({
  464. modelId: this.form.processModelId,
  465. processDefinitionId: this.form.processDefinitionId
  466. });
  467. await this.getDefaultInfo(row.processModelId);
  468. },
  469. async getDefaultInfo(businessKey) {
  470. let info = await getModel(businessKey);
  471. //let info = await getProcessDefinitionInfo({ id: businessKey });
  472. this.form.LCFL = info?.category;
  473. this.form.FQLC = info?.id;
  474. this.form.name = this.title;
  475. this.form.key = info?.key;
  476. if (this.form.LCFL) await this.getProcessList(this.form.LCFL);
  477. },
  478. async getProcessList(val) {
  479. let params = {
  480. pageNo: 1,
  481. pageSize: 999,
  482. processTypeId: val
  483. };
  484. const { list } = await getModelPage(params);
  485. this.processList = list.filter((item) => item.processDefinition);
  486. },
  487. async getProcessDefinitionBpmnXML(val) {
  488. this.bpmnXML = await getProcessDefinitionBpmnXML(val);
  489. },
  490. async getProcessDefinitionBpmnXMLInfo(val) {
  491. // 加载流程图
  492. let res = await getModel(val);
  493. this.bpmnXML = res.bpmnXml;
  494. },
  495. async getTaskAssignRuleListInfo(find) {
  496. this.datasource = await getTaskAssignRuleList({
  497. modelId: find.modelId,
  498. processDefinitionId: find.processDefinitionId
  499. });
  500. },
  501. handleEditDataScope() {
  502. this.$refs.staffSelection.open(this.form.noticeScope);
  503. // this.visibilityRangeDialogFlag = true;
  504. // this.$nextTick(() => {
  505. // this.$refs.visibilityRangeDialogRef.init(this.form);
  506. // });
  507. },
  508. getTreeList(list) {
  509. list.forEach((item) => {
  510. item.type = 1;
  511. });
  512. this.form.noticeScope = list;
  513. },
  514. handleCloseTag(index) {
  515. this.form.noticeScope.splice(index, 1);
  516. },
  517. getAssignRuleOptionName(row, option) {
  518. if (row.type == 10) {
  519. for (const roleOption of this.roleOptions) {
  520. if (roleOption.id === option) {
  521. return roleOption.name;
  522. }
  523. }
  524. } else if (row.type === 20 || row.type === 21) {
  525. for (const deptOption of this.deptOptions) {
  526. if (deptOption.id === option) {
  527. return deptOption.name;
  528. }
  529. }
  530. } else if (row.type === 22) {
  531. option = option + ''; // 转换成 string
  532. return this.getDictV(this.dictEnum['工种类型'], option);
  533. } else if (row.type === 30 || row.type === 31 || row.type === 32) {
  534. for (const userOption of this.userOptions) {
  535. if (userOption.id === option) {
  536. return userOption.nickname || userOption.name;
  537. }
  538. }
  539. } else if (row.type === 40) {
  540. for (const userGroupOption of this.userGroupOptions) {
  541. if (userGroupOption.id === option) {
  542. return userGroupOption.name;
  543. }
  544. }
  545. } else if (row.type === 50) {
  546. option = option + ''; // 转换成 string
  547. return this.getDictV(
  548. this.dictEnum['工作流任务分配自定义脚本'],
  549. option
  550. );
  551. } else if (row.type === 60) {
  552. return row.variableName;
  553. }
  554. return '未知(' + option + ')';
  555. },
  556. async getTreeData() {
  557. this.treeData = await getGroupUserTree();
  558. },
  559. filterNode(value, data) {
  560. if (!value) return true;
  561. return data.name.indexOf(value) !== -1;
  562. },
  563. /**
  564. * 构造树型结构数据
  565. * @param {*} data 数据源
  566. * @param {*} id id字段 默认 'id'
  567. * @param {*} parentId 父节点字段 默认 'parentId'
  568. * @param {*} children 孩子节点字段 默认 'children'
  569. * @param {*} rootId 根Id 默认 0
  570. */
  571. handleTree(data, id, parentId, children, rootId) {
  572. id = id || 'id';
  573. parentId = parentId || 'parentId';
  574. children = children || 'children';
  575. rootId =
  576. rootId ||
  577. Math.min.apply(
  578. Math,
  579. data.map((item) => {
  580. return item[parentId];
  581. })
  582. ) ||
  583. 0;
  584. //对源数据深度克隆
  585. const cloneData = JSON.parse(JSON.stringify(data));
  586. //循环所有项
  587. const treeData = cloneData.filter((father) => {
  588. let branchArr = cloneData.filter((child) => {
  589. //返回每一项的子级数组
  590. return father[id] == child[parentId];
  591. });
  592. branchArr.length > 0 ? (father.children = branchArr) : '';
  593. //返回第一层
  594. return father[parentId] == rootId;
  595. });
  596. return treeData !== '' ? treeData : data;
  597. },
  598. getDictV(code, val) {
  599. if (!this.dictList[code]) return '';
  600. return this.dictList[code].find((item) => item.value == val)?.label;
  601. },
  602. async getDictList(code) {
  603. let { data: res } = await getByCode(code);
  604. this.dictList[code] = res.map((item) => {
  605. let values = Object.keys(item);
  606. return {
  607. value: values[0],
  608. label: item[values[0]]
  609. };
  610. });
  611. },
  612. generateFormValid(validate = true) {
  613. return this.$refs.generateForm.getData(validate).then((data) => {
  614. return data;
  615. });
  616. },
  617. handleTreeChange() {
  618. this.$nextTick(() => {
  619. this.form.noticeScope =
  620. this.$refs.treeSelect.$refs.tree.getCheckedNodes();
  621. console.log(this.form.noticeScope);
  622. });
  623. },
  624. async changeLCFL(val) {
  625. this.bpmnXML = null;
  626. this.form.processDefinitionId = null;
  627. this.form.FQLC = null;
  628. await this.getProcessList(val);
  629. },
  630. async changeFQLC(val) {
  631. if (!val) return;
  632. let find = this.processList.find((item) => item.id === val) || {};
  633. this.form.name = find.name;
  634. this.form.key = find.key;
  635. this.form.processDefinitionId = find.processDefinition.id;
  636. this.form.processModelId = val;
  637. await this.getProcessDefinitionBpmnXML(find.processDefinition.id);
  638. await this.getTaskAssignRuleListInfo({
  639. modelId: find.id,
  640. processDefinitionId: find.processDefinition.id
  641. });
  642. },
  643. async submit() {
  644. this.form.valueJson = await this.generateFormValid();
  645. this.form.processType = '1';
  646. await processInstanceCreateAPI({
  647. ...this.form,
  648. variables: { ...this.form.valueJson }
  649. });
  650. this.$message('提交审核成功');
  651. this.$emit('reload');
  652. this.cancel();
  653. },
  654. cancel() {
  655. this.$emit('update:processSubmitDialogFlag', false);
  656. },
  657. getDays(start, end) {
  658. const startDay = dayjs(start);
  659. const endDay = dayjs(end);
  660. const diffInMilliseconds = endDay.diff(startDay);
  661. // 计算天数
  662. const days = Math.floor(diffInMilliseconds / (1000 * 60 * 60 * 24));
  663. // 计算剩余小时数
  664. const hours = Math.floor(
  665. (diffInMilliseconds % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)
  666. );
  667. // 计算剩余分钟数
  668. const minutes = Math.floor(
  669. (diffInMilliseconds % (1000 * 60 * 60)) / (1000 * 60)
  670. );
  671. // 计算剩余秒数
  672. const seconds = Math.floor((diffInMilliseconds % (1000 * 60)) / 1000);
  673. let result = '';
  674. if (days > 0) result += `${days} 天 `;
  675. if (hours > 0) result += `${hours} 小时 `;
  676. if (minutes > 0) result += `${minutes} 分钟 `;
  677. if (seconds > 0) result += `${seconds} 秒`;
  678. return result.trim();
  679. }
  680. }
  681. };
  682. </script>
  683. <style scoped lang="scss">
  684. .box {
  685. display: flex;
  686. height: 450px;
  687. .left-box {
  688. width: 55%;
  689. border-right: 1px solid #e2e4e7;
  690. padding-right: 15px;
  691. height: 100%;
  692. .el-tree {
  693. height: 85%;
  694. overflow-y: auto;
  695. }
  696. }
  697. .right-box {
  698. flex: 1;
  699. padding-left: 20px;
  700. height: 100%;
  701. .right-box-item {
  702. margin-top: 5px;
  703. display: flex;
  704. justify-content: space-between;
  705. align-items: center;
  706. }
  707. }
  708. }
  709. .form-box {
  710. max-height: 500px;
  711. min-width: 400px;
  712. overflow: auto;
  713. background: #4298fd0d;
  714. }
  715. ::v-deep .el-dialog {
  716. min-width: 400px;
  717. .el-dialog__header {
  718. background: #1890ffd6;
  719. }
  720. .el-dialog__title,
  721. .el-dialog__close {
  722. color: #ffffff;
  723. }
  724. }
  725. .blank_adopzrdd {
  726. display: flex;
  727. align-items: center;
  728. > span {
  729. display: inline-block;
  730. width: 80px;
  731. }
  732. margin-bottom: 10px;
  733. }
  734. </style>