BST_two.vue 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827
  1. <template>
  2. <div style="height:100%">
  3. <FullPage
  4. title="生产排产列表"
  5. :list="set_list"
  6. @init="init"
  7. @searchData="searchData"
  8. @selectTable="selectTable"
  9. @changePage="changePage"
  10. @changeSize="changeSize"
  11. @changeSelected='tooltip_change'
  12. @total_choose='total_choose'
  13. :tableColums="computedTable"
  14. :tableData="tableData"
  15. :showPage="false"
  16. :tooltip_data='tooltip_data'
  17. :page_index="page_index"
  18. :loading="loading"
  19. :total="total"
  20. >
  21. <div slot="titleButton">
  22. <Button
  23. v-if="persimissionData['分类派工'] || persimissionData.all"
  24. type="primary"
  25. style="margin-right:10px"
  26. @click="handleDispatchType(selects)"
  27. ghost
  28. >批量派工</Button
  29. >
  30. <!-- <Button
  31. v-if="persimissionData['批量派工单'] || persimissionData.all"
  32. type="primary"
  33. @click="dispatchList(selects)"
  34. ghost
  35. >批量派工单</Button
  36. > -->
  37. </div>
  38. <div slot="navButton">
  39. <Button
  40. v-if="persimissionData['表头设置'] || persimissionData.all"
  41. @click="setupTableHeader"
  42. type="primary"
  43. ghost
  44. icon="ios-cog"
  45. >设置</Button
  46. >
  47. </div>
  48. <template slot="basicTypeSet" slot-scope="{ row }">
  49. <div>
  50. <span
  51. v-for="item in warningList"
  52. :key="item.id"
  53. :style="{ color: item.color }"
  54. v-show="item.id == row.warning_state"
  55. >{{ item.title }}</span
  56. >
  57. </div>
  58. </template>
  59. <template slot="set" slot-scope="{ row }">
  60. <div>
  61. <a
  62. v-if="persimissionData['详情'] || persimissionData.all"
  63. style="margin:0 5px"
  64. @click="goDetial(row)"
  65. >详情</a
  66. >
  67. <!-- <a
  68. v-if="persimissionData['派工单'] || persimissionData.all"
  69. style="margin:0 5px"
  70. @click="dispatchList(row)"
  71. >派工单</a
  72. > -->
  73. </div>
  74. </template>
  75. <template slot="pageSlot">
  76. <div class="pageSlotStyle">
  77. <Page
  78. :page-size-opts="[10, 20, 30, 40, 100, 1000]"
  79. @on-page-size-change="changeSize"
  80. @on-change="changePage"
  81. :current="page_index"
  82. show-total
  83. :total="total"
  84. show-sizer
  85. :page-size="page_size"
  86. />
  87. </div>
  88. </template>
  89. </FullPage>
  90. <Modal
  91. v-model="showModal"
  92. title="设置"
  93. @on-ok="handleModalOk"
  94. @on-cancel="showModal = false"
  95. >
  96. <div class="modal_content">
  97. <Tabs
  98. value="name1"
  99. style="max-height: 700px; overflow: hidden; overflow-y: auto"
  100. >
  101. <TabPane label="表单设置" name="name1">
  102. <Table
  103. :columns="formModalColumns"
  104. border
  105. draggable
  106. @on-drag-drop="(a, b) => onDragDrop(a, b, formModalTableData, 1)"
  107. :data="formModalTableData"
  108. ></Table>
  109. </TabPane>
  110. <TabPane label="表头设置" name="name2">
  111. <Table
  112. :columns="tableModalColumns"
  113. border
  114. draggable
  115. @on-drag-drop="(a, b) => onDragDrop(a, b, tableModalTableData, 2)"
  116. :data="tableModalTableData"
  117. ></Table>
  118. </TabPane>
  119. </Tabs>
  120. </div>
  121. </Modal>
  122. </div>
  123. </template>
  124. <script>
  125. import { mapState } from "vuex";
  126. export default {
  127. data() {
  128. return {
  129. url_number:[],
  130. tooltip_data:'',
  131. loading: true,
  132. url_number_list:[],
  133. tableModalColumns: [
  134. {
  135. title: "是否展示",
  136. align: "center",
  137. key: "is_show",
  138. minWidth: 60,
  139. render: (h, params) => {
  140. const { index } = params;
  141. const currentRow = JSON.parse(
  142. JSON.stringify(this.tableModalTableData[index])
  143. );
  144. return h("Checkbox", {
  145. props: {
  146. value: currentRow.is_show,
  147. },
  148. on: {
  149. "on-change": (e) => {
  150. currentRow.is_show = e;
  151. this.tableModalTableData.splice(index, 1, currentRow);
  152. },
  153. },
  154. });
  155. },
  156. },
  157. {
  158. title: "字段名",
  159. align: "center",
  160. key: "value",
  161. minWidth: 100,
  162. },
  163. {
  164. title: "展示名称",
  165. align: "center",
  166. key: "title",
  167. minWidth: 100,
  168. render: (h, params) => {
  169. const { index } = params;
  170. const currentRow = JSON.parse(
  171. JSON.stringify(this.tableModalTableData[index])
  172. );
  173. return h("Input", {
  174. props: {
  175. value: currentRow.title,
  176. type: "text",
  177. disabled: currentRow.title == "全选" ? true : false,
  178. },
  179. on: {
  180. "on-change": (e) => {
  181. currentRow.title = e.target.value;
  182. this.tableModalTableData.splice(index, 1, currentRow);
  183. },
  184. },
  185. });
  186. },
  187. },
  188. ],
  189. tableModalTableData: [
  190. { is_show: true, key: "selection", value: "全选", title: "全选" },
  191. {
  192. is_show: true,
  193. key: "order_no",
  194. value: "订单编号",
  195. title: "订单编号",
  196. },
  197. {
  198. is_show: true,
  199. key: "residential_name",
  200. value: "项目名称",
  201. title: "项目名称",
  202. },
  203. { is_show: true, key: "nickname", value: "业务员", title: "业务员" },
  204. {
  205. is_show: true,
  206. key: "client_name",
  207. value: "客户姓名",
  208. title: "客户姓名",
  209. },
  210. { is_show: true, key: "address", value: "客户地址", title: "客户地址" },
  211. {
  212. is_show: true,
  213. key: "leading_name",
  214. value: "负责人",
  215. title: "负责人",
  216. },
  217. {
  218. is_show: true,
  219. key: "warning_state",
  220. value: "紧急程度",
  221. title: "紧急程度",
  222. },
  223. {
  224. is_show: true,
  225. key: "predict_price",
  226. value: "产品总价",
  227. title: "产品总价",
  228. },
  229. {
  230. is_show: true,
  231. key: "fax_price",
  232. value: "折扣金额",
  233. title: "折扣金额",
  234. },
  235. { is_show: true, key: "price", value: "订单金额", title: "订单金额" },
  236. { is_show: true, key: "get_money", value: "已收款", title: "已收款" },
  237. { is_show: true, key: "unget_money", value: "未收款", title: "未收款" },
  238. { is_show: true, key: "remark", value: "备注", title: "备注" },
  239. {
  240. is_show: true,
  241. key: "start_time",
  242. value: "订单开始日期",
  243. title: "订单开始日期",
  244. },
  245. {
  246. is_show: true,
  247. key: "end_time",
  248. value: "订单交付日期",
  249. title: "订单交付日期",
  250. },
  251. {
  252. is_show: true,
  253. key: "complete_rate",
  254. value: "生产进度",
  255. title: "生产进度",
  256. },
  257. { is_show: true, key: "state", value: "订单状态", title: "订单状态" },
  258. { is_show: true, key: "crt_name", value: "制单人", title: "制单人" },
  259. {
  260. is_show: true,
  261. key: "crt_time",
  262. value: "订单创建时间",
  263. title: "订单创建时间",
  264. },
  265. { is_show: true, key: "set", value: "操作", title: "操作" },
  266. ],
  267. formModalColumns: [
  268. {
  269. title: "是否展示",
  270. align: "center",
  271. key: "is_show",
  272. minWidth: 60,
  273. render: (h, params) => {
  274. const { index } = params;
  275. const currentRow = JSON.parse(
  276. JSON.stringify(this.formModalTableData[index])
  277. );
  278. return h("Checkbox", {
  279. props: {
  280. value: currentRow.is_show,
  281. },
  282. on: {
  283. "on-change": (e) => {
  284. currentRow.is_show = e;
  285. this.formModalTableData.splice(index, 1, currentRow);
  286. },
  287. },
  288. });
  289. },
  290. },
  291. {
  292. title: "字段名",
  293. align: "center",
  294. key: "value",
  295. minWidth: 100,
  296. },
  297. {
  298. title: "展示名称",
  299. align: "center",
  300. key: "title",
  301. minWidth: 100,
  302. render: (h, params) => {
  303. const { index } = params;
  304. const currentRow = JSON.parse(
  305. JSON.stringify(this.formModalTableData[index])
  306. );
  307. return h("Input", {
  308. props: {
  309. value: currentRow.title,
  310. type: "text",
  311. },
  312. on: {
  313. "on-change": (e) => {
  314. currentRow.title = e.target.value;
  315. this.formModalTableData.splice(index, 1, currentRow);
  316. },
  317. },
  318. });
  319. },
  320. },
  321. ],
  322. formModalTableData: [
  323. {
  324. is_show: true,
  325. key: "order_no",
  326. value: "订单编号",
  327. title: "订单编号",
  328. },
  329. {
  330. is_show: true,
  331. key: "residential_name",
  332. value: "项目名称",
  333. title: "项目名称",
  334. },
  335. {
  336. is_show: true,
  337. key: "client_name",
  338. value: "客户姓名",
  339. title: "客户姓名",
  340. },
  341. { is_show: true, key: "address", value: "客户地址", title: "客户地址" },
  342. { is_show: true, key: "salesman", value: "业务员", title: "业务员" },
  343. { is_show: true, key: "state", value: "订单状态", title: "订单状态" },
  344. { is_show: true, key: "crt_id", value: "制单人", title: "制单人" },
  345. {
  346. is_show: true,
  347. key: "leading_name",
  348. value: "负责人",
  349. title: "负责人",
  350. },
  351. {
  352. is_show: true,
  353. key: "warning_state",
  354. value: "紧急程度",
  355. title: "紧急程度",
  356. },
  357. {
  358. is_show: true,
  359. key: "",
  360. value: "订单创建时间",
  361. title: "订单创建时间",
  362. },
  363. ],
  364. tableColums: [
  365. {
  366. type: "selection",
  367. title: "全选",
  368. key: "selection",
  369. fixed: "left",
  370. width: "90",
  371. align: "center",
  372. },
  373. { title: "项目编号", align: "center", key: "order_no", minWidth: 200 },
  374. {
  375. title: "项目名称",
  376. align: "center",
  377. key: "residential_name",
  378. minWidth: 200,
  379. },
  380. { title: "图号", align: "center", key: "url_number", minWidth: 200,ellipsis:'true',tooltip:'true'
  381. },
  382. { title: "计划单号", align: "center", key: "plan_no", minWidth: 200 },
  383. // {
  384. // title: "订单类型",
  385. // align: "center",
  386. // key: "order_type",
  387. // minWidth: 150,
  388. // render(h, params) {
  389. // return h("span", {}, params.row.order_type == 1 ? "工装" : "家装");
  390. // },
  391. // },
  392. {
  393. title: "订单状态",
  394. align: "center",
  395. key: "state",
  396. minWidth: 150,
  397. render: (h, params) =>
  398. h(
  399. "span",
  400. {},
  401. params.row.state == 0
  402. ? "未派工"
  403. : params.row.state == 1
  404. ? "派工中"
  405. : params.row.state == 2
  406. ? "完成"
  407. : ""
  408. ),
  409. },
  410. // { title: "业务员", align: "center", key: "nickname", minWidth: 150 },
  411. {
  412. title: "紧急程度",
  413. align: "center",
  414. key: "warning_state",
  415. minWidth: 150,
  416. slot: "basicTypeSet",
  417. },
  418. {
  419. title: "计划开始时间",
  420. align: "center",
  421. minWidth: 200,
  422. key: "plan_start_time",
  423. render: (h, params) =>
  424. h("span", {}, this.func.replaceDate(params.row.plan_start_time, 1)),
  425. },
  426. {
  427. title: "计划结束时间",
  428. align: "center",
  429. minWidth: 200,
  430. key: "plan_end_time",
  431. render: (h, params) =>
  432. h("span", {}, this.func.replaceDate(params.row.plan_end_time, 1)),
  433. },
  434. {
  435. title: "生产进度",
  436. align: "center",
  437. key: "complete_rate",
  438. minWidth: 100,
  439. render: (h, params) =>
  440. h("span", {}, parseInt(params.row.complete_rate * 100) + "%"),
  441. },
  442. {
  443. title: "预估交付日期",
  444. align: "center",
  445. key: "predict_time",
  446. minWidth: 200,
  447. render: (h, params) =>
  448. h("span", {}, this.func.replaceDate(params.row.predict_time, 1)),
  449. },
  450. {
  451. title: "操作",
  452. align: "center",
  453. key: "set",
  454. slot: "set",
  455. fixed: "right",
  456. width: "150",
  457. },
  458. ],
  459. tableData: [],
  460. showModal:false,
  461. page_index: 1,
  462. currencyPageId:null,
  463. page_size: 10,
  464. total: 0,
  465. proxyObj: {},
  466. selects: [],
  467. tableheaders: [],
  468. userList: [],
  469. //详情页返回保留搜索数据
  470. corssPageData: localStorage.getItem("corssPageData")
  471. ? JSON.parse(localStorage.getItem("corssPageData"))
  472. : {},
  473. warningList: [],
  474. };
  475. },
  476. beforeRouteEnter(to, from, next) {
  477. next((vm) => {
  478. if (from.path != "/cms/productionorderlist/productionplanlist/details") {
  479. localStorage.removeItem("corssPageData");
  480. } else {
  481. vm.firstEnter = 1;
  482. }
  483. });
  484. },
  485. beforeRouteLeave(to, from, next) {
  486. if (to.path == "/cms/productionorderlist/productionplanlist/details") {
  487. (this.corssPageData.page_index = this.page_index),
  488. (this.corssPageData.page_size = this.page_size),
  489. localStorage.setItem(
  490. "corssPageData",
  491. JSON.stringify(this.corssPageData)
  492. );
  493. } else {
  494. localStorage.removeItem("corssPageData");
  495. }
  496. next((vm) => {});
  497. },
  498. created() {
  499. // 获取紧急程度
  500. this.axios.get("/api/warning_list").then((res) => {
  501. this.warningList = res.data.data;
  502. });
  503. this.axios
  504. .get("/api/employee_list")
  505. .then((res) => (this.userList = res.data.data));
  506. //this.axios.get('/api/employee_list').then(res => { this.employeeList = res.data })
  507. this.currencyPageId = this.$store.state.navgationData[0].sub[0].sub[0].id;
  508. },
  509. computed: {
  510. ...mapState(["persimissionData"]),
  511. computedTable() {
  512. // if (this.tableheaders.length < 1) {
  513. return this.tableColums;
  514. // }
  515. // return this.func.computedHeader(this.tableheaders, this.tableColums)
  516. },
  517. set_list() {
  518. return [
  519. {
  520. title: "项目编号",
  521. name: "Input",
  522. serverName: "order_no",
  523. placeholder: "请输入项目编号",
  524. value: "",
  525. },
  526. {
  527. title: "项目名称",
  528. name: "Input",
  529. serverName: "residential_name",
  530. placeholder: "请选择项目名称",
  531. value: "",
  532. },
  533. {
  534. title: "图号",
  535. isTooltip:true,
  536. width:'160',
  537. change:true,
  538. name: "Select",
  539. serverName: "url_number",
  540. placeholder: "请选择",
  541. value: this.url_number,
  542. optionName: "title",
  543. optionValue: "title",
  544. option: this.url_number_list,
  545. multiple:true
  546. },
  547. // {
  548. // title: "订单类型",
  549. // name: "Select",
  550. // placeholder: "请选择",
  551. // serverName: "order_type",
  552. // value: "",
  553. // option: [
  554. // { label: "工装", value: 1 },
  555. // { label: "家装", value: 0 },
  556. // ],
  557. // },
  558. {
  559. title: "计划单号",
  560. name: "Input",
  561. serverName: "plan_no",
  562. placeholder: "请填写计划单号",
  563. value: "",
  564. },
  565. // {
  566. // title: "业务员",
  567. // name: "Select",
  568. // serverName: "nickname",
  569. // placeholder: "请选择",
  570. // value: "",
  571. // optionName: "nickname",
  572. // optionValue: "id",
  573. // option: this.userList,
  574. // },
  575. {
  576. title: "计划开始时间",
  577. name: "Input",
  578. start_server: "start_time",
  579. end_server: "end_time",
  580. start_value: "",
  581. end_value: "",
  582. isDate: true,
  583. serverName: "id2",
  584. start_placeholder: "开始日期",
  585. end_placeholder: "结束日期",
  586. },
  587. {
  588. title: "紧急程度",
  589. name: "Select",
  590. serverName: "warning_state",
  591. placeholder: "请选择",
  592. value: "",
  593. optionName: "title",
  594. optionValue: "id",
  595. option: this.warningList,
  596. },
  597. {
  598. title: "订单状态",
  599. name: "Select",
  600. placeholder: "请选择",
  601. serverName: "state",
  602. value: "",
  603. option: [
  604. { label: "未派工", value: 0 },
  605. { label: "派工中", value: 1 },
  606. { label: "完成", value: 2 },
  607. ],
  608. },
  609. ];
  610. },
  611. },
  612. methods: {
  613. total_choose(e){
  614. let data=[];
  615. if(e[2].value.indexOf('全选')>=0){
  616. e[2].option.forEach(v=>{
  617. data.push(v.title)
  618. })
  619. data.unshift('全选')
  620. this.set_list[2].value = data;
  621. this.url_number = data;
  622. }else{
  623. this.set_list[2].value = [];
  624. this.url_number = [];
  625. }
  626. },
  627. tooltip_change(e){
  628. this.tooltip_data = e[2].value.toString();
  629. },
  630. handleModalOk(){
  631. this.formModalTableData.forEach((element, index) => {
  632. element.sort = index;
  633. });
  634. this.tableModalTableData.forEach((element, index) => {
  635. element.sort = index;
  636. });
  637. this.axios({
  638. method: "post",
  639. url: "/api/update/table",
  640. data: {
  641. id: this.currencyPageId,
  642. result: {
  643. formSet: this.formModalTableData,
  644. tableSet: this.tableModalTableData,
  645. },
  646. },
  647. }).then((res) => {
  648. this.$Message.success(res.msg);
  649. this.init(this.proxyObj);
  650. });
  651. },
  652. init(row) {
  653. const { order_no } = this.$route.query;
  654. if (order_no) {
  655. row.order_no = order_no;
  656. this.set_list[0].value = order_no;
  657. }
  658. row.sub_state = 5;
  659. if (this.firstEnter == 1) {
  660. this.corssPageData = JSON.parse(localStorage.getItem("corssPageData"));
  661. row = this.corssPageData;
  662. this.proxyObj = row;
  663. this.searchData(row);
  664. } else {
  665. this.page_index = 1;
  666. row.page_index = this.page_index;
  667. row.page_size = this.page_size;
  668. this.proxyObj = row;
  669. this.getData(row);
  670. }
  671. },
  672. searchData(row) {
  673. if (this.firstEnter == 1) {
  674. this.page_index = this.corssPageData.page_index;
  675. this.page_size = this.corssPageData.page_size;
  676. this.set_list[0].value = this.corssPageData.order_no;
  677. this.set_list[1].value = this.corssPageData.residential_name;
  678. this.set_list[3].value = this.corssPageData.warning_state;
  679. this.set_list[4].value = this.corssPageData.state;
  680. this.set_list[2].start_value = this.corssPageData.start_time
  681. ? this.corssPageData.start_time
  682. : "";
  683. this.set_list[2].end_value = this.corssPageData.end_time
  684. ? this.corssPageData.end_time
  685. : "";
  686. this.corssPageData.type = this.$route.query.type;
  687. this.getData(this.corssPageData);
  688. } else {
  689. this.page_index = 1;
  690. row.page_index = this.page_index;
  691. row.page_size = this.page_size;
  692. this.corssPageData.order_no = this.set_list[0].value;
  693. this.corssPageData.residential_name = this.set_list[1].value;
  694. this.corssPageData.warning_state = this.set_list[3].value;
  695. this.corssPageData.state = this.set_list[4].value;
  696. this.corssPageData.start_time = this.func.setDate(
  697. this.set_list[2].start_value
  698. );
  699. this.corssPageData.end_time = this.func.setDate(
  700. this.set_list[2].end_value
  701. );
  702. this.proxyObj = row;
  703. this.getData(row);
  704. }
  705. },
  706. changePage(e) {
  707. this.page_index = e;
  708. this.proxyObj.page_index = this.page_index;
  709. this.proxyObj.page_size = this.page_size;
  710. this.getData(this.proxyObj);
  711. },
  712. changeSize(e) {
  713. this.page_size = e;
  714. this.proxyObj.page_size = this.page_size;
  715. this.getData(this.proxyObj);
  716. },
  717. getData(row) {
  718. this.axios("/api/orders_produce_plan_list", { params: row }).then(
  719. (res) => {
  720. this.firstEnter++;
  721. this.tableData = res.data.data;
  722. this.total = res.data.total;
  723. // this.tableheaders = res.data.tableSet || []
  724. let data =[];
  725. res.data.url_number_list.map(v=>{
  726. let obj={};
  727. obj.title =v;
  728. data.push(obj)
  729. })
  730. this.url_number_list = data;
  731. // this.url_number_list.unshift({title:'全选'})
  732. this.loading = false;
  733. }
  734. );
  735. },
  736. goDetial(row) {
  737. this.$router.push({
  738. path: "/cms/productionorderlist/productionplanlist/details",
  739. query: {
  740. order_no: row.order_no,
  741. plan_no: row.plan_no,
  742. },
  743. });
  744. },
  745. onDragDrop(a, b, table, type) {
  746. if (type == 2 && (a == 0 || b == 0)) {
  747. return this.$Message.warning("全选位置不可变");
  748. }
  749. table.splice(b, 0, ...table.splice(a, 1));
  750. },
  751. handleDispatchType(row) {
  752. // console.log("row :>> ", row);
  753. this.axios.post('/api/order_produce_list').then(res=>{
  754. if(res.code == 200){
  755. this.$router.push({
  756. path: "/cms/Dispatching/Dispatching",
  757. query: {
  758. order_no: row.order_no,
  759. plan_no: row.plan_no,
  760. },
  761. });
  762. }
  763. })
  764. },
  765. dispatchList(row) {
  766. this.dispatchOrder({
  767. params: {
  768. order_no: Array.isArray(row) ? this.selects.join(",") : row.order_no,
  769. },
  770. then: () => this.getData(this.proxyObj),
  771. });
  772. },
  773. selectTable(e) {
  774. let result = [];
  775. e.map((v) => result.push(v.order_no));
  776. this.selects = result;
  777. },
  778. setupTableHeader() {
  779. this.showModal = true;
  780. return;
  781. // this.tableheaders.length < 1
  782. // ? (this.tableheaders = this.tableColums.reduce(
  783. // (pre, cur) => pre.concat(cur.key),
  784. // []
  785. // ))
  786. // : "";
  787. // this.$setTableheader({
  788. // list: this.tableColums,
  789. // selects: this.tableheaders,
  790. // then: (result) => {
  791. // this.tableheaders = result;
  792. // this.axios
  793. // .post("/api/update/table", { id: this.$route.query.id, result })
  794. // .then((res) => {
  795. // if (res.code == 200) {
  796. // this.$Message.success(res.msg);
  797. // let data =[];
  798. // for(let i = 0 ; i++ ; i<this.tableColums){
  799. // if(this.tableColums[i].title.indexOf(result)>=0){
  800. // data.push(this.tableColums[i])
  801. // }
  802. // }
  803. // this.computedTable = data
  804. // }
  805. // });
  806. // },
  807. // });
  808. },
  809. },
  810. };
  811. </script>
  812. <style lang="scss" scoped>
  813. .pageSlotStyle {
  814. display: flex;
  815. justify-content: center;
  816. margin-top: 10px;
  817. }
  818. .modal_content {
  819. display: flex;
  820. justify-content: center;
  821. // width: 500px;
  822. }
  823. </style>