developermypos / myPOS-SDK-Android

myPOS SDK Android enabling to integrate Apps with myPOS Card Terminals for Card Payments processing
48 stars 22 forks source link

Last transaction not completed yet #3

Closed philsnook closed 5 years ago

philsnook commented 5 years ago

How can we programmatically clear the previous transaction? I get the message 'Last transaction not completed yet' when calling:

         mPOSHandler.openPaymentActivity(
                        pos.this /*activity*/,
                        REQUEST_CODE_MAKE_PAYMENT /*requestCode*/,
                        "10.50" /*amount*/,
                        UUID.randomUUID().toString()/*transaction reference*/
                );

A reboot of the device does not seem to solve the issue. screenshot-1555231006352

screenshot-1555231330002

philsnook commented 5 years ago

The problem was caused by this event being fired twice..

I have now resolved the issue.


       mPOSHandler.setConnectionListener(new ConnectionListener() {
            @Override
            public void onConnected(final BluetoothDevice device) {

``
AndreTaxiDigital commented 5 years ago

I checked my code I the setConnectionListener is just called once but I always receive "Last transaction not completed yet". Any help?