feat: 重构 AGV 对接与在制品查询,新增 PLC 手动监控功能
This commit is contained in:
@@ -356,7 +356,6 @@ func (s *Service) CreateCallOrders(ctx context.Context, stationNo int, items []C
|
||||
return 0, errors.New("工位已停用,不能叫料")
|
||||
}
|
||||
allowCross := s.CfgInt(ctx, CfgAllowCrossDay, 1) == 1
|
||||
maxQty := s.CfgInt(ctx, CfgCallMaxQty, 0)
|
||||
// 接驳台校验:目标接驳台必须属于该工位(一工位 R1/R2 两个,真源=dock 表)
|
||||
dockSet := map[string]bool{}
|
||||
if dks, e := s.ctx.EntClient.Dock.Query().Where(dock.StationNo(stationNo)).All(ctx); e == nil {
|
||||
@@ -377,9 +376,6 @@ func (s *Service) CreateCallOrders(ctx context.Context, stationNo int, items []C
|
||||
if !dockSet[it.Dock] {
|
||||
return 0, errors.New("该工位无此接驳台:" + it.Dock)
|
||||
}
|
||||
if maxQty > 0 && it.Qty > maxQty {
|
||||
return 0, fmt.Errorf("单次叫料数量不能超过 %d", maxQty)
|
||||
}
|
||||
}
|
||||
tx, terr := s.ctx.EntClient.Tx(ctx)
|
||||
if terr != nil {
|
||||
|
||||
Reference in New Issue
Block a user