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
832872b8
Commit
832872b8
authored
Jun 22, 2021
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
ab45e590
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
35 additions
and
19 deletions
+35
-19
RB_Order_Guest_ViewModel.cs
Edu.Model/ViewModel/Course/RB_Order_Guest_ViewModel.cs
+5
-0
ClassModule.cs
Edu.Module.Course/ClassModule.cs
+8
-7
OrderModule.cs
Edu.Module.Course/OrderModule.cs
+6
-6
RB_Order_GuestRepository.cs
Edu.Repository/Course/RB_Order_GuestRepository.cs
+11
-0
ClassController.cs
Edu.WebApi/Controllers/Course/ClassController.cs
+5
-6
No files found.
Edu.Model/ViewModel/Course/RB_Order_Guest_ViewModel.cs
View file @
832872b8
...
...
@@ -110,6 +110,11 @@ namespace Edu.Model.ViewModel.Course
/// </summary>
public
DateTime
EffectTime
{
get
;
set
;
}
/// <summary>
/// 生效状态(1-正常,2-全部)
/// </summary>
public
int
QEffectStatus
{
get
;
set
;
}
/// <summary>
/// 生效状态(0-未生效,1-生效中,2-完成)
/// </summary>
...
...
Edu.Module.Course/ClassModule.cs
View file @
832872b8
...
...
@@ -1052,14 +1052,15 @@ namespace Edu.Module.Course
/// </summary>
/// <param name="classId">班级编号</param>
/// <returns></returns>
public
object
GetClassStudentListModule
(
int
classId
,
int
school_Id
,
int
group_Id
,
int
ClassTimeId
)
public
object
GetClassStudentListModule
(
int
classId
,
int
school_Id
,
int
group_Id
,
int
ClassTimeId
,
int
QEffectStatus
=
0
)
{
List
<
object
>
list
=
new
List
<
object
>();
var
orderStudentList
=
order_GuestRepository
.
Get
List
(
new
RB_Order_Guest_ViewModel
()
var
orderStudentList
=
order_GuestRepository
.
Get
OrderGuestListRepository
(
new
RB_Order_Guest_ViewModel
()
{
ClassId
=
classId
,
Group_Id
=
group_Id
,
School_Id
=
school_Id
School_Id
=
school_Id
,
QEffectStatus
=
QEffectStatus
,
}).
Where
(
x
=>
x
.
GuestState
==
1
).
ToList
();
var
classModel
=
GetClassModule
(
classId
);
var
courseModel
=
courseRepository
.
GetEntity
((
classModel
?.
CouseId
??
0
));
...
...
@@ -1109,9 +1110,9 @@ namespace Edu.Module.Course
/// </summary>
/// <param name="classId"></param>
/// <returns></returns>
public
List
<
RB_Order_Guest_ViewModel
>
GetOrderGuest
(
RB_Order_Guest_ViewModel
model
)
public
List
<
RB_Order_Guest_ViewModel
>
GetOrderGuest
ListModule
(
RB_Order_Guest_ViewModel
model
)
{
return
order_GuestRepository
.
Get
List
(
model
);
return
order_GuestRepository
.
Get
OrderGuestListRepository
(
model
);
}
...
...
@@ -1800,7 +1801,7 @@ namespace Edu.Module.Course
timeList
=
class_TimeRepository
.
GetClassTimeListRepository
(
new
RB_Class_Time_ViewModel
()
{
QClassPlanIds
=
Ids
});
}
string
ClassIds
=
string
.
Join
(
","
,
planList
.
GroupBy
(
x
=>
x
.
ClassId
).
Select
(
x
=>
x
.
Key
));
var
orderStudentList
=
order_GuestRepository
.
Get
List
(
new
RB_Order_Guest_ViewModel
()
var
orderStudentList
=
order_GuestRepository
.
Get
OrderGuestListRepository
(
new
RB_Order_Guest_ViewModel
()
{
ClassIds
=
ClassIds
,
Group_Id
=
model
.
Group_Id
,
...
...
@@ -2162,7 +2163,7 @@ namespace Edu.Module.Course
string
classIds
=
string
.
Join
(
","
,
list
.
Select
(
qitem
=>
qitem
.
ClassId
));
string
planIds
=
string
.
Join
(
","
,
list
.
Select
(
qitem
=>
qitem
.
ClassPlanId
));
var
timeList
=
class_TimeRepository
.
GetClassTimeListRepository
(
new
RB_Class_Time_ViewModel
()
{
QClassIds
=
classIds
,
QClassPlanIds
=
planIds
});
var
guestList
=
order_GuestRepository
.
Get
List
(
new
RB_Order_Guest_ViewModel
()
{
ClassIds
=
classIds
});
var
guestList
=
order_GuestRepository
.
Get
OrderGuestListRepository
(
new
RB_Order_Guest_ViewModel
()
{
ClassIds
=
classIds
});
for
(
var
i
=
0
;
i
<
days
;
i
++)
{
var
ClassDate
=
startTime
.
AddDays
(
i
);
...
...
Edu.Module.Course/OrderModule.cs
View file @
832872b8
...
...
@@ -495,7 +495,7 @@ namespace Edu.Module.Course
return
flag
;
}
#
region
验证学生名单数量
var
glist
=
order_GuestRepository
.
Get
List
(
new
RB_Order_Guest_ViewModel
()
{
Group_Id
=
demodel
.
Group_Id
,
OrderId
=
demodel
.
OrderId
,
GuestState
=
1
});
var
glist
=
order_GuestRepository
.
Get
OrderGuestListRepository
(
new
RB_Order_Guest_ViewModel
()
{
Group_Id
=
demodel
.
Group_Id
,
OrderId
=
demodel
.
OrderId
,
GuestState
=
1
});
if
(
glist
.
Count
()
>
demodel
.
GuestNum
)
{
flag
=
false
;
...
...
@@ -1010,7 +1010,7 @@ namespace Edu.Module.Course
//获取备注列表
var
remarkList
=
order_RemarkRepository
.
GetList
(
new
RB_Order_Remark_ViewModel
()
{
},
orderIds
);
//获取名单列表
var
guestList
=
order_GuestRepository
.
Get
List
(
new
RB_Order_Guest_ViewModel
()
{
OrderIds
=
orderIds
});
var
guestList
=
order_GuestRepository
.
Get
OrderGuestListRepository
(
new
RB_Order_Guest_ViewModel
()
{
OrderIds
=
orderIds
});
//获取合同列表
var
clist
=
education_ContractRepository
.
GetList
(
new
RB_Education_Contract_ViewModel
()
{
Group_Id
=
groupId
,
OrderIds
=
orderIds
,
Status
=
-
1
}).
Where
(
x
=>
x
.
Status
!=
4
).
ToList
();
foreach
(
var
item
in
orderList
)
...
...
@@ -1056,7 +1056,7 @@ namespace Edu.Module.Course
{
string
orderIds
=
string
.
Join
(
","
,
orderList
.
Select
(
x
=>
x
.
OrderId
));
//获取名单列表
guestList
=
order_GuestRepository
.
Get
List
(
new
RB_Order_Guest_ViewModel
()
{
OrderIds
=
orderIds
});
guestList
=
order_GuestRepository
.
Get
OrderGuestListRepository
(
new
RB_Order_Guest_ViewModel
()
{
OrderIds
=
orderIds
});
}
foreach
(
var
item
in
orderList
)
{
...
...
@@ -1387,7 +1387,7 @@ namespace Edu.Module.Course
if
(
flag
)
{
//查询所有的学生名单
var
glist
=
order_GuestRepository
.
Get
List
(
new
RB_Order_Guest_ViewModel
()
{
OrderId
=
orderId
});
var
glist
=
order_GuestRepository
.
Get
OrderGuestListRepository
(
new
RB_Order_Guest_ViewModel
()
{
OrderId
=
orderId
});
foreach
(
var
item
in
glist
)
{
Dictionary
<
string
,
object
>
keyValues1
=
new
Dictionary
<
string
,
object
>()
{
...
...
@@ -1859,7 +1859,7 @@ namespace Edu.Module.Course
//获取备注列表
var
remarkList
=
order_RemarkRepository
.
GetList
(
new
RB_Order_Remark_ViewModel
()
{
},
orderIds
);
//获取名单列表
var
guestList
=
order_GuestRepository
.
Get
List
(
new
RB_Order_Guest_ViewModel
()
{
OrderIds
=
orderIds
});
var
guestList
=
order_GuestRepository
.
Get
OrderGuestListRepository
(
new
RB_Order_Guest_ViewModel
()
{
OrderIds
=
orderIds
});
//获取合同列表
var
clist
=
education_ContractRepository
.
GetList
(
new
RB_Education_Contract_ViewModel
()
{
Group_Id
=
demodel
.
Group_Id
,
OrderIds
=
orderIds
,
Status
=
-
1
}).
Where
(
x
=>
x
.
Status
!=
4
).
ToList
();
foreach
(
var
item
in
orderList
)
...
...
@@ -1925,7 +1925,7 @@ namespace Edu.Module.Course
//获取备注列表
var
remarkList
=
order_RemarkRepository
.
GetList
(
new
RB_Order_Remark_ViewModel
()
{
},
orderIds
);
//获取名单列表
var
guestList
=
order_GuestRepository
.
Get
List
(
new
RB_Order_Guest_ViewModel
()
{
OrderIds
=
orderIds
});
var
guestList
=
order_GuestRepository
.
Get
OrderGuestListRepository
(
new
RB_Order_Guest_ViewModel
()
{
OrderIds
=
orderIds
});
//获取合同列表
var
clist
=
education_ContractRepository
.
GetList
(
new
RB_Education_Contract_ViewModel
()
{
Group_Id
=
demodel
.
Group_Id
,
OrderIds
=
orderIds
,
Status
=
-
1
}).
Where
(
x
=>
x
.
Status
!=
4
).
ToList
();
foreach
(
var
item
in
orderList
)
...
...
Edu.Repository/Course/RB_Order_GuestRepository.cs
View file @
832872b8
...
...
@@ -58,6 +58,17 @@ namespace Edu.Repository.Course
{
where
+=
$@" and A.
{
nameof
(
RB_Order_Guest_ViewModel
.
GuestState
)}
=
{
demodel
.
GuestState
}
"
;
}
if
(
demodel
.
QEffectStatus
>
0
)
{
if
(
demodel
.
QEffectStatus
==
1
)
{
where
+=
$@" and B.
{
nameof
(
RB_Order_Guest_ViewModel
.
EffectStatus
)}
IN(1,2)"
;
}
if
(
demodel
.
QEffectStatus
==
2
)
{
where
+=
$@" and B.
{
nameof
(
RB_Order_Guest_ViewModel
.
EffectStatus
)}
IN(0,1,2)"
;
}
}
string
sql
=
$@"
SELECT A.*,IFNULL(B.IsChaBan,0) AS IsChaBan,IFNULL(B.StartClassHours,0) AS StartClassHours,IFNULL(C.CourseName,'') AS CourseName
...
...
Edu.WebApi/Controllers/Course/ClassController.cs
View file @
832872b8
...
...
@@ -707,8 +707,9 @@ namespace Edu.WebApi.Controllers.Course
{
var
classId
=
base
.
ParmJObj
.
GetInt
(
"ClassId"
);
var
schoolId
=
0
;
int
QEffectStatus
=
base
.
ParmJObj
.
GetInt
(
"QEffectStatus"
);
//var schoolId = base.ParmJObj.GetInt("School_Id");
var
data
=
classModule
.
GetClassStudentListModule
(
classId
,
schoolId
,
base
.
UserInfo
.
Group_Id
,
0
);
var
data
=
classModule
.
GetClassStudentListModule
(
classId
,
schoolId
,
base
.
UserInfo
.
Group_Id
,
0
,
QEffectStatus
:
QEffectStatus
);
return
ApiResult
.
Success
(
data
:
data
);
}
...
...
@@ -752,7 +753,7 @@ namespace Edu.WebApi.Controllers.Course
}
}
}
var
orderGuestList
=
classModule
.
GetOrderGuest
(
new
RB_Order_Guest_ViewModel
{
Group_Id
=
base
.
UserInfo
.
Group_Id
,
School_Id
=
0
,
ClassId
=
data
.
ClassId
});
var
orderGuestList
=
classModule
.
GetOrderGuest
ListModule
(
new
RB_Order_Guest_ViewModel
{
Group_Id
=
base
.
UserInfo
.
Group_Id
,
School_Id
=
0
,
ClassId
=
data
.
ClassId
,
QEffectStatus
=
1
});
var
checkLogList
=
classModule
.
GetClassCheckList
(
new
RB_Class_Check_ViewModel
{
Group_Id
=
data
.
Group_Id
,
School_Id
=
data
.
School_Id
,
ClassId
=
data
.
ClassId
,
StartDate
=
data
.
ClassDate
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
),
EndDate
=
data
.
ClassDate
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)
});
List
<
object
>
guestList
=
new
List
<
object
>();
foreach
(
var
item
in
orderGuestList
.
Where
(
x
=>
x
.
GuestState
==
1
))
...
...
@@ -884,7 +885,7 @@ namespace Edu.WebApi.Controllers.Course
return
ApiResult
.
ParamIsNull
(
""
);
}
//获取班级的学员信息
var
orderGuestList
=
classModule
.
GetOrderGuest
(
new
RB_Order_Guest_ViewModel
{
Group_Id
=
base
.
UserInfo
.
Group_Id
,
ClassId
=
list
.
FirstOrDefault
().
ClassId
});
var
orderGuestList
=
classModule
.
GetOrderGuest
ListModule
(
new
RB_Order_Guest_ViewModel
{
Group_Id
=
base
.
UserInfo
.
Group_Id
,
ClassId
=
list
.
FirstOrDefault
().
ClassId
});
if
(
list
.
Count
()
!=
orderGuestList
.
Where
(
x
=>
x
.
GuestState
==
1
).
Count
())
{
return
ApiResult
.
Failed
(
"签到总人数错误,请先检查信息"
);
...
...
@@ -981,9 +982,7 @@ namespace Edu.WebApi.Controllers.Course
}
//获取班级的学员信息
var
orderGuestList
=
classModule
.
GetOrderGuest
(
new
RB_Order_Guest_ViewModel
{
Group_Id
=
base
.
UserInfo
.
Group_Id
,
ClassId
=
exModel
.
ClassId
});
var
orderGuestList
=
classModule
.
GetOrderGuestListModule
(
new
RB_Order_Guest_ViewModel
{
Group_Id
=
base
.
UserInfo
.
Group_Id
,
ClassId
=
exModel
.
ClassId
});
//判断今天有课没有
var
planList
=
classModule
.
GetClassPlanModelRepository
(
new
RB_Class_Plan_ViewModel
...
...
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