| | |
| | | import {VXETable} from "vxe-table"; |
| | | import {toolbarButtonClickEvent} from "@/hook/mouseMove"; |
| | | import PrintProcess from '@/views/pp/processCard/PrintProcess.vue' |
| | | import PrintLabel from '@/views/pp/processCard/PrintLabel.vue' |
| | | //语言获取 |
| | | const {t} = useI18n() |
| | | let router = useRouter() |
| | | const dialogTableVisible = ref(false) |
| | | const dialogTableVisibleLabel = ref(false) |
| | | let selectRecords = ref(null) |
| | | |
| | | //定义滚动条高度 |
| | |
| | | |
| | | toolbarConfig: { |
| | | buttons: [ |
| | | {code: 'print', name: '打印', status: 'primary'}, |
| | | {code: 'print', name: '打印流程卡', status: 'primary'}, |
| | | {code: 'printLabel', name: '打印标签', status: 'primary'}, |
| | | ], |
| | | // import: false, |
| | | // export: true, |
| | |
| | | } |
| | | router.push({path: '/main/processCard/printProcess', query: {printList: JSON.stringify(selectRecords)}}) |
| | | |
| | | // let routeData = router.resolve({path: '/main/processCard/printProcess', query: {printList: JSON.stringify(selectRecords)}}); |
| | | // window.open(routeData.href, '_blank'); |
| | | //dialogTableVisible.value = true |
| | | break |
| | | } |
| | | |
| | | case 'printLabel': { |
| | | if(selectRecords===null ||selectRecords===''||selectRecords.length===0){ |
| | | ElMessage.warning(t('searchOrder.msgList.checkOrder')) |
| | | return |
| | | } |
| | | |
| | | let id = "" |
| | | for (let i = 0; i < selectRecords.length; i++) { |
| | | if (i + 1 === selectRecords.length) { |
| | | id += selectRecords[i].id |
| | | } else { |
| | | id += selectRecords[i].id + "|" |
| | | } |
| | | } |
| | | router.push({path: '/main/processCard/PrintLabel', query: {printList: JSON.stringify(selectRecords)}}) |
| | | |
| | | break |
| | | } |
| | | |
| | |
| | | <PrintProcess :printList="selectRecords" |
| | | style="width: 100%;height: 100%" /> |
| | | </el-dialog> |
| | | |
| | | <el-dialog |
| | | v-model="dialogTableVisibleLabel" |
| | | destroy-on-close |
| | | title="标签打印" |
| | | style="width: 80%;height:75% "> |
| | | <PrintLabel :printList="selectRecords" |
| | | style="width: 100%;height: 100%" /> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | width: 99%; |
| | | height: 100%; |
| | | } |
| | | |
| | | </style> |