From 61b1b79074b69b4ae8a269b66a97727a4640b829 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc-Andr=C3=A9=20Barbeau?= Date: Tue, 30 May 2017 15:47:18 -0400 Subject: [PATCH 1/2] fix(travis): fix npm cache with npm5 --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 2cd8f2d48..1cbdf9c60 100644 --- a/.travis.yml +++ b/.travis.yml @@ -24,7 +24,7 @@ before_install: - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sh -e /etc/init.d/xvfb start; fi before_script: - - rm -rf node_modules && npm cache clean + - rm -rf node_modules - npm install - npm run build.prod - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then nohup bash -c "npm run serve.prod 2>&1 &"; fi # Protractor CI From deb7b19427a3c15db6ba00909b8e99c0a9bd9c4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc-Andr=C3=A9=20Barbeau?= Date: Wed, 31 May 2017 13:42:20 -0400 Subject: [PATCH 2/2] feat(igo-lib): upgrade igo-lib, add query params from url and metadata --- package.json | 7 +++---- proxy.conf.json | 11 ++++++++++- src/app/app.module.ts | 3 ++- src/app/pages/portal/portal.component.ts | 2 +- src/contexts/embacle.json | 4 ++++ 5 files changed, 20 insertions(+), 7 deletions(-) diff --git a/package.json b/package.json index f305495fc..b5e63b1b5 100644 --- a/package.json +++ b/package.json @@ -69,7 +69,7 @@ "angular2-notifications": "^0.4.53", "core-js": "^2.4.1", "hammerjs": "^2.0.8", - "igo2": "^0.4.1", + "igo2": "^0.5.0", "intl": "^1.2.5", "jspdf": "^1.3.3", "md2": "0.0.18", @@ -77,9 +77,9 @@ "openlayers": "^4.0.1", "proj4": "^2.4.3", "rxjs": "^5.1.0", + "snyk": "^1.30.1", "ts-md5": "^1.2.0", - "zone.js": "^0.8.4", - "snyk": "^1.30.1" + "zone.js": "^0.8.4" }, "devDependencies": { "@angular/cli": "^1.0.0", @@ -92,7 +92,6 @@ "codelyzer": "~2.0.0", "compodoc": "0.0.41", "conventional-changelog-cli": "^1.3.1", - "igo2": "^0.4.3", "jasmine-core": "~2.5.2", "jasmine-spec-reporter": "~3.2.0", "karma": "~1.4.1", diff --git a/proxy.conf.json b/proxy.conf.json index 0db3279e4..ba306dd5b 100644 --- a/proxy.conf.json +++ b/proxy.conf.json @@ -1,3 +1,12 @@ { - + "/ws/igo_gouvouvert.fcgi": { + "target": "http://geoegl.msp.gouv.qc.ca", + "changeOrigin": true, + "secure": false + }, + "/ws/adnInternetV2.fcgi": { + "target": "http://geoegl.msp.gouv.qc.ca", + "changeOrigin": true, + "secure": false + } } diff --git a/src/app/app.module.ts b/src/app/app.module.ts index 4bbdb0697..683c93e93 100644 --- a/src/app/app.module.ts +++ b/src/app/app.module.ts @@ -8,7 +8,7 @@ import { IgoModule, provideSearchSourceOptions, provideNominatimSearchSource, provideDataSourceSearchSource, LanguageLoader, provideLanguageLoader, - provideContextServiceOptions } from 'igo2'; + provideContextServiceOptions, RouteService } from 'igo2'; import { PortalModule } from './pages'; import { AppComponent } from './app.component'; @@ -37,6 +37,7 @@ export function languageLoader(http: Http) { PortalModule ], providers: [ + RouteService, provideSearchSourceOptions({ limit: 5 }), diff --git a/src/app/pages/portal/portal.component.ts b/src/app/pages/portal/portal.component.ts index f420b9de0..39873ad8f 100644 --- a/src/app/pages/portal/portal.component.ts +++ b/src/app/pages/portal/portal.component.ts @@ -48,7 +48,7 @@ export class PortalComponent implements OnInit, OnDestroy { this.selectedFeature$$ = this.featureService.selectedFeature$ .subscribe((feature) => this.handleFeatureSelect(feature)); - this.contextService.loadContext('_default'); + this.contextService.loadDefaultContext(); this.context$$ = this.contextService.context$ .subscribe((context) => this.handleContextChange(context)); diff --git a/src/contexts/embacle.json b/src/contexts/embacle.json index 8811732eb..da17500b3 100644 --- a/src/contexts/embacle.json +++ b/src/contexts/embacle.json @@ -54,6 +54,10 @@ "version": "1.3.0" } }, + "metadata": { + "url": "https://www.donneesquebec.ca/recherche/fr/dataset/historique-publique-d-embacles-repertories-au-msp", + "extern": true + }, "timeFilter": { "min": "2017-01-01", "max": "2018-01-01",