Skip to content
切换导航条
切换导航条
当前项目
正在载入...
登录
孙克
/
QisdaNew
转到一个项目
切换导航栏
切换导航栏固定状态
项目
群组
代码片段
帮助
项目
活动
版本库
流水线
图表
问题
0
合并请求
0
维基
网络
创建新的问题
作业
提交
问题看板
文件
提交
网络
比较
分支
标签
Commit c48be333
由
孙克
编写于
2023-08-14 13:47:23 +0800
浏览文件
选项
浏览文件
标签
下载
电子邮件补丁
差异文件
多个工单同时提交时,分盘料合单
无需求单包装仓任务与有紧急料和分盘料任务分配到相同的料架 包装料架如果已放满,使用新的料架 分配库位时,清理入库时使用的RFID信息
1 个父辈
07f40731
隐藏空白字符变更
内嵌
并排
正在显示
7 个修改的文件
包含
90 行增加
和
17 行删除
myproject/src/main/java/com/myproject/bean/qisda/InquiryShelfBean.java
myproject/src/main/java/com/myproject/dao/mongo/IStoragePosDao.java
myproject/src/main/java/com/myproject/dao/mongo/impl/StoragePosDaoImpl.java
myproject/src/main/java/com/myproject/webapp/controller/webService/QisdaBindService.java
myproject/src/main/java/com/myproject/webapp/controller/webService/TaskService.java
myproject/src/main/webapp/WEB-INF/pages/updateHistory.jsp
myproject/src/main/webapp/decorators/metro.jsp
myproject/src/main/java/com/myproject/bean/qisda/InquiryShelfBean.java
查看文件 @
c48be33
...
...
@@ -283,10 +283,15 @@ public class InquiryShelfBean {
//工单料
return
shelfInfo
;
}
else
{
//不是包装仓的分盘料或紧急料,使用同一个料架;包装料架按需求单号进行区分
//if(!shelfInfo.isAShelf()){
if
(
shelfInfo
.
isAShelf
()){
//包装料架, 如果已经放满,那么使用新的料架
if
(!
shelfInfo
.
isFull
()){
//未放满,可以继续使用此料架
return
shelfInfo
;
}
}
else
{
return
shelfInfo
;
//
}
}
}
}
}
...
...
@@ -356,6 +361,7 @@ public class InquiryShelfBean {
if
(
task
.
isPackageReel
()){
//包装料,固定库位
loc
=
emptyShelfInfo
.
addLimitLoc
(
task
.
getBarcode
(),
task
.
getReelType
());
appendInfo
.
setRfid
(
""
);
appendInfo
.
setRfidLoc
(
loc
);
}
else
{
loc
=
emptyShelfInfo
.
addLimitLoc
(
barcode
,
task
.
getReelType
());
...
...
@@ -366,6 +372,7 @@ public class InquiryShelfBean {
appendInfo
.
setShelfType
(
shelfType
);
appendInfo
.
sethSerial
(
outItem
.
gethSerial
());
if
(
barcode
!=
null
&&
!
barcode
.
isEmpty
()){
appendInfo
.
setRfid
(
""
);
appendInfo
.
setRfidLoc
(
loc
);
}
String
location
=
shelfType
;
...
...
myproject/src/main/java/com/myproject/dao/mongo/IStoragePosDao.java
查看文件 @
c48be33
...
...
@@ -42,6 +42,8 @@ public interface IStoragePosDao extends IMongoDao {
Map
<
String
,
Integer
>
availableInventory
();
List
<
StoragePos
>
listPnFacility
(
String
pn
,
String
facility
);
/**
* 根据pn和facility获取未锁定的数量最小的盘
*/
...
...
myproject/src/main/java/com/myproject/dao/mongo/impl/StoragePosDaoImpl.java
查看文件 @
c48be33
package
com
.
myproject
.
dao
.
mongo
.
impl
;
import
com.google.common.base.Function
;
import
com.google.common.collect.Lists
;
import
com.google.common.collect.Maps
;
import
com.mongodb.DBObject
;
...
...
@@ -8,14 +7,11 @@ import com.myproject.bean.json.ChartData;
import
com.myproject.bean.json.ChartItem
;
import
com.myproject.bean.json.InventoryItem
;
import
com.myproject.bean.json.PlateSizeBean
;
import
com.myproject.bean.qisda.AppendInfo
;
import
com.myproject.bean.qisda.AvailableInventoryBean
;
import
com.myproject.bean.update.Barcode
;
import
com.myproject.bean.update.StoragePos
;
import
com.myproject.dao.mongo.AbstractMongoDao
;
import
com.myproject.dao.mongo.IBarcodeDao
;
import
com.myproject.dao.mongo.IStoragePosDao
;
import
com.myproject.exception.ValidateException
;
import
com.myproject.util.PLATE_SIZE
;
import
com.myproject.util.StorageConstants
;
import
com.myproject.util.StringHelper
;
...
...
@@ -273,6 +269,20 @@ public class StoragePosDaoImpl extends AbstractMongoDao implements IStoragePosDa
return
resultMap
;
}
/**
* 获取绑定和未绑定的所有物料, 按生产日期和数量排序
* @param pn
* @param facility
* @return
*/
@Override
public
List
<
StoragePos
>
listPnFacility
(
String
pn
,
String
facility
){
//PN和Facility一样
Criteria
c
=
Criteria
.
where
(
"barcode.partNumber"
).
is
(
pn
).
and
(
"barcode.appendInfo.facility"
).
is
(
facility
);
Query
q
=
new
Query
(
c
);
q
.
with
(
new
Sort
(
Sort
.
Direction
.
ASC
,
"barcode.produceDateStr"
).
and
(
new
Sort
(
Sort
.
Direction
.
ASC
,
"barcode.amount"
)));
return
findByQuery
(
q
);
}
/**
* 根据pn和facility获取未锁定的数量最小的盘
...
...
myproject/src/main/java/com/myproject/webapp/controller/webService/QisdaBindService.java
查看文件 @
c48be33
...
...
@@ -52,7 +52,7 @@ public class QisdaBindService {
log
.
info
(
"需求单["
+
outInfo
+
"]开始进行真实绑定"
);
for
(
OutItem
outItem
:
outInfo
.
getOutItems
())
{
firstBindCutReel
(
outItem
);
secondBindCutReel
(
outItem
);
secondBindCutReel
(
outItem
,
null
);
realBindNoCutReel
(
outItem
);
bindSamePnFromOtherSlotForFirstAction
(
outItem
,
new
ArrayList
<
String
>());
}
...
...
@@ -64,8 +64,10 @@ public class QisdaBindService {
* 预绑定分盘料
*/
public
void
preBindCutOutInfoList
(
Collection
<
OutInfo
>
outInfoList
){
List
<
String
>
soList
=
new
ArrayList
<>();
for
(
OutInfo
outInfo
:
outInfoList
)
{
if
(
outInfo
.
isReelCutAction
()){
soList
.
add
(
outInfo
.
getSo
());
//分盘需求单进行预绑定
log
.
info
(
"需求单["
+
outInfo
+
"]开始进行预绑定"
);
for
(
OutItem
outItem
:
outInfo
.
getOutItems
())
{
...
...
@@ -83,7 +85,7 @@ public class QisdaBindService {
log
.
info
(
"分盘需求单["
+
outInfo
+
"]开始进行二次分盘绑定"
);
for
(
OutItem
outItem
:
outInfo
.
getOutItems
())
{
if
(
outItem
.
isReelCutAction
()){
//分盘
secondBindCutReel
(
outItem
);
secondBindCutReel
(
outItem
,
soList
);
}
}
}
...
...
@@ -208,15 +210,39 @@ public class QisdaBindService {
2.By SO逐一挑选,料卷数量,从小到大去挑选
* @param outItem
*/
private
void
secondBindCutReel
(
OutItem
outItem
){
private
void
secondBindCutReel
(
OutItem
outItem
,
List
<
String
>
shareCutSoList
){
if
(
outItem
.
isCutMaterial
()){
log
.
info
(
"第二轮绑定分盘料:So=["
+
outItem
.
getSo
()+
"]hSerial=["
+
outItem
.
gethSerial
()+
"]+refno=["
+
outItem
.
getRefno
()+
"]的slot"
+
outItem
.
getSlotlocation
()+
"]pn=["
+
outItem
.
getPn
()+
"]当前预绑定数量["
+
outItem
.
getLockQty
()+
"/"
+
outItem
.
getQty
()+
"]"
);
//剩余需求数量
int
needNum
=
outItem
.
getQty
()
-
outItem
.
getLockQty
();
while
(
needNum
>
0
){
//分盘料
//TODO: 第二轮应该查找未绑定过或者有分盘信息的物料
StoragePos
pos
=
storagePosDao
.
findNoBindMinQty
(
outItem
.
getPn
(),
outItem
.
getFacility
());
StoragePos
pos
=
null
;
if
(
shareCutSoList
!=
null
){
//第二轮应该查找未绑定过或者有分盘信息的物料
List
<
StoragePos
>
posList
=
storagePosDao
.
listPnFacility
(
outItem
.
getPn
(),
outItem
.
getFacility
());
for
(
StoragePos
storagePos
:
posList
)
{
Barcode
barcode
=
storagePos
.
getBarcode
();
boolean
hasCutInfo
=
barcode
.
hasCutInfo
();
if
(
barcode
.
getAmount
()
>
0
&&
hasCutInfo
){
//优先查找同批需求单中有分盘的物料
AppendInfo
appendInfo
=
storagePos
.
getBarcode
().
getAppendInfo
();
String
bindSo
=
appendInfo
.
getSo
();
if
(
bindSo
!=
null
&&
shareCutSoList
.
contains
(
bindSo
)){
//同批需求单已经有绑定
pos
=
storagePos
;
break
;
}
}
}
}
if
(
pos
==
null
){
//未找到已经绑定过有分盘信息的物料
pos
=
storagePosDao
.
findNoBindMinQty
(
outItem
.
getPn
(),
outItem
.
getFacility
());
}
if
(
pos
==
null
){
log
.
info
(
"\t第二轮分盘料绑定"
+
outItem
.
getSlotlocation
()
+
"的pn=["
+
outItem
.
getPn
()+
"]facility = "
+
outItem
.
getFacility
()+
"时无库存,跳出绑定"
);
break
;
...
...
myproject/src/main/java/com/myproject/webapp/controller/webService/TaskService.java
查看文件 @
c48be33
...
...
@@ -1665,13 +1665,23 @@ public class TaskService implements ITaskService {
//手动出库的当做是工单料,放到皮带线上
task
.
setUrgentReel
(
true
);
AppendInfo
appendInfo
=
task
.
getAppendInfo
();
appendInfo
.
setShelfType
(
StorageConstants
.
SHEFL_TYPE
.
B
);
task
.
setAppendInfo
(
appendInfo
);
task
.
setType
(
StorageConstants
.
OP
.
CHECKOUT
);
task
.
setStatus
(
StorageConstants
.
OP_STATUS
.
WAIT
.
name
());
task
.
setSingleOut
(
isSingleOut
);
if
(
task
.
isPackageReel
()){
//包装料需要出到包装料架上, 其他料出到料串上
OutItem
outItem
=
new
OutItem
();
outItem
.
sethSerial
(
"0"
);
task
=
InquiryShelfBean
.
addLimitLoc
(
task
,
outItem
);
}
else
{
AppendInfo
appendInfo
=
task
.
getAppendInfo
();
appendInfo
.
setShelfType
(
StorageConstants
.
SHEFL_TYPE
.
B
);
task
.
setAppendInfo
(
appendInfo
);
}
//task.setAppendInfo(pos.getBarcode().getAppendInfo());
//工单出库任务
if
(!
Strings
.
isNullOrEmpty
(
subSourceId
)){
...
...
myproject/src/main/webapp/WEB-INF/pages/updateHistory.jsp
查看文件 @
c48be33
...
...
@@ -12,6 +12,24 @@
<div class="row">
<div class="col-md-12">
<ul class="timeline">
<li class="timeline-purple">
<div class="timeline-time">
<span class="date">2023</span>
<span class="time">08-14</span>
</div>
<div class="timeline-icon">
<i class="fa fa-clock-o"></i>
</div>
<div class="timeline-body">
<h2>版本: V2023081413</h2>
<div class="timeline-content">
<ul>
<li>多个工单同时提交时,分盘料合单</li>
<li>无需求单包装仓任务与有紧急料和分盘料任务分配到相同的料架</li>
</ul>
</div>
</div>
</li>
<li class="timeline-green">
<div class="timeline-time">
<span class="date">2023</span>
...
...
myproject/src/main/webapp/decorators/metro.jsp
查看文件 @
c48be33
...
...
@@ -239,7 +239,7 @@
<div
class=
"page-footer-inner"
>
2016
©
<a
href=
"${ctx}/updateHistory.html"
>
SMD BOX
</a>
</div>
<span
class=
"right"
style=
"color: #a3a3a3;"
>
Version: V20230
71310
</span>
<span
class=
"right"
style=
"color: #a3a3a3;"
>
Version: V20230
81413
</span>
<div
class=
"scroll-to-top"
>
<i
class=
"icon-arrow-up"
></i>
</div>
...
...
编写
预览
支持
Markdown
格式
附加文件
你添加了
0
人
到此讨论。请谨慎行事。
Finish editing this message first!
Cancel
请
注册
或
登录
后发表评论