Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
dc-java
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
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
huluobin
dc-java
Commits
416e7314
Commit
416e7314
authored
Mar 05, 2021
by
huluobin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
# 更新
parent
53c0260e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
0 deletions
+5
-0
AutoTurnoverJob.java
...over/src/main/java/com/bailuntec/job/AutoTurnoverJob.java
+5
-0
No files found.
data-show/show-auto-turnover/src/main/java/com/bailuntec/job/AutoTurnoverJob.java
View file @
416e7314
...
...
@@ -1511,6 +1511,8 @@ public class AutoTurnoverJob extends PointJob {
});
forecastSalesList
.
remove
(
forecastSalesList
.
size
()
-
1
);
weightingAvgSales
=
calculateWeightingAvgSales
(
dcAutoConfigSafeInventory
.
getWeightingCoefficientSeven
(),
dcAutoConfigSafeInventory
.
getWeightingCoefficientFourteen
(),
dcAutoConfigSafeInventory
.
getWeightingCoefficientThirty
(),
forecastSalesList
);
//type 12 乘倍数
weightingAvgSales
=
weightingAvgSales
.
multiply
(
dcAutoConfigSafeInventory
.
getParam
()).
setScale
(
3
,
RoundingMode
.
HALF_EVEN
);
}
else
{
//历史
dcAutoConfigSafeInventory
=
autoConfigSafeInventoryMapper
.
selectOneByExample
(
DcAutoConfigSafeInventoryExample
.
newAndCreateCriteria
().
andVariableCodeEqualTo
(
bailunSku
).
andWarehouseCodeEqualTo
(
warehouseCode
).
andStatusEqualTo
(
1
).
andTypeEqualTo
(
11
).
example
());
...
...
@@ -1518,6 +1520,9 @@ public class AutoTurnoverJob extends PointJob {
});
if
(
dcAutoConfigSafeInventory
!=
null
)
{
weightingAvgSales
=
calculateWeightingAvgSales
(
dcAutoConfigSafeInventory
.
getWeightingCoefficientSeven
(),
dcAutoConfigSafeInventory
.
getWeightingCoefficientFourteen
(),
dcAutoConfigSafeInventory
.
getWeightingCoefficientThirty
(),
historyThirtySalesList
);
//type11 乘倍数
weightingAvgSales
=
weightingAvgSales
.
multiply
(
dcAutoConfigSafeInventory
.
getParam
()).
setScale
(
3
,
RoundingMode
.
HALF_EVEN
);
}
else
{
//仓库。根据历史销量加权计算。最后可以乘以一个倍数
dcAutoConfigSafeInventory
=
autoConfigSafeInventoryMapper
.
selectOneByExample
(
DcAutoConfigSafeInventoryExample
.
newAndCreateCriteria
().
andVariableCodeEqualTo
(
""
).
andWarehouseCodeEqualTo
(
warehouseCode
).
andStatusEqualTo
(
1
).
andTypeEqualTo
(
3
).
example
());
...
...
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