Skip to content

Commit d1a1407

Browse files
author
synapticloop
committed
Fixed generation of before and after URIs in the JSON response where there is a range selected with an 'Or' facet
1 parent 82c0d8f commit d1a1407

File tree

3 files changed

+18
-4
lines changed

3 files changed

+18
-4
lines changed

README.md

+11-2
Original file line numberDiff line numberDiff line change
@@ -388,10 +388,19 @@ with the release files named `solr-panl-9-x.x.x`
388388

389389
## 1.2.0 - more like this (codename `needy-phanton`) **UNDER DEVELOPMENT**
390390

391-
## 1.1.1 - the better update (codename `grizzled-pebble`)
391+
## 1.1.1 - the fly spray (codename `grizzled-pebble`)
392392

393393
- Bug fixes
394-
- Fixed 'OR' facet `before` and `after` URL values
394+
- Fixed 'OR' facet `before` and `after` URL values in the JSON response where a range facet has already been selected
395+
- Code cleanup
396+
- Updated explanation for DATE Range and RANGE facets
397+
398+
[View the code for this release](https://github.com/synapticloop/panl/tree/1.1.1)
399+
400+
[Download the release packages](https://github.com/synapticloop/panl/releases/tag/1.1.1)
401+
402+
[See all releases](https://github.com/synapticloop/panl/releases/)
403+
395404

396405
## 1.1.0 - the better update (codename `broad-firefly`)
397406

src/main/java/com/synapticloop/panl/server/handler/fielderiser/field/facet/PanlOrFacetField.java

+7-1
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,13 @@ protected JSONObject getAdditionURIObject(
249249
lpseUri.append(baseField.getURIPath(panlTokenMap, collectionProperties));
250250
int numTokens = panlTokenMap.get(orderedLpseCode).size();
251251
if(numTokens == 1) {
252-
lpseUriCode.append(baseField.getLpseCode());
252+
// if we have a range facet - we need to make sure that we are
253+
// encoding it correctly there can only be one range token for the
254+
// panl field (no over-lapping ranges, or distinct ranges)
255+
256+
// if it is not a range facet - then this won't do any harm and is a
257+
// better implementation
258+
lpseUriCode.append(baseField.getLpseCode(panlTokenMap.get(orderedLpseCode).get(0), collectionProperties));
253259
} else {
254260
lpseUriCode.append(new String(new char[numTokens]).replace("\0", baseField.getLpseCode()));
255261
}

src/main/java/com/synapticloop/panl/server/handler/tokeniser/token/facet/DateRangeFacetLpseToken.java

-1
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,6 @@ public DateRangeFacetLpseToken(
8787
} else {
8888
this.isValid = false;
8989
}
90-
9190
}
9291

9392
@Override public String explain() {

0 commit comments

Comments
 (0)