Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
A
appzxhy
Project
Project
Details
Activity
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wanglei
appzxhy
Commits
841943c9
Commit
841943c9
authored
Jul 02, 2025
by
wanglei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[迭代]通知限制条件
parent
52f1ba86
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
11 deletions
+12
-11
MyNotificationManager.kt
...uperr/business/push/notification/MyNotificationManager.kt
+11
-11
SplashActivity.kt
app/src/main/java/com/rgt/superr/ui/splash/SplashActivity.kt
+1
-0
No files found.
app/src/main/java/com/rgt/superr/business/push/notification/MyNotificationManager.kt
View file @
841943c9
...
...
@@ -70,6 +70,17 @@ object MyNotificationManager {
}
try
{
sendBeanBlockingQueue
.
put
(
bean
)
LogEx
.
logDebug
(
TAG
,
"sendNotificationCan where=${bean.where} actionId=${bean.actionId}"
)
//上报通知
EventUtils
.
event
(
"Notification_Popup_${bean.where}"
,
"actionId=${bean.actionId}"
)
//当天次数加一
dayPopupCount
+=
1
//推送时间
lastPopupTime
=
System
.
currentTimeMillis
()
//这条推送回调
bean
.
sendSuccess
?.
invoke
()
}
catch
(
e
:
Exception
)
{
EventUtils
.
event
(
"Notification_Error"
,
"submitSendBean Exception"
)
LogEx
.
logDebug
(
"canSendNotification"
,
"submitSendBean Exception"
)
...
...
@@ -103,17 +114,6 @@ object MyNotificationManager {
NotificationUiUtil
.
setNotification
(
bean
)
}.
await
()
LogEx
.
logDebug
(
TAG
,
"sendNotificationCan where=${bean.where} actionId=${bean.actionId}"
)
//上报通知
EventUtils
.
event
(
"Notification_Popup_${bean.where}"
,
"actionId=${bean.actionId}"
)
//当天次数加一
dayPopupCount
+=
1
//推送时间
lastPopupTime
=
System
.
currentTimeMillis
()
//这条推送回调
bean
.
sendSuccess
?.
invoke
()
async
(
Dispatchers
.
Main
)
{
//发送悬停
NotificationHoverUtils
.
sendHoverNotification
(
bean
)
...
...
app/src/main/java/com/rgt/superr/ui/splash/SplashActivity.kt
View file @
841943c9
...
...
@@ -325,6 +325,7 @@ class SplashActivity : BaseActivity<ActivitySplashBinding>(ActivitySplashBinding
super
.
onNewIntent
(
intent
)
actionId
=
intent
?.
extras
?.
getString
(
"actionId"
)
?:
""
isHotLaunch
=
intent
?.
extras
?.
getBoolean
(
"isHotLaunch"
)
==
true
LogEx
.
logDebug
(
TAG
,
"actionId=$actionId"
)
}
}
\ 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