metacatui
metacatui copied to clipboard
dateFilter serialized with wrong date
The month and date of the rangeMin and rangeMax are changed when the portal was parsed into the PortalModel. This is because the PortalModel generalizes the rangeMin and rangeMax to the year, since the date range slider in the UI is really a numeric slider, changing the year number only.
This is going to be a rarely-used feature of the portals (filter groups with date ranges specified to the month or date), so fixing this can wait.
Portal XML that was inserted via curl:
<dateFilter>
<label>freewheel wrath decathlon</label>
<field>datePublished</field>
<rangeMax>2039-08-12T00:00:00Z</rangeMax>
<filterOptions>
<placeholder>Vancouver upland redcoat fluorocarbon festival deflate kumquat tumultuous altogether consign</placeholder>
<icon>zoomin</icon>
<description>Camino vanguard slushy barbiturate rabies bum maharaja clove Euripides incorrigible inceptor term substrate modish</description>
</filterOptions>
</dateFilter>
After saving in the editor:
<dateFilter>
<label>freewheel wrath decathlon</label>
<field>datePublished</field>
<operator>AND</operator>
<exclude>false</exclude>
<rangeMax>2039-12-31T23:59:59Z</rangeMax>
<filterOptions>
<placeholder>Vancouver upland redcoat fluorocarbon festival deflate kumquat tumultuous altogether consign</placeholder>
<icon>zoomin</icon>
<description>Camino vanguard slushy barbiturate rabies bum maharaja clove Euripides incorrigible inceptor term substrate modish</description>
</filterOptions>
</dateFilter>