25-10-6/1
This commit is contained in:
@@ -10,6 +10,7 @@ import 'package:Intaleq/views/home/map_page_passenger.dart';
|
||||
import 'package:Intaleq/views/widgets/elevated_btn.dart';
|
||||
|
||||
import '../firebase/firbase_messge.dart';
|
||||
import '../firebase/notification_service.dart';
|
||||
import '../payment/payment_controller.dart';
|
||||
|
||||
// import '../home/captin/home_captain_controller.dart';
|
||||
@@ -70,12 +71,21 @@ class RateController extends GetxController {
|
||||
'token': token1,
|
||||
});
|
||||
if (res != 'failure') {
|
||||
Get.find<FirebaseMessagesController>().sendNotificationToDriverMAP(
|
||||
'You Have Tips'.tr,
|
||||
'${'${tip.toString()}\$${' tips\nTotal is'.tr}'} ${tip + (Get.find<MapPassengerController>().totalPassenger)}',
|
||||
Get.find<MapPassengerController>().driverToken.toString(),
|
||||
[],
|
||||
'ding.wav',
|
||||
// Get.find<FirebaseMessagesController>().sendNotificationToDriverMAP(
|
||||
// 'You Have Tips'.tr,
|
||||
// '${'${tip.toString()}\$${' tips\nTotal is'.tr}'} ${tip + (Get.find<MapPassengerController>().totalPassenger)}',
|
||||
// Get.find<MapPassengerController>().driverToken.toString(),
|
||||
// [],
|
||||
// 'ding',
|
||||
// );
|
||||
await NotificationService.sendNotification(
|
||||
target: Get.find<MapPassengerController>().driverToken.toString(),
|
||||
title: 'You Have Tips',
|
||||
body:
|
||||
'${'${tip.toString()}\$${' tips\nTotal is'.tr}'} ${tip + (Get.find<MapPassengerController>().totalPassenger)}',
|
||||
isTopic: false, // Important: this is a token
|
||||
tone: 'ding',
|
||||
driverList: [],
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user