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
b6b0e740
Commit
b6b0e740
authored
Nov 04, 2020
by
吴春
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交代码
parent
7895cfb6
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
103 additions
and
7 deletions
+103
-7
RB_Reserve_ServicePersonal_Extend.cs
...Model/Extend/Reserve/RB_Reserve_ServicePersonal_Extend.cs
+7
-1
ReserveModule.cs
Mall.Module.Reserve/ReserveModule.cs
+18
-3
RB_Reserve_ServicePersonalRepository.cs
...epository/Reserve/RB_Reserve_ServicePersonalRepository.cs
+40
-3
AppletStoresController.cs
Mall.WebApi/Controllers/Reserve/AppletStoresController.cs
+34
-0
ReserveController.cs
Mall.WebApi/Controllers/Reserve/ReserveController.cs
+4
-0
No files found.
Mall.Model/Extend/Reserve/RB_Reserve_ServicePersonal_Extend.cs
View file @
b6b0e740
...
...
@@ -97,6 +97,12 @@ namespace Mall.Model.Extend.Reserve
/// 查询时间条件
/// </summary>
public
string
EndWorkDate
{
get
;
set
;
}
/// <summary>
/// 排序
/// </summary>
public
int
OrderBy
{
get
;
set
;
}
}
...
...
@@ -162,7 +168,7 @@ namespace Mall.Model.Extend.Reserve
public
string
UserName
{
get
;
set
;
}
public
string
BuyerMessage
{
get
;
set
;
}
public
string
Mobile
{
get
;
set
;
}
...
...
Mall.Module.Reserve/ReserveModule.cs
View file @
b6b0e740
...
...
@@ -228,16 +228,31 @@ namespace Mall.Module.Reserve
/// <summary>
///
套餐卡信息列表 订单数和商品数还未关联
///
小程序端服务人员信息列表 待完善
/// </summary>
/// <param name="pageIndex">页码</param>
/// <param name="pageSize">每页显示条数</param>
/// <param name="rowCount">总条数</param>
/// <param name="query">查询条件</param>
/// <returns></returns>
public
List
<
RB_Reserve_ServicePersonal_Extend
>
GetMinServicePersonalList
(
int
pageIndex
,
int
pageSize
,
out
long
rowCount
,
RB_Reserve_ServicePersonal_Extend
query
)
public
List
<
RB_Reserve_ServicePersonal_Extend
>
GetServicePersonalDetailList
(
int
pageIndex
,
int
pageSize
,
out
long
rowCount
,
RB_Reserve_ServicePersonal_Extend
query
)
{
var
list
=
servicePersonalRepository
.
GetServicePersonalDetailList
(
pageIndex
,
pageSize
,
out
rowCount
,
query
);
return
list
;
}
/// <summary>
/// 套餐卡信息列表 订单数和商品数还未关联
/// </summary>
/// <param name="pageIndex">页码</param>
/// <param name="pageSize">每页显示条数</param>
/// <param name="rowCount">总条数</param>
/// <param name="query">查询条件</param>
/// <returns></returns>
public
List
<
RB_Reserve_ServicePersonal_Extend
>
GetMinServicePersonalList
(
int
pageIndex
,
int
pageSize
,
out
long
rowCount
,
RB_Reserve_ServicePersonal_Extend
query
)
{
var
list
=
servicePersonalRepository
.
GetMinServicePersonalList
(
pageIndex
,
pageSize
,
out
rowCount
,
query
);
//if (list != null && list.Any())
...
...
Mall.Repository/Reserve/RB_Reserve_ServicePersonalRepository.cs
View file @
b6b0e740
...
...
@@ -116,8 +116,14 @@ LEFT JOIN (SELECT ServicePersonalId,COUNT(*) as CommentNum from rb_goods_commen
public
List
<
RB_Reserve_ServicePersonal_Extend
>
GetServicePersonalDetailList
(
int
pageIndex
,
int
pageSize
,
out
long
rowCount
,
RB_Reserve_ServicePersonal_Extend
query
)
{
StringBuilder
builder
=
new
StringBuilder
();
builder
.
Append
(
@
$" SELECT a.*,b.CommentNum FROM
{
TableName
}
as A
LEFT
JOIN
(
SELECT
ServicePersonalId
,
COUNT
(*)
as
CommentNum
from
rb_goods_comment
where
Is_Show
=
1
and
Status
=
0
GROUP
by
ServicePersonalId
)
as
b
on
a
.
ID
=
b
.
ServicePersonalId
WHERE
a
.{
nameof
(
RB_Reserve_ServicePersonal_Extend
.
Status
)}=
0
");
builder
.
Append
(
@
$" SELECT a.*,b.OrderNum FROM
{
TableName
}
as A
LEFT
JOIN
(
SELECT
od
.
ServicepersonalId
,
COUNT
(*)
OrderNum
FROM
rb_goods_orderdetail
od
INNER
JOIN
rb_goods_order
o
on
o
.
OrderId
=
od
.
OrderId
where
o
.
OrderClassify
=
3
and
o
.
OrderStatus
in
(
2
,
3
,
4
,
5
,
6
)
and
DATE_FORMAT
(
o
.
PaymentTime
,
'
%
Y
-%
m
-%
d
'
)>=
DATE_FORMAT
(
'
{
System
.
DateTime
.
Now
.
AddDays
(-
30
)}
','
%
Y
-%
m
-%
d
'
)
and
DATE_FORMAT
(
o
.
PaymentTime
,
'
%
Y
-%
m
-%
d
'
)<=
DATE_FORMAT
(
'
{
System
.
DateTime
.
Now
}
','
%
Y
-%
m
-%
d
'
)
GROUP
BY
od
.
ServicepersonalId
)
as
b
on
a
.
ID
=
b
.
ServicePersonalId
WHERE
a
.{
nameof
(
RB_Reserve_ServicePersonal_Extend
.
Status
)}=
0
");
if
(
query
!=
null
)
{
if
(
query
.
TenantId
>
0
)
...
...
@@ -141,7 +147,38 @@ LEFT JOIN (SELECT ServicePersonalId,COUNT(*) as CommentNum from rb_goods_commen
builder
.
Append
(
$" AND a.
{
nameof
(
RB_Reserve_ServicePersonal_Extend
.
Name
)}
like '%
{
query
.
Name
}
%'"
);
}
}
builder
.
Append
(
$" order by a.
{
nameof
(
RB_Reserve_ServicePersonal_Extend
.
ID
)}
desc"
);
if
(!
string
.
IsNullOrWhiteSpace
(
query
.
WorkDate
))
{
builder
.
Append
(
$" and DATE_FORMAT(b.Date,'%Y-%m-%d' )=DATE_FORMAT('
{
query
.
WorkDate
}
','%Y-%m-%d')"
);
}
if
(!
string
.
IsNullOrEmpty
(
query
.
QIds
))
{
builder
.
Append
(
$" AND a.
{
nameof
(
RB_Reserve_ServicePersonal_Extend
.
ID
)}
IN(
{
query
.
QIds
}
) "
);
}
if
(
query
.
OrderBy
==
0
)
{
builder
.
Append
(
$" order by a.
{
nameof
(
RB_Reserve_ServicePersonal_Extend
.
ID
)}
desc"
);
}
else
if
(
query
.
OrderBy
==
1
)
{
builder
.
Append
(
$" order by a.
{
nameof
(
RB_Reserve_ServicePersonal_Extend
.
Score
)}
desc"
);
}
else
if
(
query
.
OrderBy
==
2
)
{
builder
.
Append
(
$" order by a.
{
nameof
(
RB_Reserve_ServicePersonal_Extend
.
Score
)}
asc"
);
}
else
if
(
query
.
OrderBy
==
3
)
{
builder
.
Append
(
$" order by b.OrderNum desc"
);
}
else
if
(
query
.
OrderBy
==
4
)
{
builder
.
Append
(
$" order by b.OrderNum asc"
);
}
return
GetPage
<
RB_Reserve_ServicePersonal_Extend
>(
pageIndex
,
pageSize
,
out
rowCount
,
builder
.
ToString
()).
ToList
();
}
...
...
Mall.WebApi/Controllers/Reserve/AppletStoresController.cs
View file @
b6b0e740
...
...
@@ -249,6 +249,40 @@ namespace Mall.WebApi.Controllers.Reserve
}
[
HttpPost
]
[
AllowAnonymous
]
public
ApiResult
GetServicePersonalDetailList
(
object
requestMsg
)
{
var
parms
=
JsonConvert
.
DeserializeObject
<
RequestParm
>(
requestMsg
.
ToString
());
ResultPageModel
pagelist
=
JsonConvert
.
DeserializeObject
<
ResultPageModel
>(
parms
.
msg
.
ToString
());
RB_Reserve_ServicePersonal_Extend
demodel
=
JsonConvert
.
DeserializeObject
<
RB_Reserve_ServicePersonal_Extend
>(
parms
.
msg
.
ToString
());
demodel
.
TenantId
=
parms
.
TenantId
;
demodel
.
MallBaseId
=
parms
.
MallBaseId
;
demodel
.
ServiceStatus
=
1
;
var
list
=
reserveModule
.
GetServicePersonalDetailList
(
pagelist
.
pageIndex
,
pagelist
.
pageSize
,
out
long
count
,
demodel
);
pagelist
.
count
=
Convert
.
ToInt32
(
count
);
pagelist
.
pageData
=
list
.
Select
(
x
=>
new
{
x
.
ID
,
x
.
ServiceLogo
,
x
.
Name
,
Score
=
x
.
Score
==
0
?
"5"
:
x
.
Score
.
ToString
(),
x
.
OrderNum
,
CreateDateStr
=
x
.
CreateDate
.
ToString
(
"yyyy-MM-dd HH:mm:ss"
),
x
.
ServiceStatus
,
x
.
Telephone
,
x
.
Major
,
x
.
WorkYears
,
x
.
Gender
,
ServiceTypeStr
=
x
.
ServiceType
.
GetEnumName
(),
x
.
ServiceType
,
x
.
FictitiousReserveNum
,
x
.
CommentNum
});
return
ApiResult
.
Success
(
""
,
pagelist
);
}
/// <summary>
/// 获取详情
/// </summary>
...
...
Mall.WebApi/Controllers/Reserve/ReserveController.cs
View file @
b6b0e740
...
...
@@ -166,6 +166,10 @@ namespace Mall.WebApi.Controllers.Reserve
}
/// <summary>
/// 禁用/启用服务人员状态
/// </summary>
...
...
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