Our app relies on getting Customer information from the Order. Seems to work for all our merchants except one. Can we get some insight into why this might be? I will post the device ID as a comment-for-moderator. Thanks.
Our app relies on getting Customer information from the Order. Seems to work for all our merchants except one. Can we get some insight into why this might be? I will post the device ID as a comment-for-moderator. Thanks.
Can you provide an order id in a private post as well? Is it possible there isn't a customer associated with the order? How are you obtaining the order/customer? Is it possible at some point you had to add customer read permissions? If so, is it possible the merchant never uninstalled/reinstalled your app after you added the permission?
We've confirmed with a pic of the order screen that there is a customer attached.
Our app gets the Order and Customer with an OrderConnecter in our customer tender activity (code fragment below).
We definitely did have to add customer read permission in an app update. We had issues with this merchant in the uninstall/reinstall process but I'm relatively confident it eventually worked.
new Thread(new Runnable() { @Override public void run() { OrderConnector orderConnector = new OrderConnector(getApplicationContext(), CloverAccount.getAccount(TenderActivity.this), null); try { Order order = orderConnector.getOrder(mOrderId); List<Customer> customers = order.getCustomers(); Logger.i("log_test", "Set CustomerInfo from " + customers.size() + " customer"); // assign object whether or not we have an attached customer mTenderViewModel.CustomerInfo = new JSONObject(); if (customers != null && customers.size() > 0) { try { mTenderViewModel.CustomerInfo.put(Constant.KEY_MOBILE, customers.get(0).getPhoneNumbers().get(0).getPhoneNumber()); mTenderViewModel.CustomerInfo.put(Constant.KEY_EMAIL, customers.get(0).getEmailAddresses().get(0).getEmailAddress()); } catch (Exception e) { e.printStackTrace(); } } } catch (RemoteException e) { e.printStackTrace(); } catch (ClientException e) { e.printStackTrace(); } catch (ServiceException e) { e.printStackTrace(); } catch (BindingException e) { e.printStackTrace(); } } }).start();
Have the merchant reproduce the issue and then immediately after send us the device logs (Help App -> Menu -> Diagnostics -> Send device logs) we can then check the logs to see if any of those exceptions are printing.
2 People are following this question.