This commit is contained in:
lizandrogd
2023-08-21 22:25:51 -05:00
parent ede125d181
commit 74e857bab3
2 changed files with 4 additions and 3 deletions
+1
View File
@@ -74,6 +74,7 @@ class Professional {
' longitude: $longitude,\n'
' professionalEspecializado: ${getEspecializaciones()}\n'
' tarifa: $tarifa,\n'
' token: $token,\n'
'}';
}
+3 -3
View File
@@ -47,7 +47,7 @@ class _ServiceScreenState extends State<ServiceScreen> {
}
}
Future<void> sendPushNotification(String token) async {
Future<void> sendPushNotification(String pro) async {
try {
http.Response response = await http.post(
Uri.parse('https://fcm.googleapis.com/fcm/send'),
@@ -68,12 +68,12 @@ class _ServiceScreenState extends State<ServiceScreen> {
'id': '1',
'status': 'done'
},
'to': token,
'to': pro,
},
),
);
print(token);
print(pro);
print(response);
response;
} catch (e) {