Merge Angular 16 Irish Monitor to develop #33
|
@ -781,12 +781,13 @@ export class IndicatorUtils {
|
|||
for (let filter of query["query"]["filters"]) {
|
||||
for (let gfilter of filter["groupFilters"]) {
|
||||
//ignore field No Of Funders
|
||||
if (gfilter["field"].indexOf(" funder") != -1 && gfilter["field"].indexOf(" funders") == -1) {//new statistcs schema
|
||||
gfilter["values"][0] = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters)
|
||||
} else if (gfilter["field"].indexOf(".funder") != -1) {
|
||||
gfilter["values"][0] = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters)
|
||||
} else if (gfilter["field"].indexOf(".funder.id") != -1) {
|
||||
gfilter["values"][0] = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters)
|
||||
let replacedValue = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters);
|
||||
if(replacedValue) { // don't proceed in replacement if no replaced value matches
|
||||
if ((gfilter["field"].indexOf(" funder") != -1 && gfilter["field"].indexOf(" funders") == -1 ) ||
|
||||
(gfilter["field"].indexOf(".funder") != -1) ||
|
||||
(gfilter["field"].indexOf(".funder.id") != -1)) {
|
||||
gfilter["values"][0] = replacedValue;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -806,10 +807,12 @@ export class IndicatorUtils {
|
|||
}
|
||||
for (let filter of query["query"]["filters"]) {
|
||||
for (let gfilter of filter["groupFilters"]) {
|
||||
if (gfilter["field"].indexOf(".context.name") != -1) {
|
||||
gfilter["values"][0] = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters);
|
||||
} else if (gfilter["field"].indexOf(".context.id") != -1) {
|
||||
gfilter["values"][0] = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters);
|
||||
let replacedValue = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters);
|
||||
if(replacedValue) { // don't proceed in replacement if no replaced value matches
|
||||
if ((gfilter["field"].indexOf(".context.name") != -1)
|
||||
|| (gfilter["field"].indexOf(".context.id") != -1)) {
|
||||
gfilter["values"][0] = replacedValue;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -831,10 +834,12 @@ export class IndicatorUtils {
|
|||
}
|
||||
for (let filter of query["query"]["filters"]) {
|
||||
for (let gfilter of filter["groupFilters"]) {
|
||||
if (gfilter["field"].indexOf(".organization.name") != -1) {
|
||||
gfilter["values"][0] = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters)
|
||||
} else if (gfilter["field"].indexOf(".organization.id") != -1) {
|
||||
gfilter["values"][0] = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters)
|
||||
let replacedValue = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters);
|
||||
if(replacedValue) { // don't proceed in replacement if no replaced value matches
|
||||
if ((gfilter["field"].indexOf(".organization.name") != -1)||
|
||||
(gfilter["field"].indexOf(".organization.id") != -1)) {
|
||||
gfilter["values"][0] = replacedValue;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -855,10 +860,12 @@ export class IndicatorUtils {
|
|||
}
|
||||
for (let filter of query["query"]["filters"]) {
|
||||
for (let gfilter of filter["groupFilters"]) {
|
||||
if (gfilter["field"].indexOf(".datasource.name") != -1 || gfilter["field"].indexOf(".HostedBy datasource") != -1) {
|
||||
gfilter["values"][0] = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters)
|
||||
} else if (gfilter["field"].indexOf(".datasource.id") != -1) {
|
||||
gfilter["values"][0] = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters)
|
||||
let replacedValue = this.replaceIndexValues(gfilter["values"][0], stakeholder, indicatorPath.parameters);
|
||||
if(replacedValue) { // don't proceed in replacement if no replaced value matches
|
||||
if ((gfilter["field"].indexOf(".datasource.name") != -1 || gfilter["field"].indexOf(".HostedBy datasource") != -1)||
|
||||
(gfilter["field"].indexOf(".datasource.id") != -1)) {
|
||||
gfilter["values"][0] = replacedValue;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue