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
f655cc0e
Commit
f655cc0e
authored
Aug 30, 2021
by
liudong1993
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
小程序榜单
parent
c687a920
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
624 additions
and
21 deletions
+624
-21
RB_FirstShop_List.cs
Mall.Model/Entity/TradePavilion/RB_FirstShop_List.cs
+7
-2
RB_FirstShop_ListEnroll.cs
Mall.Model/Entity/TradePavilion/RB_FirstShop_ListEnroll.cs
+11
-6
RB_Brand_Extend.cs
Mall.Model/Extend/TradePavilion/RB_Brand_Extend.cs
+5
-0
RB_Carrier_Extend.cs
Mall.Model/Extend/TradePavilion/RB_Carrier_Extend.cs
+5
-0
RB_FirstShop_ListEnroll_Extend.cs
...el/Extend/TradePavilion/RB_FirstShop_ListEnroll_Extend.cs
+10
-0
RB_FirstShop_List_Extend.cs
Mall.Model/Extend/TradePavilion/RB_FirstShop_List_Extend.cs
+25
-0
FirstShopListModule.cs
Mall.Module.TradePavilion/FirstShopListModule.cs
+274
-3
RB_FirstShop_ListEnrollRepository.cs
...sitory/TradePavilion/RB_FirstShop_ListEnrollRepository.cs
+5
-1
RB_FirstShop_ListRepository.cs
Mall.Repository/TradePavilion/RB_FirstShop_ListRepository.cs
+47
-5
AppletTradeController.cs
...WebApi/Controllers/TradePavilion/AppletTradeController.cs
+228
-0
TradeController.cs
Mall.WebApi/Controllers/TradePavilion/TradeController.cs
+7
-4
No files found.
Mall.Model/Entity/TradePavilion/RB_FirstShop_List.cs
View file @
f655cc0e
...
...
@@ -47,13 +47,18 @@ namespace Mall.Model.Entity.TradePavilion
/// <summary>
/// 报名截止日期
/// </summary>
public
DateTime
Deadline
Date
{
get
;
set
;
}
public
DateTime
End
Date
{
get
;
set
;
}
/// <summary>
///
公示
日期
///
报名开始
日期
/// </summary>
public
DateTime
StartDate
{
get
;
set
;
}
/// <summary>
/// 放榜日期
/// </summary>
public
DateTime
FinishDate
{
get
;
set
;
}
/// <summary>
/// 详细内容
/// </summary>
...
...
Mall.Model/Entity/TradePavilion/RB_FirstShop_ListEnroll.cs
View file @
f655cc0e
...
...
@@ -19,6 +19,11 @@ namespace Mall.Model.Entity.TradePavilion
/// </summary>
public
int
Id
{
get
;
set
;
}
/// <summary>
/// 榜单Id
/// </summary>
public
int
ListId
{
get
;
set
;
}
/// <summary>
/// 用户id
/// </summary>
...
...
@@ -29,6 +34,11 @@ namespace Mall.Model.Entity.TradePavilion
/// </summary>
public
ListObjectTypeEnum
ObjectType
{
get
;
set
;
}
/// <summary>
/// 品牌/载体id
/// </summary>
public
int
ObjectId
{
get
;
set
;
}
/// <summary>
/// 表单内容
/// </summary>
...
...
@@ -79,18 +89,13 @@ namespace Mall.Model.Entity.TradePavilion
/// </summary>
public
int
MallBaseId
{
get
;
set
;
}
/// <summary>
/// 创建人
/// </summary>
public
int
CreateBy
{
get
;
set
;
}
/// <summary>
/// 创建时间
/// </summary>
public
DateTime
CreateDate
{
get
;
set
;
}
/// <summary>
///
修改人
///
操作人 - 后台empId
/// </summary>
public
int
UpdateBy
{
get
;
set
;
}
...
...
Mall.Model/Extend/TradePavilion/RB_Brand_Extend.cs
View file @
f655cc0e
...
...
@@ -12,6 +12,11 @@ namespace Mall.Model.Extend.TradePavilion
/// </summary>
public
string
ClassName
{
get
;
set
;
}
/// <summary>
/// 品牌ids查询
/// </summary>
public
string
BrandIds
{
get
;
set
;
}
public
List
<
string
>
BannerList
{
get
;
set
;
}
...
...
Mall.Model/Extend/TradePavilion/RB_Carrier_Extend.cs
View file @
f655cc0e
...
...
@@ -13,6 +13,11 @@ namespace Mall.Model.Extend.TradePavilion
/// </summary>
public
List
<
RB_CarrierMetro_Extend
>
CarrierMetroList
{
get
;
set
;
}
/// <summary>
/// 载体ids查询
/// </summary>
public
string
CarrierIds
{
get
;
set
;
}
/// <summary>
/// 介绍图
/// </summary>
...
...
Mall.Model/Extend/TradePavilion/RB_FirstShop_ListEnroll_Extend.cs
View file @
f655cc0e
...
...
@@ -17,5 +17,15 @@ namespace Mall.Model.Extend.TradePavilion
/// 用户名称
/// </summary>
public
string
UserName
{
get
;
set
;
}
/// <summary>
/// 品牌/载体名称
/// </summary>
public
string
ObjectName
{
get
;
set
;
}
/// <summary>
/// 品牌/载体图标
/// </summary>
public
string
ObjectIcon
{
get
;
set
;
}
}
}
Mall.Model/Extend/TradePavilion/RB_FirstShop_List_Extend.cs
View file @
f655cc0e
...
...
@@ -22,5 +22,30 @@ namespace Mall.Model.Extend.TradePavilion
/// 面向群里id
/// </summary>
public
int
ObjectTypeId
{
get
;
set
;
}
/// <summary>
/// 小程序端状态 1进行中 , 2报名已截止 , 3已放榜
/// </summary>
public
int
State
{
get
;
set
;
}
/// <summary>
/// 排序 1根据报名截止日期
/// </summary>
public
int
OrderBy
{
get
;
set
;
}
/// <summary>
/// 是否查询正常的 1是
/// </summary>
public
int
IsAppletSelectNor
{
get
;
set
;
}
/// <summary>
/// 报名
/// </summary>
public
List
<
RB_FirstShop_ListEnroll_Extend
>
EnrollList
{
get
;
set
;
}
/// <summary>
/// 上榜列表
/// </summary>
public
List
<
RB_FirstShop_ListEnroll_Extend
>
RankList
{
get
;
set
;
}
}
}
Mall.Module.TradePavilion/FirstShopListModule.cs
View file @
f655cc0e
This diff is collapsed.
Click to expand it.
Mall.Repository/TradePavilion/RB_FirstShop_ListEnrollRepository.cs
View file @
f655cc0e
...
...
@@ -75,13 +75,17 @@ where {where} order by w.Id desc
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_ListEnroll_Extend
.
MallBaseId
)}
=
{
dmodel
.
MallBaseId
}
"
;
}
if
(
dmodel
.
ListId
>
0
)
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_ListEnroll_Extend
.
ListId
)}
=
{
dmodel
.
ListId
}
"
;
}
if
(
dmodel
.
UserId
>
0
)
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_ListEnroll_Extend
.
UserId
)}
=
{
dmodel
.
UserId
}
"
;
}
if
(
dmodel
.
ObjectType
>
0
)
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_ListEnroll_Extend
.
ObjectType
)}
=
{
dmodel
.
ObjectType
}
"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_ListEnroll_Extend
.
ObjectType
)}
=
{
(
int
)
dmodel
.
ObjectType
}
"
;
}
if
(
dmodel
.
CandidateState
>
0
)
{
...
...
Mall.Repository/TradePavilion/RB_FirstShop_ListRepository.cs
View file @
f655cc0e
...
...
@@ -47,12 +47,13 @@ namespace Mall.Repository.TradePavilion
if
(
dmodel
.
ListState
==
Common
.
Enum
.
TradePavilion
.
ListStateEnum
.
Enroll
)
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
ListState
)}
=
{(
int
)
Common
.
Enum
.
TradePavilion
.
ListStateEnum
.
Enroll
}
"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
DeadlineDate
)}
>='
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)}
'"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
StartDate
)}
<='
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)}
'"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
EndDate
)}
>='
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)}
'"
;
}
else
if
(
dmodel
.
ListState
==
Common
.
Enum
.
TradePavilion
.
ListStateEnum
.
Rating
)
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
ListState
)}
=
{(
int
)
Common
.
Enum
.
TradePavilion
.
ListStateEnum
.
Enroll
}
"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
Deadline
Date
)}
<'
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)}
'"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
End
Date
)}
<'
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)}
'"
;
}
else
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
ListState
)}
=
{(
int
)
dmodel
.
ListState
}
"
;
...
...
@@ -68,10 +69,19 @@ namespace Mall.Repository.TradePavilion
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
ListName
)}
@ListName"
;
parameters
.
Add
(
"ListName"
,
"%"
+
dmodel
.
ListName
+
"%"
);
}
if
(
dmodel
.
IsAppletSelectNor
==
1
)
{
//小程序端查询
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
ListState
)}
<>
{(
int
)
Common
.
Enum
.
TradePavilion
.
ListStateEnum
.
Cancel
}
"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
StartDate
)}
<='
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)}
'"
;
}
string
orderBy
=
" order by w.Id desc"
;
if
(
dmodel
.
OrderBy
==
1
)
{
orderBy
=
" order by w.EndDate desc"
;
//根据报名截止日期
}
string
sql
=
$@"select w.* from RB_FirstShop_List w
where
{
where
}
order by w.Id desc
where
{
where
}
{
orderBy
}
"
;
return
GetPage
<
RB_FirstShop_List_Extend
>(
pageIndex
,
pageSize
,
out
count
,
sql
,
parameters
).
ToList
();
}
...
...
@@ -106,12 +116,13 @@ where {where} order by w.Id desc
if
(
dmodel
.
ListState
==
Common
.
Enum
.
TradePavilion
.
ListStateEnum
.
Enroll
)
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
ListState
)}
=
{(
int
)
Common
.
Enum
.
TradePavilion
.
ListStateEnum
.
Enroll
}
"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
DeadlineDate
)}
>='
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)}
'"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
StartDate
)}
>='
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)}
'"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
EndDate
)}
<='
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)}
'"
;
}
else
if
(
dmodel
.
ListState
==
Common
.
Enum
.
TradePavilion
.
ListStateEnum
.
Rating
)
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
ListState
)}
=
{(
int
)
Common
.
Enum
.
TradePavilion
.
ListStateEnum
.
Enroll
}
"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
Deadline
Date
)}
<'
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)}
'"
;
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
End
Date
)}
<'
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
)}
'"
;
}
else
{
...
...
@@ -136,5 +147,36 @@ where {where} order by w.Id desc
return
Get
<
RB_FirstShop_List_Extend
>(
sql
,
parameters
).
ToList
();
}
/// <summary>
/// 获取小程序 我的报名榜单分页列表
/// </summary>
/// <param name="pageIndex"></param>
/// <param name="pageSize"></param>
/// <param name="count"></param>
/// <param name="dmodel"></param>
/// <returns></returns>
public
List
<
RB_FirstShop_List_Extend
>
GetAppletMyEnrollFistShopListPageList
(
int
pageIndex
,
int
pageSize
,
out
long
count
,
RB_FirstShop_List_Extend
dmodel
)
{
var
parameters
=
new
DynamicParameters
();
string
where
=
$" 1=1 and w.Status =0 and e.Status =0 and w.ListState <>
{(
int
)
Common
.
Enum
.
TradePavilion
.
ListStateEnum
.
Cancel
}
"
;
if
(
dmodel
.
TenantId
>
0
)
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
TenantId
)}
=
{
dmodel
.
TenantId
}
"
;
}
if
(
dmodel
.
MallBaseId
>
0
)
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_List_Extend
.
MallBaseId
)}
=
{
dmodel
.
MallBaseId
}
"
;
}
if
(
dmodel
.
CreateBy
>
0
)
{
where
+=
$@" and w.
{
nameof
(
RB_FirstShop_ListEnroll_Extend
.
UserId
)}
=
{
dmodel
.
CreateBy
}
"
;
}
string
sql
=
$@"select w.* from RB_FirstShop_List w
left join rb_firstshop_listenroll e on w.Id = e.ListId
where
{
where
}
group by w.Id order by w.EndDate desc
"
;
return
GetPage
<
RB_FirstShop_List_Extend
>(
pageIndex
,
pageSize
,
out
count
,
sql
,
parameters
).
ToList
();
}
}
}
\ No newline at end of file
Mall.WebApi/Controllers/TradePavilion/AppletTradeController.cs
View file @
f655cc0e
...
...
@@ -84,6 +84,10 @@ namespace Mall.WebApi.Controllers.TradePavilion
/// </summary>
private
readonly
Module
.
User
.
MiniProgramModule
programModule
=
new
Module
.
User
.
MiniProgramModule
();
/// <summary>
/// 榜单
/// </summary>
private
readonly
FirstShopListModule
firstShopListModule
=
new
FirstShopListModule
();
/// <summary>
/// 心愿单
/// </summary>
private
readonly
FirstShopWishModule
firstShopWishModule
=
new
FirstShopWishModule
();
...
...
@@ -1793,6 +1797,230 @@ namespace Mall.WebApi.Controllers.TradePavilion
}
#
endregion
#
region
榜单管理
/// <summary>
/// 获取榜单分页列表
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetAppletFirstShopListPageList
()
{
var
userInfo
=
base
.
AppletUserInfo
;
var
req
=
base
.
RequestParm
;
ResultPageModel
pageModel
=
JsonHelper
.
DeserializeObject
<
ResultPageModel
>(
req
.
msg
.
ToString
());
RB_FirstShop_List_Extend
demodel
=
JsonHelper
.
DeserializeObject
<
RB_FirstShop_List_Extend
>(
req
.
msg
.
ToString
());
demodel
.
TenantId
=
userInfo
.
TenantId
;
demodel
.
MallBaseId
=
userInfo
.
MallBaseId
;
demodel
.
IsAppletSelectNor
=
1
;
demodel
.
OrderBy
=
1
;
var
list
=
firstShopListModule
.
GetAppletFirstShopListPageList
(
pageModel
.
pageIndex
,
pageModel
.
pageSize
,
out
long
count
,
demodel
);
return
ApiResult
.
Success
(
""
,
list
.
Select
(
x
=>
new
{
x
.
Id
,
x
.
ListType
,
ListTypeName
=
x
.
ListType
.
GetEnumName
(),
x
.
ObjectTypeList
,
x
.
Sponsor
,
x
.
ListName
,
x
.
CoverImage
,
EndDate
=
x
.
EndDate
.
ToString
(
"yyyy-MM-dd"
),
StartDate
=
x
.
StartDate
.
ToString
(
"yyyy-MM-dd"
),
FinishDate
=
x
.
FinishDate
.
ToString
(
"yyyy-MM-dd HH:mm"
),
x
.
PrizeNum
,
x
.
State
}));
}
/// <summary>
/// 获取榜单详情
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetAppletFistShopListInfo
()
{
var
userInfo
=
base
.
AppletUserInfo
;
var
req
=
base
.
RequestParm
;
JObject
parms
=
JObject
.
Parse
(
req
.
msg
.
ToString
());
int
ListId
=
parms
.
GetInt
(
"ListId"
,
0
);
//榜单id
if
(
ListId
<=
0
)
{
return
ApiResult
.
ParamIsNull
();
}
var
model
=
firstShopListModule
.
GetAppletFirstShopListInfo
(
ListId
,
userInfo
);
if
(
model
==
null
)
{
return
ApiResult
.
Failed
(
"榜单不存在"
);
}
return
ApiResult
.
Success
(
""
,
new
{
model
.
Id
,
model
.
ListType
,
model
.
ObjectTypeIds
,
model
.
Sponsor
,
model
.
ListName
,
model
.
CoverImage
,
EndDate
=
model
.
EndDate
.
ToString
(
"yyyy-MM-dd"
),
StartDate
=
model
.
StartDate
.
ToString
(
"yyyy-MM-dd"
),
FinishDate
=
model
.
FinishDate
.
ToString
(
"yyyy-MM-dd HH:mm"
),
model
.
Content
,
model
.
EnableRank
,
model
.
PrizeNum
,
model
.
ListState
,
EnrollList
=
model
.
EnrollList
?.
Select
(
x
=>
new
{
x
.
Id
,
x
.
UserId
,
x
.
UserName
,
x
.
ObjectType
,
ObjectTypeName
=
x
.
ObjectType
.
GetEnumName
(),
x
.
ObjectId
,
x
.
ObjectName
,
x
.
ObjectIcon
,
x
.
Content
}),
RankList
=
model
.
RankList
?.
Select
(
x
=>
new
{
x
.
Id
,
x
.
UserId
,
x
.
UserName
,
x
.
ObjectId
,
x
.
ObjectType
,
ObjectTypeName
=
x
.
ObjectType
.
GetEnumName
(),
x
.
ObjectName
,
x
.
ObjectIcon
,
x
.
Reviews
,
x
.
Rank
,
x
.
MedalImage
,
x
.
MedalImageBig
})
});
}
/// <summary>
/// 获取我的可报名的品牌载体
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetAppletMyBrandCarrierList
()
{
var
userInfo
=
base
.
AppletUserInfo
;
JObject
parms
=
JObject
.
Parse
(
base
.
RequestParm
.
msg
.
ToString
());
int
ListId
=
parms
.
GetInt
(
"ListId"
,
0
);
//榜单id
int
EnrollId
=
parms
.
GetInt
(
"EnrollId"
,
0
);
//报名Id
if
(
ListId
<=
0
)
{
return
ApiResult
.
ParamIsNull
();
}
var
list
=
firstShopListModule
.
GetAppletMyBrandCarrierList
(
ListId
,
EnrollId
,
userInfo
);
return
ApiResult
.
Success
(
""
,
list
);
}
/// <summary>
/// 榜单报名
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
SetAppletFirstShopListInfo
()
{
var
userInfo
=
base
.
AppletUserInfo
;
RB_FirstShop_ListEnroll_Extend
demodel
=
JsonHelper
.
DeserializeObject
<
RB_FirstShop_ListEnroll_Extend
>(
base
.
RequestParm
.
msg
.
ToString
());
if
(
demodel
.
ListId
<=
0
)
{
return
ApiResult
.
ParamIsNull
(
"请传递榜单id"
);
}
if
(
demodel
.
ObjectType
<=
0
)
{
return
ApiResult
.
ParamIsNull
(
"请传递类型"
);
}
if
(
demodel
.
ObjectId
<=
0
)
{
return
ApiResult
.
ParamIsNull
(
"请传递品牌载体id"
);
}
if
(
string
.
IsNullOrEmpty
(
demodel
.
Content
))
{
return
ApiResult
.
ParamIsNull
(
"请传递表单内容"
);
}
demodel
.
UserId
=
userInfo
.
UserId
;
demodel
.
CandidateState
=
1
;
demodel
.
RankListState
=
2
;
demodel
.
Status
=
0
;
demodel
.
TenantId
=
userInfo
.
TenantId
;
demodel
.
MallBaseId
=
userInfo
.
MallBaseId
;
demodel
.
CreateDate
=
DateTime
.
Now
;
demodel
.
UpdateDate
=
DateTime
.
Now
;
string
msg
=
firstShopListModule
.
SetAppletFirstShopListInfo
(
demodel
);
if
(
msg
==
""
)
{
return
ApiResult
.
Success
();
}
else
{
return
ApiResult
.
Failed
(
msg
);
}
}
/// <summary>
/// 取消报名
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
CancelAppletFirstShopListInfo
()
{
var
userInfo
=
base
.
AppletUserInfo
;
JObject
parms
=
JObject
.
Parse
(
base
.
RequestParm
.
msg
.
ToString
());
int
EnrollId
=
parms
.
GetInt
(
"EnrollId"
,
0
);
//报名Id
if
(
EnrollId
<=
0
)
{
return
ApiResult
.
ParamIsNull
();
}
string
msg
=
firstShopListModule
.
CancelAppletFirstShopListInfo
(
EnrollId
,
userInfo
);
if
(
msg
==
""
)
{
return
ApiResult
.
Success
();
}
else
{
return
ApiResult
.
Failed
(
msg
);
}
}
/// <summary>
/// 获取榜单类型枚举列表
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetListTypeEnumList
()
{
var
list
=
EnumHelper
.
GetEnumList
(
typeof
(
Common
.
Enum
.
TradePavilion
.
ListTypeEnum
));
return
ApiResult
.
Success
(
""
,
list
.
Select
(
x
=>
new
{
Name
=
x
.
Key
,
Id
=
Convert
.
ToInt32
(
x
.
Value
)
}));
}
/// <summary>
/// 获取我报名的榜单分页列表
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetAppletMyEnrollFistShopListPageList
()
{
var
userInfo
=
base
.
AppletUserInfo
;
var
req
=
base
.
RequestParm
;
ResultPageModel
pageModel
=
JsonHelper
.
DeserializeObject
<
ResultPageModel
>(
req
.
msg
.
ToString
());
RB_FirstShop_List_Extend
demodel
=
JsonHelper
.
DeserializeObject
<
RB_FirstShop_List_Extend
>(
req
.
msg
.
ToString
());
demodel
.
TenantId
=
userInfo
.
TenantId
;
demodel
.
MallBaseId
=
userInfo
.
MallBaseId
;
var
list
=
firstShopListModule
.
GetAppletMyEnrollFistShopListPageList
(
pageModel
.
pageIndex
,
pageModel
.
pageSize
,
out
long
count
,
demodel
);
return
ApiResult
.
Success
(
""
,
list
.
Select
(
x
=>
new
{
x
.
Id
,
x
.
ListType
,
ListTypeName
=
x
.
ListType
.
GetEnumName
(),
x
.
Sponsor
,
x
.
ListName
,
x
.
CoverImage
,
EndDate
=
x
.
EndDate
.
ToString
(
"yyyy-MM-dd"
),
StartDate
=
x
.
StartDate
.
ToString
(
"yyyy-MM-dd"
),
FinishDate
=
x
.
FinishDate
.
ToString
(
"yyyy-MM-dd HH:mm"
),
x
.
PrizeNum
}));
}
#
endregion
#
region
公司信息
(
管理端
)
/// <summary>
...
...
Mall.WebApi/Controllers/TradePavilion/TradeController.cs
View file @
f655cc0e
...
...
@@ -1817,8 +1817,9 @@ namespace Mall.WebApi.Controllers.TradePavilion
x
.
Sponsor
,
x
.
ListName
,
x
.
CoverImage
,
DeadlineDate
=
x
.
DeadlineDate
.
ToString
(
"yyyy-MM-dd HH:mm"
),
StartDate
=
x
.
StartDate
.
ToString
(
"yyyy-MM-dd HH:mm"
),
EndDate
=
x
.
EndDate
.
ToString
(
"yyyy-MM-dd"
),
StartDate
=
x
.
StartDate
.
ToString
(
"yyyy-MM-dd"
),
FinishDate
=
x
.
FinishDate
.
ToString
(
"yyyy-MM-dd HH:mm"
),
x
.
Content
,
x
.
EnableRank
,
x
.
PrizeNum
,
...
...
@@ -1851,8 +1852,9 @@ namespace Mall.WebApi.Controllers.TradePavilion
model
.
Sponsor
,
model
.
ListName
,
model
.
CoverImage
,
DeadlineDate
=
model
.
DeadlineDate
.
ToString
(
"yyyy-MM-dd HH:mm"
),
StartDate
=
model
.
StartDate
.
ToString
(
"yyyy-MM-dd HH:mm"
),
EndDate
=
model
.
EndDate
.
ToString
(
"yyyy-MM-dd"
),
StartDate
=
model
.
StartDate
.
ToString
(
"yyyy-MM-dd"
),
FinishDate
=
model
.
FinishDate
.
ToString
(
"yyyy-MM-dd HH:mm"
),
model
.
Content
,
model
.
EnableRank
,
model
.
PrizeNum
,
...
...
@@ -1887,6 +1889,7 @@ namespace Mall.WebApi.Controllers.TradePavilion
return
ApiResult
.
ParamIsNull
(
"请输入入围名额"
);
}
demodel
.
EndDate
=
Convert
.
ToDateTime
(
demodel
.
EndDate
.
ToString
(
"yyyy-MM-dd"
)
+
" 23:59:59"
);
demodel
.
ListState
=
Common
.
Enum
.
TradePavilion
.
ListStateEnum
.
Enroll
;
demodel
.
TenantId
=
req
.
TenantId
;
demodel
.
MallBaseId
=
req
.
MallBaseId
;
...
...
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