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
de784c46
Commit
de784c46
authored
Jul 20, 2021
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增停课日志
parent
3edae069
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
38 additions
and
1 deletion
+38
-1
RB_User_ChangeLog.cs
Edu.Model/Entity/Log/RB_User_ChangeLog.cs
+1
-1
ClassModule.cs
Edu.Module.Course/ClassModule.cs
+21
-0
OrderModule.cs
Edu.Module.Course/OrderModule.cs
+16
-0
No files found.
Edu.Model/Entity/Log/RB_User_ChangeLog.cs
View file @
de784c46
...
...
@@ -44,7 +44,7 @@ namespace Edu.Model.Entity.Log
private
int
type
=
1
;
/// <summary>
/// 类型
1日常日志 2订单
日志
/// 类型
1-日常日志;2-订单日志;3-学员
日志
/// </summary>
public
int
Type
{
get
=>
type
;
set
=>
type
=
value
;
}
...
...
Edu.Module.Course/ClassModule.cs
View file @
de784c46
...
...
@@ -149,6 +149,11 @@ namespace Edu.Module.Course
/// </summary>
private
readonly
RB_Student_MakeupRepository
student_MakeupRepository
=
new
RB_Student_MakeupRepository
();
/// <summary>
/// 日志仓储对象
/// </summary>
private
readonly
RB_User_ChangeLogRepository
user_ChangeLogRepository
=
new
RB_User_ChangeLogRepository
();
/// <summary>
/// 获取班级列表
/// </summary>
...
...
@@ -1475,13 +1480,29 @@ namespace Edu.Module.Course
{
{
nameof
(
RB_Order_Guest_ViewModel
.
CompleteHours
),
completeHours
}
};
string
LogContent
=
""
;
//已上课时>=有效课时,如果是,修改学员状态为停课,并且备注“有效课时消耗完毕,系统自动停课”
if
(
completeHours
>
guestModel
.
ValidClassHours
)
{
orderFileds
.
Add
(
nameof
(
RB_Order_Guest_ViewModel
.
GuestState
),
5
);
orderFileds
.
Add
(
nameof
(
RB_Order_Guest_ViewModel
.
DropOutRemark
),
"有效课时消耗完毕,系统自动停课"
);
LogContent
=
guestModel
.
GuestName
+
"有效课时消耗完毕,系统自动停课!"
;
}
flag
=
order_GuestRepository
.
Update
(
orderFileds
,
new
WhereHelper
(
nameof
(
RB_Order_Guest_ViewModel
.
Id
),
item
.
OrderGuestId
));
if
(
flag
&&
!
string
.
IsNullOrEmpty
(
LogContent
))
{
user_ChangeLogRepository
.
Insert
(
new
Model
.
Entity
.
Log
.
RB_User_ChangeLog
()
{
Id
=
0
,
Type
=
3
,
CreateBy
=
item
.
CreateBy
,
CreateTime
=
DateTime
.
Now
,
Group_Id
=
item
.
Group_Id
,
LogContent
=
LogContent
,
School_Id
=
item
.
School_Id
,
SourceId
=
guestModel
.
Id
});
}
//缺勤和请假
if
(
item
.
CheckStatus
==
1
||
item
.
CheckStatus
==
2
)
{
...
...
Edu.Module.Course/OrderModule.cs
View file @
de784c46
...
...
@@ -2557,10 +2557,26 @@ namespace Edu.Module.Course
{
nameof
(
RB_Order_Guest
.
ValidClassHours
),
validClassHours
}
};
//HK2021-07-19新增【有效课时大于完成课时修改学员状态为正常】
string
LogContent
=
""
;
if
(
gmodel
.
CompleteHours
<
validClassHours
)
{
keyValues
.
Add
(
nameof
(
RB_Order_Guest
.
GuestState
),
1
);
keyValues
.
Add
(
nameof
(
RB_Order_Guest
.
DropOutRemark
),
"有效课时大于完成课时,恢复学员状态!"
);
LogContent
=
gmodel
.
GuestName
+
"有效课时大于完成课时,系统恢复学员状态!"
;
}
if
(!
string
.
IsNullOrEmpty
(
LogContent
))
{
changeLogRepository
.
Insert
(
new
Model
.
Entity
.
Log
.
RB_User_ChangeLog
()
{
Id
=
0
,
Type
=
3
,
CreateBy
=
gmodel
.
CreateBy
,
CreateTime
=
DateTime
.
Now
,
Group_Id
=
gmodel
.
Group_Id
,
LogContent
=
LogContent
,
School_Id
=
gmodel
.
School_Id
,
SourceId
=
gmodel
.
Id
});
}
List
<
WhereHelper
>
wheres
=
new
List
<
WhereHelper
>()
{
...
...
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