Beispiel #1
0
  /** p2p付款 */
  public String p2pPay(
      String toPayAmount,
      String toPayReason,
      String toPayAccount,
      String smsMobileNo,
      String isAddContact,
      String toPayMemo,
      RootActivity activity) {
    BaseServiceBean createP2pOrder =
        serviceFactory.getBean(ServiceBeanConfig.BEAN_NAME_CREATEP2PORDER);

    // 业务联网参数设置
    createP2pOrder.initParams(
        toPayAmount, toPayReason, toPayAccount, smsMobileNo, isAddContact, toPayMemo);
    String responseStr = createP2pOrder.doX();

    if (CommonRespHandler.filter(createP2pOrder)) {
      JSONObject p2pResponse;
      try {
        p2pResponse = new JSONObject(responseStr);
        String tradeNo = p2pResponse.optString(Constant.RQF_TRADE_NO);

        return BaseHelper.payBizDeal(
            activity, null, tradeNo, activity.getExtToken(), null, "trade", "");
      } catch (JSONException e) {
        e.printStackTrace();
      }
      return null;
    } else {
      return responseStr;
    }
  }
Beispiel #2
0
  public String getTransferAccountInfo(String toPayAccount) {
    BaseServiceBean getAccountInfo =
        serviceFactory.getBean(ServiceBeanConfig.BEAN_NAME_GETACCOUNTINFO);
    getAccountInfo.initParams(toPayAccount);

    return getAccountInfo.doX();
  }
Beispiel #3
0
  public String getReceiveTime(String bankShortName) {
    BaseServiceBean getReceiveTime =
        serviceFactory.getBean(ServiceBeanConfig.BEAN_NAME_SUPPORTTRANSFERBANKLIST);
    getReceiveTime.initParams(bankShortName);

    return getReceiveTime.doX();
  }
Beispiel #4
0
  /**
   * 验证手机号绑定关系
   *
   * @param clientID
   * @param sessionId
   * @param phoneNumber
   * @return
   */
  public String queryPhoneBinding(String phoneNumber) {
    BaseServiceBean queryMobileBinding =
        serviceFactory.getBean(ServiceBeanConfig.BEAN_NAME_PHONEBINDINGQUERY);

    // 业务联网参数设置
    queryMobileBinding.initParams(phoneNumber);
    return queryMobileBinding.doX();
  }
Beispiel #5
0
  public String getTransformFee(
      String transferSpeedName, String bankShortName, String transferAmount) {
    BaseServiceBean consultChargeFee =
        serviceFactory.getBean(ServiceBeanConfig.BEAN_NAME_CONSULTCHARGEFEE);
    consultChargeFee.initParams(transferSpeedName, bankShortName, transferAmount);

    return consultChargeFee.doX();
  }
Beispiel #6
0
  public String p2phonePay(
      String receiverPhone,
      String receiverName,
      String transferAmount,
      String bankShortName,
      String transferSpeedName,
      String reason,
      String toPayMemo,
      RootActivity activity) {
    BaseServiceBean createP2PhoneOrder =
        serviceFactory.getBean(ServiceBeanConfig.BEAN_NAME_CREATEP2PHONEORDER);

    // 业务联网参数设置
    createP2PhoneOrder.initParams(
        receiverPhone,
        receiverName,
        transferAmount,
        bankShortName,
        transferSpeedName,
        reason,
        toPayMemo);
    String responseStr = createP2PhoneOrder.doX();

    if (CommonRespHandler.filter(createP2PhoneOrder)) {
      JSONObject p2pResponse;
      try {
        p2pResponse = new JSONObject(responseStr);
        String billNo = p2pResponse.optString(Constant.RPF_BILLNO);

        return BaseHelper.payBizDeal(
            activity, null, billNo, activity.getExtToken(), null, "cell_num_transfer", "");
      } catch (JSONException e) {
        e.printStackTrace();
      }
      return null;
    } else {
      return responseStr;
    }
  }
Beispiel #7
0
 /**
  * 获取转账历史
  *
  * @param clientID
  * @param sessionId
  * @param queryTradeType
  * @return
  */
 public String loadTransferList() {
   BaseServiceBean getTransferList =
       serviceFactory.getBean(ServiceBeanConfig.BEAN_NAME_GETTRANSFERLIST);
   getTransferList.initParams();
   return getTransferList.doX();
 }