Thanks Jan
The Active and Deactive modules are not ready yet.
I tested the ADD NEW PLAN, I had to create ther rule for the plan and works good. The delete plan is working also.
Hi Jan
Is not ease to see if plan is active or inactive. In this case is inactive and took me some time to figure it out what is the plan status looking at the UI. Probably we can do a little change and give an eye candy to the users.
You will find the code that implement toggle active/inactive plans in this link:
1.switch case “togglePlanStatus”: get the data from /controllers/browse/view/plans_config.php
2. function togglePlanStatus($plan_id, $nm_flag) update clinical_plans table
I will apraciate your review.
I just push origin with more code in interface/super/rules/controllers/browse/view/plans_config.php and /library/RulesPlanMappingEventHandlers.php
The piece of code does the functionality to the Activate and Deactivate buttons.
I will apreciate your review
Next goal is to flatten it all into one commit, which will take care of some issues I noted in the branch (for example, there are a couple duplicative commits from official openemr branch).
In this situation, I take a non-git shortcut:
First, always keep your original branch since you will be doing a diff on it with your new branch to ensure there isn’t any missing code.
In your current branch copy entire openemr directoroy somewhere and remove the .git directory from this copy (Do NOT remove the .git directory from your git repo though)
Now go back to your git repo.
Find the last openemr official commit you have in there, which I think is 63b296a
check out the official master branch
now make a new branch from this “git checkout -b rebase-cdr-plans-admin_gui_1”
now reset it to commit from step 4 (git reset --hard 63b296a)
now copy in entire openemr directory that you saved in step 2
now make your commit, which will contain all your new code.
Now do following to ensure nothing missing (git diff cdr-plans-admin_gui…rebase-cdr-plans-admin_gui_1). This should return nothing; if it returns something that means code has been left out.
Now get ready to bring in the official openemr commits after 63b296a
go to a new branch “git checkout -b rebase-cdr-plans-admin_gui_2”
now do “git rebase master” (ensure the master branch is up to date official codebase)
You should now have your one commit on top of the most recent official codebase.
One bummer about git is that it only allows one author per commit. I am guessing that will change someday. So when I big project like this is initially brought into OpenEMR then only get to assign one author. We need to ensure other author’s, such as Roberto, get credit in the git commit comments. The nice thing is that all the following commits that happen to the code on this project (after you get the big initial commit in) generally don’t require doing this, so then can ensure proper author, per codeline, credit.