diff --git a/src/api/wms/printLabelCorrelation/index.ts b/src/api/wms/printLabelCorrelation/index.ts
new file mode 100644
index 000000000..a5370b81c
--- /dev/null
+++ b/src/api/wms/printLabelCorrelation/index.ts
@@ -0,0 +1,50 @@
+import request from '@/config/axios'
+
+export interface PrintCorrelationVO {
+ id: number
+ number: string
+ labelId: string
+ labelType: string
+ available: string
+}
+
+// 查询打印标签关联列表
+export const getPrintCorrelationPage = async (params) => {
+ if (params.isSearch) {
+ delete params.isSearch
+ const data = {...params}
+ return await request.post({ url: '/wms/print-correlation/senior', data })
+ } else {
+ return await request.get({ url: `/wms/print-correlation/page`, params })
+ }
+}
+
+// 查询打印标签关联详情
+export const getPrintCorrelation = async (id: number) => {
+ return await request.get({ url: `/wms/print-correlation/get?id=` + id })
+}
+
+// 新增打印标签关联
+export const createPrintCorrelation = async (data: PrintCorrelationVO) => {
+ return await request.post({ url: `/wms/print-correlation/create`, data })
+}
+
+// 修改打印标签关联
+export const updatePrintCorrelation = async (data: PrintCorrelationVO) => {
+ return await request.put({ url: `/wms/print-correlation/update`, data })
+}
+
+// 删除打印标签关联
+export const deletePrintCorrelation = async (id: number) => {
+ return await request.delete({ url: `/wms/print-correlation/delete?id=` + id })
+}
+
+// 导出打印标签关联 Excel
+export const exportPrintCorrelation = async (params) => {
+ return await request.download({ url: `/wms/print-correlation/export-excel`, params })
+}
+
+// 下载用户导入模板
+export const importTemplate = () => {
+ return request.download({ url: '/wms/print-correlation/get-import-template' })
+}
\ No newline at end of file
diff --git a/src/views/wms/inventoryManage/balance/index.vue b/src/views/wms/inventoryManage/balance/index.vue
index f566ba699..e4a619623 100644
--- a/src/views/wms/inventoryManage/balance/index.vue
+++ b/src/views/wms/inventoryManage/balance/index.vue
@@ -178,20 +178,31 @@ const openDetail = (row: any, titleName: any, titleValue: any) => {
}
const BASE_URL = import.meta.env.VITE_JMREPORT_BASE_URL
-
+const labelType = ref('') // 标签类别 采购还是制造等
// 标签打印
const handlePoint = async (row) => {
console.log(row.packingNumber,445555555555555);
PackageApi.getBalanceToPackage(row.packingNumber).then(res => {
- console.log(res,66666666666);
- // 判断是采购还是制造
- if (res.asnNumber !== null && res.asnNumber !== '') {
+ console.log(777,res);
+ if (res.productionLineCode != null) {
+ labelType.value = 'zz'
+ } else {
+ labelType.value = 'cg'
+ }
+ PackageApi.batchPrintingLable((res.number)).then((resLable) =>{
+ console.log(159,resLable )
+ // 判断是采购还是制造
+ if (labelType.value == 'cg') {
const src = ref(BASE_URL + '/jmreport/view/922729953438072832?token=' + getAccessToken())
- window.open(src.value+'&asn_number='+res.id)
+ console.log(159,resLable )
+ window.open(src.value+'&asn_number='+resLable)
} else {
const src = ref(BASE_URL + '/jmreport/view/922734157577715712?token=' + getAccessToken())
- window.open(src.value+'&asn_number='+res.id)
+ window.open(src.value+'&asn_number='+resLable)
}
+ })
+ }).catch(err => {
+ console.log(err)
})
}
diff --git a/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRecordMain/index.vue b/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRecordMain/index.vue
index 6729c03a1..ec1050a12 100644
--- a/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRecordMain/index.vue
+++ b/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRecordMain/index.vue
@@ -66,6 +66,7 @@ import download from '@/utils/download'
import { PackageoverMain,PackageoverMainRules, PackageoverDetail, PackageoverDetailRules } from './packageoverRecordMain.data'
import * as PackageoverRecordMainApi from '@/api/wms/packageoverRecordMain'
import * as PackageoverRecordDetailApi from '@/api/wms/packageoverRecordDetail'
+import * as printLabelCorrelationApi from '@/api/wms/printLabelCorrelation'
import * as defaultButtons from '@/utils/disposition/defaultButtons'
import * as PackageApi from '@/api/wms/package'
import { getAccessToken } from '@/utils/auth'
@@ -149,19 +150,22 @@ const handlePoint = async (row) => {
} else {
labelType.value = 'cg'
}
- }
- }).catch(err => {
- console.log(err)
- })
- // 判断是采购还是制造
- if (labelType.value == 'cg') {
+ PackageApi.batchPrintingLable(res.list.map(item1=>item1.number).join(',')).then((resLable) =>{
+ console.log(159,resLable )
+
+ // 判断是采购还是制造
+ if (labelType.value == 'cg') {
const src = ref(BASE_URL + '/jmreport/view/922729953438072832?token=' + getAccessToken())
- console.log(159,row.number )
- window.open(src.value+'&asn_number='+row.number)
+ window.open(src.value+'&asn_number='+resLable)
} else {
const src = ref(BASE_URL + '/jmreport/view/922734157577715712?token=' + getAccessToken())
- window.open(src.value+'&asn_number='+row.number)
+ window.open(src.value+'&asn_number='+resLable)
}
+ })
+ }
+ }).catch(err => {
+ console.log(err)
+ })
}
/** 详情操作 */
diff --git a/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/index.vue b/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/index.vue
index b05a91479..24f86773b 100644
--- a/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/index.vue
+++ b/src/views/wms/inventoryjobManage/packageManage/packageoverMain/packageoverRequestMain/index.vue
@@ -74,9 +74,7 @@
-
-
-
+