예제 #1
0
  @Override
  public void onCreate() {
    super.onCreate();
    JPushInterface.setDebugMode(true);
    JPushInterface.init(this);
    RongIM.init(this, "pvxdm17jx5lmr", R.drawable.mineral_logo);
    if (SettingUtil.getInstance(getApplicationContext())
        .getValue(SettingUtil.KEY_ACCEPT_PUSH_NOTIFICATION, true)) {
      JPushInterface.resumePush(getApplicationContext());

    } else {
      JPushInterface.stopPush(getApplicationContext());
    }
  }
 void stopPush(JSONArray data, CallbackContext callbackContext) {
   JPushInterface.stopPush(this.cordova.getActivity().getApplicationContext());
   callbackContext.success();
 }