-
Notifications
You must be signed in to change notification settings - Fork 425
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AC-810 Allergy can be deleted in online/offline mode #793
Conversation
Codecov Report
@@ Coverage Diff @@
## master #793 +/- ##
==========================================
- Coverage 13.87% 13.76% -0.11%
==========================================
Files 227 228 +1
Lines 9234 9312 +78
Branches 890 893 +3
==========================================
+ Hits 1281 1282 +1
- Misses 7854 7931 +77
Partials 99 99
Continue to review full report at Codecov.
|
}); | ||
} | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@rishabh-997 this file needs formatting maybe !
} | ||
|
||
@Override | ||
public void onFailure(Call<ResponseBody> call, Throwable t) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@rishabh-997 instead of using customAPI callback use default response callback and try to use toast utils in the presenter by using these callbacks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does that mean I need to create another Listener extending DefaultResponseCallback
??? Because I need to send ToastType also as three different Toasts are being used here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@rishabh-997 Maybe we can have an additional method other than OnSuccess and On failure just extend from default response callback and add the additional method for notify does it sounds good ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@rishabh-997 See my comments. Also the dialog's button text color should be white.
openmrs-client/src/main/java/org/openmrs/mobile/api/repository/AllergyRepository.java
Outdated
Show resolved
Hide resolved
openmrs-client/src/main/java/org/openmrs/mobile/api/workers/allergy/DeleteAllergyWorker.java
Outdated
Show resolved
Hide resolved
...main/java/org/openmrs/mobile/activities/patientdashboard/allergy/PatientAllergyFragment.java
Outdated
Show resolved
Hide resolved
I think this needs a separate issue on JIRA as there are other instances in register patient activity where the same problem occurs in night mode, so I will create a separate issue regarding this and update all occurrence of this error. |
I agree, this occurs on almost all alert dialogs in dark mode. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM @rishabh-997
Description of what I changed
Issue I worked on
JIRA Issue: https://issues.openmrs.org/browse/AC-810
Checklist: I completed these to help reviewers :)
(the number above, next to the 'Commits' tab is 1).
existing code that was well tested you do not have to add tests)