Quellcode durchsuchen

优化谷歌推送铃声

peng vor 1 Jahr
Ursprung
Commit
c645fefe40
1 geänderte Dateien mit 2 neuen und 4 gelöschten Zeilen
  1. 2 4
      Service/PushService.py

+ 2 - 4
Service/PushService.py

@@ -168,13 +168,11 @@ class PushObject:
                 push_data['content_available'] = True
                 push_data['direct_boot_ok'] = True
                 sound = 'android.resource://com.ansjer.zccloud_a/raw/phone_call'
-                default_sound = False
-                android_channel_id = 'video'
                 result = push_service.notify_single_device(registration_id=token_val, message_title=msg_title,
                                                            message_body=msg_text, data_message=push_data, sound=sound,
-                                                           android_channel_id=android_channel_id,
+                                                           android_channel_id='video',
                                                            click_action='android.intent.action.VIEW',
-                                                           extra_kwargs={'default_sound': default_sound,
+                                                           extra_kwargs={'default_sound': False,
                                                                          'default_vibrate_timings': True,
                                                                          'default_light_settings': True,
                                                                          },