index.vue 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794
  1. <template>
  2. <div class="app-container">
  3. <el-row :gutter="10">
  4. <!--机构数据-->
  5. <!-- <el-col :span="4" :xs="24">
  6. <org-tree
  7. v-model="queryParams.orgId"
  8. @defaultKey="getDefaultKey"
  9. @checkChange="checkChange"
  10. @click="clickTreeNode"
  11. :defaultCheckSub="false"
  12. hangsheTree
  13. ></org-tree>
  14. </el-col> -->
  15. <el-col :span="24" :xs="24">
  16. <div class="main-right-box">
  17. <!-- 搜索条件 -->
  18. <div class="main-search-box">
  19. <el-form
  20. :model="queryParams"
  21. ref="search"
  22. size="small"
  23. :inline="true"
  24. v-show="showSearch"
  25. >
  26. <el-form-item label="行社名称">
  27. <org-tree
  28. v-model="queryParams.orgId"
  29. @defaultKey="getDefaultKey"
  30. @checkChange="checkChange"
  31. @click="clickTreeNode"
  32. :defaultCheckSub="false"
  33. hangsheTree
  34. ref="orgTree"
  35. ></org-tree>
  36. </el-form-item>
  37. <el-form-item prop="planType" label="任务类型">
  38. <el-select
  39. prop="planType"
  40. label="任务类型"
  41. v-model="queryParams.planType"
  42. placeholder="请选择任务类型"
  43. clearable
  44. >
  45. <el-option
  46. v-for="dict in dict.type.resumption_plan_type"
  47. :key="dict.value"
  48. :label="dict.label"
  49. :value="dict.value"
  50. />
  51. </el-select>
  52. </el-form-item>
  53. <el-form-item prop="resumptionRole" label="履职人员">
  54. <el-select
  55. @visible-change="getRolesByOrg"
  56. prop="resumptionRole"
  57. label="履职人员"
  58. v-model="queryParams.resumptionRole"
  59. placeholder="请选择用户角色"
  60. clearable
  61. >
  62. <el-option
  63. v-for="dict in resumptionRoles"
  64. :key="dict.index"
  65. :label="dict.roleName"
  66. :value="dict.id"
  67. />
  68. </el-select>
  69. </el-form-item>
  70. <el-form-item prop="planCycle" label="任务周期">
  71. <el-select
  72. prop="planCycle"
  73. label="任务周期"
  74. v-model="queryParams.planCycle"
  75. placeholder="请选择任务周期"
  76. clearable
  77. >
  78. <el-option
  79. v-for="item in dict.type.resumption_plan_cycle"
  80. :key="item.value"
  81. :label="item.label"
  82. :value="item.value"
  83. >
  84. </el-option>
  85. </el-select>
  86. </el-form-item>
  87. <el-form-item prop="planStatus" label="任务状态">
  88. <el-select
  89. prop="planStatus"
  90. label="任务状态"
  91. v-model="queryParams.planStatus"
  92. placeholder="请选择任务状态"
  93. clearable
  94. >
  95. <el-option
  96. v-for="item in dict.type.resumption_plan_status"
  97. :key="item.value"
  98. :label="item.label"
  99. :value="item.value"
  100. >
  101. </el-option>
  102. </el-select>
  103. <!-- <el-switch v-model="queryParams.planStatus" active-value="1" inactive-value="0"></el-switch> -->
  104. </el-form-item>
  105. <el-form-item prop="planName" label="任务名称">
  106. <el-input
  107. v-model="queryParams.planName"
  108. :maxlength="50"
  109. name="planName"
  110. placeholder="请输入任务名称"
  111. clearable
  112. />
  113. </el-form-item>
  114. <!-- <el-row :gutter="10" >
  115. <el-col :span="1.5"> </el-col>
  116. </el-row> -->
  117. </el-form>
  118. <el-row>
  119. <el-button
  120. type="primary"
  121. icon="el-icon-search"
  122. size="mini"
  123. @click="getList"
  124. >搜索</el-button
  125. >
  126. <el-button
  127. type="primary"
  128. icon="el-icon-refresh"
  129. size="mini"
  130. @click="resetQuery"
  131. >重置</el-button
  132. >
  133. <el-button
  134. type="primary"
  135. icon="el-icon-plus"
  136. size="mini"
  137. @click="handleAdd()"
  138. v-hasPermi="['core:plan:edit']"
  139. >新增任务</el-button
  140. >
  141. <right-toolbar
  142. :showSearch.sync="showSearch"
  143. @queryTable="getList"
  144. ></right-toolbar>
  145. </el-row>
  146. </div>
  147. <!-- 按纽 -->
  148. <el-table
  149. border
  150. height="594"
  151. size="small"
  152. v-loading="loading"
  153. :data="pageData"
  154. @selection-change="handleSelectionChange"
  155. row-key="id"
  156. >
  157. <el-table-column
  158. label="序号"
  159. fixed
  160. type="index"
  161. align="center"
  162. width="80px"
  163. v-if="columns[0].visible"
  164. ></el-table-column>
  165. <el-table-column
  166. prop="planName"
  167. label="任务名称"
  168. width="250px"
  169. :show-overflow-tooltip="true"
  170. v-if="columns[1].visible"
  171. ></el-table-column>
  172. <el-table-column
  173. prop="planType"
  174. label="任务类型"
  175. align="center"
  176. width="180px"
  177. v-if="columns[2].visible"
  178. >
  179. <template slot-scope="r"
  180. >{{
  181. getLabel(dict.type.resumption_plan_type, `${r.row.planType}`)
  182. }}
  183. </template>
  184. </el-table-column>
  185. <el-table-column
  186. prop="planCreateOrgName"
  187. label="创建机构"
  188. align="center"
  189. width="180px"
  190. v-if="columns[3].visible"
  191. >
  192. <!-- <template slot-scope="r"
  193. >{{ getLabel(dict.type.sys_org_type, r.row.execOrgType) }}
  194. </template> -->
  195. </el-table-column>
  196. <el-table-column
  197. prop="planOfOrgName"
  198. label="行社名称"
  199. align="center"
  200. width="180px"
  201. v-if="columns[4].visible"
  202. ></el-table-column>
  203. <el-table-column
  204. prop="execOrgType"
  205. label="机构类型"
  206. align="center"
  207. width="180px"
  208. v-if="columns[5].visible"
  209. >
  210. <template slot-scope="r"
  211. >{{ getLabel(dict.type.sys_org_type, `${r.row.execOrgType}`) }}
  212. </template>
  213. </el-table-column>
  214. <el-table-column
  215. prop="roleNames"
  216. label="履职人员"
  217. align="center"
  218. width="180px"
  219. v-if="columns[6].visible"
  220. ></el-table-column>
  221. <el-table-column
  222. prop="planCycle"
  223. label="任务周期"
  224. align="center"
  225. width="180px"
  226. v-if="columns[7].visible"
  227. >
  228. <template slot-scope="r"
  229. >{{
  230. getLabel(
  231. dict.type.resumption_plan_cycle,
  232. `${r.row.planCycle}`
  233. )
  234. }}
  235. </template>
  236. </el-table-column>
  237. <el-table-column
  238. prop="planExec"
  239. label="任务时间"
  240. align="center"
  241. width="180px"
  242. v-if="columns[8].visible"
  243. >
  244. <template slot-scope="r"
  245. >{{
  246. getLabel(dict.type.resumption_plan_exec, `${r.row.planExec}`)
  247. }}
  248. </template>
  249. </el-table-column>
  250. <el-table-column
  251. prop="count"
  252. label="任务次数"
  253. align="center"
  254. width="180px"
  255. v-if="columns[7].visible"
  256. ></el-table-column>
  257. <el-table-column
  258. prop="planStatus"
  259. label="任务状态"
  260. align="center"
  261. width="180px"
  262. v-if="columns[10].visible"
  263. >
  264. <template slot-scope="r"
  265. >{{
  266. getLabel(
  267. dict.type.resumption_plan_status,
  268. `${r.row.planStatus}`
  269. )
  270. }}
  271. </template>
  272. </el-table-column>
  273. <el-table-column
  274. prop="updateName"
  275. label="修改人"
  276. align="center"
  277. width="180px"
  278. v-if="false"
  279. ></el-table-column>
  280. <el-table-column fixed="right" width="210" label="操作">
  281. <template slot-scope="r">
  282. <el-button
  283. size="mini"
  284. type="text"
  285. icon="el-icon-arrow-down"
  286. v-if="showPublish(r.row)"
  287. @click="showDialogDistribute(r.row)"
  288. v-hasPermi="['core:plan:distribute']"
  289. >下发</el-button
  290. >
  291. <el-button
  292. size="mini"
  293. type="text"
  294. icon="el-icon-top-left"
  295. v-if="showWithDraw(r.row)"
  296. @click="chhuile(r.row)"
  297. v-hasPermi="['core:plan:distribute']"
  298. >撤回</el-button
  299. >
  300. <el-button
  301. v-if="eqOrg(r.row)"
  302. size="mini"
  303. type="text"
  304. icon="el-icon-edit-outline"
  305. @click="onEdit(r.row.id)"
  306. v-hasPermi="['core:plan:edit']"
  307. >编辑</el-button
  308. >
  309. <el-button
  310. v-if="showDelete(r.row)"
  311. size="mini"
  312. type="text"
  313. icon="el-icon-delete"
  314. @click="onDel(r.row)"
  315. v-hasPermi="['core:plan:delete']"
  316. >删除</el-button
  317. >
  318. </template>
  319. </el-table-column>
  320. </el-table>
  321. <pagination
  322. v-show="total > 0"
  323. :total="total"
  324. :page.sync="queryParams.pageNum"
  325. :limit.sync="queryParams.pageSize"
  326. @pagination="getList"
  327. />
  328. </div>
  329. </el-col>
  330. </el-row>
  331. <dialog-edit
  332. ref="editDialog"
  333. @success="getList()"
  334. :orgTypeOptions="orgTypeOptions"
  335. :ruleTypeOptions="dict.type.rule_type"
  336. ></dialog-edit>
  337. <DialogDistribute ref="dialogDistribute" @select="sel"></DialogDistribute>
  338. <DialogThreeState ref="DialogThreeState"> </DialogThreeState>
  339. </div>
  340. </template>
  341. <script>
  342. import DialogDistribute from "@/views/resumption/plan/distribute.vue";
  343. import OrgTree from "@/components/orgTree/orgQuerySelector.vue";
  344. import { mapState, mapMutations, mapGetters } from "vuex";
  345. import DialogEdit from "./dialog.edit";
  346. import * as api from "@/api/resumption/plan";
  347. import { statusOptions, getLabel } from "./../../commonOption";
  348. import { allRole } from "@/api/system/role";
  349. import DialogThreeState from "@/components/message/threeStateMessageBox.vue";
  350. export default {
  351. name: "resumptionplan",
  352. dicts: [
  353. "sys_org_type",
  354. "rule_type",
  355. "resumption_plan_type",
  356. "resumption_plan_cycle",
  357. "resumption_plan_status",
  358. "resumption_plan_exec",
  359. ],
  360. components: {
  361. DialogEdit,
  362. OrgTree,
  363. DialogDistribute,
  364. DialogThreeState,
  365. },
  366. data() {
  367. const { params, query } = this.$route;
  368. return {
  369. isShow: false,
  370. loading: false,
  371. ids: [],
  372. // 非单个禁用
  373. single: true,
  374. // 非多个禁用
  375. multiple: true,
  376. // 显示搜索条件
  377. showSearch: true,
  378. resumptionRoles: [],
  379. total: 0,
  380. queryParams: {
  381. orgId: null,
  382. planType: null,
  383. resumptionRole: null,
  384. planCycle: null,
  385. planStatus: null,
  386. planName: null,
  387. pageNum: 1,
  388. pageSize: 10,
  389. checkSub: false,
  390. roleList: [],
  391. ...query,
  392. },
  393. pageData: [],
  394. // 列信息
  395. columns: [
  396. { key: 0, label: `序号`, visible: true },
  397. { key: 1, label: `计划名称`, visible: true },
  398. { key: 2, label: `计划类型`, visible: true },
  399. { key: 3, label: `计划创建机构`, visible: true },
  400. { key: 4, label: `计划所属机构`, visible: true },
  401. { key: 5, label: `履职机构类型`, visible: true },
  402. { key: 6, label: `履职角色`, visible: true },
  403. { key: 7, label: `履职周期`, visible: true },
  404. // { key: 8, label: `履职次数`, visible: true },
  405. { key: 8, label: `履职时间`, visible: true },
  406. { key: 9, label: `修改人`, visible: true },
  407. { key: 10, label: `计划状态`, visible: true },
  408. ],
  409. };
  410. },
  411. props: {},
  412. watch: {},
  413. computed: {
  414. ...mapGetters(["orgId", "orgName"]),
  415. orgTypeOptions(){
  416. if(!this.dict || !this.dict.type.sys_org_type==null) {
  417. return []
  418. }
  419. return this.dict.type.sys_org_type.filter(t=>!["1","2","7","8"].includes(t.value))
  420. }
  421. },
  422. methods: {
  423. ...mapMutations([]),
  424. //判断是否跟当前用户同机构
  425. eqOrg(row) {
  426. // console.log(row.planOfOrgId,"row.planOfOrgId");
  427. // console.log(this.orgId,"this.orgId");
  428. if (
  429. row != null &&
  430. row != undefined &&
  431. (row.planCreateOrgId == this.orgId ||
  432. (row.planOfOrgType == 3 && row.planOfOrgId == this.orgId))
  433. ) {
  434. return true;
  435. }
  436. return false;
  437. },
  438. // eqOrg2(row) {
  439. // // console.log(row.planCreateOrgId,"row.planCreateOrgId");
  440. // // console.log(this.orgId,"this.orgId");
  441. // if (
  442. // row != null &&
  443. // row != undefined &&
  444. // row.planCreateOrgId == this.orgId &&
  445. // row.planOfOrgId == this.orgId
  446. // ) {
  447. // return true;
  448. // }
  449. // return false;
  450. // },
  451. showPublish(row) {
  452. //有父计划且父计划不是使用中状态,不能下发
  453. if (row.parentStatus != 1 && row.parentId>0) {
  454. return false;
  455. }
  456. //可以下发:本机构创建+状态为草稿、停用的计划
  457. if (
  458. row.planCreateOrgId == this.orgId &&
  459. (row.planStatus == 0 || row.planStatus == 2)
  460. ) {
  461. return true;
  462. }
  463. // if (
  464. // row.planOfOrgId == this.orgId &&
  465. // row.planCreateOrgId != this.orgId &&
  466. // (row.planStatus == 0 || row.planStatus == 2) &&
  467. // row.distributePlanStatus == 0
  468. // ) {
  469. // return true;
  470. // }
  471. return false;
  472. },
  473. showDelete(row) {
  474. //本机构创建的计划,才能删除
  475. return row.planCreateOrgId == this.orgId;
  476. },
  477. showWithDraw(row) {
  478. //本机构创建是自己+状态为使用中
  479. if (row.planCreateOrgId == this.orgId && row.planStatus == 1) {
  480. return true;
  481. }
  482. // if (
  483. // row.planOfOrgId == this.orgId &&
  484. // row.planCreateOrgId != this.orgId &&
  485. // row.planStatus == 1 &&
  486. // row.distributePlanStatus == 0
  487. // ) {
  488. // return true;
  489. // }
  490. return false;
  491. },
  492. // //已完成下发的计划不显示下发按钮
  493. // checkCanPublish(row) {
  494. // // console.log(row.planStatus,"row.planStatus")
  495. // if (row.planOfOrgType == "1" && row.distribute == 0) {
  496. // return true;
  497. // }
  498. // return false;
  499. // },
  500. // newcheckCanPublish(row) {
  501. // //如果计划所属机构类型为行社并且计划不为进行中并且计划创建机构为当前机构或者
  502. // //计划状态为停用并且不属于子计划并且计划所属机构类型为省联社
  503. // if (
  504. // (row.planOfOrgType == 3 &&
  505. // row.planStatus != 1 &&
  506. // row.planCreateOrgId == this.orgId) ||
  507. // (row.planStatus == 2 && row.parentId != -1 && row.planOfOrgType == 1)
  508. // ) {
  509. // return true;
  510. // }
  511. // return false;
  512. // },
  513. //开始撤回
  514. chhuile(row) {
  515. let msg = "";
  516. if (row.taskHasCompleted != 1) {
  517. msg = "因不存在已完成任务,撤回后将删除所有生成任务?";
  518. } else {
  519. msg = "因存在已完成任务,撤回后下周期起将不再生成任务?";
  520. }
  521. this.$modal
  522. .confirm(msg, "提示")
  523. .then(() => {
  524. // 用户点击了确认按钮
  525. // console.log("执行操作...");
  526. this.loading = true;
  527. api.cheHui(row.id).then((response) => {
  528. this.getList();
  529. this.loading = false;
  530. });
  531. })
  532. .catch(() => {
  533. // 用户点击了取消按钮
  534. // console.log("取消操作...");
  535. });
  536. },
  537. //已下发的显示撤回
  538. // chehui(row) {
  539. // if (row.distribute == 1 && row.planCreateOrgId == this.orgId) {
  540. // return true;
  541. // }
  542. // return false;
  543. // },
  544. sel(selectList, row) {
  545. let msg = "";
  546. if (row.planStatus == 0) {
  547. msg = "请选择下发后立即生成或下周期生成任务。";
  548. this.$refs["DialogThreeState"].show(
  549. msg,
  550. (state) => {
  551. if (state == 0 || state == 1) {
  552. this.distributeInner(selectList, state == 1);
  553. }
  554. },
  555. {
  556. yesText: "立即生成",
  557. noText: "下周期",
  558. cancelText: "取消",
  559. }
  560. );
  561. } else if (row.planStatus == 2) {
  562. this.$modal
  563. .confirm("因存在已完成任务,是否确定从下周期生成任务?")
  564. .then(() => {
  565. this.distributeInner(selectList, false);
  566. });
  567. } else {
  568. this.distributeInner(selectList, false);
  569. }
  570. },
  571. distributeInner(selectList, imme) {
  572. this.loading = true;
  573. api
  574. .distribute(selectList, imme)
  575. .then((response) => {
  576. this.getList();
  577. this.loading = false;
  578. })
  579. .catch(() => {
  580. this.loading = false;
  581. });
  582. },
  583. onHSPlanDistribute(row) {
  584. if (row.planStatus == 0) {
  585. let msg = "请选择下发后立即生成或下周期生成任务。";
  586. this.$refs["DialogThreeState"].show(
  587. msg,
  588. (state) => {
  589. if (state == 0 || state == 1) {
  590. this.distributeHS(row.id, state == 1);
  591. }
  592. },
  593. {
  594. yesText: "立即生成",
  595. noText: "下周期",
  596. cancelText: "取消",
  597. }
  598. );
  599. } else if (row.planStatus == 2) {
  600. this.$modal
  601. .confirm("因存在已完成任务,是否确定从下周期生成任务?")
  602. .then(() => {
  603. this.distributeHS(row.id, false);
  604. });
  605. } else {
  606. this.distributeHS(row.id, false);
  607. }
  608. },
  609. distributeHS(id, immediateEffect) {
  610. this.loading = true;
  611. api
  612. .distributeHS(id, immediateEffect)
  613. .then((response) => {
  614. // console.log(response, "then");
  615. if (response.data == 0) {
  616. this.loading = false;
  617. } else {
  618. this.getList();
  619. this.loading = false;
  620. }
  621. })
  622. .catch((response) => {
  623. // console.log(response, "catch");
  624. this.getList();
  625. this.loading = false;
  626. });
  627. },
  628. showDialogDistribute(row) {
  629. if (row.planOfOrgType == 3) {
  630. this.onHSPlanDistribute(row);
  631. } else {
  632. this.$refs.dialogDistribute.show(row);
  633. }
  634. // this.loading = true;
  635. // api
  636. // .distributeCheHui(row.id)
  637. // .then((response) => {
  638. // // console.log(response, "then");
  639. // if (response.data == 0) {
  640. // this.loading = false;
  641. // this.$refs.dialogDistribute.show(row);
  642. // } else {
  643. // this.getList();
  644. // this.loading = false;
  645. // }
  646. // })
  647. // .catch((response) => {
  648. // // console.log(response, "catch");
  649. // this.getList();
  650. // this.loading = false;
  651. // this.$refs.dialogDistribute.show(row);
  652. // });
  653. },
  654. async getRolesByOrg() {
  655. await allRole().then((res) => {
  656. // console.info(res);
  657. this.resumptionRoles = res.data;
  658. });
  659. },
  660. getList() {
  661. this.loading = true;
  662. this.queryParams.roleList = [];
  663. if (
  664. this.queryParams.resumptionRole != null &&
  665. this.queryParams.resumptionRole != ""
  666. ) {
  667. this.queryParams.roleList.push(this.queryParams.resumptionRole);
  668. }
  669. console.info(this.dict.type);
  670. api
  671. .list(this.queryParams)
  672. .then((response) => {
  673. this.pageData = response.rows;
  674. this.total = response.total;
  675. this.loading = false;
  676. })
  677. .catch(() => {
  678. this.loading = false;
  679. });
  680. },
  681. getDefaultKey(key) {
  682. this.queryParams.orgId = key;
  683. this.getList();
  684. },
  685. handleAdd(id, other = {}) {
  686. this.$refs.editDialog.show(id, other);
  687. },
  688. onEdit(id, other = {}) {
  689. this.$refs.editDialog.show(id, other);
  690. },
  691. async onDel(row) {
  692. let msg = "";
  693. if (row.planStatus == 0) {
  694. msg = '是否确认删除名称为"' + row.planName + '"的任务?';
  695. } else if (row.planStatus == 1) {
  696. if (row.planCycle == 1) {
  697. msg = "本次删除将强制删除今日所有任务?";
  698. } else {
  699. msg = "本次删除将强制删除当前任务时间及以后所有任务";
  700. }
  701. } else if (row.planStatus == 2) {
  702. if (row.hasTaskCurrentCycle) {
  703. if (row.planCycle == 1) {
  704. msg = "本次删除将强制删除今日所有任务?";
  705. } else {
  706. msg = "本次删除将强制删除当前任务时间及以后所有任务";
  707. }
  708. } else {
  709. msg = '是否确认删除名称为"' + row.planName + '"的任务?';
  710. }
  711. }
  712. this.$modal
  713. .confirm(msg)
  714. .then(() => {
  715. // 用户点击了确认按钮
  716. console.log("执行操作...");
  717. this.loading = true;
  718. api
  719. .del(row.id)
  720. .then(() => {
  721. this.getList();
  722. this.loading = false;
  723. this.$modal.msgSuccess("删除成功");
  724. })
  725. .catch(() => {
  726. this.loading = false;
  727. });
  728. })
  729. .catch(() => {
  730. // 用户点击了取消按钮
  731. console.log("取消操作...");
  732. this.loading = false;
  733. });
  734. },
  735. // 多选框选中数据
  736. handleSelectionChange(selection) {
  737. this.ids = selection.map((item) => item.userId);
  738. this.single = selection.length != 1;
  739. this.multiple = !selection.length;
  740. },
  741. /** 重置按钮操作 */
  742. resetQuery() {
  743. this.resetForm("search");
  744. this.queryParams.orgId = this.orgId;
  745. this.queryParams.checkSub = false;
  746. this.$refs["orgTree"].setCheckSub(this.queryParams.checkSub);
  747. // this.$refs.tree.setCurrentKey(null);
  748. this.getList();
  749. },
  750. //单选框状态改变
  751. checkChange(state) {
  752. this.queryParams.checkSub = state;
  753. this.getList();
  754. },
  755. // 节点单击事件
  756. clickTreeNode(data) {
  757. this.queryParams.orgId = data.id;
  758. this.getList();
  759. },
  760. getStatusLabel(value) {
  761. return getLabel(statusOptions, value);
  762. },
  763. getLabel(options, value) {
  764. return getLabel(options, value);
  765. },
  766. //apimark//
  767. },
  768. mounted() {},
  769. };
  770. </script>
  771. <style lang="scss" scoped>
  772. .brand {
  773. }
  774. </style>