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
81a57690
Commit
81a57690
authored
Feb 19, 2021
by
泽锋 李
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
停止监控分永久停止跟暂时停止。永久停止的自动删除已出的单
美容调拨单 deadline 改成两个工作日
parent
34370626
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
29 additions
and
1 deletion
+29
-1
db_config.cs
AutoTurnOver.DB/db_config.cs
+4
-0
dc_auto_purchase_advise.cs
AutoTurnOver.Models/dc_auto_purchase_advise.cs
+25
-1
No files found.
AutoTurnOver.DB/db_config.cs
View file @
81a57690
...
...
@@ -581,6 +581,10 @@ left join dc_base_warehouse as dbw on dacp.warehouse_code = dbw.warehouse_code w
{
throw
new
Exception
(
"状态异常"
);
}
if
(
monitor_status
==
0
)
{
time_type
=
0
;
}
var
datas
=
conn
.
Query
<
AutoTurnOver
.
Models
.
dc_auto_turnover
>(
" select * from dc_auto_turnover where id in @ids "
,
new
{
ids
=
ids
.
Split
(
','
)
}).
AsList
();
foreach
(
AutoTurnOver
.
Models
.
dc_auto_turnover
turnover_item
in
datas
)
{
...
...
AutoTurnOver.Models/dc_auto_purchase_advise.cs
View file @
81a57690
...
...
@@ -359,13 +359,37 @@ namespace AutoTurnOver.Models
return
count
;
}
public
static
int
WorkingDays2
(
DateTime
date
,
DateTime
date2
)
{
var
this_date
=
date
;
var
count
=
0
;
while
((
date2
-
this_date
).
TotalHours
>=
24
)
{
if
(
this_date
.
DayOfWeek
==
DayOfWeek
.
Monday
||
this_date
.
DayOfWeek
==
DayOfWeek
.
Wednesday
||
this_date
.
DayOfWeek
==
DayOfWeek
.
Friday
)
{
count
++;
}
this_date
=
this_date
.
AddDays
(
1
);
}
return
count
;
}
/// <summary>
/// 工作日
/// </summary>
public
int
working_days
{
get
{
if
(
create_time
!=
null
)
{
return
WorkingDays
(
create_time
.
Value
,
DateTime
.
Now
);
//如果是美容调拨单
if
((
buyer_name
==
"张莹霞"
||
buyer_name
==
"张莹霞1"
)
&&
hq_type
!=
"国内仓"
)
{
return
WorkingDays2
(
create_time
.
Value
,
DateTime
.
Now
);
}
else
{
return
WorkingDays
(
create_time
.
Value
,
DateTime
.
Now
);
}
}
else
{
...
...
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