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
f99ccbc4
Commit
f99ccbc4
authored
May 14, 2021
by
吴春
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交支付回调修改
parent
341670f7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
274 additions
and
169 deletions
+274
-169
CacheKey.cs
Edu.Cache/CacheKey.cs
+6
-0
UserReidsCache.cs
Edu.Cache/User/UserReidsCache.cs
+22
-2
RB_Order_Guest.cs
Edu.Model/Entity/Course/RB_Order_Guest.cs
+5
-0
ClassModule.cs
Edu.Module.Course/ClassModule.cs
+1
-1
OrderModule.cs
Edu.Module.Course/OrderModule.cs
+24
-3
ClassController.cs
Edu.WebApi/Controllers/Course/ClassController.cs
+17
-0
OrderController.cs
Edu.WebApi/Controllers/Course/OrderController.cs
+3
-1
WeChatPayController.cs
Edu.WebApi/Controllers/WeChatPay/WeChatPayController.cs
+196
-162
No files found.
Edu.Cache/CacheKey.cs
View file @
f99ccbc4
...
...
@@ -37,5 +37,11 @@ namespace Edu.Cache
/// </summary>
public
static
string
Student_Frozen_Key
=
"Edu_Student_Frozen_"
;
/// <summary>
/// 微信支付回调key
/// </summary>
public
static
string
WeChatPay_Callback_Key
=
"WeChatPay_Callback_Key_"
;
}
}
Edu.Cache/User/UserReidsCache.cs
View file @
f99ccbc4
...
...
@@ -71,12 +71,32 @@ namespace Edu.Cache.User
{
TimeSpan
ts
=
GetExpirTime
(
JwtExpirTime
);
redis
.
StringSet
(
cacheKey
,
Data
,
ts
);
}
catch
(
Exception
)
{
}
}
/// <summary>
/// 获取缓存
/// </summary>
/// <param name="cacheKey"></param>
/// <param name="Data"></param>
/// <param name="JwtExpirTime"></param>
public
static
object
Get
(
string
cacheKey
,
object
Data
,
int
JwtExpirTime
)
{
try
{
object
info
=
redis
.
StringGet
<
object
>(
cacheKey
);
return
info
;
}
catch
(
Exception
)
{
return
""
;
}
}
/// <summary>
/// 账号仓储层对象
/// </summary>
...
...
@@ -88,7 +108,7 @@ namespace Edu.Cache.User
/// <param name="Id">账号Id</param>
/// <param name="apiRequestFromEnum">请求来源</param>
/// <returns></returns>
public
static
UserInfo
GetUserLoginInfo
(
object
Id
,
ApiRequestFromEnum
apiRequestFromEnum
=
ApiRequestFromEnum
.
WebAdmin
)
public
static
UserInfo
GetUserLoginInfo
(
object
Id
,
ApiRequestFromEnum
apiRequestFromEnum
=
ApiRequestFromEnum
.
WebAdmin
)
{
UserInfo
userInfo
=
null
;
if
(
Id
!=
null
)
...
...
@@ -100,7 +120,7 @@ namespace Edu.Cache.User
}
catch
(
Exception
ex
)
{
Common
.
Plugin
.
LogHelper
.
Write
(
ex
,
"GetUserLoginInfo"
);
Common
.
Plugin
.
LogHelper
.
Write
(
ex
,
"GetUserLoginInfo"
);
}
if
(
userInfo
==
null
)
{
...
...
Edu.Model/Entity/Course/RB_Order_Guest.cs
View file @
f99ccbc4
...
...
@@ -190,5 +190,10 @@ namespace Edu.Model.Entity.Course
/// 补课课时
/// </summary>
public
int
MakeUpHours
{
get
;
set
;
}
/// <summary>
/// 学生头像
/// </summary>
public
string
StuIcon
{
get
;
set
;
}
}
}
Edu.Module.Course/ClassModule.cs
View file @
f99ccbc4
...
...
@@ -963,7 +963,7 @@ namespace Edu.Module.Course
{
list
.
Add
(
new
{
UserIcon
=
""
,
UserIcon
=
item
.
StuIcon
,
item
.
Id
,
SexStr
=
item
.
Sex
==
1
?
"男"
:
"女"
,
item
.
GuestName
,
...
...
Edu.Module.Course/OrderModule.cs
View file @
f99ccbc4
...
...
@@ -1525,6 +1525,13 @@ namespace Edu.Module.Course
{
LogContent
+=
",总课时由【"
+
gModel
.
TotalHours
+
"】修改为【"
+
dmodel
.
TotalHours
+
"】"
;
}
if
(
gModel
.
StuIcon
!=
dmodel
.
StuIcon
)
{
LogContent
+=
",学生头像由【"
+
gModel
.
StuIcon
+
"】修改为【"
+
dmodel
.
StuIcon
+
"】"
;
}
gModel
.
StuIcon
=
dmodel
.
StuIcon
;
gModel
.
TotalHours
=
dmodel
.
TotalHours
;
gModel
.
UpdateTime
=
dmodel
.
UpdateTime
;
...
...
@@ -1543,6 +1550,19 @@ namespace Edu.Module.Course
School_Id
=
dmodel
.
School_Id
,
SourceId
=
gModel
.
OrderId
});
if
(!
string
.
IsNullOrWhiteSpace
(
dmodel
.
StuIcon
))
//更新学生表中的头像
{
var
orderGuestModel
=
student_OrderGuestRepository
.
GetStrOrderGuestListRepository
(
new
RB_Student_OrderGuest_ViewModel
{
ClassId
=
gModel
.
ClassId
,
OrderId
=
gModel
.
OrderId
,
GuestId
=
gModel
.
Id
}).
FirstOrDefault
();
if
(
orderGuestModel
!=
null
&&
orderGuestModel
.
Student_Id
>
0
)
{
Dictionary
<
string
,
object
>
fileds
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_Student_ViewModel
.
StuIcon
),
dmodel
.
StuIcon
},
};
studentRepository
.
Update
(
fileds
,
new
WhereHelper
(
nameof
(
RB_Student_ViewModel
.
StuId
),
orderGuestModel
.
Student_Id
));
}
}
}
}
else
...
...
@@ -1603,12 +1623,13 @@ namespace Edu.Module.Course
School_Id
=
classmodel
.
School_Id
,
Status
=
DateStateEnum
.
Normal
,
StuBirth
=
dmodel
.
BirthDate
,
StuIcon
=
""
,
StuIcon
=
dmodel
.
StuIcon
,
StuName
=
dmodel
.
GuestName
,
StuSex
=
dmodel
.
Sex
-
1
,
StuTel
=
dmodel
.
Mobile
,
UpdateBy
=
dmodel
.
CreateBy
,
UpdateTime
=
DateTime
.
Now
UpdateTime
=
DateTime
.
Now
,
});
int
AccountId
=
accountRepository
.
Insert
(
new
Model
.
Entity
.
User
.
RB_Account
()
{
...
...
@@ -1650,7 +1671,7 @@ namespace Edu.Module.Course
Group_Id
=
dmodel
.
Group_Id
,
LogContent
=
LogContent
,
School_Id
=
dmodel
.
School_Id
,
SourceId
=
dmodel
.
OrderId
SourceId
=
dmodel
.
OrderId
,
});
}
}
...
...
Edu.WebApi/Controllers/Course/ClassController.cs
View file @
f99ccbc4
...
...
@@ -1435,6 +1435,23 @@ namespace Edu.WebApi.Controllers.Course
bool
retult
=
classModule
.
UpdateTimeClassVideo
(
extModel
.
VideoUrl
,
extModel
.
ClassTimeId
);
return
retult
?
ApiResult
.
Success
(
"课堂视频更新成功"
)
:
ApiResult
.
Failed
(
"课堂视频更新失败"
);
}
/// <summary>
/// 获取学员列表
/// </summary>
/// <returns></returns>
[
HttpPost
]
[
Microsoft
.
AspNetCore
.
Authorization
.
AllowAnonymous
]
public
ApiResult
GetStudentByClassId
()
{
var
classId
=
base
.
ParmJObj
.
GetInt
(
"ClassId"
);
var
schoolId
=
0
;
var
Group_Id
=
base
.
ParmJObj
.
GetInt
(
"Group_Id"
,
100000
);
var
data
=
classModule
.
GetClassStudentListModule
(
classId
,
schoolId
,
Group_Id
);
return
ApiResult
.
Success
(
data
:
data
);
}
#
endregion
}
...
...
Edu.WebApi/Controllers/Course/OrderController.cs
View file @
f99ccbc4
...
...
@@ -883,6 +883,7 @@ namespace Edu.WebApi.Controllers.Course
x
.
VolunteerMajor
,
x
.
Price
,
x
.
StudyRemark
,
x
.
StuIcon
});
return
ApiResult
.
Success
(
""
,
pageModel
);
}
...
...
@@ -920,7 +921,8 @@ namespace Edu.WebApi.Controllers.Course
Price
=
base
.
ParmJObj
.
GetDecimal
(
"Price"
),
StudyRemark
=
base
.
ParmJObj
.
GetStringValue
(
"StudyRemark"
),
BirthDate
=
base
.
ParmJObj
.
GetDateTime
(
"BirthDate"
),
TotalHours
=
base
.
ParmJObj
.
GetInt
(
"TotalHours"
)
TotalHours
=
base
.
ParmJObj
.
GetInt
(
"TotalHours"
),
StuIcon
=
base
.
ParmJObj
.
GetStringValue
(
"StuIcon"
),
};
if
(
dmodel
.
OrderId
<=
0
)
{
...
...
Edu.WebApi/Controllers/WeChatPay/WeChatPayController.cs
View file @
f99ccbc4
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