Skip to content

Commit

Permalink
feat: option to hide ticket zone data from assembly
Browse files Browse the repository at this point in the history
  • Loading branch information
vesameskanen committed Feb 12, 2024
1 parent 42b1516 commit 2a51e53
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions app/configurations/config.hameenlinna.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ export default configMerger(walttiConfig, {
feedIds: ['Hameenlinna'],

geoJson: {
noZoneSharing: true,
layers: [
{
name: {
Expand Down
8 changes: 5 additions & 3 deletions server/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -304,9 +304,11 @@ function setUpAvailableTickets() {
}

function getZoneUrl(json) {
const zoneLayer = json.layers.find(
layer => layer.name.fi === 'Vyöhykkeet' || layer.name.en === 'Zones',
);
const zoneLayer =
!json.noZoneSharing &&
json.layers.find(
layer => layer.name.fi === 'Vyöhykkeet' || layer.name.en === 'Zones',
);
if (zoneLayer && !allZones) {
// use a geoJson source to initialize combined zone data
allZones = zoneLayer;
Expand Down

0 comments on commit 2a51e53

Please sign in to comment.