Hi everyone,
This thread is open to discuss the “potential move” of the current EHR codebase to Laravel.
This was initially brought up by @pri2si17 and probably I wasn’t around LH yet who did tremendous work translating the EHR database so that it can be compatible to the Laravel standard. You can find this here -
Thanks @pri2si17 ,
Problem: While the current codebase “works”, it is however really complicated/tough to navigate around especially for a newbie. I perfectly understand that the code was written years ago, probably by the php gurus, yet things have evolved in the way we build modern apps.
I in particular have had several complaints from students (GCI and aspirant GSocers) that the codebase is actually tough to navigate, While this is somehow true, the codebase is really bulky and has a lot of duplicate stuffs here and there. An attempt for example toe refactor assets during GCI 2018 - Moved imgs in images folder to assets/images folder by jonathanzhang53 · Pull Request #1279 · LibreHealthIO/lh-ehr · GitHub which till date hasn’t been complete.
TL:DR The goal is to port the current codebase to Laravel . I took it up as a challenge to do the whole refactoring and porting to Laravel which I spoke to @r0bby about before going ahead. This has seen progress as I began by installing the basic requirements and gathing the work @pri2si17 did here though a little obsolete with the recent changes in Laravel, but with some modifications helped me get a working database seeded with data of my given size.
TECH STACK: Deciding the tech stack is not an easy choice but however I decided to go with what is comfortable to go with and also easy to learn by any newbie.
- Laravel - https://laravel.com/
- TailwindCss - https://tailwindcss.com/
- InertiaJS - https://inertiajs.com (for single-page app)
- VueJS - https://vuejs.org/
- Sentry sentry.io (for bug triaging)
This will go a long way to address many things such as:
- ACL - Access Control Level
- MultiLanguage app
- Improve Security - this was the major motivation of this push prior to Bishop Fox Security Advisory related to LibreHealth EHR version 2.0.0
- Modularity of codebase.
So far I have been working on this and it has known tremendous progress. Currently, I am done with the boilerplate all those stated up have been addressed and need little or no efforts to implement/stretch through out the codebase. Some basic screens I get are shown below
Your inputs and feedback are highly appreciated as this will go a long way to help achieve the desired results.
NOTE: This change was proposed by me and I am committed in seeing that it is realized. Obviously there is a lot to do, so I am calling on everyone interested in making this big change happen to please reach out so that we can have a roadmap and see how to get things done.
This thread will also serve as update on what is being done and what’s left to do.
BR, Mua