Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
Education
Project
Project
Details
Activity
Releases
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
黄奎
Education
Commits
081484fd
Commit
081484fd
authored
Jun 22, 2021
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
b08068ed
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
46 additions
and
4 deletions
+46
-4
RB_Order_ViewModel.cs
Edu.Model/ViewModel/Course/RB_Order_ViewModel.cs
+5
-0
OrderModule2.cs
Edu.Module.Course/OrderModule2.cs
+31
-1
RB_OrderRepository.cs
Edu.Repository/Course/RB_OrderRepository.cs
+9
-2
TimerJobj.cs
Edu.WebApi/Timers/TimerJobj.cs
+1
-1
No files found.
Edu.Model/ViewModel/Course/RB_Order_ViewModel.cs
View file @
081484fd
...
...
@@ -64,6 +64,11 @@ namespace Edu.Model.ViewModel.Course
/// </summary>
public
int
Q_NotCollect
{
get
;
set
;
}
/// <summary>
/// 生效日期
/// </summary>
public
string
Q_EffectTime
{
get
;
set
;
}
/// <summary>
/// 销售备注
/// </summary>
...
...
Edu.Module.Course/OrderModule2.cs
View file @
081484fd
...
...
@@ -253,7 +253,37 @@ namespace Edu.Module.Course
public
virtual
bool
DealOrderEffectStatusModule
()
{
bool
flag
=
false
;
// orderRepository.GetList
var
orderList
=
orderRepository
.
GetOrderListRepository
(
new
RB_Order_ViewModel
()
{
OrderState
=
Common
.
Enum
.
Course
.
OrderStateEnum
.
Normal
,
IsChaBan
=
1
,
Q_EffectTime
=
Common
.
ConvertHelper
.
FormatDate
(
DateTime
.
Now
)
});
if
(
orderList
!=
null
&&
orderList
.
Count
>
0
)
{
var
tempOrderList
=
orderList
.
Where
(
qitem
=>
qitem
.
EffectStatus
==
0
)?.
ToList
();
if
(
tempOrderList
!=
null
&&
tempOrderList
.
Count
>
0
)
{
foreach
(
var
item
in
tempOrderList
)
{
Dictionary
<
string
,
object
>
fileds1
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_Order_ViewModel
.
EffectStatus
),
1
}
};
//更新当前订单为“生效中”
flag
=
orderRepository
.
Update
(
fileds1
,
new
WhereHelper
(
nameof
(
RB_Order_ViewModel
.
OrderId
),
item
.
OrderId
));
if
(
item
.
UpOrderId
>
0
)
{
Dictionary
<
string
,
object
>
fileds2
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_Order_ViewModel
.
EffectStatus
),
2
}
};
//更新前置订单为“完成”
flag
=
orderRepository
.
Update
(
fileds2
,
new
WhereHelper
(
nameof
(
RB_Order_ViewModel
.
OrderId
),
item
.
UpOrderId
));
}
}
}
}
return
flag
;
}
}
...
...
Edu.Repository/Course/RB_OrderRepository.cs
View file @
081484fd
...
...
@@ -22,7 +22,7 @@ namespace Edu.Repository.Course
/// <returns></returns>
public
List
<
RB_Order_ViewModel
>
GetOrderListRepository
(
RB_Order_ViewModel
demodel
)
{
string
where
=
$@" 1=1"
;
string
where
=
$@" 1=1
"
;
if
(
demodel
.
Group_Id
>
0
)
{
where
+=
$@" and o.
{
nameof
(
RB_Order_ViewModel
.
Group_Id
)}
=
{
demodel
.
Group_Id
}
"
;
...
...
@@ -90,7 +90,14 @@ namespace Edu.Repository.Course
where
+=
$@" and o.
{
nameof
(
RB_Order_ViewModel
.
OrderState
)}
=3"
;
}
}
if
(
demodel
.
IsChaBan
==
1
)
{
where
+=
$@" and o.
{
nameof
(
RB_Order_ViewModel
.
IsChaBan
)}
=
{
demodel
.
IsChaBan
}
"
;
}
if
(!
string
.
IsNullOrEmpty
(
demodel
.
Q_EffectTime
))
{
where
+=
string
.
Format
(
" and DATE_FORMAT(o.EffectTime,'%y/%m/%d')=DATE_FORMAT('{0}','%y/%m/%d') "
,
demodel
.
Q_EffectTime
);
}
string
orderBy
=
" o.OrderId asc"
;
if
(
demodel
.
Q_OrderBy
==
1
)
{
...
...
Edu.WebApi/Timers/TimerJobj.cs
View file @
081484fd
...
...
@@ -46,7 +46,7 @@ namespace Edu.WebApi.Timers
timer3
=
new
System
.
Timers
.
Timer
()
{
Interval
=
(
1000
*
60
)
*
(
1
)
//1
小时执行一次
Interval
=
(
1000
*
60
)
*
(
1
*
60
*
6
)
//6
小时执行一次
};
timer3
.
Elapsed
+=
new
System
.
Timers
.
ElapsedEventHandler
(
DealOrderEffectStatus
);
timer3
.
Enabled
=
true
;
...
...
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