| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 6b1f8c3 commit ec985fd
5 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -315,7 +315,7 @@ export function createWebMapV3Extending(SuperClass, { MapManager, mapRepo, crsMa | |||
| 315 | 315 | } | |
| 316 | 316 | return (url, resourceType) => { | |
| 317 | 317 | if (resourceType === 'Tile') { | |
| 318 | - const withCredentials = this.options.iportalServiceProxyUrl && url.indexOf(this.options.iportalServiceProxyUrl) >= 0; | ||
| 318 | + const withCredentials = this.options.iportalServiceProxyUrlPrefix && url.indexOf(this.options.iportalServiceProxyUrlPrefix) >= 0; | ||
| 319 | 319 | return { | |
| 320 | 320 | url: url, | |
| 321 | 321 | credentials: withCredentials ? 'include' : undefined, | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -426,7 +426,7 @@ export function L7LayerUtil(config) { | |||
| 426 | 426 | } | |
| 427 | 427 | ||
| 428 | 428 | function isIportalProxyServiceUrl(url, options) { | |
| 429 | - return options.iportalServiceProxyUrl && url.indexOf(options.iportalServiceProxyUrl) >= 0; | ||
| 429 | + return options.iportalServiceProxyUrlPrefix && url.indexOf(options.iportalServiceProxyUrlPrefix) >= 0; | ||
| 430 | 430 | } | |
| 431 | 431 | ||
| 432 | 432 | function handleWithRequestOptions(url, options) { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -517,7 +517,7 @@ describe('L7LayerUtil', () => { | |||
| 517 | 517 | ...addOptions.options, | |
| 518 | 518 | withCredentials: false, | |
| 519 | 519 | server: '/iportal/', | |
| 520 | - iportalServiceProxyUrl: 'http://localhost:8195/portalproxy' | ||
| 520 | + iportalServiceProxyUrlPrefix: 'http://localhost:8195/portalproxy' | ||
| 521 | 521 | } | |
| 522 | 522 | }; | |
| 523 | 523 | const spy = spyOn(nextOptions.map, 'addLayer').and.callThrough(); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -105,7 +105,7 @@ describe('mapboxgl-webmap3.0', () => { | |||
| 105 | 105 | }); | |
| 106 | 106 | mapstudioWebmap = new WebMap(id, { | |
| 107 | 107 | server: server, | |
| 108 | - iportalServiceProxyUrl: 'initialize_raster' | ||
| 108 | + iportalServiceProxyUrlPrefix: 'initialize_raster' | ||
| 109 | 109 | }); | |
| 110 | 110 | expect(mapstudioWebmap.credentialKey).toBeUndefined(); | |
| 111 | 111 | expect(mapstudioWebmap.credentialValue).toBeUndefined(); | |
@@ -172,7 +172,7 @@ describe('mapboxgl-webmap3.0', () => { | |||
| 172 | 172 | mapstudioWebmap = new WebMapV3(mapInfo, { | |
| 173 | 173 | server: server, | |
| 174 | 174 | target: 'map', | |
| 175 | - iportalServiceProxyUrl: 'mapId is JSON' | ||
| 175 | + iportalServiceProxyUrlPrefix: 'mapId is JSON' | ||
| 176 | 176 | }); | |
| 177 | 177 | mapstudioWebmap.initializeMap(mapInfo); | |
| 178 | 178 | ||
@@ -256,7 +256,7 @@ describe('mapboxgl-webmap3.0', () => { | |||
| 256 | 256 | mapstudioWebmap = new WebMap(nextMapInfo, { | |
| 257 | 257 | server: server, | |
| 258 | 258 | target: 'map', | |
| 259 | - iportalServiceProxyUrl: 'projection is 4490 and include mapbox-gl-enhance' | ||
| 259 | + iportalServiceProxyUrlPrefix: 'projection is 4490 and include mapbox-gl-enhance' | ||
| 260 | 260 | }); | |
| 261 | 261 | ||
| 262 | 262 | mapstudioWebmap.on('mapcreatesucceeded', ({ map }) => { | |
@@ -342,7 +342,7 @@ describe('mapboxgl-webmap3.0', () => { | |||
| 342 | 342 | mapstudioWebmap = new WebMapV3(mapInfo, { | |
| 343 | 343 | server: server, | |
| 344 | 344 | target: 'map', | |
| 345 | - iportalServiceProxyUrl: 'overlayLayersManager' | ||
| 345 | + iportalServiceProxyUrlPrefix: 'overlayLayersManager' | ||
| 346 | 346 | }); | |
| 347 | 347 | mapstudioWebmap.initializeMap(mapInfo); | |
| 348 | 348 | ||
@@ -500,7 +500,7 @@ describe('mapboxgl-webmap3.0', () => { | |||
| 500 | 500 | mapstudioWebmap = new WebMapV3(mapInfo, { | |
| 501 | 501 | server: server, | |
| 502 | 502 | target: 'map', | |
| 503 | - iportalServiceProxyUrl: 'exclude source and layer' | ||
| 503 | + iportalServiceProxyUrlPrefix: 'exclude source and layer' | ||
| 504 | 504 | }); | |
| 505 | 505 | mapstudioWebmap.initializeMap(mapInfo); | |
| 506 | 506 | ||
@@ -733,14 +733,14 @@ describe('mapboxgl-webmap3.0', () => { | |||
| 733 | 733 | }); | |
| 734 | 734 | const spyTest = spyOn(MapManagerUtil, 'default').and.callFake(mbglmap); | |
| 735 | 735 | const mapInfo = JSON.parse(mapstudioWebMap_raster); | |
| 736 | - const iportalServiceProxyUrl = 'http://localhost:8195/portalproxy'; | ||
| 736 | + const iportalServiceProxyUrlPrefix = 'http://localhost:8195/portalproxy'; | ||
| 737 | 737 | const tileCustomRequestHeaders = { 'Authorization': 'test token' }; | |
| 738 | 738 | mapstudioWebmap = new WebMap(mapInfo, { | |
| 739 | 739 | server: server, | |
| 740 | 740 | target: 'map', | |
| 741 | - iportalServiceProxyUrl, | ||
| 741 | + iportalServiceProxyUrlPrefix, | ||
| 742 | 742 | tileTransformRequest: (url) => { | |
| 743 | - if (url.includes(iportalServiceProxyUrl)) { | ||
| 743 | + if (url.includes(iportalServiceProxyUrlPrefix)) { | ||
| 744 | 744 | return { headers: tileCustomRequestHeaders }; | |
| 745 | 745 | } | |
| 746 | 746 | } | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -105,7 +105,7 @@ describe('maplibregl-webmap3.0', () => { | |||
| 105 | 105 | }); | |
| 106 | 106 | mapstudioWebmap = new WebMap(id, { | |
| 107 | 107 | server: server, | |
| 108 | - iportalServiceProxyUrl: 'initialize_raster' | ||
| 108 | + iportalServiceProxyUrlPrefix: 'initialize_raster' | ||
| 109 | 109 | }); | |
| 110 | 110 | expect(mapstudioWebmap.credentialKey).toBeUndefined(); | |
| 111 | 111 | expect(mapstudioWebmap.credentialValue).toBeUndefined(); | |
@@ -172,7 +172,7 @@ describe('maplibregl-webmap3.0', () => { | |||
| 172 | 172 | mapstudioWebmap = new WebMapV3(mapInfo, { | |
| 173 | 173 | server: server, | |
| 174 | 174 | target: 'map', | |
| 175 | - iportalServiceProxyUrl: 'mapId is JSON' | ||
| 175 | + iportalServiceProxyUrlPrefix: 'mapId is JSON' | ||
| 176 | 176 | }); | |
| 177 | 177 | mapstudioWebmap.initializeMap(mapInfo); | |
| 178 | 178 | ||
@@ -256,7 +256,7 @@ describe('maplibregl-webmap3.0', () => { | |||
| 256 | 256 | mapstudioWebmap = new WebMap(nextMapInfo, { | |
| 257 | 257 | server: server, | |
| 258 | 258 | target: 'map', | |
| 259 | - iportalServiceProxyUrl: 'projection is 4490 and include maplibre-gl-enhance' | ||
| 259 | + iportalServiceProxyUrlPrefix: 'projection is 4490 and include maplibre-gl-enhance' | ||
| 260 | 260 | }); | |
| 261 | 261 | ||
| 262 | 262 | mapstudioWebmap.on('mapcreatesucceeded', ({ map }) => { | |
@@ -342,7 +342,7 @@ describe('maplibregl-webmap3.0', () => { | |||
| 342 | 342 | mapstudioWebmap = new WebMapV3(mapInfo, { | |
| 343 | 343 | server: server, | |
| 344 | 344 | target: 'map', | |
| 345 | - iportalServiceProxyUrl: 'overlayLayersManager' | ||
| 345 | + iportalServiceProxyUrlPrefix: 'overlayLayersManager' | ||
| 346 | 346 | }); | |
| 347 | 347 | mapstudioWebmap.initializeMap(mapInfo); | |
| 348 | 348 | ||
@@ -500,7 +500,7 @@ describe('maplibregl-webmap3.0', () => { | |||
| 500 | 500 | mapstudioWebmap = new WebMapV3(mapInfo, { | |
| 501 | 501 | server: server, | |
| 502 | 502 | target: 'map', | |
| 503 | - iportalServiceProxyUrl: 'exclude source and layer' | ||
| 503 | + iportalServiceProxyUrlPrefix: 'exclude source and layer' | ||
| 504 | 504 | }); | |
| 505 | 505 | mapstudioWebmap.initializeMap(mapInfo); | |
| 506 | 506 | ||
@@ -732,14 +732,14 @@ describe('maplibregl-webmap3.0', () => { | |||
| 732 | 732 | }); | |
| 733 | 733 | const spyTest = spyOn(MapManagerUtil, 'default').and.callFake(mbglmap); | |
| 734 | 734 | const mapInfo = JSON.parse(mapstudioWebMap_raster); | |
| 735 | - const iportalServiceProxyUrl = 'http://localhost:8195/portalproxy'; | ||
| 735 | + const iportalServiceProxyUrlPrefix = 'http://localhost:8195/portalproxy'; | ||
| 736 | 736 | const tileCustomRequestHeaders = { 'Authorization': 'test token' }; | |
| 737 | 737 | mapstudioWebmap = new WebMap(mapInfo, { | |
| 738 | 738 | server: server, | |
| 739 | 739 | target: 'map', | |
| 740 | - iportalServiceProxyUrl, | ||
| 740 | + iportalServiceProxyUrlPrefix, | ||
| 741 | 741 | tileTransformRequest: (url) => { | |
| 742 | - if (url.includes(iportalServiceProxyUrl)) { | ||
| 742 | + if (url.includes(iportalServiceProxyUrlPrefix)) { | ||
| 743 | 743 | return { headers: tileCustomRequestHeaders }; | |
| 744 | 744 | } | |
| 745 | 745 | } | |
| Back | FazBrowse Home | New Git URL |
0 commit comments