openmrs-core icon indicating copy to clipboard operation
openmrs-core copied to clipboard

TRUNK-5466: Business logic of Locations supporting Visits.

Open jnsereko opened this issue 4 years ago • 25 comments

Description: Introduced business logic around having certain locations in OpenMRS support visits.

Issue I worked on TRUNK-5466

see https://issues.openmrs.org/browse/TRUNK-5466

Checklist: I completed these to help reviewers :)

  • [x] My pull request only contains ONE single commit (the number above, next to the 'Commits' tab is 1).

    No? -> read here on how to squash multiple commits into one

  • [x] My IDE is configured to follow the code style of this project.

    No? Unsure? -> configure your IDE, format the code and add the changes with git add . && git commit --amend

  • [ ] I have added tests to cover my changes. (If you refactored existing code that was well tested you do not have to add tests)

    No? -> write tests and add them to this commit git add . && git commit --amend

  • [x] I ran mvn clean package right before creating this pull request and added all formatting changes to my commit.

    No? -> execute above command

  • [ ] All new and existing tests passed.

    No? -> figure out why and add the fix to your commit. It is your responsibility to make sure your code works.

  • [x] My pull request is based on the latest changes of the master branch.

    No? Unsure? -> execute command git pull --rebase upstream master

jnsereko avatar May 06 '20 22:05 jnsereko

I am Still working with tests but i cant tell why security fails cc @ibacher @mozzy11 @dkayiwa

jnsereko avatar May 06 '20 22:05 jnsereko

Coverage Status

Coverage increased (+53.4%) to 63.666% when pulling 3860722ca2c3d2c4bee188daed270a4451270aa0 on jnsereko:TRUNK-5466 into 7ada31cde7b744f53b5f1371a54669651fddbbe9 on openmrs:master.

coveralls avatar May 06 '20 22:05 coveralls

you can go on and complete the ticket requi5rements@jnsereko

HerbertYiga avatar May 07 '20 06:05 HerbertYiga

good progress @jnsereko ,,kindly add some test coverage for your changes

gitcliff avatar May 07 '20 09:05 gitcliff

@jnsereko do you think it was necessary to Test the methods which you introduced . That's part of the Reason why coveralls is catching the changes.

tendomart avatar May 07 '20 09:05 tendomart

@jnsereko I wouldn't worry about the security failures. They're most likely not related to your code changes (I can't see what they are).

A couple of things to bear in mind while working on this:

  1. From the ticket: "We never write openmrs-core code that refers to specific LocationTags"
  2. We're adding a new field, which means we need to add a Hibernate mapping and an appropriate Liquibase migration to add the field to core.
  3. We may need another Liquibase migration to set the default value of the field depending on whether or not it has the "Visit Location" tag.
  4. If you need to add a logger for whatever reason, please use the SLF4J version rather than directly referring to an underlying logging system. SLF4J looks like this:
private static final Logger log = LoggerFactory.getLogger(...);

ibacher avatar May 07 '20 14:05 ibacher

do you think it was necessary to Test the methods which you introduced

@tendomart i thought every new feature added should be written tests. Or may be i am not getting your question clearly.

jnsereko avatar May 07 '20 14:05 jnsereko

May you please review and comment. @ibacher @gitcliff @tendomart @HerbertYiga

jnsereko avatar Jul 06 '20 22:07 jnsereko

@jnsereko the commit message should have the title message

gitcliff avatar Jul 07 '20 06:07 gitcliff

@jnsereko the commit message should have the title message

Thank you @gitcliff for the advice. I thought the commits were going to be more than one as i was pushing, but luckily enough, it only one. So let me try to re-edit the commit. Re-editing the commit is tricky, sometimes i end up closing the PR instead.

jnsereko avatar Jul 07 '20 07:07 jnsereko

@jnsereko also please dont squash the commits as advised here https://talk.openmrs.org/t/rfc-favour-not-squashing-commits-over-squashing-commits/28482/5

gitcliff avatar Jul 07 '20 07:07 gitcliff

hello @dkayiwa @ibacher @gitcliff @tendomart @djazayeri may you please take a review about my work

jnsereko avatar Jul 11 '20 18:07 jnsereko

Thanks @jnsereko for the additions , may be few things worth noting

1.Heading needs to be more clear 2.Your committs are 'noisy" , need to squash them , take time and see how it's done here

https://stackoverflow.com/questions/5189560/squash-my-last-x-commits-together-using-git

tendomart avatar Jul 12 '20 01:07 tendomart

thank you @tendomart. I am to work on your suggestions.

On Sun, Jul 12, 2020 at 4:52 AM tendomart [email protected] wrote:

Thanks @jnsereko https://github.com/jnsereko for the additions , may be few things worth noting

1.Heading needs to be more clear 2.Your committs are 'noisy" , need to squash them

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/openmrs/openmrs-core/pull/3192#issuecomment-657161455, or unsubscribe https://github.com/notifications/unsubscribe-auth/AN2Q6777TDCTWYG2HF3NL2DR3EJMBANCNFSM4M22WLXQ .

jnsereko avatar Jul 12 '20 05:07 jnsereko

Thanks @dkayiwa. I think this branch requires a rebase. Thanks for the review.

jnsereko avatar May 03 '21 19:05 jnsereko

@dkayiwa @gracepotma i have updated my branch. I request for review

thanks

jnsereko avatar May 06 '21 15:05 jnsereko

Hello @jnsereko , Can you resolve merge conflicts probably to have this up to date Thanks man and keep up :+1:

sherrif10 avatar Oct 12 '21 13:10 sherrif10

@jnsereko i know they're annoying and scary attimes but one way to always avoid them is by running a

"git pull --rebase upstream master" at every commit ...

tendomart avatar Oct 12 '21 14:10 tendomart

Hello @jnsereko , Can you resolve merge conflicts probably to have this up to date Thanks man and keep up +1

cc @sherrif10 @dkayiwa @ibacher

jnsereko avatar Oct 13 '21 10:10 jnsereko

@dkayiwa @ibacher @sherrif10 I have added some changes and looked through previous changes.
I kindly request for a review.

jnsereko avatar Nov 23 '21 02:11 jnsereko

hello @ibacher @dkayiwa @sherrif10 @tendomart this has taken sometime :thinking:

jnsereko avatar Mar 11 '22 14:03 jnsereko

thanks @sherrif10 @ibacher for the suggestions

jnsereko avatar Mar 14 '22 15:03 jnsereko

@tendomart looking through the code I believe this code is ready for merge.

jwnasambu avatar Apr 05 '22 07:04 jwnasambu

Thanks @jwnasambu let me also take look

tendomart avatar Apr 05 '22 09:04 tendomart

tl;dr our action detected no activity on this PR and will close it in 30 days if the stale label is not removed.

OpenMRS welcomes your contribution! It means a lot to us that you want to contribute to equity in healthcare!

This PR has not seen any activity in the last 5 months. That is why we wanted to check whether you are still working on it or need assistance from our side. Please note that this is an automated message and we might very well be the reason why there has not been any activity lately. We certainly do not want to discourage you from contributing. We do need to be honest in that OpenMRS has limited resources for reviewing PRs.

If you do not have time to continue the work or have moved on you don’t need to do anything. We will automatically close the PR in 30 days. We hope to see you back soon :) If you would like to continue working on it or require help from us please remove the stale label and respond by commenting on the issue.

github-actions[bot] avatar Sep 03 '22 00:09 github-actions[bot]

tl;dr closing this PR since it has not seen any activity in the last 6 months.

OpenMRS welcomes your contribution! It means a lot to us that you want to contribute to equity in healthcare! We certainly do not want to discourage you from contributing. We do need to be honest in that OpenMRS has limited resources for reviewing PRs. Your PR has not seen any activity in the last 6 months. This is why we have decided to close this PR for now. This allows us OpenMRS reviewers to focus our limited time to review all other PRs in a timely and professional manner.

Please feel free to reassign yourself to the issue you worked on in our JIRA when you have time to focus on it. After that reopen a new PR and we will be glad to work with you to get your contribution merged. Thank you very much for your help and understanding :)

github-actions[bot] avatar Oct 04 '22 00:10 github-actions[bot]