-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Notification/local notify #439
base: develop
Are you sure you want to change the base?
Conversation
…tion/local_notify
Notification/local notify
"@react-native-masked-view/masked-view": "^0.2.6", | ||
"@react-native-picker/picker": "^2.7.7", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- why are we adding this package in this pr?
@@ -0,0 +1,22 @@ | |||
import PushNotification from 'react-native-push-notification'; | |||
|
|||
const LocalNotification = () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Can we export this directly instead of using the default export? It would be easy to find references to LocalNotification once they are used in multiple places.
const key = Date.now().toString(); // Key must be unique everytime | ||
PushNotification.createChannel( | ||
{ | ||
channelId: key, // (required) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- how will the notification work if the channelId is different everytime?
importance: 4, // (optional) default: 4. Int value of the Android notification importance | ||
vibrate: true, // (optional) default: true. Creates the default vibration patten if true. | ||
}, | ||
(created) => console.log(`createChannel returned '${created}'`), // (optional) callback returns whether the channel was created, false means it already existed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- do we need this? where are the logs stored?
// process the notification here | ||
}, | ||
// Android only: GCM or FCM Sender ID | ||
senderID: '1234567890', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- why are we hardcoding this id?
userNameDropDown: { | ||
padding: 20, | ||
borderBottomColor: 'white', | ||
width: '90%', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- 90% seems random can you please paste a screenshot of how this looks and is there any other way to achieve the same thing?
padding: scale(10), | ||
borderRadius: 8, | ||
backgroundColor: StyleConfig.colors.whiteInput, | ||
fontSize: scale(12), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- do we just scale the font to set a font size or is there another way to handle this?
@@ -191,6 +183,7 @@ const AuthScreen = () => { | |||
device_id: deviceId, | |||
}), | |||
}); | |||
console.log('🚀 ~ getAuthStatus ~ data:', data); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove this
@@ -209,6 +202,7 @@ const AuthScreen = () => { | |||
]); | |||
} else { | |||
await data.json(); | |||
console.log('dataa>>>', data.json()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove this
@@ -442,3 +446,46 @@ export const overallTaskProgress = async ( | |||
console.error('API error:', err); | |||
} | |||
}; | |||
|
|||
export const postFcmToken = async (fcmToken: string, token: string) => { | |||
console.log('token is ', `${Config.RDS_SESSION}=${token}`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove this
Date: 29-09-2024
Developer Name: @divyansh0908
Issue Ticket Number
#438
Description
This update marks the completion of the remaining tasks from TCR. The rest of the changes made for this TCR can be found in this (https://github.com/Real-Dev-Squad/mobile-app/pull/439)[PR]. Additionally, This update also include a script that creates
google-services.json
, with support from env.Documentation Updated?
Under Feature Flag
Database Changes
Breaking Changes
Development Tested?
Screenshots
Screenshot 1
WhatsApp.Video.2024-10-01.at.23.15.03.mp4
Test Coverage
Screenshot 1
Additional Notes