react-native-radar 3.8.13 → 3.8.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/android/build.gradle
CHANGED
|
@@ -18,7 +18,7 @@ android {
|
|
|
18
18
|
minSdkVersion 16
|
|
19
19
|
targetSdkVersion 31
|
|
20
20
|
versionCode 1
|
|
21
|
-
versionName '3.8.
|
|
21
|
+
versionName '3.8.15'
|
|
22
22
|
}
|
|
23
23
|
lintOptions {
|
|
24
24
|
abortOnError false
|
|
@@ -45,5 +45,5 @@ repositories {
|
|
|
45
45
|
|
|
46
46
|
dependencies {
|
|
47
47
|
api 'com.facebook.react:react-native:+'
|
|
48
|
-
api 'io.radar:sdk:3.8.
|
|
48
|
+
api 'io.radar:sdk:3.8.16'
|
|
49
49
|
}
|
|
@@ -34,6 +34,7 @@ import io.radar.sdk.model.RadarRouteMatrix;
|
|
|
34
34
|
import io.radar.sdk.model.RadarRoutes;
|
|
35
35
|
import io.radar.sdk.model.RadarTrip;
|
|
36
36
|
import io.radar.sdk.model.RadarUser;
|
|
37
|
+
import io.radar.sdk.RadarNotificationOptions;
|
|
37
38
|
|
|
38
39
|
import org.json.JSONException;
|
|
39
40
|
import org.json.JSONObject;
|
|
@@ -527,6 +528,17 @@ public class RNRadarModule extends ReactContextBaseJavaModule implements Permiss
|
|
|
527
528
|
}
|
|
528
529
|
}
|
|
529
530
|
|
|
531
|
+
@ReactMethod
|
|
532
|
+
public void setNotificationOptions(ReadableMap optionsMap) {
|
|
533
|
+
try {
|
|
534
|
+
JSONObject optionsObj = RNRadarUtils.jsonForMap(optionsMap);
|
|
535
|
+
RadarNotificationOptions options = RadarNotificationOptions.fromJson(optionsObj);
|
|
536
|
+
Radar.setNotificationOptions(options);
|
|
537
|
+
} catch (JSONException e) {
|
|
538
|
+
Log.e(TAG, "JSONException", e);
|
|
539
|
+
}
|
|
540
|
+
}
|
|
541
|
+
|
|
530
542
|
@ReactMethod
|
|
531
543
|
public void acceptEvent(String eventId, String verifiedPlaceId) {
|
|
532
544
|
Radar.acceptEvent(eventId, verifiedPlaceId);
|
package/ios/RNRadar.m
CHANGED
|
@@ -425,7 +425,11 @@ RCT_EXPORT_METHOD(getTrackingOptions:(RCTPromiseResolveBlock)resolve reject:(RCT
|
|
|
425
425
|
resolve([options dictionaryValue]);
|
|
426
426
|
}
|
|
427
427
|
|
|
428
|
-
RCT_EXPORT_METHOD(setForegroundServiceOptions) {
|
|
428
|
+
RCT_EXPORT_METHOD(setForegroundServiceOptions:(NSDictionary *)optionsDict) {
|
|
429
|
+
// not implemented
|
|
430
|
+
}
|
|
431
|
+
|
|
432
|
+
RCT_EXPORT_METHOD(setNotificationOptions:(NSDictionary *)optionsDict) {
|
|
429
433
|
// not implemented
|
|
430
434
|
}
|
|
431
435
|
|
package/js/index.native.js
CHANGED
|
@@ -115,6 +115,10 @@ const setForegroundServiceOptions = options => (
|
|
|
115
115
|
NativeModules.RNRadar.setForegroundServiceOptions(options)
|
|
116
116
|
);
|
|
117
117
|
|
|
118
|
+
const setNotificationOptions = options => (
|
|
119
|
+
NativeModules.RNRadar.setNotificationOptions(options)
|
|
120
|
+
);
|
|
121
|
+
|
|
118
122
|
const getTripOptions = () => (
|
|
119
123
|
NativeModules.RNRadar.getTripOptions()
|
|
120
124
|
)
|
|
@@ -231,6 +235,7 @@ const Radar = {
|
|
|
231
235
|
isTracking,
|
|
232
236
|
getTrackingOptions,
|
|
233
237
|
setForegroundServiceOptions,
|
|
238
|
+
setNotificationOptions,
|
|
234
239
|
acceptEvent,
|
|
235
240
|
rejectEvent,
|
|
236
241
|
getTripOptions,
|
package/package.json
CHANGED