Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mall.oytour.com
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
黄奎
mall.oytour.com
Commits
52ff59e2
Commit
52ff59e2
authored
Feb 01, 2021
by
liudong1993
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加小程序控制器
parent
ea95149a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
66 additions
and
0 deletions
+66
-0
AppletPointController.cs
Mall.WebApi/Controllers/Education/AppletPointController.cs
+66
-0
No files found.
Mall.WebApi/Controllers/Education/AppletPointController.cs
0 → 100644
View file @
52ff59e2
using
System
;
using
System.Collections.Generic
;
using
System.Linq
;
using
System.Threading.Tasks
;
using
Mall.CacheManager.User
;
using
Mall.Common.API
;
using
Mall.Common.Plugin
;
using
Mall.Model.Extend.Point
;
using
Mall.Module.Education
;
using
Mall.WebApi.Filter
;
using
Microsoft.AspNetCore.Cors
;
using
Microsoft.AspNetCore.Http
;
using
Microsoft.AspNetCore.Mvc
;
using
Newtonsoft.Json
;
using
Newtonsoft.Json.Linq
;
namespace
Mall.WebApi.Controllers.Education
{
[
Route
(
"api/[controller]/[action]"
)]
[
ApiExceptionFilter
]
[
ApiController
]
[
EnableCors
(
"AllowCors"
)]
public
class
AppletPointController
:
BaseController
{
private
readonly
PointModule
pointModule
=
new
PointModule
();
#
region
点数记录
/// <summary>
/// 小程序获取点数记录
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetAppletUserPointDetailPageList
()
{
var
parms
=
RequestParm
;
var
userInfo
=
AppletUserInfo
;
ResultPageModel
pagelist
=
JsonConvert
.
DeserializeObject
<
ResultPageModel
>(
RequestParm
.
msg
.
ToString
());
RB_Member_PointBalance_Extend
demodel
=
JsonConvert
.
DeserializeObject
<
RB_Member_PointBalance_Extend
>(
RequestParm
.
msg
.
ToString
());
demodel
.
TenantId
=
userInfo
.
TenantId
;
demodel
.
MallBaseId
=
userInfo
.
MallBaseId
;
demodel
.
UserId
=
userInfo
.
UserId
;
var
list
=
pointModule
.
GetUserPointDetailPageList
(
pagelist
.
pageIndex
,
pagelist
.
pageSize
,
out
long
count
,
demodel
);
int
PointNum
=
pointModule
.
GetUserPointBalance
(
userInfo
.
UserId
);
pagelist
.
count
=
Convert
.
ToInt32
(
count
);
pagelist
.
pageData
=
new
{
PointNum
,
List
=
list
.
Select
(
x
=>
new
{
x
.
Id
,
x
.
Type
,
TypeName
=
x
.
Type
.
GetEnumName
(),
x
.
Description
,
x
.
PonitNum
,
x
.
Remarks
,
CreateDate
=
x
.
CreateDate
.
HasValue
?
x
.
CreateDate
.
Value
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)
:
""
})
};
return
ApiResult
.
Success
(
""
,
pagelist
);
}
#
endregion
}
}
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