mirror of
https://gitlab.com/mbugroup/lti-api.git
synced 2026-05-20 13:31:56 +00:00
fix: first push need support testing, and implemented fifo v2 to all modules
This commit is contained in:
@@ -121,12 +121,7 @@ func main() {
|
||||
continue
|
||||
}
|
||||
|
||||
usableType := fifo.UsableKeyAdjustmentOut.String()
|
||||
if route.SourceTable == "adjustment_stocks" && strings.TrimSpace(route.LegacyTypeKey) != "" {
|
||||
usableType = strings.TrimSpace(route.LegacyTypeKey)
|
||||
}
|
||||
|
||||
activeAllocationCount, err := countActiveAllocations(ctx, db, usableType, adj.ID)
|
||||
activeAllocationCount, err := countActiveAllocations(ctx, db, fifo.UsableKeyAdjustmentOut.String(), adj.ID)
|
||||
if err != nil {
|
||||
fmt.Printf("FAIL adj=%d error=count allocations: %v\n", adj.ID, err)
|
||||
failed++
|
||||
@@ -142,13 +137,7 @@ func main() {
|
||||
reflowReq := commonSvc.FifoStockV2ReflowRequest{
|
||||
FlagGroupCode: route.FlagGroupCode,
|
||||
ProductWarehouseID: adj.ProductWarehouseID,
|
||||
Usable: commonSvc.FifoStockV2Ref{
|
||||
ID: adj.ID,
|
||||
LegacyTypeKey: usableType,
|
||||
FunctionCode: route.FunctionCode,
|
||||
},
|
||||
DesiredQty: desiredQty,
|
||||
IdempotencyKey: fmt.Sprintf("manual-adjustment-reflow-%d-%d", adj.ID, time.Now().UnixNano()),
|
||||
IdempotencyKey: fmt.Sprintf("manual-adjustment-reflow-%d-%d", adj.ID, time.Now().UnixNano()),
|
||||
}
|
||||
if asOfCreatedAt {
|
||||
asOf := adj.CreatedAt
|
||||
|
||||
Reference in New Issue
Block a user