From cab7f23be84840d613ee8cb3261da1f49abdd205 Mon Sep 17 00:00:00 2001 From: Mateo Clarke Date: Mon, 15 Mar 2021 15:38:07 -0500 Subject: [PATCH 1/7] add version info to console --- moped-editor/src/App.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/moped-editor/src/App.js b/moped-editor/src/App.js index 61e08320dc..d06c2c179b 100644 --- a/moped-editor/src/App.js +++ b/moped-editor/src/App.js @@ -8,6 +8,7 @@ import theme from "src/theme"; import { routes, restrictRoutes } from "src/routes"; import { useUser, getJwt, getHighestRole } from "./auth/user"; import { setContext } from "@apollo/client/link/context"; +var pckg = require("../package.json"); // Apollo GraphQL Client import { @@ -48,6 +49,8 @@ const App = () => { cache: new InMemoryCache(), }); + console.log(`🛵 ${pckg.name} ${pckg.version} 🛵`); + return ( From 8f4e5b0a3790331af2b2318fc5a7839108f7952c Mon Sep 17 00:00:00 2001 From: Mateo Clarke Date: Mon, 15 Mar 2021 16:21:06 -0500 Subject: [PATCH 2/7] remove console logging --- moped-editor/src/App.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/moped-editor/src/App.js b/moped-editor/src/App.js index d06c2c179b..61e08320dc 100644 --- a/moped-editor/src/App.js +++ b/moped-editor/src/App.js @@ -8,7 +8,6 @@ import theme from "src/theme"; import { routes, restrictRoutes } from "src/routes"; import { useUser, getJwt, getHighestRole } from "./auth/user"; import { setContext } from "@apollo/client/link/context"; -var pckg = require("../package.json"); // Apollo GraphQL Client import { @@ -49,8 +48,6 @@ const App = () => { cache: new InMemoryCache(), }); - console.log(`🛵 ${pckg.name} ${pckg.version} 🛵`); - return ( From 20e300de6eb62957990e8863c4f46ad4e8d67e71 Mon Sep 17 00:00:00 2001 From: Mateo Clarke Date: Fri, 4 Jun 2021 01:54:35 -0500 Subject: [PATCH 3/7] bump version number --- moped-editor/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/moped-editor/package.json b/moped-editor/package.json index 899851028f..7c12b38942 100644 --- a/moped-editor/package.json +++ b/moped-editor/package.json @@ -2,7 +2,7 @@ "name": "atd-moped-editor", "author": "ATD Data & Technology Services", "licence": "CC0 1.0 Universal", - "version": "0.5.0", + "version": "0.6.0", "homepage": "/moped", "private": false, "scripts": { From 400d9a9860237f0a36bfb2160b557515dd1dac40 Mon Sep 17 00:00:00 2001 From: tillyw Date: Thu, 10 Jun 2021 15:27:13 -0500 Subject: [PATCH 4/7] added current phase to projects list view --- moped-database/metadata/tables.yaml | 3 ++ .../1623356400058_run_sql_migration/up.sql | 33 +++++++++++++++++++ .../ProjectsListViewQueryConf.js | 2 +- 3 files changed, 37 insertions(+), 1 deletion(-) create mode 100644 moped-database/migrations/1623356400058_run_sql_migration/up.sql diff --git a/moped-database/metadata/tables.yaml b/moped-database/metadata/tables.yaml index 3a3ba560bf..8a8627fd50 100644 --- a/moped-database/metadata/tables.yaml +++ b/moped-database/metadata/tables.yaml @@ -4525,6 +4525,7 @@ - fiscal_year - is_retired - milestone_id + - phase_name - project_description - project_description_public - project_id @@ -4554,6 +4555,7 @@ - fiscal_year - is_retired - milestone_id + - phase_name - project_description - project_description_public - project_id @@ -4583,6 +4585,7 @@ - fiscal_year - is_retired - milestone_id + - phase_name - project_description - project_description_public - project_id diff --git a/moped-database/migrations/1623356400058_run_sql_migration/up.sql b/moped-database/migrations/1623356400058_run_sql_migration/up.sql new file mode 100644 index 0000000000..2face19dba --- /dev/null +++ b/moped-database/migrations/1623356400058_run_sql_migration/up.sql @@ -0,0 +1,33 @@ +CREATE OR REPLACE VIEW "public"."project_list_view" AS + SELECT mp.project_uuid, + mp.project_id, + mp.project_name, + mp.project_description, + mp.project_description_public, + mp.ecapris_subproject_id, + mp.project_importance, + mp.project_order, + mp.current_status, + mp.timeline_id, + mp.current_phase, + mp.end_date, + mp.project_length, + mp.start_date, + mp.fiscal_year, + mp.capitally_funded, + mp.project_priority, + mp.date_added, + mp.added_by, + mp.is_retired, + mp.milestone_id, + mp.status_id, + string_agg(concat(mu.first_name, ' ', mu.last_name, ':', mpr.project_role_name), ','::text) AS project_team_members, + mp.updated_at, + mpph.phase_name + FROM (((moped_project mp + LEFT JOIN moped_proj_personnel mpp ON (((mp.project_id = mpp.project_id) AND (mpp.status_id = 1)))) + LEFT JOIN moped_users mu ON ((mpp.user_id = mu.user_id))) + LEFT JOIN moped_project_roles mpr ON ((mpp.role_id = mpr.project_role_id))) + LEFT JOIN moped_proj_phases mpph ON ((mp.project_id = mpph.project_id)) + WHERE ((mpph.is_current_phase = TRUE)) + GROUP BY mp.project_uuid, mp.project_id, mp.project_name, mp.project_description, mp.project_description_public, mp.ecapris_subproject_id, mp.project_importance, mp.project_order, mp.current_status, mp.timeline_id, mp.current_phase, mp.end_date, mp.project_length, mp.start_date, mp.fiscal_year, mp.capitally_funded, mp.project_priority, mp.date_added, mp.added_by, mp.is_retired, mp.milestone_id, mp.status_id, mp.updated_at, mpph.phase_name; diff --git a/moped-editor/src/views/projects/projectsListView/ProjectsListViewQueryConf.js b/moped-editor/src/views/projects/projectsListView/ProjectsListViewQueryConf.js index 5e94c98f9f..f8dcd32cd2 100644 --- a/moped-editor/src/views/projects/projectsListView/ProjectsListViewQueryConf.js +++ b/moped-editor/src/views/projects/projectsListView/ProjectsListViewQueryConf.js @@ -103,7 +103,7 @@ export const ProjectsListViewQueryConf = { canceled: "default", }, }, - current_phase: { + phase_name: { searchable: true, sortable: false, label: "Current phase", From 3f7ac35b1b1493a80eab1c6ee457f1ba43f1853f Mon Sep 17 00:00:00 2001 From: tillyw Date: Thu, 10 Jun 2021 16:14:54 -0500 Subject: [PATCH 5/7] Fixes bug where projects with no current phase do not appear in list view --- .../1623358779761_run_sql_migration/up.sql | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 moped-database/migrations/1623358779761_run_sql_migration/up.sql diff --git a/moped-database/migrations/1623358779761_run_sql_migration/up.sql b/moped-database/migrations/1623358779761_run_sql_migration/up.sql new file mode 100644 index 0000000000..4bd36422af --- /dev/null +++ b/moped-database/migrations/1623358779761_run_sql_migration/up.sql @@ -0,0 +1,32 @@ +CREATE OR REPLACE VIEW "public"."project_list_view" AS + SELECT mp.project_uuid, + mp.project_id, + mp.project_name, + mp.project_description, + mp.project_description_public, + mp.ecapris_subproject_id, + mp.project_importance, + mp.project_order, + mp.current_status, + mp.timeline_id, + mp.current_phase, + mp.end_date, + mp.project_length, + mp.start_date, + mp.fiscal_year, + mp.capitally_funded, + mp.project_priority, + mp.date_added, + mp.added_by, + mp.is_retired, + mp.milestone_id, + mp.status_id, + string_agg(concat(mu.first_name, ' ', mu.last_name, ':', mpr.project_role_name), ','::text) AS project_team_members, + mp.updated_at, + mpph.phase_name + FROM ((((moped_project mp + LEFT JOIN moped_proj_personnel mpp ON (((mp.project_id = mpp.project_id) AND (mpp.status_id = 1)))) + LEFT JOIN moped_users mu ON ((mpp.user_id = mu.user_id))) + LEFT JOIN moped_project_roles mpr ON ((mpp.role_id = mpr.project_role_id))) + LEFT JOIN moped_proj_phases mpph ON ((mp.project_id = mpph.project_id)) AND mpph.is_current_phase = true) + GROUP BY mp.project_uuid, mp.project_id, mp.project_name, mp.project_description, mp.project_description_public, mp.ecapris_subproject_id, mp.project_importance, mp.project_order, mp.current_status, mp.timeline_id, mp.current_phase, mp.end_date, mp.project_length, mp.start_date, mp.fiscal_year, mp.capitally_funded, mp.project_priority, mp.date_added, mp.added_by, mp.is_retired, mp.milestone_id, mp.status_id, mp.updated_at, mpph.phase_name; From 0828621cb6afebe4968b7b63b8823fd00a642f2b Mon Sep 17 00:00:00 2001 From: tillyw Date: Thu, 10 Jun 2021 16:17:00 -0500 Subject: [PATCH 6/7] Removed unnecessary SQL migration --- .../1623356400058_run_sql_migration/up.sql | 33 ------------------- 1 file changed, 33 deletions(-) delete mode 100644 moped-database/migrations/1623356400058_run_sql_migration/up.sql diff --git a/moped-database/migrations/1623356400058_run_sql_migration/up.sql b/moped-database/migrations/1623356400058_run_sql_migration/up.sql deleted file mode 100644 index 2face19dba..0000000000 --- a/moped-database/migrations/1623356400058_run_sql_migration/up.sql +++ /dev/null @@ -1,33 +0,0 @@ -CREATE OR REPLACE VIEW "public"."project_list_view" AS - SELECT mp.project_uuid, - mp.project_id, - mp.project_name, - mp.project_description, - mp.project_description_public, - mp.ecapris_subproject_id, - mp.project_importance, - mp.project_order, - mp.current_status, - mp.timeline_id, - mp.current_phase, - mp.end_date, - mp.project_length, - mp.start_date, - mp.fiscal_year, - mp.capitally_funded, - mp.project_priority, - mp.date_added, - mp.added_by, - mp.is_retired, - mp.milestone_id, - mp.status_id, - string_agg(concat(mu.first_name, ' ', mu.last_name, ':', mpr.project_role_name), ','::text) AS project_team_members, - mp.updated_at, - mpph.phase_name - FROM (((moped_project mp - LEFT JOIN moped_proj_personnel mpp ON (((mp.project_id = mpp.project_id) AND (mpp.status_id = 1)))) - LEFT JOIN moped_users mu ON ((mpp.user_id = mu.user_id))) - LEFT JOIN moped_project_roles mpr ON ((mpp.role_id = mpr.project_role_id))) - LEFT JOIN moped_proj_phases mpph ON ((mp.project_id = mpph.project_id)) - WHERE ((mpph.is_current_phase = TRUE)) - GROUP BY mp.project_uuid, mp.project_id, mp.project_name, mp.project_description, mp.project_description_public, mp.ecapris_subproject_id, mp.project_importance, mp.project_order, mp.current_status, mp.timeline_id, mp.current_phase, mp.end_date, mp.project_length, mp.start_date, mp.fiscal_year, mp.capitally_funded, mp.project_priority, mp.date_added, mp.added_by, mp.is_retired, mp.milestone_id, mp.status_id, mp.updated_at, mpph.phase_name; From 040f14ce317fc560e1284e0cee0705def9fb70fe Mon Sep 17 00:00:00 2001 From: Chia Berry Date: Fri, 11 Jun 2021 11:27:37 -0500 Subject: [PATCH 7/7] update phase name in fitler for project list view --- .../projects/projectsListView/ProjectsListViewFiltersConf.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/moped-editor/src/views/projects/projectsListView/ProjectsListViewFiltersConf.js b/moped-editor/src/views/projects/projectsListView/ProjectsListViewFiltersConf.js index 86d403a15e..6f7c878251 100644 --- a/moped-editor/src/views/projects/projectsListView/ProjectsListViewFiltersConf.js +++ b/moped-editor/src/views/projects/projectsListView/ProjectsListViewFiltersConf.js @@ -56,7 +56,7 @@ export const ProjectsListViewFiltersConf = { ], }, { - name: "current_phase", + name: "phase_name", label: "Currrent Phase", placeholder: "Current phase", type: "string",