Open fallGamlet opened 2 years ago
Видать не находит такого сервиса, потому что внутри IntegrationManagerImpl.convertImplicitIntentToExplicitIntent
public static List<ComponentName> convertImplicitIntentToExplicitIntent(String action, Context context) {
PackageManager pm = context.getPackageManager();
List<ResolveInfo> resolveInfoList = pm.queryIntentServices(new Intent(action), 0);
List<ComponentName> intentList = new ArrayList<>();
if (resolveInfoList == null || resolveInfoList.isEmpty()) {
return null;
}
for (ResolveInfo serviceInfo : resolveInfoList) {
ComponentName component = new ComponentName(serviceInfo.serviceInfo.packageName, serviceInfo.serviceInfo.name);
intentList.add(component);
}
return intentList;
}
Я думаю, что дело в том, что на моем тестовом терминале Эвотор нет этой службы, потому что он не обновлен до какой-то версии, или у него версия ФФД ниже 1.1
Данные моего терминала Наименование: Эвотор СТ51Ф Версия ОС: 4.3.0 Версия ККТ: 5252 Версия ФФД: 1.05
Если эта ошибка связана с тем, что для использования PrintCorrectionIncomeReceiptCommand нужна версия ФФД выше чем 1.0.5, то лучше выкидывать соответствующее исключение или хотя бы сделать поме нку в документации метода
в классе PrintCorrectionIncomeReceiptCommand возникает ошибка NPE java.lang.NullPointerException: convertImplicitIntentToExplicitIntent(NAME, context.applicationContext) must not be null
потому что IntegrationManagerImpl.convertImplicitIntentToExplicitIntent(NAME, context.applicationContext) возвращает NULL
https://github.com/evotor/integration-library/blob/2e08ffd04f5c7ad69e0b8f88e4195eba8c662204/src/main/java/ru/evotor/framework/core/action/command/print_receipt_command/PrintCorrectionIncomeReceiptCommand.kt