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
75d62059
Commit
75d62059
authored
Mar 15, 2021
by
liudong1993
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
相亲消息提醒
parent
a61a6db9
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
61 additions
and
2 deletions
+61
-2
RB_Miai_Message_Extend.cs
Mall.Model/Extend/Miai/RB_Miai_Message_Extend.cs
+4
-1
MiaiModule.cs
Mall.Module.Miai/MiaiModule.cs
+13
-1
RB_MiAi_BaseInfoRepository.cs
Mall.Repository/Miai/RB_MiAi_BaseInfoRepository.cs
+4
-0
RB_Miai_MessageRepository.cs
Mall.Repository/Miai/RB_Miai_MessageRepository.cs
+36
-0
AppletMiaiController.cs
Mall.WebApi/Controllers/Miai/AppletMiaiController.cs
+4
-0
No files found.
Mall.Model/Extend/Miai/RB_Miai_Message_Extend.cs
View file @
75d62059
...
@@ -13,6 +13,9 @@ namespace Mall.Model.Extend.Miai
...
@@ -13,6 +13,9 @@ namespace Mall.Model.Extend.Miai
[
DB
(
ConnectionName
=
"DefaultConnection"
)]
[
DB
(
ConnectionName
=
"DefaultConnection"
)]
public
class
RB_Miai_Message_Extend
:
RB_Miai_Message
public
class
RB_Miai_Message_Extend
:
RB_Miai_Message
{
{
/// <summary>
/// 查询类型 1圈子 2拼拼plus 3访客 4系统消息
/// </summary>
public
int
SelectType
{
get
;
set
;
}
}
}
}
}
Mall.Module.Miai/MiaiModule.cs
View file @
75d62059
...
@@ -85,7 +85,19 @@ namespace Mall.Module.Miai
...
@@ -85,7 +85,19 @@ namespace Mall.Module.Miai
/// <returns></returns>
/// <returns></returns>
public
List
<
RB_Miai_Message_Extend
>
GetMiaiMessagePageList
(
int
pageIndex
,
int
pageSize
,
out
long
count
,
RB_Miai_Message_Extend
demodel
)
public
List
<
RB_Miai_Message_Extend
>
GetMiaiMessagePageList
(
int
pageIndex
,
int
pageSize
,
out
long
count
,
RB_Miai_Message_Extend
demodel
)
{
{
return
miaiCommonModule
.
GetPageList
(
pageIndex
,
pageSize
,
out
count
,
demodel
);
var
list
=
miaiCommonModule
.
GetPageList
(
pageIndex
,
pageSize
,
out
count
,
demodel
);
if
(
list
.
Any
())
{
//每种类型 额外返回数据
var
activityList
=
list
.
Where
(
x
=>
x
.
Type
==
Common
.
Enum
.
MiAi
.
MessageTypeEnum
.
SpellEnroll
||
x
.
Type
==
Common
.
Enum
.
MiAi
.
MessageTypeEnum
.
SpellEnrollCancel
||
x
.
Type
==
Common
.
Enum
.
MiAi
.
MessageTypeEnum
.
SpellComment
||
x
.
Type
==
Common
.
Enum
.
MiAi
.
MessageTypeEnum
.
SpellReply
).
ToList
();
if
(
activityList
.
Any
())
{
string
ActivityIds
=
string
.
Join
(
","
,
activityList
.
Select
(
x
=>
x
.
SourceId
).
Distinct
());
var
alist
=
miai_ActivityRepository
.
GetList
(
new
RB_Miai_Activity_Extend
()
{
TenantId
=
demodel
.
TenantId
,
ActivityIds
=
ActivityIds
});
}
}
return
list
;
}
}
/// <summary>
/// <summary>
...
...
Mall.Repository/Miai/RB_MiAi_BaseInfoRepository.cs
View file @
75d62059
...
@@ -86,6 +86,10 @@ namespace Mall.Repository.Miai
...
@@ -86,6 +86,10 @@ namespace Mall.Repository.Miai
{
{
sb
.
AppendFormat
(
" and b.Name like'%{0}%'"
,
where
.
Name
);
sb
.
AppendFormat
(
" and b.Name like'%{0}%'"
,
where
.
Name
);
}
}
if
(
where
.
Sex
>
0
)
{
sb
.
AppendFormat
(
" and a.Sex ={0}"
,
where
.
Sex
);
}
}
}
return
GetPage
<
RB_MiAi_BaseInfo_Extend
>(
pageIndex
,
pageSize
,
out
rowsCount
,
sb
.
ToString
()).
ToList
();
return
GetPage
<
RB_MiAi_BaseInfo_Extend
>(
pageIndex
,
pageSize
,
out
rowsCount
,
sb
.
ToString
()).
ToList
();
}
}
...
...
Mall.Repository/Miai/RB_Miai_MessageRepository.cs
View file @
75d62059
...
@@ -43,6 +43,24 @@ namespace Mall.Repository.Miai
...
@@ -43,6 +43,24 @@ namespace Mall.Repository.Miai
{
{
where
+=
$@" and
{
nameof
(
RB_Miai_Message_Extend
.
Type
)}
=
{(
int
)
dmodel
.
Type
}
"
;
where
+=
$@" and
{
nameof
(
RB_Miai_Message_Extend
.
Type
)}
=
{(
int
)
dmodel
.
Type
}
"
;
}
}
if
(
dmodel
.
SelectType
>
0
)
{
switch
(
dmodel
.
SelectType
)
{
case
1
:
where
+=
$@" and Type in (1,2)"
;
break
;
case
2
:
where
+=
$@" and Type in (3,4,5,6)"
;
break
;
case
3
:
where
+=
$@" and Type in (7)"
;
break
;
case
4
:
where
+=
$@" and Type in (8,9)"
;
break
;
}
}
string
sql
=
$@"select * from RB_Miai_Message where
{
where
}
order by Id desc"
;
string
sql
=
$@"select * from RB_Miai_Message where
{
where
}
order by Id desc"
;
return
GetPage
<
RB_Miai_Message_Extend
>(
pageIndex
,
pageSize
,
out
rowCount
,
sql
).
ToList
();
return
GetPage
<
RB_Miai_Message_Extend
>(
pageIndex
,
pageSize
,
out
rowCount
,
sql
).
ToList
();
...
@@ -124,6 +142,24 @@ namespace Mall.Repository.Miai
...
@@ -124,6 +142,24 @@ namespace Mall.Repository.Miai
{
{
where
+=
$@" and
{
nameof
(
RB_Miai_Message_Extend
.
Type
)}
=
{(
int
)
dmodel
.
Type
}
"
;
where
+=
$@" and
{
nameof
(
RB_Miai_Message_Extend
.
Type
)}
=
{(
int
)
dmodel
.
Type
}
"
;
}
}
if
(
dmodel
.
SelectType
>
0
)
{
switch
(
dmodel
.
SelectType
)
{
case
1
:
where
+=
$@" and Type in (1,2)"
;
break
;
case
2
:
where
+=
$@" and Type in (3,4,5,6)"
;
break
;
case
3
:
where
+=
$@" and Type in (7)"
;
break
;
case
4
:
where
+=
$@" and Type in (8,9)"
;
break
;
}
}
string
sql
=
$@"select count(0) from RB_Miai_Message where
{
where
}
"
;
string
sql
=
$@"select count(0) from RB_Miai_Message where
{
where
}
"
;
var
obj
=
ExecuteScalar
(
sql
);
var
obj
=
ExecuteScalar
(
sql
);
...
...
Mall.WebApi/Controllers/Miai/AppletMiaiController.cs
View file @
75d62059
...
@@ -627,6 +627,10 @@ namespace Mall.WebApi.Controllers.MallBase
...
@@ -627,6 +627,10 @@ namespace Mall.WebApi.Controllers.MallBase
return
flag
?
ApiResult
.
Success
()
:
ApiResult
.
Failed
();
return
flag
?
ApiResult
.
Success
()
:
ApiResult
.
Failed
();
}
}
/// <summary>
/// 批量删除消息
/// </summary>
/// <returns></returns>
[
HttpPost
]
[
HttpPost
]
public
ApiResult
DelMiaiMessageInfoBatch
()
public
ApiResult
DelMiaiMessageInfoBatch
()
{
{
...
...
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