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
d22cba26
Commit
d22cba26
authored
Jun 03, 2020
by
liudong1993
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://gitlab.oytour.com/Kui2/mall.oytour.com
parents
d1876e8a
94b2c445
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
143 additions
and
5 deletions
+143
-5
MallIndexStatistics.cs
Mall.Model/Extend/Statistics/MallIndexStatistics.cs
+16
-0
RB_MiniProgram_UserCenterMenu_Extend.cs
...Model/Extend/User/RB_MiniProgram_UserCenterMenu_Extend.cs
+4
-1
StatisticsQuery.cs
Mall.Model/Query/StatisticsQuery.cs
+13
-0
ProductModule.cs
Mall.Module.Product/ProductModule.cs
+11
-0
MiniProgramModule.cs
Mall.Module.User/MiniProgramModule.cs
+22
-1
MallStatisticsRepository.cs
Mall.Repository/User/MallStatisticsRepository.cs
+33
-0
RB_MiniProgram_UserCenterMenuRepository.cs
...epository/User/RB_MiniProgram_UserCenterMenuRepository.cs
+31
-1
TenantController.cs
Mall.WebApi/Controllers/User/TenantController.cs
+13
-2
No files found.
Mall.Model/Extend/Statistics/MallIndexStatistics.cs
0 → 100644
View file @
d22cba26
using
Mall.Common.AOP
;
using
System
;
using
System.Collections.Generic
;
using
System.Text
;
namespace
Mall.Model.Extend.Statistics
{
/// <summary>
/// 首页统计
/// </summary>
[
Serializable
]
[
DB
(
ConnectionName
=
"DefaultConnection"
)]
public
class
MallIndexStatistics
{
}
}
Mall.Model/Extend/User/RB_MiniProgram_UserCenterMenu_Extend.cs
View file @
d22cba26
...
...
@@ -12,6 +12,9 @@ namespace Mall.Model.Extend.User
[
DB
(
ConnectionName
=
"DefaultConnection"
)]
public
class
RB_MiniProgram_UserCenterMenu_Extend
:
Model
.
Entity
.
User
.
RB_MiniProgram_UserCenterMenu
{
/// <summary>
/// 用户中心菜单编号
/// </summary>
public
string
DetailIds
{
get
;
set
;
}
}
}
Mall.Model/Query/StatisticsQuery.cs
0 → 100644
View file @
d22cba26
using
System
;
using
System.Collections.Generic
;
using
System.Text
;
namespace
Mall.Model.Query
{
/// <summary>
/// 统计查询条件
/// </summary>
public
class
StatisticsQuery
{
}
}
Mall.Module.Product/ProductModule.cs
View file @
d22cba26
...
...
@@ -884,6 +884,17 @@ namespace Mall.Module.Product
{
return
null
;
}
else
{
model
.
CoverImage
=
""
;
if
(!
string
.
IsNullOrEmpty
(
model
.
CarouselImage
)
&&
model
.
CarouselImage
!=
"[]"
)
{
List
<
string
>
CarouselIdList
=
JsonConvert
.
DeserializeObject
<
List
<
string
>>(
model
.
CarouselImage
);
//封面图
model
.
CoverImage
=
CarouselIdList
[
0
];
//轮播图
}
}
//小程序名称
model
.
MallName
=
programRepository
.
GetEntity
(
model
.
MallBaseId
)?.
MallName
??
""
;
...
...
Mall.Module.User/MiniProgramModule.cs
View file @
d22cba26
...
...
@@ -449,7 +449,7 @@ namespace Mall.Module.User
}
if
(
isGetUserCenterMenu
)
{
var
menuList
=
centerMenuRepository
.
GetListExtRepository
(
new
RB_MiniProgram_UserCenterMenu_Extend
()
{
MallBaseId
=
extModel
.
MallBaseId
});
var
menuList
=
GetMiniProgramUserCenterMenuListModule
(
new
RB_MiniProgram_UserCenterMenu_Extend
()
{
MallBaseId
=
extModel
.
MallBaseId
});
if
(
menuList
!=
null
&&
menuList
.
Count
>
0
)
{
extModel
.
FavoriteFootMenuList
=
menuList
?.
Where
(
qitem
=>
qitem
.
MenuType
==
1
)?.
ToList
();
...
...
@@ -472,6 +472,27 @@ namespace Mall.Module.User
return
extModel
;
}
/// <summary>
/// 根据查询条件获取小程序用户中心菜单列表
/// </summary>
/// <param name="query">查询条件</param>
/// <returns></returns>
public
List
<
RB_MiniProgram_UserCenterMenu_Extend
>
GetMiniProgramUserCenterMenuListModule
(
RB_MiniProgram_UserCenterMenu_Extend
query
)
{
return
centerMenuRepository
.
GetMiniProgramUserCenterMenuListRepository
(
query
);
}
/// <summary>
/// 删除小程序用户中心菜单
/// </summary>
/// <param name="DetailIds">详情编号</param>
/// <param name="MallBaseId">商城编号</param>
/// <returns></returns>
public
bool
DeleteMiniProgramUserCenterMenuModule
(
string
DetailIds
=
""
,
int
MallBaseId
=
0
)
{
return
centerMenuRepository
.
DeleteMiniProgramUserCenterMenuRepository
(
DetailIds
:
DetailIds
,
MallBaseId
:
MallBaseId
);
}
/// <summary>
/// 更新小程序状态
/// </summary>
...
...
Mall.Repository/User/MallStatisticsRepository.cs
0 → 100644
View file @
d22cba26
using
System
;
using
System.Collections.Generic
;
using
System.Text
;
using
Mall.Model.Entity.User
;
using
Mall.Model.Extend.User
;
using
System.Linq
;
using
Mall.Model.Extend.Statistics
;
using
Mall.Model.Query
;
namespace
Mall.Repository.User
{
/// <summary>
/// 商城统计
/// </summary>
public
class
MallStatisticsRepository
:
RepositoryBase
<
MallIndexStatistics
>
{
/// <summary>
/// 用户统计
/// </summary>
public
void
MemberUserStatistics
(
StatisticsQuery
query
)
{
}
/// <summary>
/// 订单统计
/// </summary>
public
void
OrderStatistics
(
StatisticsQuery
query
)
{
}
}
}
Mall.Repository/User/RB_MiniProgram_UserCenterMenuRepository.cs
View file @
d22cba26
...
...
@@ -17,7 +17,7 @@ namespace Mall.Repository.User
/// </summary>
/// <param name="query">查询条件</param>
/// <returns></returns>
public
List
<
RB_MiniProgram_UserCenterMenu_Extend
>
Get
ListEx
tRepository
(
RB_MiniProgram_UserCenterMenu_Extend
query
)
public
List
<
RB_MiniProgram_UserCenterMenu_Extend
>
Get
MiniProgramUserCenterMenuLis
tRepository
(
RB_MiniProgram_UserCenterMenu_Extend
query
)
{
StringBuilder
builder
=
new
StringBuilder
();
builder
.
Append
(
" SELECT * FROM RB_MiniProgram_UserCenterMenu WHERE 1=1 "
);
...
...
@@ -27,8 +27,38 @@ namespace Mall.Repository.User
{
builder
.
AppendFormat
(
" AND MallBaseId={0} "
,
query
.
MallBaseId
);
}
if
(
query
.
DetailIds
!=
null
&&
!
string
.
IsNullOrWhiteSpace
(
query
.
DetailIds
))
{
builder
.
AppendFormat
(
" AND DetailId IN({0}) "
,
query
.
DetailIds
);
}
}
return
Get
<
RB_MiniProgram_UserCenterMenu_Extend
>(
builder
.
ToString
()).
ToList
();
}
/// <summary>
/// 删除小程序用户中心菜单
/// </summary>
/// <param name="DetailIds">详情编号</param>
/// <param name="MallBaseId">商城编号</param>
/// <returns></returns>
public
bool
DeleteMiniProgramUserCenterMenuRepository
(
string
DetailIds
=
""
,
int
MallBaseId
=
0
)
{
bool
flag
=
true
;
StringBuilder
builder
=
new
StringBuilder
();
builder
.
AppendFormat
(
"DELETE FROM RB_MiniProgram_UserCenterMenu WHERE 1=1 "
);
if
(!
string
.
IsNullOrEmpty
(
DetailIds
)
||
MallBaseId
>
0
)
{
if
(!
string
.
IsNullOrEmpty
(
DetailIds
))
{
builder
.
AppendFormat
(
" AND DetailId IN({0}) "
,
DetailIds
);
}
if
(
MallBaseId
>
0
)
{
builder
.
AppendFormat
(
" AND MallBaseId IN({0}) "
,
MallBaseId
);
}
flag
=
base
.
Execute
(
builder
.
ToString
())
>
0
;
}
return
flag
;
}
}
}
Mall.WebApi/Controllers/User/TenantController.cs
View file @
d22cba26
...
...
@@ -1168,8 +1168,19 @@ namespace Mall.WebApi.Controllers.User
public
ApiResult
RemoveMiniUserCenterMenu
()
{
JObject
parms
=
JObject
.
Parse
(
RequestParm
.
msg
.
ToString
());
var
DetailId
=
parms
.
GetInt
(
"DetailId"
,
0
);
var
flag
=
programModule
.
RemoveMiniUserCenterMenuModule
(
DetailId
);
var
DetailId
=
parms
.
GetStringValue
(
"DetailId"
);
var
flag
=
programModule
.
DeleteMiniProgramUserCenterMenuModule
(
DetailIds
:
DetailId
,
MallBaseId
:
0
);
return
flag
?
ApiResult
.
Success
()
:
ApiResult
.
Failed
();
}
/// <summary>
/// 根据商城Id删除用户中心菜单【恢复默认使用】
/// </summary>
/// <returns></returns>
public
ApiResult
RemoveMiniUserCenterMenuByMallId
()
{
JObject
parms
=
JObject
.
Parse
(
RequestParm
.
msg
.
ToString
());
var
flag
=
programModule
.
DeleteMiniProgramUserCenterMenuModule
(
DetailIds
:
""
,
MallBaseId
:
RequestParm
.
MallBaseId
);
return
flag
?
ApiResult
.
Success
()
:
ApiResult
.
Failed
();
}
#
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