Skip to content

Commit

Permalink
feat: Release/giant pacific octopus (#78)
Browse files Browse the repository at this point in the history
Co-authored-by: Om Mishra <[email protected]>
Co-authored-by: dmitri-korin-bcps <[email protected]>
  • Loading branch information
3 people authored Aug 20, 2024
1 parent 6d37ea1 commit 5a6d032
Show file tree
Hide file tree
Showing 15 changed files with 23 additions and 23 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/scheduled.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ jobs:
FLYWAY_USER: postgres
FLYWAY_PASSWORD: default
FLYWAY_LOCATIONS: filesystem:./migrations
FLYWAY_DEFAULT_SCHEMA: "public"
FLYWAY_DEFAULT_SCHEMA: "case_management"
with:
args: info migrate info

Expand All @@ -85,7 +85,7 @@ jobs:
mkdir output
chmod a+rwx -R output
- name: Run Schemaspy
run: docker run --network host -v "$PWD/output:/output" schemaspy/schemaspy:6.2.4 -t pgsql11 -db default -host 127.0.0.1 -port 5432 -u postgres -p default -schemas public
run: docker run --network host -v "$PWD/output:/output" schemaspy/schemaspy:6.2.4 -t pgsql11 -db default -host 127.0.0.1 -port 5432 -u postgres -p default -schemas case_management
- name: Deploy to Pages
uses: JamesIves/github-pages-deploy-action@v4
with:
Expand Down
2 changes: 1 addition & 1 deletion backend/src/age_code/age_code.resolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class AgeCodeResolver {
constructor(private readonly ageCodeService: AgeCodeService) {}

@Query("ageCodes")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
findAll() {
return this.ageCodeService.findAll();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class ConflictHistoryCodeResolver {
constructor(private readonly conflictHistoryCodeService: ConflictHistoryCodeService) {}

@Query("conflictHistoryCodes")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
findAll() {
return this.conflictHistoryCodeService.findAll();
}
Expand Down
2 changes: 1 addition & 1 deletion backend/src/drug_code/drug_code.resolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class DrugCodeResolver {
constructor(private readonly drugCodeService: DrugCodeService) {}

@Query("drugCodes")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
findAll() {
return this.drugCodeService.findAll();
}
Expand Down
2 changes: 1 addition & 1 deletion backend/src/drug_method_code/drug_method_code.resolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class DrugMethodCodeResolver {
constructor(private readonly drugMethodCodeService: DrugMethodCodeService) {}

@Query("drugMethodCodes")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
findAll() {
return this.drugMethodCodeService.findAll();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class DrugRemainingOutcomeCodeResolver {
constructor(private readonly drugRemainingOutcomeCodeService: DrugRemainingOutcomeCodeService) {}

@Query("drugRemainingOutcomeCodes")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
findAll() {
return this.drugRemainingOutcomeCodeService.findAll();
}
Expand Down
2 changes: 1 addition & 1 deletion backend/src/ear_code/ear_code.resolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class EarCodeResolver {
constructor(private readonly earCodeService: EarCodeService) {}

@Query("earCodes")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
findAll() {
return this.earCodeService.findAll();
}
Expand Down
1 change: 1 addition & 0 deletions backend/src/enum/role.enum.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
export enum Role {
COS_OFFICER = "COS Officer",
COS_ADMIN = "COS Admin",
CEEB = "CEEB",
}
2 changes: 1 addition & 1 deletion backend/src/equipment_code/equipment_code.resolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export class EquipmentCodeResolver {
constructor(private readonly equipmentCodeService: EquipmentCodeService) {}

@Query("equipmentCodes")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
findAll() {
return this.equipmentCodeService.findAll();
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,18 @@

import { Resolver, Query, Args } from '@nestjs/graphql';
import { Resolver, Query, Args } from "@nestjs/graphql";
import { JwtRoleGuard } from "../auth/jwtrole.guard";
import { UseGuards } from "@nestjs/common";
import { Role } from "../enum/role.enum";
import { Roles } from "../auth/decorators/roles.decorator";
import { ActionCodeService } from '../action_code/action_code.service';
import { ACTION_TYPE_CODES } from '../common/action_type_codes';
import { ActionCodeService } from "../action_code/action_code.service";
import { ACTION_TYPE_CODES } from "../common/action_type_codes";

@UseGuards(JwtRoleGuard)
@Resolver("HWCRAssessmentAction")
export class HWCRAssessmentActionResolver {
constructor(private readonly actionCodeService: ActionCodeService) { }
constructor(private readonly actionCodeService: ActionCodeService) {}

@Query("HWCRAssessmentActions")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
find() {
return this.actionCodeService.findAllCodesByType(ACTION_TYPE_CODES.COMPASSESS);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class HwcrOutcomeCodeResolver {
constructor(private readonly hwcrOutcomeCodeService: HwcrOutcomeCodeService) {}

@Query("hwcrOutcomeCodes")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
findAll() {
return this.hwcrOutcomeCodeService.findAll();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@ import { JwtRoleGuard } from "../auth/jwtrole.guard";
import { UseGuards } from "@nestjs/common";
import { Role } from "../enum/role.enum";
import { Roles } from "../auth/decorators/roles.decorator";
import { ActionCodeService } from '../action_code/action_code.service';
import { ACTION_TYPE_CODES } from '../common/action_type_codes';
import { ActionCodeService } from "../action_code/action_code.service";
import { ACTION_TYPE_CODES } from "../common/action_type_codes";

@UseGuards(JwtRoleGuard)
@Resolver("HWCRPreventionAction")
export class HWCRPreventionActionResolver {
constructor(private readonly actionCodeService: ActionCodeService) { }
constructor(private readonly actionCodeService: ActionCodeService) {}

@Query("HWCRPreventionActions")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
find() {
return this.actionCodeService.findAllCodesByType(ACTION_TYPE_CODES.COSPRVANDEDU);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class InactionJustificationTypeResolver {
constructor(private readonly inactionJustificationTypeService: InactionJustificationTypeService) {}

@Query("inactionJustificationCodes")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
find(@Args("agencyCode") agencyCode?: string) {
return this.inactionJustificationTypeService.find(agencyCode);
}
Expand Down
2 changes: 1 addition & 1 deletion backend/src/sex_code/sex_code.resolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class SexCodeResolver {
constructor(private readonly sexCodeService: SexCodeService) {}

@Query("sexCodes")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
findAll() {
return this.sexCodeService.findAll();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export class ThreatLevelCodeResolver {
constructor(private readonly threatLevelCodeService: ThreatLevelCodeService) {}

@Query("threatLevelCodes")
@Roles(Role.COS_OFFICER)
@Roles(Role.COS_OFFICER, Role.CEEB)
findAll() {
return this.threatLevelCodeService.findAll();
}
Expand Down

0 comments on commit 5a6d032

Please sign in to comment.