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
7f40a18b
Commit
7f40a18b
authored
Dec 10, 2020
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
d950d570
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
29 additions
and
12 deletions
+29
-12
ClassModule.cs
Edu.Module.Course/ClassModule.cs
+19
-11
ClassController.cs
Edu.WebApi/Controllers/Course/ClassController.cs
+10
-1
No files found.
Edu.Module.Course/ClassModule.cs
View file @
7f40a18b
...
...
@@ -382,19 +382,27 @@ namespace Edu.Module.Course
case
Common
.
Enum
.
Course
.
ClassStyleEnum
.
Month
:
if
(
model
.
WeekDayList
!=
null
&&
model
.
WeekDayList
.
Count
>
0
)
{
foreach
(
var
item
in
model
.
WeekDayList
)
var
srartDate
=
model
.
OpenTime
;
for
(
var
i
=
0
;
i
<
120
;
i
++)
{
classPlanList
.
Add
(
new
RB_Class_Plan_ViewModel
()
var
newDate
=
srartDate
.
AddDays
(
i
);
foreach
(
var
item
in
model
.
WeekDayList
)
{
ClassDate
=
Convert
.
ToDateTime
(
item
),
ClassId
=
model
.
ClassId
,
ClassPlanId
=
0
,
ClassRoomId
=
model
.
ClassRoomId
,
Group_Id
=
model
.
Group_Id
,
School_Id
=
model
.
School_Id
,
PlanTimeList
=
defaultPlanTimeList
,
TeacherId
=
model
.
Teacher_Id
,
});
if
(
newDate
.
Day
==
Convert
.
ToInt32
(
item
))
{
classPlanList
.
Add
(
new
RB_Class_Plan_ViewModel
()
{
ClassDate
=
newDate
,
ClassId
=
model
.
ClassId
,
ClassPlanId
=
0
,
ClassRoomId
=
model
.
ClassRoomId
,
Group_Id
=
model
.
Group_Id
,
School_Id
=
model
.
School_Id
,
PlanTimeList
=
defaultPlanTimeList
,
TeacherId
=
model
.
Teacher_Id
,
});
}
}
}
}
break
;
...
...
Edu.WebApi/Controllers/Course/ClassController.cs
View file @
7f40a18b
...
...
@@ -58,6 +58,7 @@ namespace Edu.WebApi.Controllers.Course
{
item
.
ClassId
,
item
.
ClassName
,
item
.
School_Id
,
item
.
SchoolName
,
item
.
CourseName
,
item
.
Teacher_Id
,
...
...
@@ -171,7 +172,15 @@ namespace Edu.WebApi.Controllers.Course
break
;
//按月排课
case
ClassStyleEnum
.
Month
:
if
(!
string
.
IsNullOrEmpty
(
WeekDayListStr
))
{
extModel
.
WeekDayList
=
Common
.
Plugin
.
JsonHelper
.
DeserializeObject
<
List
<
string
>>(
WeekDayListStr
);
extModel
.
DateJson
=
Common
.
Plugin
.
JsonHelper
.
Serialize
(
extModel
.
WeekDayList
);
}
else
{
extModel
.
DateJson
=
""
;
}
break
;
//网约课
case
ClassStyleEnum
.
OnLine
:
...
...
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