diff --git a/app/src/main/java/org/apache/fineract/ui/online/customers/customerprofile/editcustomerprofilebottomsheet/EditCustomerProfileBottomSheet.java b/app/src/main/java/org/apache/fineract/ui/online/customers/customerprofile/editcustomerprofilebottomsheet/EditCustomerProfileBottomSheet.java index 77ee5c9c..c2f6d4f0 100644 --- a/app/src/main/java/org/apache/fineract/ui/online/customers/customerprofile/editcustomerprofilebottomsheet/EditCustomerProfileBottomSheet.java +++ b/app/src/main/java/org/apache/fineract/ui/online/customers/customerprofile/editcustomerprofilebottomsheet/EditCustomerProfileBottomSheet.java @@ -286,6 +286,10 @@ void onCancel() { @OnClick(R.id.btn_upload_photo) void uploadPhoto() { if (editAction == EditAction.CAMERA || editAction == EditAction.GALLERY) { + if (file == null) { + Toaster.show(rootView, getString(R.string.select_photo)); + return; + } editCustomerProfilePresenter.uploadCustomerPortrait(customerIdentifier, file); } else if (editAction == EditAction.DELETE) { editCustomerProfilePresenter.deleteCustomerPortrait(customerIdentifier); diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index af22aaa1..b3786122 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -176,6 +176,7 @@ Portrait uploaded successfully Portrait deleted successfully Portrait can\'t exceed size of 512KB. + Please select photo to upload Customer deposit account %1$s created successfully %1$s updated successfully