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

LBAC-5 Added implementation to edit the patient's locations though patient dashboard #8

Merged
merged 1 commit into from Jul 9, 2018

Conversation

Projects
None yet
2 participants
@suthagar23
Member

suthagar23 commented Jul 5, 2018

Description

Added Implementation to edit the patient's locations through the patient dashboard

  • Added edit link to patient dashboard general actions

Ticket

Ticket : https://issues.openmrs.org/browse/LBAC-5

@suthagar23

This comment has been minimized.

Show comment
Hide comment
@suthagar23

suthagar23 Jul 6, 2018

Member

@dkayiwa I'm struggling at a point to continue the work. I have added a detail description about the issue at here - https://talk.openmrs.org/t/how-to-create-a-fragment-which-can-support-to-edit-from-patient-dashboard/18822

Error Log : https://pastebin.com/dTWFyPHB
Expecting your valuable support to resolve this issue.

Member

suthagar23 commented Jul 6, 2018

@dkayiwa I'm struggling at a point to continue the work. I have added a detail description about the issue at here - https://talk.openmrs.org/t/how-to-create-a-fragment-which-can-support-to-edit-from-patient-dashboard/18822

Error Log : https://pastebin.com/dTWFyPHB
Expecting your valuable support to resolve this issue.

@suthagar23

This comment has been minimized.

Show comment
Hide comment
@suthagar23

suthagar23 Jul 8, 2018

Member

@dkayiwa I have fixed the issue and updated the PR with changes. Now the user can edit the location through the Patient Dashboard.
When he goes to the Edit Location Section, the existing location will be selected to indicate the user. Then he can change it to whatever he needs, and save it.

image

Member

suthagar23 commented Jul 8, 2018

@dkayiwa I have fixed the issue and updated the PR with changes. Now the user can edit the location through the Patient Dashboard.
When he goes to the Edit Location Section, the existing location will be selected to indicate the user. Then he can change it to whatever he needs, and save it.

image

PersonAttribute personAttribute = patient.getAttribute(personAttributeType);
if (personAttribute != null) {
Location patientLocation = Context.getLocationService().getLocationByUuid(personAttribute.getValue());
model.addAttribute("selectedLocationUuid", patientLocation.getUuid());

This comment has been minimized.

@dkayiwa

dkayiwa Jul 8, 2018

Member

Have you tested the user interface when this model attribute is not set?

@dkayiwa

dkayiwa Jul 8, 2018

Member

Have you tested the user interface when this model attribute is not set?

This comment has been minimized.

@suthagar23

suthagar23 Jul 8, 2018

Member

If this model attribute isn't set, then I will get an exception in the interface.
Anymore I have set a null in the top, and replacing that by this value later through this line. So I think, there will be no chances to get that exception
This setting null line also will be updated to set the session location by this ticket soon.

@suthagar23

suthagar23 Jul 8, 2018

Member

If this model attribute isn't set, then I will get an exception in the interface.
Anymore I have set a null in the top, and replacing that by this value later through this line. So I think, there will be no chances to get that exception
This setting null line also will be updated to set the session location by this ticket soon.

@dkayiwa

This comment has been minimized.

Show comment
Hide comment
@dkayiwa

dkayiwa Jul 8, 2018

Member

Is the above ticket link correct?

Member

dkayiwa commented Jul 8, 2018

Is the above ticket link correct?

@suthagar23

This comment has been minimized.

Show comment
Hide comment
@suthagar23

suthagar23 Jul 8, 2018

Member

@dkayiwa Just correct now. Please have a look again

Member

suthagar23 commented Jul 8, 2018

@dkayiwa Just correct now. Please have a look again

Suthagar23
LBAC-5 Added implementation to edit the patient's locations though pa…
…tient dashboard

LBAC-5 Added implementation to edit the patient's locations though patient dashboard

Changed app definition name

Changed app definition name

Changed to RequestParam

Changed privilege to edit the location

Added Constant file

Added license header to constant file

Minor fix for PR review

@dkayiwa dkayiwa merged commit c3fe9c9 into openmrs:master Jul 9, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment