Skip to content

Commit

Permalink
feat: update navbar link, fix tests, centered homepage text
Browse files Browse the repository at this point in the history
  • Loading branch information
wilwong89 committed Jan 29, 2024
1 parent e0004f5 commit fe04181
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 48 deletions.
84 changes: 42 additions & 42 deletions app/src/db/prisma/schema.prisma
Original file line number Diff line number Diff line change
Expand Up @@ -44,48 +44,6 @@ model identity_provider {
user user[]
}

model permit {
permitId String @id @db.Uuid
permitTypeId Int
submissionId String @db.Uuid
issuedPermitId String?
trackingId String?
authStatus String?
needed String?
status String?
submittedDate DateTime? @db.Timestamptz(6)
adjudicationDate DateTime? @db.Timestamptz(6)
createdBy String? @default("00000000-0000-0000-0000-000000000000")
createdAt DateTime? @default(now()) @db.Timestamptz(6)
updatedBy String?
updatedAt DateTime? @db.Timestamptz(6)
permit_type permit_type @relation(fields: [permitTypeId], references: [permitTypeId], onDelete: Cascade, map: "permit_permittypeid_foreign")
submission submission @relation(fields: [submissionId], references: [submissionId], onDelete: Cascade, map: "permit_submissionid_foreign")
@@unique([permitId, permitTypeId, submissionId], map: "permit_permitid_permittypeid_submissionid_unique")
}

model permit_type {
permitTypeId Int @id @default(autoincrement())
agency String
division String?
branch String?
businessDomain String
type String
family String?
name String
nameSubtype String?
acronym String?
trackedInATS Boolean?
sourceSystem String?
sourceSystemAcronym String
createdBy String? @default("00000000-0000-0000-0000-000000000000")
createdAt DateTime? @default(now()) @db.Timestamptz(6)
updatedBy String?
updatedAt DateTime? @db.Timestamptz(6)
permit permit[]
}

model submission {
submissionId String @id @db.Uuid
assignedToUserId String? @db.Uuid
Expand Down Expand Up @@ -150,3 +108,45 @@ model user {
@@index([identityId], map: "user_identityid_index")
@@index([username], map: "user_username_index")
}

model permit {
permitId String @id @db.Uuid
permitTypeId Int
submissionId String @db.Uuid
issuedPermitId String?
trackingId String?
authStatus String?
needed String?
status String?
submittedDate DateTime? @db.Timestamptz(6)
adjudicationDate DateTime? @db.Timestamptz(6)
createdBy String? @default("00000000-0000-0000-0000-000000000000")
createdAt DateTime? @default(now()) @db.Timestamptz(6)
updatedBy String?
updatedAt DateTime? @db.Timestamptz(6)
permit_type permit_type @relation(fields: [permitTypeId], references: [permitTypeId], onDelete: Cascade, map: "permit_permittypeid_foreign")
submission submission @relation(fields: [submissionId], references: [submissionId], onDelete: Cascade, map: "permit_submissionid_foreign")
@@unique([permitId, permitTypeId, submissionId], map: "permit_permitid_permittypeid_submissionid_unique")
}

model permit_type {
permitTypeId Int @id @default(autoincrement())
agency String
division String?
branch String?
businessDomain String
type String
family String?
name String
nameSubtype String?
acronym String?
trackedInATS Boolean?
sourceSystem String?
sourceSystemAcronym String
createdBy String? @default("00000000-0000-0000-0000-000000000000")
createdAt DateTime? @default(now()) @db.Timestamptz(6)
updatedBy String?
updatedAt DateTime? @db.Timestamptz(6)
permit permit[]
}
2 changes: 1 addition & 1 deletion frontend/src/components/layout/Navbar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const { getIsAuthenticated } = storeToRefs(useAuthStore());
<router-link :to="{ name: RouteNames.HOME }">Home</router-link>
</li>
<li v-if="getIsAuthenticated">
<router-link :to="{ name: RouteNames.INITIATIVES }">Submissions</router-link>
<router-link :to="{ name: RouteNames.SUBMISSIONS }">Submissions</router-link>
</li>
</ol>
</template>
Expand Down
6 changes: 2 additions & 4 deletions frontend/src/views/HomeView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,8 @@ const toSubmissions = (): void => {
</Message>

<div class="text-center">
<h1 class="font-bold">Welcome to the PermitConnect Navigator Service!</h1>
</div>
<div>
<h2>Choose an Initiative:</h2>
<h1 class="font-bold">Welcome to the PermitConnect Applications</h1>
<h2 class="mb-3">Choose an Initiative:</h2>
<Button
:disabled="!getIsAuthenticated"
@click="toSubmissions"
Expand Down
2 changes: 1 addition & 1 deletion frontend/tests/unit/components/layout/Navbar.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ describe('Navbar.vue', () => {
const linkEle = wrapper.findAll('a');
expect(linkEle).toHaveLength(2);
expect(linkEle[0].text()).toBe('Home');
expect(linkEle[1].text()).toBe('Initiatives');
expect(linkEle[1].text()).toBe('Submissions');
});

it('shows correct navbar when false', async () => {
Expand Down

0 comments on commit fe04181

Please sign in to comment.