Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
factory_front
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
qinjianhui
factory_front
Commits
e8396971
Commit
e8396971
authored
Jan 13, 2026
by
qinjianhui
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' into 'master'
fix: POD(CN & US) DTF排版 修改 See merge request
!140
parents
14603244
9f5792ba
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
36 additions
and
171 deletions
+36
-171
src/api/podCnOrder.ts
+2
-1
src/api/podUsOrder.ts
+2
-1
src/views/order/podCN/index.vue
+16
-39
src/views/order/podUs/index.vue
+16
-130
No files found.
src/api/podCnOrder.ts
View file @
e8396971
...
...
@@ -483,12 +483,13 @@ export function refreshProductInformationApi(data: {
}
// 设计图排版
export
function
composingDesignImages
(
url
:
string
,
data
:
number
[],
type
?:
string
,
templateWidth
?:
number
,
)
{
return
axios
.
post
<
never
,
BaseRespData
<
never
>>
(
`
factory/podJomallOrderCn/composingDesignImages
?type=
${
type
}
&templateWidth=
${
templateWidth
}
`
,
`
${
url
}
?type=
${
type
}
&templateWidth=
${
templateWidth
}
`
,
data
,
)
}
...
...
src/api/podUsOrder.ts
View file @
e8396971
...
...
@@ -397,12 +397,13 @@ export function updateSelfLogistics(params: {
// 更改物流
export
function
composingDesignImages
(
url
:
string
,
data
:
number
[],
type
?:
string
,
templateWidth
?:
number
,
)
{
return
axios
.
post
<
never
,
BaseRespData
<
never
>>
(
`
factory/podJomallOrderUs/composingDesignImages
?type=
${
type
}
&templateWidth=
${
templateWidth
}
`
,
`
${
url
}
?type=
${
type
}
&templateWidth=
${
templateWidth
}
`
,
data
,
)
}
...
...
src/views/order/podCN/index.vue
View file @
e8396971
...
...
@@ -612,38 +612,6 @@
</ElDropdown>
</ElFormItem>
<ElFormItem>
<!-- <span
v-if="
status === 'PICKING' ||
status === 'TO_BE_REPLENISHMENT' ||
status === 'IN_PRODUCTION'
"
class="item"
>
<ElButton
:loading="tifDownloadLoading"
type="warning"
@click="downloadTif('tiff')"
>
TIF排版
</ElButton>
</span>
<span
v-if="
status === 'PICKING' ||
status === 'TO_BE_REPLENISHMENT' ||
status === 'IN_PRODUCTION'
"
class="item"
>
<ElButton
:loading="pngDownloadLoading"
type="warning"
@click="downloadTif('png')"
>
PNG排版
</ElButton>
</span> -->
<span
v-if=
"status === 'TO_BE_CONFIRMED'"
class=
"item"
>
<ElButton
type=
"success"
@
click=
"confirmProduct"
>
确认生产
...
...
@@ -4259,13 +4227,18 @@ const downloadTif = async (type: string, templateWidth: number) => {
text
:
'操作中...'
,
background
:
'rgba(0, 0, 0, 0.3)'
,
}
)
const
url
=
status
.
value
===
'TO_BE_REPLENISHMENT'
?
'factory/podJomallOrderCn/replenishmentComposingDesignImages'
:
'factory/podJomallOrderCn/composingDesignImages'
try
{
const
res
=
await
composingDesignImages
(
url
,
cardSelection
.
value
.
map
((
el
)
=>
el
.
id
),
type
,
templateWidth
,
)
const
u
rl
=
const
filePathU
rl
=
type
===
'tiff'
?
res
.
message
?.
startsWith
(
'/temp'
)
?
`https://factory.jomalls.com/upload/factory`
+
res
.
message
...
...
@@ -4273,10 +4246,10 @@ const downloadTif = async (type: string, templateWidth: number) => {
:
filePath
+
res
.
message
if
(
type
===
'tiff'
)
{
window
.
open
(
u
rl
,
'_blank'
)
window
.
open
(
filePathU
rl
,
'_blank'
)
tifDownloadLoading
.
value
=
false
}
else
{
fetch
(
u
rl
)
fetch
(
filePathU
rl
)
.
then
((
response
)
=>
{
// 确保响应是 OK
if
(
!
response
.
ok
)
{
...
...
@@ -4352,9 +4325,13 @@ const downloadSingleType = async (
templateWidth
?:
number
,
)
=>
{
try
{
const
res
=
await
composingDesignImages
([
id
],
type
,
templateWidth
)
const
url
=
status
.
value
===
'TO_BE_REPLENISHMENT'
?
'factory/podJomallOrderCn/replenishmentComposingDesignImages'
:
'factory/podJomallOrderCn/composingDesignImages'
const
res
=
await
composingDesignImages
(
url
,
[
id
],
type
,
templateWidth
)
const
isTiff
=
type
===
'tiff'
const
u
rl
=
isTiff
const
filePathU
rl
=
isTiff
?
res
.
message
?.
startsWith
(
'/temp'
)
?
`https://factory.jomalls.com/upload/factory`
+
res
.
message
:
`https://ps.jomalls.com/tiff/`
+
res
.
message
...
...
@@ -4362,10 +4339,10 @@ const downloadSingleType = async (
if
(
isTiff
)
{
// 对于tiff类型,直接在新窗口打开
window
.
open
(
u
rl
,
'_blank'
)
window
.
open
(
filePathU
rl
,
'_blank'
)
}
else
{
// 对于其他类型,使用下载方式
await
downloadFile
(
u
rl
,
res
.
message
as
string
)
await
downloadFile
(
filePathU
rl
,
res
.
message
as
string
)
}
}
catch
(
error
)
{
console
.
error
(
`下载类型 ${type
}
时出错:`
,
error
)
...
...
src/views/order/podUs/index.vue
View file @
e8396971
...
...
@@ -577,40 +577,6 @@
</
template
>
</ElDropdown>
</ElFormItem>
<!-- <ElFormItem
v-if="
status === 'PICKING' ||
status === 'TO_BE_REPLENISHMENT' ||
status === 'IN_PRODUCTION'
"
>
<span class="item">
<ElButton
:loading="tifDownloadLoading"
type="warning"
@click="downloadTif('tiff')"
>
TIF排版
</ElButton>
</span>
</ElFormItem>
<ElFormItem
v-if="
status === 'PICKING' ||
status === 'TO_BE_REPLENISHMENT' ||
status === 'IN_PRODUCTION'
"
>
<span class="item">
<ElButton
:loading="pngDownloadLoading"
type="warning"
@click="downloadTif('png')"
>
PNG排版
</ElButton>
</span>
</ElFormItem> -->
<ElFormItem
v-if=
"status === 'TO_BE_CONFIRMED'"
>
<span
class=
"item"
>
<ElButton
type=
"success"
@
click=
"confirmProduct"
>
...
...
@@ -4600,23 +4566,28 @@ const downloadTif = async (type: string, templateWidth: number) => {
text
:
'操作中...'
,
background
:
'rgba(0, 0, 0, 0.3)'
,
}
)
const
url
=
status
.
value
===
'TO_BE_REPLENISHMENT'
?
'factory/podJomallOrderUs/replenishmentComposingDesignImages'
:
'factory/podJomallOrderUs/composingDesignImages'
try
{
const
res
=
await
composingDesignImages
(
url
,
cardSelection
.
value
.
map
((
el
)
=>
el
.
id
),
type
,
templateWidth
,
)
const
u
rl
=
const
filePathU
rl
=
type
===
'tiff'
?
res
.
message
?.
startsWith
(
'/temp'
)
?
`https://factory.jomalls.com/upload/factory`
+
res
.
message
:
`https://ps.jomalls.com/tiff/`
+
res
.
message
:
filePath
+
res
.
message
if
(
type
===
'tiff'
)
{
window
.
open
(
u
rl
,
'_blank'
)
window
.
open
(
filePathU
rl
,
'_blank'
)
tifDownloadLoading
.
value
=
false
}
else
{
fetch
(
u
rl
)
fetch
(
filePathU
rl
)
.
then
((
response
)
=>
{
// 确保响应是 OK
if
(
!
response
.
ok
)
{
...
...
@@ -4691,9 +4662,13 @@ const downloadSingleType = async (
templateWidth
?:
number
,
)
=>
{
try
{
const
res
=
await
composingDesignImages
([
id
],
type
,
templateWidth
)
const
url
=
status
.
value
===
'TO_BE_REPLENISHMENT'
?
'factory/podJomallOrderUs/replenishmentComposingDesignImages'
:
'factory/podJomallOrderUS/composingDesignImages'
const
res
=
await
composingDesignImages
(
url
,
[
id
],
type
,
templateWidth
)
const
isTiff
=
type
===
'tiff'
const
u
rl
=
isTiff
const
filePathU
rl
=
isTiff
?
res
.
message
?.
startsWith
(
'/temp'
)
?
`https://factory.jomalls.com/upload/factory`
+
res
.
message
:
`https://ps.jomalls.com/tiff/`
+
res
.
message
...
...
@@ -4701,10 +4676,10 @@ const downloadSingleType = async (
if
(
isTiff
)
{
// 对于tiff类型,直接在新窗口打开
window
.
open
(
u
rl
,
'_blank'
)
window
.
open
(
filePathU
rl
,
'_blank'
)
}
else
{
// 对于其他类型,使用下载方式
await
downloadFile
(
u
rl
,
res
.
message
as
string
)
await
downloadFile
(
filePathU
rl
,
res
.
message
as
string
)
}
}
catch
(
error
)
{
console
.
error
(
`下载类型 ${type
}
时出错:`
,
error
)
...
...
@@ -4778,95 +4753,6 @@ const handleMultiRadioGroupClick = (event: Event) => {
}
}
}
// const downloadTifItem = async () =>
{
// const row =
{
...(
typesettingRow
.
value
as
PodUsOrderListData
)
}
// const loading = ElLoading.service(
{
// fullscreen: true,
// text: '操作中...',
// background: 'rgba(0, 0, 0, 0.3)',
//
}
)
// const
{
templateWidth
,
typeArr
}
=
typesettingForm
.
value
// const type = (typeArr?.join(',') as string) || ''
// typesettingVisible.value = false
// try
{
// if ((typeArr as string[]).length > 1)
{
// typeArr?.forEach(async (el) =>
{
// const res = await composingDesignImages([row.id], el, templateWidth)
// const url =
// type === 'tiff'
// ? `https://ps.jomalls.com/tiff/` + res.message
// : filePath + res.message
// if (el === 'tiff')
{
// window.open(url, '_blank')
//
}
else
{
// fetch(url)
// .then((response) =>
{
// // 确保响应是 OK
// if (!response.ok)
{
// throw new Error('网络响应错误')
//
}
// // 返回图片的二进制数据(Blob)
// return response.blob()
//
}
)
// .then((blob) =>
{
// const a = document.createElement('a')
// a.href = window.URL.createObjectURL(blob)
// a.target = '_blank'
// a.download = (res.message as string).split('/')[
// (res.message as string).split('/').length - 1
// ]
// a.click()
// pngDownloadLoading.value = false
//
}
)
// .catch((error) =>
{
// console.error('下载图片时出错:', error)
// pngDownloadLoading.value = false
//
}
)
//
}
//
}
)
//
}
else
{
// const res = await composingDesignImages([row.id], type, templateWidth)
// const url =
// type === 'tiff'
// ? `https://ps.jomalls.com/tiff/` + res.message
// : filePath + res.message
// if (type === 'tiff')
{
// window.open(url, '_blank')
//
}
else
{
// fetch(url)
// .then((response) =>
{
// // 确保响应是 OK
// if (!response.ok)
{
// throw new Error('网络响应错误')
//
}
// // 返回图片的二进制数据(Blob)
// return response.blob()
//
}
)
// .then((blob) =>
{
// const a = document.createElement('a')
// a.href = window.URL.createObjectURL(blob)
// a.target = '_blank'
// a.download = (res.message as string).split('/')[
// (res.message as string).split('/').length - 1
// ]
// a.click()
// pngDownloadLoading.value = false
//
}
)
// .catch((error) =>
{
// console.error('下载图片时出错:', error)
// pngDownloadLoading.value = false
//
}
)
//
}
//
}
//
}
catch
(
e
)
{
// console.log(e)
//
}
finally
{
// typesettingRow.value = undefined
// loading.close()
//
}
//
}
const
loadProductionClient
=
async
()
=>
{
try
{
const
res
=
await
getProductionClientApi
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment