From 99a91988e4ea4179e668f1afc2766743c6ede231 Mon Sep 17 00:00:00 2001 From: yecksin Date: Fri, 19 May 2023 16:12:52 -0500 Subject: [PATCH 1/4] :bug: fix(PDF result detail) LFUB-539: link improved --- .../components/pdf-actions/pdf-actions.component.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/onecgiar-pr-client/src/app/pages/results/pages/result-detail/components/pdf-actions/pdf-actions.component.ts b/onecgiar-pr-client/src/app/pages/results/pages/result-detail/components/pdf-actions/pdf-actions.component.ts index 000a9fe14..4c314e2d6 100644 --- a/onecgiar-pr-client/src/app/pages/results/pages/result-detail/components/pdf-actions/pdf-actions.component.ts +++ b/onecgiar-pr-client/src/app/pages/results/pages/result-detail/components/pdf-actions/pdf-actions.component.ts @@ -18,6 +18,6 @@ export class PdfActionsComponent { } get link() { - return `${environment.frontBaseUrl}/reports/result-details/${this.api.currentResultCode}?phase=1`; + return `${environment.frontBaseUrl}reports/result-details/${this.api.currentResultCode}?phase=1`; } } From 24c2fa59246b108c85e0891e08bd5cf257a9ef31 Mon Sep 17 00:00:00 2001 From: yecksin Date: Fri, 19 May 2023 16:13:17 -0500 Subject: [PATCH 2/4] :bug: fix(PDF result detail) LFUB-539: submit_button improved to use grid --- .../panel-menu/panel-menu.component.html | 20 ++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/onecgiar-pr-client/src/app/pages/results/pages/result-detail/panel-menu/panel-menu.component.html b/onecgiar-pr-client/src/app/pages/results/pages/result-detail/panel-menu/panel-menu.component.html index 093f68916..90f140c0c 100644 --- a/onecgiar-pr-client/src/app/pages/results/pages/result-detail/panel-menu/panel-menu.component.html +++ b/onecgiar-pr-client/src/app/pages/results/pages/result-detail/panel-menu/panel-menu.component.html @@ -29,15 +29,17 @@ -
- - -
- This button will be available once all sections are available. +
+
+ + +
+ This button will be available once all sections are available. +
From d0ede9842e24508d79bf7c6cb7ce0edd21d8c87d Mon Sep 17 00:00:00 2001 From: German Martinez Date: Wed, 24 May 2023 08:42:16 -0500 Subject: [PATCH 3/4] =?UTF-8?q?=F0=9F=90=9B=20fix(Excel=20Report):=20fixin?= =?UTF-8?q?g=20delivery=20types=20grouping=20on=20result=20report.=20LFUB-?= =?UTF-8?q?595?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/api/results/result.repository.ts | 26 ++++++++++--------- 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/onecgiar-pr-server/src/api/results/result.repository.ts b/onecgiar-pr-server/src/api/results/result.repository.ts index 9fb73d7b6..d54591a31 100644 --- a/onecgiar-pr-server/src/api/results/result.repository.ts +++ b/onecgiar-pr-server/src/api/results/result.repository.ts @@ -919,8 +919,8 @@ left join results_by_inititiative rbi3 on rbi3.result_id = r.id GROUP_CONCAT(distinct CONCAT('(',ci6.official_code,' - ',ci6.short_name,'): ', 'Toc Level: ' ,IFNULL(tl2.name , 'Not provider'), ', ToC result title:' ,IFNULL(tr2.title, 'Not provider')) SEPARATOR ', ') as "ToC Mapping (Contributting initiatives)", -- section 3 if(r.no_applicable_partner=1, "No", "Yes") as "Are partners applicable?", - /* GROUP_CONCAT(DISTINCT concat('(',prt.name, ', Delivery type(s): ', prt.deliveries_type,')') SEPARATOR ', ') as "Partners (with delivery type)",*/ - if(rt.id <> 6,(select GROUP_CONCAT(DISTINCT concat('• ',concat(if(coalesce(ci7.acronym, '') = '', '', concat(ci7.acronym, ' - ')), ci7.name), '; Delivery type(s): ', pdt.name) SEPARATOR '\n') + if(rt.id <> 6,(select GROUP_CONCAT(DISTINCT concat('• ', q1.partner) SEPARATOR '\n') + from (select concat(concat(if(coalesce(ci7.acronym, '') = '', '', concat(ci7.acronym, ' - ')), ci7.name), '; Delivery type(s): ', group_concat(distinct pdt.name separator ', ')) as partner FROM results_by_institution rbi left join result_by_institutions_by_deliveries_type rbibdt on rbibdt.result_by_institution_id = rbi.id @@ -932,16 +932,17 @@ left join results_by_inititiative rbi3 on rbi3.result_id = r.id WHERE rbi.result_id = r.id and rbi.institution_roles_id = 2 and rbi.is_active > 0 - GROUP by rbi.result_id), 'Not Applicable') as "Partners (with delivery type) for non-KP results", - if(rt.id = 6, (SELECT group_concat(distinct concat('• CGSpace Institution: ', rkmi.intitution_name, '; Mapped institution: ', if(rbi.id is null, 'None', concat(concat(if(coalesce(ci8.acronym, '') = '', '', concat(ci8.acronym, ' - ')), ci8.name), '; Delivery type(s): ', pdt.name))) separator '\n') + GROUP by rbi.result_id, ci7.id) as q1), 'Not Applicable') as "Partners (with delivery type) for non-KP results", + if(rt.id = 6, (SELECT group_concat(distinct concat('• ', q1.partner) separator '\n') + from ( select concat('CGSpace Institution: ', rkmi.intitution_name, '; Mapped institution: ', if(rbi.id is null, 'None', concat(concat(if(coalesce(ci8.acronym, '') = '', '', concat(ci8.acronym, ' - ')), ci8.name), '; Delivery type(s): ', group_concat(distinct pdt.name separator ', ')))) as partner FROM results_kp_mqap_institutions rkmi left join results_knowledge_product rkp on rkmi.result_knowledge_product_id = rkp.result_knowledge_product_id and rkp.is_active > 0 left join results_by_institution rbi on rkmi.results_by_institutions_id = rbi.id and rbi.is_active > 0 and rbi.institution_roles_id = 2 left join result_by_institutions_by_deliveries_type rbibdt on rbibdt.result_by_institution_id = rbi.id and rbibdt.is_active > 0 left join clarisa_institutions ci8 on ci8.id = rbi.institutions_id left JOIN partner_delivery_type pdt on pdt.id = rbibdt.partner_delivery_type_id - WHERE rkmi.is_active > 0 and rkp.results_id = r.id - GROUP by rkp.results_id), 'Not Applicable') as "Partners (with delivery type) for KP results", + WHERE rkmi.is_active > 0 and rkp.results_id = 7 + GROUP by rkp.results_id, rbi.institutions_id, rkmi.intitution_name, rkmi.results_by_institutions_id) as q1), 'Not Applicable') as "Partners (with delivery type) for KP results", -- section 4 (SELECT if(cgs.name is null, 'Not Provided', (if(cgs.id = 3, 'National', cgs.name))) FROM clarisa_geographic_scope cgs @@ -1101,8 +1102,8 @@ left join clarisa_countries cc3 GROUP_CONCAT(distinct CONCAT('(',ci6.official_code,' - ',ci6.short_name,'): ', 'Toc Level: ' ,IFNULL(tl2.name , 'Not provider'), ', ToC result title:' ,IFNULL(tr2.title, 'Not provider')) SEPARATOR ', ') as "ToC Mapping (Contributting initiatives)", -- section 3 if(r.no_applicable_partner=1, "No", "Yes") as "Are partners applicable?", - /* GROUP_CONCAT(DISTINCT concat('(',prt.name, ', Delivery type(s): ', prt.deliveries_type,')') SEPARATOR ', ') as "Partners (with delivery type)",*/ - if(rt.id <> 6,(select GROUP_CONCAT(DISTINCT concat('• ',concat(if(coalesce(ci7.acronym, '') = '', '', concat(ci7.acronym, ' - ')), ci7.name), '; Delivery type(s): ', pdt.name) SEPARATOR '\n') + if(rt.id <> 6,(select GROUP_CONCAT(DISTINCT concat('• ', q1.partner) SEPARATOR '\n') + from (select concat(concat(if(coalesce(ci7.acronym, '') = '', '', concat(ci7.acronym, ' - ')), ci7.name), '; Delivery type(s): ', group_concat(distinct pdt.name separator ', ')) as partner FROM results_by_institution rbi left join result_by_institutions_by_deliveries_type rbibdt on rbibdt.result_by_institution_id = rbi.id @@ -1114,16 +1115,17 @@ left join clarisa_countries cc3 WHERE rbi.result_id = r.id and rbi.institution_roles_id = 2 and rbi.is_active > 0 - GROUP by rbi.result_id), 'Not Applicable') as "Partners (with delivery type) for non-KP results", - if(rt.id = 6, (SELECT group_concat(distinct concat('• CGSpace Institution: ', rkmi.intitution_name, '; Mapped institution: ', if(rbi.id is null, 'None', concat(concat(if(coalesce(ci8.acronym, '') = '', '', concat(ci8.acronym, ' - ')), ci8.name), '; Delivery type(s): ', pdt.name))) separator '\n') + GROUP by rbi.result_id, ci7.id) as q1), 'Not Applicable') as "Partners (with delivery type) for non-KP results", + if(rt.id = 6, (SELECT group_concat(distinct concat('• ', q1.partner) separator '\n') + from ( select concat('CGSpace Institution: ', rkmi.intitution_name, '; Mapped institution: ', if(rbi.id is null, 'None', concat(concat(if(coalesce(ci8.acronym, '') = '', '', concat(ci8.acronym, ' - ')), ci8.name), '; Delivery type(s): ', group_concat(distinct pdt.name separator ', ')))) as partner FROM results_kp_mqap_institutions rkmi left join results_knowledge_product rkp on rkmi.result_knowledge_product_id = rkp.result_knowledge_product_id and rkp.is_active > 0 left join results_by_institution rbi on rkmi.results_by_institutions_id = rbi.id and rbi.is_active > 0 and rbi.institution_roles_id = 2 left join result_by_institutions_by_deliveries_type rbibdt on rbibdt.result_by_institution_id = rbi.id and rbibdt.is_active > 0 left join clarisa_institutions ci8 on ci8.id = rbi.institutions_id left JOIN partner_delivery_type pdt on pdt.id = rbibdt.partner_delivery_type_id - WHERE rkmi.is_active > 0 and rkp.results_id = r.id - GROUP by rkp.results_id), 'Not Applicable') as "Partners (with delivery type) for KP results", + WHERE rkmi.is_active > 0 and rkp.results_id = 7 + GROUP by rkp.results_id, rbi.institutions_id, rkmi.intitution_name, rkmi.results_by_institutions_id) as q1), 'Not Applicable') as "Partners (with delivery type) for KP results", -- section 4 (SELECT if(cgs.name is null, 'Not Provided', (if(cgs.id = 3, 'National', cgs.name))) FROM clarisa_geographic_scope cgs From 050b8e9dacd90f7b27409d71b5143c2f172c330f Mon Sep 17 00:00:00 2001 From: German Martinez Date: Wed, 24 May 2023 09:04:35 -0500 Subject: [PATCH 4/4] =?UTF-8?q?=F0=9F=90=9B=20fix(Excel=20Report):=20fixin?= =?UTF-8?q?g=20wrong=20condition=20on=20subselect.=20LFUB-595?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- onecgiar-pr-server/src/api/results/result.repository.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/onecgiar-pr-server/src/api/results/result.repository.ts b/onecgiar-pr-server/src/api/results/result.repository.ts index d54591a31..e8c1d3544 100644 --- a/onecgiar-pr-server/src/api/results/result.repository.ts +++ b/onecgiar-pr-server/src/api/results/result.repository.ts @@ -941,7 +941,7 @@ left join results_by_inititiative rbi3 on rbi3.result_id = r.id left join result_by_institutions_by_deliveries_type rbibdt on rbibdt.result_by_institution_id = rbi.id and rbibdt.is_active > 0 left join clarisa_institutions ci8 on ci8.id = rbi.institutions_id left JOIN partner_delivery_type pdt on pdt.id = rbibdt.partner_delivery_type_id - WHERE rkmi.is_active > 0 and rkp.results_id = 7 + WHERE rkmi.is_active > 0 and rkp.results_id = r.id GROUP by rkp.results_id, rbi.institutions_id, rkmi.intitution_name, rkmi.results_by_institutions_id) as q1), 'Not Applicable') as "Partners (with delivery type) for KP results", -- section 4 (SELECT if(cgs.name is null, 'Not Provided', (if(cgs.id = 3, 'National', cgs.name))) @@ -1124,7 +1124,7 @@ left join clarisa_countries cc3 left join result_by_institutions_by_deliveries_type rbibdt on rbibdt.result_by_institution_id = rbi.id and rbibdt.is_active > 0 left join clarisa_institutions ci8 on ci8.id = rbi.institutions_id left JOIN partner_delivery_type pdt on pdt.id = rbibdt.partner_delivery_type_id - WHERE rkmi.is_active > 0 and rkp.results_id = 7 + WHERE rkmi.is_active > 0 and rkp.results_id = r.id GROUP by rkp.results_id, rbi.institutions_id, rkmi.intitution_name, rkmi.results_by_institutions_id) as q1), 'Not Applicable') as "Partners (with delivery type) for KP results", -- section 4 (SELECT if(cgs.name is null, 'Not Provided', (if(cgs.id = 3, 'National', cgs.name)))