冷凝胶前端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

808 lines
23 KiB

2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
  1. <template>
  2. <div class="mod-config">
  3. <!-- 条件查询 -->
  4. <el-form :inline="true" label-position="top" :model="searchData" @keyup.enter.native="getDataList()">
  5. <el-form-item :label="'物料编码:'">
  6. <el-input v-model="searchData.partNo" clearable style="width: 120px"></el-input>
  7. </el-form-item>
  8. <el-form-item :label="'库位编码:'">
  9. <el-input v-model="searchData.locationID" clearable style="width: 120px"></el-input>
  10. </el-form-item>
  11. <el-form-item :label="'料号描述:'">
  12. <el-input v-model="searchData.partDesc" clearable style="width: 120px"></el-input>
  13. </el-form-item>
  14. <!-- <el-form-item :label="'卷号:'">-->
  15. <!-- <el-input v-model="searchData.rollNo" clearable style="width: 120px"></el-input>-->
  16. <!-- </el-form-item>-->
  17. <el-form-item :label="' '">
  18. <el-button v-if="!authSearch" type="primary" @click="getDataList()">查询</el-button>
  19. <!-- <download-excel-->
  20. <!-- :fields="fields()"-->
  21. <!-- :data="exportData"-->
  22. <!-- type="xls"-->
  23. <!-- :name="exportName"-->
  24. <!-- :header="exportHeader"-->
  25. <!-- :footer="exportFooter"-->
  26. <!-- :fetch="createExportData"-->
  27. <!-- :before-generate="startDownload"-->
  28. <!-- :before-finish="finishDownload"-->
  29. <!-- worksheet="导出信息"-->
  30. <!-- class="el-button el-button&#45;&#45;primary el-button&#45;&#45;medium">-->
  31. <!-- {{ "导出" }}-->
  32. <!-- </download-excel>-->
  33. </el-form-item>
  34. </el-form>
  35. <!-- 展示列表 -->
  36. <el-table
  37. :height="height"
  38. :data="dataList"
  39. @row-click="changeData"
  40. border
  41. highlight-current-row
  42. ref="mainTable"
  43. style="width: 100%;">
  44. <el-table-column
  45. v-for="(item,index) in columnList" :key="index"
  46. :sortable="item.columnSortable"
  47. :prop="item.columnProp"
  48. :header-align="item.headerAlign"
  49. :show-overflow-tooltip="item.showOverflowTooltip"
  50. :align="item.align"
  51. :fixed="item.fixed==''?false:item.fixed"
  52. :width="item.columnWidth"
  53. :label="item.columnLabel">
  54. <template slot-scope="scope">
  55. <span v-if="!item.columnHidden"> {{ scope.row[item.columnProp] }}</span>
  56. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  57. </template>
  58. </el-table-column>
  59. </el-table>
  60. <el-pagination
  61. @size-change="sizeChangeHandle"
  62. @current-change="currentChangeHandle"
  63. :current-page="pageIndex"
  64. :page-sizes="[20, 50, 100, 200, 500]"
  65. :page-size="pageSize"
  66. :total="totalPage"
  67. layout="total, sizes, prev, pager, next, jumper">
  68. </el-pagination>
  69. <el-tabs style="font-size: 12px;min-height: 200px" class="customer-tab" v-model="activeName" type="border-card" @tab-click="tabClick">
  70. <el-tab-pane label="卷明细" name="detail">
  71. <el-table
  72. :data="dataList2"
  73. :height="height"
  74. border
  75. style="width: 100%; ">
  76. <el-table-column
  77. v-for="(item,index) in columnList2" :key="index"
  78. :sortable="item.columnSortable"
  79. :prop="item.columnProp"
  80. :header-align="item.headerAlign"
  81. :show-overflow-tooltip="item.showOverflowTooltip"
  82. :align="item.align"
  83. :fixed="item.fixed==''?false:item.fixed"
  84. :min-width="item.columnWidth"
  85. :label="item.columnLabel">
  86. <template slot-scope="scope">
  87. <span v-if="!item.columnHidden"> {{ scope.row[item.columnProp] }}</span>
  88. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]"
  89. style="width: 100px; height: 80px"/></span>
  90. </template>
  91. </el-table-column>
  92. </el-table>
  93. </el-tab-pane>
  94. </el-tabs>
  95. </div>
  96. </template>
  97. <script>
  98. import {
  99. findByNum, // 检验方法查询
  100. findByNumOrRollNo //查询卷明细
  101. } from "@/api/material/seekByTrans.js"
  102. // import {getTableDefaultListLanguage, getTableUserListLanguage} from "@/api/table.js"
  103. // import {userFavoriteList, saveUserFavorite, removeUserFavorite} from '@/api/userFavorite.js'
  104. export default {
  105. data () {
  106. return {
  107. activeName:'detail',
  108. wareHouseList:'',
  109. // 是否收藏
  110. favorite: false,
  111. // 导出 start
  112. exportData: [],
  113. exportName: "检验方法" + this.dayjs().format('YYYYMMDDHHmmss'),
  114. exportHeader: ["检验方法"],
  115. exportFooter: [],
  116. exportList: [],
  117. warehouseData: {
  118. id:'',
  119. site: '',
  120. },
  121. // 导出 end
  122. searchData: {
  123. site: '',
  124. userName: this.$store.state.user.name,
  125. transDate: '',
  126. warehouseID: '',
  127. rollNo: '',
  128. partNo: '',
  129. partDesc: '',
  130. qtyOnHand: '',
  131. batchNo: '',
  132. locationID: '',
  133. manufactureDate: '',
  134. orderRef1: '',
  135. receiver: '',
  136. FirstInDate: '',
  137. transType: '',
  138. page: 1,
  139. limit: 10,
  140. },
  141. pageIndex: 1,
  142. pageSize: 20,
  143. totalPage: 0,
  144. height: 200,
  145. secondHeight: 200,
  146. dataList: [],
  147. dataList2:[],
  148. dataListLoading: false,
  149. modalFlag: false,
  150. modalDisableFlag: false,
  151. modalData: {
  152. site: '',
  153. warehouseId: '',
  154. locationId: '',
  155. active: 'Y',
  156. locationName: '',
  157. creator: this.$store.state.user.name,
  158. // updateBy: this.$store.state.user.name,
  159. locationDescription: '',
  160. keeper: '',
  161. remarks: '',
  162. createTime: '',
  163. },//新增..用的
  164. // 标头展示
  165. columnList: [
  166. {
  167. userId: this.$store.state.user.name,
  168. functionId: 200005,
  169. serialNumber: '200005TableWarehouseId',
  170. tableId: "200005Table",
  171. tableName: "仓位编码",
  172. columnWidth: 130,
  173. columnProp: 'warehouseID',
  174. headerAlign: 'left',
  175. align: "left",
  176. columnLabel: '仓位编码',
  177. columnHidden: false,
  178. columnImage: false,
  179. columnSortable: false,
  180. sortLv: 0,
  181. status: true,
  182. fixed: '',
  183. },
  184. {
  185. userId: this.$store.state.user.name,
  186. functionId: 200005,
  187. serialNumber: '200005TablePartNo',
  188. tableId: "200005Table",
  189. tableName: "物料编码",
  190. columnWidth: 130,
  191. columnProp: 'partNo',
  192. headerAlign: 'left',
  193. align: "left",
  194. columnLabel: '物料编码',
  195. columnHidden: false,
  196. columnImage: false,
  197. columnSortable: false,
  198. sortLv: 0,
  199. status: true,
  200. fixed: '',
  201. },
  202. {
  203. userId: this.$store.state.user.name,
  204. functionId: 200005,
  205. serialNumber: '200005TablePartDesc',
  206. tableId: "200005Table",
  207. tableName: "料号描述",
  208. columnWidth: 130,
  209. columnProp: 'partDesc',
  210. headerAlign: 'left',
  211. align: "left",
  212. columnLabel: '料号描述',
  213. columnHidden: false,
  214. columnImage: false,
  215. columnSortable: false,
  216. sortLv: 0,
  217. status: true,
  218. fixed: '',
  219. },
  220. {
  221. userId: this.$store.state.user.name,
  222. functionId: 200005,
  223. serialNumber: '200005TableNum',
  224. tableId: "200005Table",
  225. tableName: "卷数量",
  226. columnWidth: 130,
  227. columnProp: 'num',
  228. headerAlign: 'right',
  229. align: "right",
  230. columnLabel: '卷数量',
  231. columnHidden: false,
  232. columnImage: false,
  233. columnSortable: false,
  234. sortLv: 0,
  235. status: true,
  236. fixed: '',
  237. },
  238. {
  239. userId: this.$store.state.user.name,
  240. functionId: 200005,
  241. serialNumber: '200005TableQtyOnHand',
  242. tableId: "200005Table",
  243. tableName: "库存数量",
  244. columnWidth: 130,
  245. columnProp: 'qtyOnHand',
  246. headerAlign: 'right',
  247. align: "right",
  248. columnLabel: '库存数量',
  249. columnHidden: false,
  250. columnImage: false,
  251. columnSortable: false,
  252. sortLv: 0,
  253. status: true,
  254. fixed: '',
  255. },
  256. {
  257. userId: this.$store.state.user.name,
  258. functionId: 200005,
  259. serialNumber: '200005TableBatchNo',
  260. tableId: "200005Table",
  261. tableName: "批号",
  262. columnWidth: 130,
  263. columnProp: 'batchNo',
  264. headerAlign: 'left',
  265. align: "left",
  266. columnLabel: '批号',
  267. columnHidden: false,
  268. columnImage: false,
  269. columnSortable: false,
  270. sortLv: 0,
  271. status: true,
  272. fixed: '',
  273. },
  274. {
  275. userId: this.$store.state.user.name,
  276. functionId: 200005,
  277. serialNumber: '200005TableLocationID',
  278. tableId: "200005Table",
  279. tableName: "库位",
  280. columnWidth: 130,
  281. columnProp: 'locationID',
  282. headerAlign: 'left',
  283. align: "left",
  284. columnLabel: '库位',
  285. columnHidden: false,
  286. columnImage: false,
  287. columnSortable: false,
  288. sortLv: 0,
  289. status: true,
  290. fixed: '',
  291. },
  292. {
  293. userId: this.$store.state.user.name,
  294. functionId: 200005,
  295. serialNumber: '200005TableManufactureDate',
  296. tableId: "200005Table",
  297. tableName: "生产日期",
  298. columnWidth: 130,
  299. columnProp: 'manufactureDate',
  300. headerAlign: 'center',
  301. align: "center",
  302. columnLabel: '生产日期',
  303. columnHidden: false,
  304. columnImage: false,
  305. columnSortable: false,
  306. sortLv: 0,
  307. status: true,
  308. fixed: '',
  309. },
  310. {
  311. userId: this.$store.state.user.name,
  312. functionId: 200005,
  313. serialNumber: '200005TableFirstInDate',
  314. tableId: "200005Table",
  315. tableName: "首次入库日期",
  316. columnWidth: 130,
  317. columnProp: 'FirstInDate',
  318. headerAlign: 'center',
  319. align: "center",
  320. columnLabel: '首次入库日期',
  321. columnHidden: false,
  322. columnImage: false,
  323. columnSortable: false,
  324. sortLv: 0,
  325. status: true,
  326. fixed: '',
  327. },
  328. {
  329. userId: this.$store.state.user.name,
  330. functionId: 200005,
  331. serialNumber: '200005TableExpiredDate',
  332. tableId: "200005Table",
  333. tableName: "失效日期",
  334. columnWidth: 130,
  335. columnProp: 'expiredDate',
  336. headerAlign: 'center',
  337. align: "center",
  338. columnLabel: '失效日期',
  339. columnHidden: false,
  340. columnImage: false,
  341. columnSortable: false,
  342. sortLv: 0,
  343. status: true,
  344. fixed: '',
  345. },
  346. {
  347. userId: this.$store.state.user.name,
  348. functionId: 200005,
  349. serialNumber: '200005TableDaysUntilExpired',
  350. tableId: "200005Table",
  351. tableName: "剩余有效期天数",
  352. columnWidth: 130,
  353. columnProp: 'daysUntilExpired',
  354. headerAlign: 'right',
  355. align: "right",
  356. columnLabel: '剩余有效期天数',
  357. columnHidden: false,
  358. columnImage: false,
  359. columnSortable: false,
  360. sortLv: 0,
  361. status: true,
  362. fixed: '',
  363. },
  364. ],
  365. columnList2:[
  366. {
  367. userId: this.$store.state.user.name,
  368. functionId: 200005,
  369. serialNumber: '200005TableRollNo',
  370. tableId: "200005Table",
  371. tableName: "卷号",
  372. columnWidth: 200,
  373. columnProp: 'rollNo',
  374. headerAlign: 'left',
  375. align: "left",
  376. columnLabel: '卷号',
  377. columnHidden: false,
  378. columnImage: false,
  379. columnSortable: false,
  380. sortLv: 0,
  381. status: true,
  382. fixed: '',
  383. },
  384. {
  385. userId: this.$store.state.user.name,
  386. functionId: 200005,
  387. serialNumber: '200005TableQtyOnHand',
  388. tableId: "200005Table",
  389. tableName: "库存数量",
  390. columnWidth: 200,
  391. columnProp: 'qtyOnHand',
  392. headerAlign: 'right',
  393. align: "right",
  394. columnLabel: '库存数量',
  395. columnHidden: false,
  396. columnImage: false,
  397. columnSortable: false,
  398. sortLv: 0,
  399. status: true,
  400. fixed: '',
  401. },
  402. {
  403. userId: this.$store.state.user.name,
  404. functionId: 200005,
  405. serialNumber: '200005TableManufactureDate',
  406. tableId: "200005Table",
  407. tableName: "生产日期",
  408. columnWidth: 200,
  409. columnProp: 'manufactureDate',
  410. headerAlign: 'center',
  411. align: "center",
  412. columnLabel: '生产日期',
  413. columnHidden: false,
  414. columnImage: false,
  415. columnSortable: false,
  416. sortLv: 0,
  417. status: true,
  418. fixed: '',
  419. },
  420. ],
  421. rules: {
  422. },
  423. options: [],
  424. userBuList: [],
  425. authSearch: false,
  426. authSave: false,
  427. authUpdate: false,
  428. authDelete: false,
  429. menuId: this.$route.meta.menuId,
  430. }
  431. },
  432. mounted () {
  433. this.$nextTick(() => {
  434. this.height = (window.innerHeight- 260) / 2
  435. })
  436. },
  437. //页面加载前初始化着两个方法
  438. created () {
  439. this.getDataList()
  440. //this.getWareHouseList()
  441. },
  442. methods: {
  443. // 获取用户的bu
  444. getSiteAndBuByUserName () {
  445. let tempData = {
  446. username: this.$store.state.user.name,
  447. }
  448. getSiteAndBuByUserName(tempData).then(({data}) => {
  449. if (data.code === 0) {
  450. this.userBuList = data.rows
  451. }
  452. })
  453. },
  454. //根据warehouse查询warehouseId
  455. getWareHouseList (){
  456. findByWarehouse(``).then(({data}) =>{
  457. this.wareHouseList=data.rows
  458. }
  459. )
  460. },
  461. // 查询获取数据列表
  462. getDataList (){
  463. this.searchData.limit = this.pageSize
  464. this.searchData.page = this.pageIndex
  465. findByNum(this.searchData).then(({data}) => {
  466. if (data.code === 0) {
  467. this.dataList = data.page.list
  468. this.pageIndex = data.page.currPage
  469. this.pageSize = data.page.pageSize
  470. this.totalPage = data.page.totalCount
  471. if(this.dataList.length>0){
  472. this.$refs.mainTable.setCurrentRow(this.dataList[0]);
  473. this.changeData(this.dataList[0])
  474. }else {
  475. this.changeData(null)
  476. }
  477. }
  478. })
  479. },
  480. // 每页数
  481. sizeChangeHandle (val) {
  482. this.pageSize = val
  483. this.pageIndex = 1
  484. this.getDataList()
  485. },
  486. // 当前页
  487. currentChangeHandle (val) {
  488. this.pageIndex = val
  489. this.getDataList()
  490. },
  491. tabClick (tab, event) {
  492. // 刷新列表数据
  493. this.refreshCurrentTabTable()
  494. },
  495. changeData(row){
  496. this.currentRow = JSON.parse(JSON.stringify(row));
  497. this.headerData=row;
  498. this.refreshCurrentTabTable ();
  499. },
  500. refreshCurrentTabTable(){
  501. if(this.currentRow===''||this.currentRow===null){
  502. this.currentRow={site:'',transNo:''}
  503. }
  504. findByNumOrRollNo(this.currentRow).then(({data}) => {
  505. //区分请求成功和失败的状况
  506. if (data && data.code == 0) {
  507. this.dataList2 = data.rows
  508. } else {
  509. this.dataList2 = [];
  510. }
  511. });
  512. },
  513. // // 新增按钮
  514. // addModal () {
  515. // this.modalData = {
  516. // flag: '1',
  517. // site: '',
  518. // creator: this.$store.state.user.name,
  519. // locationId: '',
  520. // locationName: '',
  521. // active: 'Y',
  522. // warehouseId: '',
  523. // locationDescription: '',
  524. // keeper: '',
  525. // remarks: '',
  526. // }
  527. // this.modalDisableFlag = false
  528. // this.modalFlag = true
  529. // },
  530. // // 修改按钮
  531. // updateModal (row) {
  532. // this.modalData = {
  533. // flag: '2',
  534. // id:row.id,
  535. // site: row.site,
  536. // creator: this.$store.state.user.name,
  537. // warehouseId: row.warehouseId,
  538. // locationId: row.locationId,
  539. // active: row.active,
  540. // locationName: row.locationName,
  541. // locationDescription: row.locationDescription,
  542. // keeper: row.keeper,
  543. // remarks: row.remarks,
  544. // }
  545. // this.modalDisableFlag = true
  546. // this.modalFlag = true
  547. // },
  548. // 删除方法
  549. // deleteModal (row) {
  550. // this.$confirm(`是否删除这个检验方法?`, '提示', {
  551. // confirmButtonText: '确定',
  552. // cancelButtonText: '取消',
  553. // type: 'warning'
  554. // }).then(() => {
  555. // deleteLocation(row).then(({data}) => {
  556. // if (data && data.code === 0) {
  557. // this.getDataList()
  558. // this.$message({
  559. // message: '操作成功',
  560. // type: 'success',
  561. // duration: 1500,
  562. // onClose: () => {}
  563. // })
  564. // } else {
  565. // this.$alert(data.msg, '错误', {
  566. // confirmButtonText: '确定'
  567. // })
  568. // }
  569. // })
  570. // }).catch(() => {
  571. // })
  572. // },
  573. // 新增/修改方法
  574. // saveData () {
  575. // if (this.modalData.site === '' || this.modalData.site == null) {
  576. // this.$message.warning('请输入工厂编码!')
  577. // return
  578. // }
  579. // if (this.modalData.warehouseId === '' || this.modalData.warehouseId == null) {
  580. // this.$message.warning('请选择仓库编码!')
  581. // return
  582. // }
  583. // if(this.modalData.locationName === ''|| this.modalData.locationName == null){
  584. // this.$message.warning('请输入库位名称!')
  585. // return
  586. // }
  587. // if(this.modalData.locationId === ''|| this.modalData.locationId == null){
  588. // this.$message.warning('请输入库位编码!')
  589. // return
  590. // }
  591. // if (this.modalData.flag === '1') { // 新增
  592. // saveLocation(this.modalData).then(({data}) => {
  593. // if (data && data.code === 0) {
  594. // this.getDataList()
  595. // this.modalFlag = false
  596. // this.$message({
  597. // message: '操作成功',
  598. // type: 'success',
  599. // duration: 1500,
  600. // onClose: () => {}
  601. // })
  602. // } else {
  603. // this.$alert(data.msg, '错误', {
  604. // confirmButtonText: '确定'
  605. // })
  606. // }
  607. // })
  608. // } else { // 修改
  609. // updateLocation(this.modalData).then(({data}) => {
  610. // if (data && data.code === 0) {
  611. // this.getDataList()
  612. // this.modalFlag = false
  613. // this.$message({
  614. // message: '操作成功',
  615. // type: 'success',
  616. // duration: 1500,
  617. // onClose: () => {}
  618. // })
  619. // } else {
  620. // this.$alert(data.msg, '错误', {
  621. // confirmButtonText: '确定'
  622. // })
  623. // }
  624. // })
  625. // }
  626. // },
  627. // 查询检验类型
  628. inspectionTypeSearch () {
  629. let tempData = {
  630. site: this.$store.state.user.site
  631. }
  632. inspectionTypeSearch(tempData).then(({data}) => {
  633. if (data.code === 0) {
  634. this.options = data.rows
  635. }
  636. })
  637. },
  638. // 校验用户是否收藏
  639. favoriteIsOk () {
  640. let userFavorite = {
  641. userId: this.$store.state.user.id,
  642. languageCode: this.$i18n.locale
  643. }
  644. userFavoriteList(userFavorite).then(({data}) => {for (let i = 0; i < data.list.length; i++) {
  645. if(this.$route.meta.menuId === data.list[i].menuId){
  646. this.favorite = true
  647. }
  648. }
  649. })
  650. },
  651. // 收藏 OR 取消收藏
  652. favoriteFunction () {
  653. let userFavorite = {
  654. userId: this.$store.state.user.id,
  655. functionId: this.$route.meta.menuId,
  656. }
  657. if (this.favorite) {
  658. removeUserFavorite(userFavorite).then(({data}) => {
  659. this.$message.success(data.msg)
  660. this.favorite = false
  661. })
  662. } else {
  663. // 收藏
  664. saveUserFavorite(userFavorite).then(({data}) => {
  665. this.$message.success(data.msg)
  666. this.favorite = true
  667. })
  668. }
  669. },
  670. //导出excel
  671. async createExportData() {
  672. this.searchData.limit = -1
  673. this.searchData.page = 1
  674. await findByNum(this.searchData).then(({data}) => {
  675. this.exportList= data.rows
  676. })
  677. return this.exportList
  678. },
  679. startDownload() {},
  680. finishDownload() {},
  681. fields () {
  682. let json = "{"
  683. this.columnList.forEach((item, index) => {
  684. if (index == this.columnList.length - 1) {
  685. json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\""
  686. } else {
  687. json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\"" + ","
  688. }
  689. })
  690. json += "}"
  691. let s = eval("(" + json + ")")
  692. return s
  693. },
  694. // 动态列开始 获取 用户保存的 格式列
  695. async getTableUserColumn (tableId, columnId) {
  696. let queryTableUser = {
  697. userId: this.$store.state.user.name,
  698. functionId: this.$route.meta.menuId,
  699. tableId: tableId,
  700. status: true,
  701. languageCode: this.$i18n.locale
  702. }
  703. await getTableUserListLanguage(queryTableUser).then(({data}) => {
  704. if (data.rows.length > 0) {
  705. //this.columnList1 = []
  706. switch (columnId) {
  707. case 1:
  708. this.columnList = data.rows
  709. break;
  710. // case 2:
  711. // this.columnDetailList = data.rows
  712. // break;
  713. // case 3:
  714. // this.columnList2 = data.rows
  715. // break;
  716. // case 4:
  717. // this.columnList3 = data.rows
  718. // break;
  719. }
  720. } else {
  721. this.getColumnList(tableId, columnId)
  722. }
  723. })
  724. },
  725. // 获取 tableDefault 列
  726. async getColumnList (tableId, columnId) {
  727. let queryTable = {
  728. functionId: this.$route.meta.menuId,
  729. tableId: tableId,
  730. languageCode: this.$i18n.locale
  731. }
  732. await getTableDefaultListLanguage(queryTable).then(({data}) => {
  733. if (!data.rows.length == 0) {
  734. switch (columnId) {
  735. case 1:
  736. this.columnList = data.rows
  737. break;
  738. // case 2:
  739. // this.columnDetailList = data.rows
  740. // break;
  741. // case 3:
  742. // this.columnList2 = data.rows
  743. // break;
  744. // case 4:
  745. // this.columnList3 = data.rows
  746. // break;
  747. }
  748. } else {
  749. // this.showDefault = true.
  750. }
  751. })
  752. },
  753. //获取按钮的权限数据
  754. getButtonAuthData () {
  755. let searchFlag = this.isAuth(this.menuId+":search")
  756. let saveFlag = this.isAuth(this.menuId+":save")
  757. let updateFlag = this.isAuth(this.menuId+":update")
  758. let deleteFlag = this.isAuth(this.menuId+":delete")
  759. //处理页面的权限数据
  760. this.authSearch = !searchFlag
  761. this.authSave = !saveFlag
  762. this.authUpdate = !updateFlag
  763. this.authDelete = !deleteFlag
  764. },
  765. }
  766. }
  767. </script>