Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
data-center-auto
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
bltdc
data-center-auto
Commits
1bf81470
Commit
1bf81470
authored
Aug 30, 2021
by
zhoujinhui
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
缺货查询新增时间筛选
parent
6eb2888a
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
21 additions
and
4 deletions
+21
-4
dc_auto_week_shortage_dao.cs
AutoTurnOver.DB/dc_auto_week_shortage_dao.cs
+8
-0
week_shortage_details_page_input_dto.cs
.../WeeklyStatistics/week_shortage_details_page_input_dto.cs
+10
-0
WeeklyStatisticsServices.cs
AutoTurnOver.Services/WeeklyStatisticsServices.cs
+2
-3
ShortageBackgrounService.cs
...yStatistics/BackgroundService/ShortageBackgrounService.cs
+1
-1
No files found.
AutoTurnOver.DB/dc_auto_week_shortage_dao.cs
View file @
1bf81470
...
@@ -38,6 +38,14 @@ namespace AutoTurnOver.DB
...
@@ -38,6 +38,14 @@ namespace AutoTurnOver.DB
{
{
sql
.
Append
(
$" AND t1.warehouse_code = '
{
m
.
warehousecode
}
' "
);
sql
.
Append
(
$" AND t1.warehouse_code = '
{
m
.
warehousecode
}
' "
);
}
}
if
(!
string
.
IsNullOrWhiteSpace
(
m
.
start_date
))
{
sql
.
Append
(
$" AND t1.stockout_time >= '
{
m
.
start_date
}
' "
);
}
if
(!
string
.
IsNullOrWhiteSpace
(
m
.
end_date
))
{
sql
.
Append
(
$" AND t1.stockout_time < '
{
m
.
end_date
}
' "
);
}
sql
.
Append
(
" ORDER BY t1.create_date_time DESC "
);
sql
.
Append
(
" ORDER BY t1.create_date_time DESC "
);
try
try
{
{
...
...
AutoTurnOver.Models/ApiDto/WeeklyStatistics/week_shortage_details_page_input_dto.cs
View file @
1bf81470
...
@@ -11,5 +11,15 @@ namespace AutoTurnOver.Models.ApiDto.WeeklyStatistics
...
@@ -11,5 +11,15 @@ namespace AutoTurnOver.Models.ApiDto.WeeklyStatistics
{
{
public
string
bailun_sku
{
get
;
set
;
}
public
string
bailun_sku
{
get
;
set
;
}
public
string
warehousecode
{
get
;
set
;
}
public
string
warehousecode
{
get
;
set
;
}
/// <summary>
/// 缺货开始时间
/// </summary>
public
string
start_date
{
get
;
set
;
}
/// <summary>
/// 缺货结束时间
/// </summary>
public
string
end_date
{
get
;
set
;
}
}
}
}
}
AutoTurnOver.Services/WeeklyStatisticsServices.cs
View file @
1bf81470
...
@@ -130,9 +130,8 @@ namespace AutoTurnOver.Services
...
@@ -130,9 +130,8 @@ namespace AutoTurnOver.Services
for
(
int
i
=
1
;
i
<
30000
;
i
++)
for
(
int
i
=
1
;
i
<
30000
;
i
++)
{
{
int
offset
=
(
i
-
1
)
*
limit
;
int
offset
=
(
i
-
1
)
*
limit
;
DateTime
startTime
=
DateHelper
.
GetWeekFirstDayMon
(
DateTime
.
Now
);
DateTime
startTime
=
DateTime
.
Now
.
AddDays
(-
1
).
Date
;
DateTime
endtime
=
DateHelper
.
GetWeekLastDaySun
(
DateTime
.
Now
).
AddDays
(
1
).
AddMilliseconds
(-
1
);
DateTime
endtime
=
DateTime
.
Now
.
Date
.
AddMilliseconds
(-
1
);
var
dataList
=
dc_auto_week_shortage_dao
.
GetGmtOutStockPageList
(
startTime
,
endtime
,
offset
,
limit
,
ref
total
);
var
dataList
=
dc_auto_week_shortage_dao
.
GetGmtOutStockPageList
(
startTime
,
endtime
,
offset
,
limit
,
ref
total
);
if
(
dataList
.
Count
<=
0
)
break
;
if
(
dataList
.
Count
<=
0
)
break
;
var
skus
=
dataList
.
Select
(
x
=>
x
.
bailun_sku
).
ToList
();
var
skus
=
dataList
.
Select
(
x
=>
x
.
bailun_sku
).
ToList
();
...
...
AutoTurnOver.WeeklyStatistics/BackgroundService/ShortageBackgrounService.cs
View file @
1bf81470
...
@@ -20,7 +20,7 @@ namespace AutoTurnOver.WeeklyStatistics
...
@@ -20,7 +20,7 @@ namespace AutoTurnOver.WeeklyStatistics
{
{
var
now
=
DateTime
.
Now
;
var
now
=
DateTime
.
Now
;
var
dayOfWeek
=
System
.
Globalization
.
CultureInfo
.
CurrentCulture
.
DateTimeFormat
.
GetDayName
(
now
.
DayOfWeek
);
var
dayOfWeek
=
System
.
Globalization
.
CultureInfo
.
CurrentCulture
.
DateTimeFormat
.
GetDayName
(
now
.
DayOfWeek
);
if
(
now
.
Hour
==
0
&&
now
.
Minute
==
1
&&
dayOfWeek
.
Equals
(
"星期一"
)
)
if
(
now
.
Hour
==
0
&&
now
.
Minute
==
1
)
{
{
try
try
{
{
...
...
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