| | |
| | | </template> |
| | | <script> |
| | | import ttable from '@/views/common/ztt-table.vue' |
| | | import { getRawInspectList,delObj,exportRawMaterial,getObj } from '@/api/quality/rawMaterial' |
| | | import { getRawInspectList,delObj,exportRawMaterial,getObj,downloadReport } from '@/api/quality/rawMaterial' |
| | | import RawMaterialForm from './rawMaterial-form' |
| | | import * as fecha from 'element-ui/lib/utils/date' |
| | | import { mapGetters } from 'vuex' |
| | | import PrintJS from 'print-js' |
| | | import { transformZip } from '@/util/fileTransform' |
| | | import printTemplate from './rawMaterial-print.vue' |
| | | export default { |
| | | data() { |
| | |
| | | fun: this.downloadReport |
| | | } |
| | | ], |
| | | operator: [{ |
| | | text: '打印', |
| | | type: 'text', |
| | | size: 'small', |
| | | fun: this.previewFun, |
| | | show: { |
| | | val: [ |
| | | '1', |
| | | '0' |
| | | ], |
| | | key: 'judgeState' |
| | | } |
| | | }, |
| | | operator: [ |
| | | // { |
| | | // text: '打印', |
| | | // type: 'text', |
| | | // size: 'small', |
| | | // fun: this.previewFun, |
| | | // show: { |
| | | // val: [ |
| | | // '1', |
| | | // '0' |
| | | // ], |
| | | // key: 'judgeState' |
| | | // } |
| | | // }, |
| | | { |
| | | text: '作废', |
| | | type: 'text', |
| | |
| | | return |
| | | } |
| | | console.log(selection) |
| | | downloadReport().then(res=>{ |
| | | transformZip(res) |
| | | }).catch(error=>{ |
| | | console.log(error) |
| | | }) |
| | | } |
| | | }, |
| | | //查看报告按钮 |