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
df3ce930
Commit
df3ce930
authored
Mar 31, 2026
by
qinjianhui
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 拣胚失败表格字段
parent
54e79062
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
52 additions
and
11 deletions
+52
-11
src/views/order/factoryOrderNew/component/PickFailDialog.vue
+41
-8
src/views/order/factoryOrderNew/index.vue
+11
-3
No files found.
src/views/order/factoryOrderNew/component/PickFailDialog.vue
View file @
df3ce930
<
template
>
<
template
>
<ElDialog
<ElDialog
v-model=
"visible"
v-model=
"visible"
title=
"拣胚失败
"
:title=
"dialogTitle
"
width=
"1400px"
width=
"1400px"
:close-on-click-modal=
"false"
:close-on-click-modal=
"false"
@
close=
"handleClose"
@
close=
"handleClose"
...
@@ -66,7 +66,7 @@
...
@@ -66,7 +66,7 @@
</ElDialog>
</ElDialog>
</template>
</template>
<
script
setup
lang=
"ts"
>
<
script
setup
lang=
"ts
x
"
>
import
{
ref
}
from
'vue'
import
{
ref
}
from
'vue'
import
{
ElMessage
}
from
'element-plus'
import
{
ElMessage
}
from
'element-plus'
import
{
import
{
...
@@ -75,7 +75,7 @@ import {
...
@@ -75,7 +75,7 @@ import {
}
from
'@/api/factoryOrderNew'
}
from
'@/api/factoryOrderNew'
import
type
{
operateOrderListData
}
from
'@/types/api/factoryOrderNew'
import
type
{
operateOrderListData
}
from
'@/types/api/factoryOrderNew'
import
TableView
from
'@/components/TableView.vue'
import
TableView
from
'@/components/TableView.vue'
import
type
{
CustomColumn
}
from
'@/types/table
'
import
_
from
'lodash
'
const
emit
=
defineEmits
<
{
const
emit
=
defineEmits
<
{
success
:
[]
success
:
[]
...
@@ -85,8 +85,8 @@ const visible = ref(false)
...
@@ -85,8 +85,8 @@ const visible = ref(false)
const
submitLoading
=
ref
(
false
)
const
submitLoading
=
ref
(
false
)
const
tableData
=
ref
<
operateOrderListData
[]
>
([])
const
tableData
=
ref
<
operateOrderListData
[]
>
([])
const
orderIds
=
ref
<
(
number
|
string
)[]
>
([])
const
orderIds
=
ref
<
(
number
|
string
)[]
>
([])
const
dialogTitle
=
ref
(
'拣胚失败'
)
const
columns
:
CustomColumn
<
operateOrderListData
>
[]
=
[
const
columns
=
[
{
{
key
:
'warehouseName'
,
key
:
'warehouseName'
,
prop
:
'warehouseName'
,
prop
:
'warehouseName'
,
...
@@ -151,16 +151,26 @@ const columns: CustomColumn<operateOrderListData>[] = [
...
@@ -151,16 +151,26 @@ const columns: CustomColumn<operateOrderListData>[] = [
minWidth
:
120
,
minWidth
:
120
,
align
:
'right'
,
align
:
'right'
,
slot
:
'suggestOutQuantity'
,
slot
:
'suggestOutQuantity'
,
render
:
(
row
:
operateOrderListData
)
=>
{
return
(
<
span
style
=
"color: #f56c6c; font-weight: bold"
>
{
_
.
subtract
(
Number
(
row
.
inventory
??
0
),
Number
(
row
.
producingQuantity
??
0
),
)}
<
/span
>
)
},
},
},
{
{
prop
:
'
afterOutStock
'
,
prop
:
'
producingQuantity
'
,
label
:
'出库后库存数量'
,
label
:
'出库后库存数量'
,
minWidth
:
130
,
minWidth
:
130
,
align
:
'center'
,
align
:
'center'
,
slot
:
'right'
,
slot
:
'right'
,
},
},
{
{
prop
:
'
afterOutOccupied
'
,
prop
:
'
inventory
'
,
label
:
'出库后占用数量'
,
label
:
'出库后占用数量'
,
minWidth
:
130
,
minWidth
:
130
,
align
:
'right'
,
align
:
'right'
,
...
@@ -170,12 +180,33 @@ const columns: CustomColumn<operateOrderListData>[] = [
...
@@ -170,12 +180,33 @@ const columns: CustomColumn<operateOrderListData>[] = [
label
:
'出库后可用库存'
,
label
:
'出库后可用库存'
,
minWidth
:
130
,
minWidth
:
130
,
align
:
'right'
,
align
:
'right'
,
render
:
(
row
:
operateOrderListData
)
=>
{
return
(
<
span
style
=
"color: #f56c6c; font-weight: bold"
>
{
_
.
subtract
(
_
.
subtract
(
Number
(
row
.
producingQuantity
??
0
),
Number
(
row
.
inventory
??
0
),
),
Number
(
row
.
freezeInventory
??
0
),
)}
<
/span
>
)
},
},
},
]
]
const
open
=
async
(
ids
:
(
number
|
string
)[])
=>
{
const
open
=
async
(
ids
:
(
number
|
string
)[],
options
?:
{
title
?:
string
;
submitType
?:
string
},
)
=>
{
dialogTitle
.
value
=
options
?.
title
||
'拣胚失败'
orderIds
.
value
=
ids
orderIds
.
value
=
ids
visible
.
value
=
true
visible
.
value
=
true
const
loading
=
ElLoading
.
service
({
text
:
'操作中...'
,
background
:
'rgba(0, 0, 0, 0.3)'
,
})
try
{
try
{
const
res
=
await
applyForReplenishByIdApi
(
const
res
=
await
applyForReplenishByIdApi
(
ids
,
ids
,
...
@@ -184,6 +215,8 @@ const open = async (ids: (number | string)[]) => {
...
@@ -184,6 +215,8 @@ const open = async (ids: (number | string)[]) => {
tableData
.
value
=
res
.
data
||
[]
tableData
.
value
=
res
.
data
||
[]
}
catch
(
_e
)
{
}
catch
(
_e
)
{
tableData
.
value
=
[]
tableData
.
value
=
[]
}
finally
{
loading
.
close
()
}
}
}
}
...
...
src/views/order/factoryOrderNew/index.vue
View file @
df3ce930
...
@@ -819,7 +819,9 @@
...
@@ -819,7 +819,9 @@
ref
=
"weightDialogRef"
ref
=
"weightDialogRef"
:
list
-
by
-
no
-
api
=
"listByNoPodOrderApi"
:
list
-
by
-
no
-
api
=
"listByNoPodOrderApi"
:
order
-
weighing
-
api
=
"orderWeighingPodOrderApi"
:
order
-
weighing
-
api
=
"orderWeighingPodOrderApi"
:
build
-
order
-
weighing
-
payload
=
"(rows) => ({ podOrderWeighingParams: rows
}
)"
:
build
-
order
-
weighing
-
payload
=
"
(rows) => ({ podOrderWeighingParams: rows
}
)
"
@
update
-
list
=
"() => refreshCurrentView({ isRefreshTree: true
}
)"
@
update
-
list
=
"() => refreshCurrentView({ isRefreshTree: true
}
)"
/>
/>
<
FastProduction
<
FastProduction
...
@@ -1657,7 +1659,10 @@ const handlePickComplete = () => {
...
@@ -1657,7 +1659,10 @@ const handlePickComplete = () => {
}
}
const
handlePickFail
=
()
=>
{
const
handlePickFail
=
()
=>
{
if
(
!
ensureSelection
())
return
if
(
!
ensureSelection
())
return
pickFailDialogRef
.
value
?.
open
(
getSelectedIds
())
pickFailDialogRef
.
value
?.
open
(
getSelectedIds
(),
{
title
:
'拣胚失败'
,
submitType
:
'pick'
,
}
)
}
}
const
handleApplyReplenish
=
async
()
=>
{
const
handleApplyReplenish
=
async
()
=>
{
await
executeBatchAction
({
await
executeBatchAction
({
...
@@ -1725,7 +1730,10 @@ const handleReplenishComplete = () => {
...
@@ -1725,7 +1730,10 @@ const handleReplenishComplete = () => {
}
}
const
handleReplenishFail
=
()
=>
{
const
handleReplenishFail
=
()
=>
{
if
(
!
ensureSelection
())
return
if
(
!
ensureSelection
())
return
ElMessage
.
info
(
'补胚失败功能待集成'
)
pickFailDialogRef
.
value
?.
open
(
getSelectedIds
(),
{
title
:
'补胚失败'
,
submitType
:
'replenish'
,
}
)
}
}
const
getOperationByNo
=
(
operationNo
:
string
)
=>
const
getOperationByNo
=
(
operationNo
:
string
)
=>
getByOperationNoLogApi
(
operationNo
)
as
Promise
<
{
data
?:
unknown
}
>
getByOperationNoLogApi
(
operationNo
)
as
Promise
<
{
data
?:
unknown
}
>
...
...
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