cordova-plugin-appice 2.2.6 → 2.2.7

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cordova-plugin-appice",
3
- "version": "2.2.6",
3
+ "version": "2.2.7",
4
4
  "description": "AppICE Plugin for Cordova/PhoneGap",
5
5
  "cordova": {
6
6
  "id": "cordova-plugin-appice",
package/plugin.xml CHANGED
@@ -1,6 +1,6 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
2
  <plugin xmlns="http://apache.org/cordova/ns/plugins/1.0"
3
- id="cordova-plugin-appice" version="2.2.6">
3
+ id="cordova-plugin-appice" version="2.2.7">
4
4
  <name>AppICE</name>
5
5
  <description>AppICE Plugin for Cordova/PhoneGap</description>
6
6
  <license>Commercial</license>
@@ -41,7 +41,7 @@
41
41
 
42
42
  <podspec>
43
43
  <pods>
44
- <pod name="AppICE-IOS-SDK" spec="1.8.01" />
44
+ <pod name="AppICE-IOS-SDK" spec="1.8.02" />
45
45
  </pods>
46
46
  </podspec>
47
47
 
@@ -121,7 +121,7 @@
121
121
  <preference name="MEDIA3_UI_VERSION" default="1.0.2"/>
122
122
 
123
123
  <!-- AppICE VERSION-->
124
- <preference name="APPICE_VERSION" default="2.6.12"/>
124
+ <preference name="APPICE_VERSION" default="2.6.14-release"/>
125
125
 
126
126
 
127
127
  <!-- USES PERMISSION -->
@@ -1585,7 +1585,7 @@ public class AppICEPlugin extends CordovaPlugin {
1585
1585
  public void run() {
1586
1586
  ClickCallback clickCallback = new ClickCallback() {
1587
1587
  @Override
1588
- public void clickPayload(String obj) {
1588
+ public void clickPayload(JSONObject obj) {
1589
1589
  if (Utility.isValidObject(obj)) {
1590
1590
  if (callbackContext != null) {
1591
1591
  try {
@@ -1601,7 +1601,6 @@ public class AppICEPlugin extends CordovaPlugin {
1601
1601
  CampaignCampsReceiver campaignCampsReceiver = new CampaignCampsReceiver(clickCallback);
1602
1602
  }
1603
1603
  });
1604
- callbackContext.success();
1605
1604
  } catch (Throwable e) {
1606
1605
  callbackContext.error(e.getMessage());
1607
1606
  }
@@ -46,8 +46,9 @@ public class CampaignCampsReceiver extends BroadcastReceiver {
46
46
 
47
47
  if (inApp) {
48
48
  if (cdata != null && cdata.length() > 0) {
49
+ JSONObject cdataObject = new JSONObject(cdata);
49
50
  if (clickCallback != null) {
50
- clickCallback.clickPayload(cdata);
51
+ clickCallback.clickPayload(cdataObject);
51
52
  Utility.loginfo("CampaignRec : clickCallback "+cdata);
52
53
  } else
53
54
  Utility.loginfo("callback is null");
@@ -1,6 +1,7 @@
1
1
  package com.appice.cordova;
2
+ import org.json.JSONObject;
2
3
 
3
4
  public interface ClickCallback {
4
- void clickPayload(String obj);
5
+ void clickPayload(JSONObject obj);
5
6
 
6
7
  }
@@ -1584,9 +1584,7 @@ static NSDictionary *pendingDeeplink = nil;
1584
1584
  - (void)suspendInApp:(CDVInvokedUrlCommand *)command {
1585
1585
  [self.commandDelegate runInBackground:^{
1586
1586
  @try {
1587
- // [[appICE sharedInstance] suspendInApp];
1588
- /**NOTE: As suspendInApp is queing the INAPP ,calling discardInApp in suspendInApp function which will do NOTHING (not queue) Done as Android**/
1589
- [[appICE sharedInstance] discardInApp];
1587
+ [[appICE sharedInstance] suspendInApp];
1590
1588
  CDVPluginResult *result = [CDVPluginResult resultWithStatus:CDVCommandStatus_OK];
1591
1589
  [self.commandDelegate sendPluginResult:result callbackId:command.callbackId];
1592
1590
  } @catch (NSException *e) {