Skip to content

Commit

Permalink
AMP-30337 filter out projects with undefined sectors from Dashboard p…
Browse files Browse the repository at this point in the history
…roject list
  • Loading branch information
jdeanquin-dg committed Aug 2, 2022
1 parent 59ac014 commit 47f82bd
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion amp/TEMPLATE/ampTemplate/site-config.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<!DOCTYPE page [
<!ENTITY ampVersion "${project.version}">
<!ENTITY releaseDate "30.07.2021">
<!ENTITY releaseDate "02.08.2022">
<!ENTITY buildDate "${buildDate}">
<!ENTITY buildSource "${buildSource}">
]>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@
import org.digijava.module.categorymanager.util.CategoryConstants;
import org.digijava.module.categorymanager.util.CategoryManagerUtil;

import static org.dgfoundation.amp.nireports.runtime.ColumnReportData.UNALLOCATED_ID;

/**
*
* @author Diego Dimunzio
Expand Down Expand Up @@ -84,7 +86,7 @@ public static int getOffset(DashboardFormParameters config) {
public static LinkedHashMap<String, Object> setFilterId(Long id, String column) {
LinkedHashMap<String, Object> filterObject = new LinkedHashMap<String, Object>();
List<Long> filterIds = new ArrayList<Long>();
if (id >0) {
if (id > 0 || id.equals(UNALLOCATED_ID)) {
filterIds.add(id);
filterObject.put(column, filterIds);
}
Expand Down Expand Up @@ -122,7 +124,7 @@ protected static void postProcessRE(GeneratedReport report, ReportSpecificationI
for (ReportArea ra : report.reportContents.getChildren()) {
// detect those undefined for countries, but skip those that are really undefined for regions
if (ra.getOwner() != null && ra.getOwner().id < 0
&& (ra.getOwner().id != ColumnReportData.UNALLOCATED_ID)) {
&& (ra.getOwner().id != UNALLOCATED_ID)) {
undefinedAreas.add(ra);
}
}
Expand Down
2 changes: 1 addition & 1 deletion amp/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.devgateway</groupId>
<artifactId>amp</artifactId>
<version>3.4.3.1</version>
<version>3.4.3.2</version>
<packaging>war</packaging>
<name>Aid Management Platform</name>
<properties>
Expand Down

0 comments on commit 47f82bd

Please sign in to comment.