- Update messaging Flutter plugin with Firebase messaging service improvements - Add notification helper and custom push notification helper enhancements - Implement notification opened event handling - Add Android unit tests for payload gate and notification helpers - Update flutter-test app with integration and widget tests - Update notification pipeline roadmap and task documentation
26 lines
688 B
Dart
26 lines
688 B
Dart
class NotificationOpenedEvent {
|
|
final String? serverUrl;
|
|
final String? channelId;
|
|
final String? rootId;
|
|
final bool isCRTEnabled;
|
|
|
|
const NotificationOpenedEvent({
|
|
this.serverUrl,
|
|
this.channelId,
|
|
this.rootId,
|
|
this.isCRTEnabled = false,
|
|
});
|
|
|
|
factory NotificationOpenedEvent.fromMap(Map<String, dynamic> data) {
|
|
return NotificationOpenedEvent(
|
|
serverUrl: data['server_url'] as String?,
|
|
channelId: data['channel_id'] as String?,
|
|
rootId: data['root_id'] as String?,
|
|
isCRTEnabled: _parseCrtEnabled(data['is_crt_enabled']),
|
|
);
|
|
}
|
|
}
|
|
|
|
bool _parseCrtEnabled(Object? value) {
|
|
return value == true || value == 'true' || value == '1';
|
|
}
|