Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
Education
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
黄奎
Education
Commits
b40fe6cc
Commit
b40fe6cc
authored
Aug 29, 2024
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增测试消息推送
parent
cde72d95
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
0 deletions
+29
-0
LoginController.cs
Edu.WebApi/Controllers/User/LoginController.cs
+29
-0
No files found.
Edu.WebApi/Controllers/User/LoginController.cs
View file @
b40fe6cc
using
Edu.Cache.User
;
using
Edu.Common
;
using
Edu.Common.API
;
using
Edu.Common.Enum.System
;
using
Edu.Common.Enum.User
;
using
Edu.Common.Plugin
;
using
Edu.Model.CacheModel
;
...
...
@@ -515,6 +516,7 @@ namespace Edu.WebApi.Controllers.User
};
UserReidsCache
.
UserInfoSet
(
Cache
.
CacheKey
.
User_Login_Key
+
model
.
Id
,
obj
,
Common
.
Config
.
JwtExpirTime
);
return
ApiResult
.
Success
(
data
:
obj
);
}
}
...
...
@@ -673,5 +675,32 @@ namespace Edu.WebApi.Controllers.User
{
return
ApiResult
.
Success
();
}
[
HttpGet
]
[
HttpPost
]
[
AllowAnonymous
]
public
ApiResult
TestMsg
()
{
Common
.
Message
.
MessageHelper
messageHelper
=
new
Common
.
Message
.
MessageHelper
();
List
<
Common
.
Message
.
PushMessageModel
>
list
=
new
List
<
Common
.
Message
.
PushMessageModel
>();
Common
.
Message
.
PushMessageModel
model
=
new
Common
.
Message
.
PushMessageModel
()
{
CategoryId
=
PushMessageCategoryEnum
.
B2BCustomerStu
,
Content
=
"测试"
,
CoverImg
=
""
,
CreateByName
=
"系统"
,
JumpUrl
=
""
,
WorkMsgType
=
"markdown"
,
SendTime
=
DateTime
.
Now
,
SendType
=
0
,
Title
=
"HK"
,
Platform
=
5
,
ReceiveId
=
"HuangKui"
,
};
list
.
Add
(
model
);
messageHelper
.
SendMessage
(
list
);
return
ApiResult
.
Success
();
}
}
}
\ No newline at end of file
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