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
9b747eca
Commit
9b747eca
authored
Mar 11, 2025
by
wuqian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
下载素材优化
parent
640e6d02
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
27 additions
and
16 deletions
+27
-16
src/views/order/fastProduction.vue
+27
-16
No files found.
src/views/order/fastProduction.vue
View file @
9b747eca
...
@@ -324,7 +324,7 @@ const props = defineProps({
...
@@ -324,7 +324,7 @@ const props = defineProps({
type
:
String
,
type
:
String
,
},
},
})
})
const
emit
=
defineEmits
([
'update:detailVisible'
,
'close'
,
'onSuccess'
])
const
emit
=
defineEmits
([
'update:detailVisible'
,
'close'
,
'onSuccess'
])
watch
(
watch
(
()
=>
props
.
detailVisible
,
()
=>
props
.
detailVisible
,
...
@@ -367,9 +367,11 @@ watch(
...
@@ -367,9 +367,11 @@ watch(
watch
(
watch
(
()
=>
props
.
detailData
,
()
=>
props
.
detailData
,
(
newVal
)
=>
{
(
newVal
)
=>
{
// detail.value = {
detail
.
value
=
{
// imgList: [],
id
:
-
1
,
// }
podOrderId
:
-
1
,
imgList
:
[],
}
if
(
newVal
&&
Object
.
keys
(
newVal
).
length
>
0
)
{
if
(
newVal
&&
Object
.
keys
(
newVal
).
length
>
0
)
{
const
d
=
JSON
.
parse
(
JSON
.
stringify
(
newVal
))
const
d
=
JSON
.
parse
(
JSON
.
stringify
(
newVal
))
if
(
d
.
note
)
{
if
(
d
.
note
)
{
...
@@ -462,7 +464,7 @@ const changeStatus = async () => {
...
@@ -462,7 +464,7 @@ const changeStatus = async () => {
})
})
}
}
const
setData
=
async
(
orderNumber
:
string
)
=>
{
const
setData
=
async
(
orderNumber
:
string
)
=>
{
if
(
detail
.
value
&&
detail
.
value
?.
id
!=
-
1
)
{
if
(
detail
.
value
&&
detail
.
value
?.
id
!=
-
1
)
{
try
{
try
{
const
id
=
detail
.
value
?.
id
const
id
=
detail
.
value
?.
id
await
productionQueryApi
(
id
)
await
productionQueryApi
(
id
)
...
@@ -498,18 +500,27 @@ const handleDownload = () => {
...
@@ -498,18 +500,27 @@ const handleDownload = () => {
download
()
download
()
}
}
const
download
=
async
()
=>
{
const
download
=
async
()
=>
{
try
{
if
(
detail
.
value
&&
detail
.
value
?.
id
!=
-
1
)
{
const
id
=
detail
.
value
.
id
try
{
if
(
id
!==
undefined
)
{
const
id
=
detail
.
value
.
id
const
res
=
await
downloadMaterialApi
([
id
])
if
(
id
!==
undefined
)
{
const
{
data
}
=
res
const
res
=
await
downloadMaterialApi
([
id
])
data
.
forEach
((
item
:
string
)
=>
{
const
{
data
}
=
res
window
.
open
(
filePath
+
item
)
data
.
forEach
((
item
:
string
)
=>
{
})
// window.open(filePath + item)
const
a
=
document
.
createElement
(
'a'
)
a
.
href
=
filePath
+
item
a
.
download
=
item
a
.
target
=
'_blank'
document
.
body
.
appendChild
(
a
)
a
.
click
()
document
.
body
.
removeChild
(
a
)
})
}
}
catch
(
e
)
{
// showError(e)
console
.
error
(
e
)
}
}
}
catch
(
e
)
{
// showError(e)
console
.
error
(
e
)
}
}
}
}
type
AudioKey
=
keyof
typeof
audios
// 创建一个类型,确保 key 只能是 audios 对象的键之一
type
AudioKey
=
keyof
typeof
audios
// 创建一个类型,确保 key 只能是 audios 对象的键之一
...
...
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