generated from bcgov/quickstart-openshift
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
COMPENF-648 map marker using location data (#114)
- Loading branch information
Showing
22 changed files
with
583 additions
and
79 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,10 +26,10 @@ jobs: | |
dir: [backend, frontend] | ||
include: | ||
- dir: backend | ||
sonar_projectKey: bcgov_nr-quickstart-typescript_backend | ||
sonar_projectKey: bcgov_nr-compliance-enforcement_backend | ||
token: SONAR_TOKEN_BACKEND | ||
- dir: frontend | ||
sonar_projectKey: bcgov_nr-quickstart-typescript_frontend | ||
sonar_projectKey: bcgov_nr-compliance-enforcement_frontend | ||
token: SONAR_TOKEN_FRONTEND | ||
steps: | ||
- uses: bcgov-nr/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
backend/src/external_api/bc_geo_coder/bc_geo_coder.controller.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import { Test, TestingModule } from "@nestjs/testing"; | ||
import { BcGeoCoderController } from "./bc_geo_coder.controller"; | ||
import { BcGeoCoderService } from "./bc_geo_coder.service"; | ||
import { HttpModule } from "@nestjs/axios"; | ||
|
||
describe("BcGeoCoderController", () => { | ||
let controller: BcGeoCoderController; | ||
|
||
beforeEach(async () => { | ||
const module: TestingModule = await Test.createTestingModule({ | ||
controllers: [BcGeoCoderController], | ||
providers: [BcGeoCoderService], | ||
imports: [HttpModule], | ||
}).compile(); | ||
|
||
controller = module.get<BcGeoCoderController>(BcGeoCoderController); | ||
}); | ||
|
||
it("should be defined", () => { | ||
expect(controller).toBeDefined(); | ||
}); | ||
}); |
16 changes: 16 additions & 0 deletions
16
backend/src/external_api/bc_geo_coder/bc_geo_coder.controller.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { Controller, Get, Param } from '@nestjs/common'; | ||
import { BcGeoCoderService } from './bc_geo_coder.service'; | ||
import { Roles } from '../../auth/decorators/roles.decorator'; | ||
import { Role } from '../../enum/role.enum'; | ||
|
||
@Controller('bc-geo-coder') | ||
export class BcGeoCoderController { | ||
constructor(private readonly bcGeoCoderService: BcGeoCoderService) {} | ||
|
||
@Get('/address/:query') | ||
@Roles(Role.COS_OFFICER) | ||
findAll(@Param('query') query: string) { | ||
return this.bcGeoCoderService.findAll(query); | ||
} | ||
|
||
} |
11 changes: 11 additions & 0 deletions
11
backend/src/external_api/bc_geo_coder/bc_geo_coder.module.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import { Module } from "@nestjs/common"; | ||
import { BcGeoCoderService } from "./bc_geo_coder.service"; | ||
import { HttpModule } from "@nestjs/axios"; | ||
import { BcGeoCoderController } from "./bc_geo_coder.controller"; | ||
|
||
@Module({ | ||
imports: [HttpModule], | ||
controllers: [BcGeoCoderController], | ||
providers: [BcGeoCoderService], | ||
}) | ||
export class BcGeoCoderModule {} |
Oops, something went wrong.