From 996f10243bb04886670ae57350b057c123a81341 Mon Sep 17 00:00:00 2001 From: zhaoyiran Date: Fri, 6 Dec 2024 17:42:32 +0800 Subject: [PATCH] =?UTF-8?q?YT-1458=E6=89=93=E5=8D=B0=E8=A1=A5=E7=BB=99?= =?UTF-8?q?=E5=93=81=E5=A4=87=E6=96=99=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../preparetoissueMain/index.vue | 23 ++++++++++++++++++- .../preparetoissueMain.data.ts | 2 +- 2 files changed, 23 insertions(+), 2 deletions(-) diff --git a/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/index.vue b/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/index.vue index 7eaebfacd..2f68f971b 100644 --- a/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/index.vue +++ b/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/index.vue @@ -90,7 +90,8 @@ import * as defaultButtons from '@/utils/disposition/defaultButtons' import * as ProductionlineitemApi from '@/api/wms/productionlineitem' import { formatDate } from '@/utils/formatTime' import { usePageLoading } from '@/hooks/web/usePageLoading' -import { getBaseUrl } from '@/utils/systemParam' +import {getBaseUrl, getJmreportBaseUrl} from '@/utils/systemParam' +import {getAccessToken} from "@/utils/auth"; const { loadStart, loadDone } = usePageLoading() // 备料计划 @@ -317,6 +318,17 @@ const butttondata = (row,$index) => { link: true, // 文本展现按钮 color: '' }, + { + label: '打印补给品备料单', + name: 'printSupplyList', + hide: isShowMainButton(row,['6']), + type: 'primary', + icon: 'Select', + hasPermi:'wms:preparetoissue-main:publish', + link: true, // 文本展现按钮 + color: '' + }, + ] } @@ -428,9 +440,18 @@ const buttonTableClick = async (val, row) => { openForm('update', row) } else if (val == 'delete') { // 删除 handleDelete(row.masterId) + } else if (val == 'printSupplyList'){ + // 打印补给品备料单 + handlePrintSupplyList(row.masterId) } } +const BASE_URL = getJmreportBaseUrl() +const documentSrc = ref(BASE_URL + '/jmreport/view/1024904872747347968?token=' + getAccessToken()) +const handlePrintSupplyList = async (id) => { + window.open(documentSrc.value + '&id=' + id) +} + /** 添加/修改操作 */ const formRef = ref() const openForm =async (type: string, row?: number) => { diff --git a/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/preparetoissueMain.data.ts b/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/preparetoissueMain.data.ts index e92acfb6d..e8d4440ae 100644 --- a/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/preparetoissueMain.data.ts +++ b/src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/preparetoissueMain.data.ts @@ -483,7 +483,7 @@ export const PreparetoissueMain = useCrudSchemas(reactive([ isDetail: false, isForm: false, table: { - width: 220, + width: 320, fixed: 'right' }, }