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
1f042ce0
Commit
1f042ce0
authored
4 months ago
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
11
parent
68a653f0
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
63 additions
and
32 deletions
+63
-32
ClassModule.cs
Edu.Module.Course/ClassModule.cs
+48
-32
ClassController.cs
Edu.WebApi/Controllers/Course/ClassController.cs
+15
-0
No files found.
Edu.Module.Course/ClassModule.cs
View file @
1f042ce0
...
...
@@ -26,6 +26,7 @@ using Edu.Repository.Scroll;
using
Edu.Repository.Sell
;
using
Edu.Repository.User
;
using
Microsoft.AspNetCore.SignalR
;
using
Senparc.Weixin.Work.AdvancedAPIs.OaDataOpen
;
using
System
;
using
System.Collections.Generic
;
using
System.Linq
;
...
...
@@ -3344,7 +3345,7 @@ namespace Edu.Module.Course
});
}
appointList
.
Where
(
x
=>
x
.
Date
==
ClassDate
).
GroupBy
(
x
=>
new
{
x
.
Date
,
x
.
TeacherId
,
x
.
TeacherName
,
x
.
RoomId
,
x
.
RoomName
,
x
.
CourseName
,
x
.
CourseGradeId
,
x
.
CourseGradeNo
,
x
.
CourseSTime
}).
OrderBy
(
x
=>
x
.
Key
.
CourseSTime
).
ToList
().
ForEach
(
item
=>
appointList
.
Where
(
x
=>
x
.
Date
==
ClassDate
).
GroupBy
(
x
=>
new
{
x
.
Date
,
x
.
TeacherId
,
x
.
TeacherName
,
x
.
RoomId
,
x
.
RoomName
,
x
.
CourseName
,
x
.
CourseGradeId
,
x
.
ShiftSort
,
x
.
CourseSTime
}).
OrderBy
(
x
=>
x
.
Key
.
CourseSTime
).
ToList
().
ForEach
(
item
=>
{
//上课时段
string
STime
=
item
.
FirstOrDefault
().
CourseSTime
??
""
,
ETime
=
item
.
FirstOrDefault
().
CourseETime
??
""
;
...
...
@@ -3358,7 +3359,7 @@ namespace Edu.Module.Course
item
.
Key
.
CourseName
,
item
.
Key
.
RoomName
,
item
.
Key
.
TeacherName
,
Ranks
=
item
.
Key
.
CourseGradeNo
,
Ranks
=
item
.
Key
.
ShiftSort
,
CourseGradeIdName
=
item
.
Key
.
CourseGradeId
.
ToName
(),
TotalPlanNum
=
item
.
FirstOrDefault
().
TotalChapterNo
,
TimeStr
=
Common
.
ConvertHelper
.
GetTimeStr
(
currentDate
),
...
...
@@ -3927,9 +3928,24 @@ namespace Edu.Module.Course
subItem
.
School_Id
,
});
}
if
(
Common
.
ConvertHelper
.
FormatDate
(
ClassDate
)
==
"2024-11-06"
)
{
string
str
=
""
;
}
//约课
appointList
.
Where
(
x
=>
x
.
Date
==
ClassDate
).
GroupBy
(
x
=>
new
{
x
.
Date
,
x
.
TeacherId
,
x
.
TeacherName
,
x
.
RoomId
,
x
.
RoomName
,
x
.
CourseName
,
x
.
CourseGradeNo
,
x
.
CourseGradeId
,
x
.
CourseSTime
}).
OrderBy
(
x
=>
x
.
Key
.
CourseSTime
).
ToList
().
ForEach
(
item
=>
var
tempAppointList
=
appointList
.
Where
(
x
=>
x
.
Date
==
ClassDate
).
GroupBy
(
x
=>
new
{
x
.
Date
,
x
.
TeacherId
,
x
.
TeacherName
,
x
.
RoomId
,
x
.
RoomName
,
x
.
CourseName
,
x
.
ShiftSort
,
x
.
CourseGradeId
,
x
.
CourseSTime
}).
OrderBy
(
x
=>
x
.
Key
.
CourseSTime
).
ToList
();
foreach
(
var
item
in
tempAppointList
)
{
//上课时段
string
STime
=
item
.
FirstOrDefault
().
CourseSTime
??
""
,
ETime
=
item
.
FirstOrDefault
().
CourseETime
??
""
;
...
...
@@ -3943,7 +3959,7 @@ namespace Edu.Module.Course
item
.
Key
.
CourseName
,
item
.
Key
.
RoomName
,
item
.
Key
.
TeacherName
,
Ranks
=
item
.
Key
.
CourseGradeNo
,
Ranks
=
item
.
Key
.
ShiftSort
,
CourseGradeIdName
=
item
.
Key
.
CourseGradeId
.
ToName
(),
TotalPlanNum
=
item
.
FirstOrDefault
().
TotalChapterNo
,
TimeStr
=
Common
.
ConvertHelper
.
GetTimeStr
(
currentDate
),
...
...
@@ -3957,7 +3973,7 @@ namespace Edu.Module.Course
item
.
FirstOrDefault
()?.
ClassPlanId
,
School_Id
=
0
,
});
});
}
var
obj
=
new
{
...
...
This diff is collapsed.
Click to expand it.
Edu.WebApi/Controllers/Course/ClassController.cs
View file @
1f042ce0
...
...
@@ -2881,7 +2881,22 @@ namespace Edu.WebApi.Controllers.Course
foreach
(
var
gItem
in
guestList
)
{
JObject
gObj
=
JObject
.
Parse
(
gItem
.
ToString
());
string
AppointTypeStr
=
""
;
int
AppointType
=
gObj
.
GetInt
(
"AppointType"
);
if
(
AppointType
==
2
)
{
AppointTypeStr
=
"补课"
;
}
if
(
AppointType
==
3
)
{
AppointTypeStr
=
"重修"
;
}
guestStr
+=
"/"
+
gObj
[
"GuestName"
].
ToString
();
if
(!
string
.
IsNullOrEmpty
(
AppointTypeStr
))
{
guestStr
+=
string
.
Format
(
"【{0}】"
,
AppointTypeStr
);
}
}
}
var
dataRow
=
new
List
<
ExcelColumn
>(
30
)
...
...
This diff is collapsed.
Click to expand it.
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