Repo Owner: Ben Guaraldi @benguaraldi
pepfar-datim / datim-approvals Goto Github PK
View Code? Open in Web Editor NEWData approval app for PEPFAR.
Data approval app for PEPFAR.
Repo Owner: Ben Guaraldi @benguaraldi
test submit, accept, recall, return
Partner can't see that mechanism was submitted by agency.....
We should make that obvious so it's not confusing,...
we have a test only as partner
let's do next step... agency, agency hq, inter-agency
User Story: Partner user should be able to Submit pending mechanism to Agency...
Let's do this via REACT Router as a a separate page.
Check MER Tide project and what it would take to redesign the forms using react
let's setup automated tests for the app..
when you click red submit / recall button you don't know what's going on..
it should show loading progress so user knows they should wait...
In order to do the Approvals app refresh I'll ask with a simple task to just display a list of Global approvals
Since we have an alpha-version of approvals.
Try to deploy it to prod...
Data sets are currently not sorted alphabetically in drop down (https://github.com/pepfar-datim/Global/issues/3332#issuecomment-453236975). change to make alphabetical
Uff.. I think we getting close to finish.
Missing tests to implement:
Workflow:
Status:
Status in List for Pending, Accepted, Submitted mechanism for ALL user types
Weird error. If you run scripts slowly the form doesn't get initialized...
If you run them very quickly it is just fine..
after some digging...
If the dataset is not initialized STELLA will re-initialize automatically.
If it has the dataset => fail
Here is a recent analysis of the DATIM server logs:
# A tibble: 13,913 x 5
endpoint Referrer Status n hit_rate
<chr> <chr> <dbl> <int> <dbl>
1 /dhis-web-commons-stream/ping.action https://www.datim.org/dhis-web-dataentry/index.action 204 476642 0.285
2 /api/system/info https://www.datim.org/api/apps/Data-Approval/index.html?v=1.5.2 200 192419 0.115
3 /api/system/info https://www.datim.org/api/apps/Data-Approval/index.html?v=1.5.1 302 150905 0.0903
4 /api/dataValues https://www.datim.org/dhis-web-dataentry/index.action 201 141482 0.0846
5 /dhis-web-commons/security/login.action https://www.datim.org/api/apps/Data-Approval/index.html?v=1.5.1 200 115367 0.0690
6 /api/system/info https://www.datim.org/api/apps/Data-Approval/index.html?v=1.5.2 302 86900 0.0520
7 /dhis-web-commons/security/login.action https://www.datim.org/api/apps/Data-Approval/index.html?v=1.5.2 200 73036 0.0437
This is from a 24 hour period and note that the app is for some reason, making numerous and very rapid requests to two end points: 1) login.action
and 2) api/system/info
. Combined, these add up to almost 37% of the hits on the server in one day, which is well not good.
This actually places a significant load on the Tomcat server, since both of these requests (unlike the `ping.action) actually get through to the Tomcat server.
There is no good reason for this to happen, but the actual cause of it is unclear. We need to get to the bottom of this as soon as possible and prevent the app from making rapid and repeated requests to the server.
If the user is not logged in (due to their session being deactivated) then the app should simply stop working and not continue to do anything.
Requests to the api/system/info
are OK, but should not be regarded as absolutely critical, since people are able to get this information from the "About" menu. If we are not able to prevent this from making a request or two, then we should just remove this functionality entirely.
@benguaraldi please elevate this issue as high as you can with the development team, as it is putting a very high load on the server.
When running gulp build-prod
on https://github.com/pepfar-datim/datim-approvals/tree/4535, app compiles without errors, but /vendor/vendor.js
was not included in zip file. This script loads angular, so without it, the app does not install properly.
App compiled successfully with vendor.js script on https://github.com/pepfar-datim/datim-approvals/tree/3332 and only relevant changes were to remove angular component on 4535
: b2d263d
If I am an Agency User from India. I shouldn't see Botswana in drop-down menu.
If there is only one OU choice make it selected by default.
It's incorrect when doing a clean install with bower
Let's add the feature which displays mechanism form content before submitting it...
Currently the old request does not get canceled.
something like a generated picture saying in which status it is....
pending - > submitted by partner -> accepted by agency-> submitted by agency-> accepted by global
**/
I think the API giving a bogus message in certain cases...
It's saying APPROVED_HERE
but obviously it hasn't been even accepted mayAccept: true
...
Let's use different endpoint which includes also level
:
https://dev-jakub.datim.org/api/29/dataApprovals/categoryOptionCombos?wf=RwNpkAM7Hw7&pe=2019Q1&ou=skj3e4YSiJY
also let's add a drop-down to filter by mechanism status....
the tests are great but here and there we have a random failure.
it would be great to explore why is that and fix those so we can rely on the tests 100% and no need to re-run them on false error
It seems like the API recognizes two actions unapprove
& unaccept
. However, in reality they do the same thing (remove 1 SQL record).
Let's merge them into one button or two separate buttons but don't display both at the same time => confusing
Since this is not a small project.
It would be awesome to use TypeScript inside REACT.
It will help to keep the app more organized and save time by catching compile time errors.
The filtering box in firefox looks a bit funky the text gets sort of sliced off.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.