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
293582b4
Commit
293582b4
authored
Sep 01, 2021
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
111
parent
93bd4e20
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
73 additions
and
0 deletions
+73
-0
AppletCustomFormController.cs
...i/Controllers/TradePavilion/AppletCustomFormController.cs
+73
-0
No files found.
Mall.WebApi/Controllers/TradePavilion/AppletCustomFormController.cs
0 → 100644
View file @
293582b4
using
System
;
using
System.Collections.Generic
;
using
System.Linq
;
using
System.Threading.Tasks
;
using
Mall.CacheManager.User
;
using
Mall.Common
;
using
Mall.Common.API
;
using
Mall.Common.Enum.Goods
;
using
Mall.Common.Enum.User
;
using
Mall.Common.Plugin
;
using
Mall.Model.Extend.TradePavilion
;
using
Mall.Module.TradePavilion
;
using
Mall.WebApi.Filter
;
using
Microsoft.AspNetCore.Authorization
;
using
Microsoft.AspNetCore.Cors
;
using
Microsoft.AspNetCore.Http
;
using
Microsoft.AspNetCore.Mvc
;
using
Newtonsoft.Json
;
using
Newtonsoft.Json.Linq
;
namespace
Mall.WebApi.Controllers.TradePavilion
{
[
Route
(
"api/[controller]/[action]"
)]
[
ApiExceptionFilter
]
[
ApiController
]
[
EnableCors
(
"AllowCors"
)]
public
class
AppletCustomFormController
:
BaseController
{
/// <summary>
/// 自定义表单处理类对象
/// </summary>
private
readonly
CustomFormModule
customFormModule
=
new
CustomFormModule
();
/// <summary>
/// 根据类型编号获取自定义榜单表单
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetCustomForm
()
{
JObject
parms
=
JObject
.
Parse
(
RequestParm
.
msg
.
ToString
());
var
query
=
new
RB_Custom_Form_Extend
();
int
formType
=
parms
.
GetInt
(
"FormType"
);
if
(
formType
<=
0
)
{
return
ApiResult
.
ParamIsNull
(
message
:
"请传递表单类型!"
);
}
else
{
query
.
FormType
=
(
Common
.
Enum
.
TradePavilion
.
CustomFormTypeEnum
)
formType
;
}
var
userInfo
=
AppletUserInfo
;
query
.
MallBaseId
=
userInfo
.
MallBaseId
;
query
.
TenantId
=
userInfo
.
TenantId
;
var
model
=
customFormModule
.
AppGetCustomFormModule
(
query
);
return
ApiResult
.
Success
(
data
:
model
);
}
/// <summary>
/// 根据表单编号获取表单详情
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetCustomFormInfo
()
{
JObject
parms
=
JObject
.
Parse
(
RequestParm
.
msg
.
ToString
());
var
Id
=
parms
.
GetInt
(
"Id"
);
var
model
=
customFormModule
.
GetCustomFormModule
(
Id
);
return
ApiResult
.
Success
(
data
:
model
);
}
}
}
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