Skip to content

Commit

Permalink
mnr
Browse files Browse the repository at this point in the history
  • Loading branch information
benzerbett committed May 24, 2021
1 parent 0590441 commit bb9b877
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 9 deletions.
6 changes: 1 addition & 5 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,6 @@
# dependencies
/node_modules
/server
/server/*
/server/node_modules
/server/package-lock.json
/server/.env

/.pnp
.pnp.js

Expand All @@ -16,6 +11,7 @@

# production
/build
/server
/buildev

# misc
Expand Down
2 changes: 1 addition & 1 deletion public/manifest.webapp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "1.0.9-beta",
"version": "1.1.0-beta",
"name": "Health Commodities Dashboard - Beta",
"appType": "APP",
"description": "An App to Visualize Health Commodities data",
Expand Down
6 changes: 3 additions & 3 deletions src/views/Dashboard/Dashboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ const Dashboard = props => {
if (rows.length > 0) {
let dx_rows = rows.filter(o_dx_rw => o_dx_rw[0] == o_dx);
if (dx_rows.length > 0) {
rows_data.push(parseFloat(dx_rows[0][3]));
rows_data.push(parseFloat(dx_rows[0][reply.fetchedData.headers.findIndex(jk=>jk.name=="value")]));
} else {
rows_data.push(0);
}
Expand Down Expand Up @@ -206,7 +206,7 @@ const Dashboard = props => {
.then(dataz => {
justFetch(hf_exp_url, { signal: abortRequests.signal })
.then(totalorgs => {
totalorgs = parseInt(totalorgs.fetchedData.rows[0][3]) || 0;
totalorgs = parseInt(totalorgs.fetchedData.rows[0][ dataz.fetchedData.headers.findIndex(jk=>jk.name=="value") ]) || 0;

const data = dataz.fetchedData;
let orgunits = data.metaData.dimensions.ou;
Expand Down Expand Up @@ -239,7 +239,7 @@ const Dashboard = props => {
hfss_row.push(nme);
data.rows.map(rentry => {
let dxid = rentry[0];
let mosval = parseFloat(rentry[3]);
let mosval = parseFloat(rentry[ data.headers.findIndex(jk=>jk.name=="value") ]);
if (dxid == entry) {
if (mosval > 6) {
overstock++;
Expand Down

0 comments on commit bb9b877

Please sign in to comment.