Pregunta

En mis intentos de entender el flujo de facturación en la aplicación, corrí el Market_billing muestra, como está, más algunos log.v () en puntos clave, como en BillingService.handleCommand():

public void handleCommand(Intent intent, int startId) {
    String action = intent.getAction();
    if (Consts.DEBUG) {
        Log.i(TAG, "handleCommand() action: " + action);
    }
    if (Consts.ACTION_CONFIRM_NOTIFICATION.equals(action)) {
        String[] notifyIds = intent.getStringArrayExtra(Consts.NOTIFICATION_ID);
        confirmNotifications(startId, notifyIds);
    } else if (Consts.ACTION_GET_PURCHASE_INFORMATION.equals(action)) {
        String notifyId = intent.getStringExtra(Consts.NOTIFICATION_ID);
        getPurchaseInformation(startId, new String[] { notifyId });
    } else if (Consts.ACTION_PURCHASE_STATE_CHANGED.equals(action)) {
        String signedData = intent.getStringExtra(Consts.INAPP_SIGNED_DATA);
        String signature = intent.getStringExtra(Consts.INAPP_SIGNATURE);
        purchaseStateChanged(startId, signedData, signature);
    } else if (Consts.ACTION_RESPONSE_CODE.equals(action)) {
        long requestId = intent.getLongExtra(Consts.INAPP_REQUEST_ID, -1);
        int responseCodeIndex = intent.getIntExtra(Consts.INAPP_RESPONSE_CODE,
                ResponseCode.RESULT_ERROR.ordinal());
        ResponseCode responseCode = ResponseCode.valueOf(responseCodeIndex);
        checkResponseCode(requestId, responseCode);
    }
}

Mi problema (?) Es que puedo ver en los registros de todas las acciones que se realizan, pero ACTION_CONFIRM_NOTIFICATION Nunca aparezca por alguna razón, a pesar de que la transacción tiene éxito.

¿Alguna idea de por qué es esto?

¿Qué me estoy perdiendo?

¿Fue útil?

Solución

Action_Confirm_Notification nunca se usa en BillingReceiver y no tengo idea de por qué lo declaran en HandLecommand como confirm_notificación no se debe hacer aquí en primer lugar

Otros consejos

El receptor de billing está esperando el mensaje in_app_notify enviado desde el mercado. Luego comenzaría la confirmación a través del servicio. ¿Su receptor recibe el mensaje in_app_notify?

Yo también tengo un problema similar. Mi aplicación nunca recupera la notificación de la aplicación del mercado. Entonces, en realidad, no hay nada que confirmar para su aplicación. Parece que ya es un problema conocido durante mucho tiempo, como puede ver aquí: http://code.google.com/p/marketbilling/issues/detail?id=14

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top