Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
CnChunfeng
/
scm_wms_outstore_service
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
90f1aced
authored
Jun 01, 2020
by
Joneq
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
修改整箱和整卡板判断
parent
b47f3541
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
2 deletions
app/Http/Model/Logic/PickTaskLogic.php
app/Http/Model/Logic/PickTaskLogic.php
View file @
90f1aced
...
...
@@ -434,13 +434,21 @@ class PickTaskLogic
$palletBoxGoodsData
=
PickTaskDetailModel
::
whereIn
(
'pick_task_detail_id'
,
$pickTaskDetailIdArr
)
->
select
(
'pallet_id'
,
'box_id'
,
'out_store_detail_id'
,
'pick_task_detail_id'
,
'number'
)
->
get
()
->
toArray
();
$pickTaskRemarkData
=
[];
//卡板和箱子的数量
$palletNum
=
[];
$boxNum
=
[];
foreach
(
$palletBoxGoodsData
as
$value
){
$value
[
'goods_id'
]
=
OutStoreDetailModel
::
where
(
'out_store_detail_id'
,
$value
[
'out_store_detail_id'
])
->
value
(
'goods_id'
);
$key
=
$value
[
'pallet_id'
]
.
'_'
.
$value
[
'box_id'
]
.
'_'
.
$value
[
'goods_id'
];
if
(
isset
(
$pickTaskRemarkData
[
$key
])){
$pickTaskRemarkData
[
$key
][
'number'
]
=
bcadd
(
$pickTaskRemarkData
[
$key
][
'number'
],
$value
[
'number'
]);
$palletNum
[
$value
[
'pallet_id'
]]
=
bcadd
(
$palletNum
[
$value
[
'pallet_id'
]],
$value
[
'number'
]);
$boxNum
[
$value
[
'box_id'
]]
=
bcadd
(
$boxNum
[
$value
[
'box_id'
]],
$value
[
'number'
]);
}
else
{
$pickTaskRemarkData
[
$key
][
'number'
]
=
$value
[
'number'
];
$palletNum
[
$value
[
'pallet_id'
]]
=
$value
[
'number'
];
$boxNum
[
$value
[
'box_id'
]]
=
$value
[
'number'
];
}
$pickTaskRemarkData
[
$key
][
'pick_task_detail_id_arr'
][]
=
$value
[
'pick_task_detail_id'
];
...
...
@@ -452,7 +460,7 @@ class PickTaskLogic
//卡板不为空卡板数量比较
if
(
!
empty
(
$locationArr
[
0
])){
if
(
$
value
[
'number'
]
==
StockModel
::
where
(
'pallet_id'
,
$locationArr
[
0
])
->
sum
(
'stock'
)){
if
(
$
palletNum
[
$locationArr
[
0
]
]
==
StockModel
::
where
(
'pallet_id'
,
$locationArr
[
0
])
->
sum
(
'stock'
)){
$pickRemark
=
'整卡板'
;
}
else
{
$pickRemark
=
'拆零'
;
...
...
@@ -460,7 +468,7 @@ class PickTaskLogic
}
else
{
//箱不为空,箱数量比较
if
(
!
empty
(
$locationArr
[
1
])){
if
(
$
value
[
'number'
]
==
StockModel
::
where
(
'box_id'
,
$locationArr
[
1
])
->
sum
(
'stock'
)){
if
(
$
boxNum
[
$locationArr
[
1
]
]
==
StockModel
::
where
(
'box_id'
,
$locationArr
[
1
])
->
sum
(
'stock'
)){
$pickRemark
=
'整箱'
;
}
else
{
$pickRemark
=
'拆零'
;
...
...
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