Skip to content

Commit

Permalink
- app version = 5.6.1
Browse files Browse the repository at this point in the history
- imported latest shared enums
- imported latest shared interfaces
- imported latest shared mixins
- added route names to enum
- added views to enum
- added filing interface
- added resource interface
- updated state interface
- added amalgamation state interface
- updated filing template mixin
- added initial amalgamation resources
- added amalgamation steps
- added amalgamation routes
- added/updated getters/actions to  store
- updated state model
- added initial amalgamation views

- renamed some methods in App.vue
- added amalgamations to App.vue
- added amalgamations to Actions.vue
- added amalgamations to EntityInfo.vue
- added amalgamations to SaveErrorDialog.vue
- added fallbacks to amalgamations in filing-template-mixin.ts
- added amalgamations to BreadCrumbResource.ts
- added amalgamations to legal-services.ts
- added amalgamations to feature-flag-utils.ts
- misc cleanup

- initial updates to Business Info page
- initial updates to Information page

- added Expandable Help
- added error return links
- added amalg blocks to Summary Define Company
- added misc placeholders for future components

- moved SummaryDefineCompany to common folder
- moved ListShareClass to common folder
- moved ShareStructure to common folder

- updated validity in Stepper
  • Loading branch information
severinbeauvais committed Nov 21, 2023
1 parent 700a8b4 commit 30262ea
Show file tree
Hide file tree
Showing 50 changed files with 2,294 additions and 185 deletions.
106 changes: 32 additions & 74 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 5 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "business-create-ui",
"version": "5.6.0",
"version": "5.6.1",
"private": true,
"appName": "Create UI",
"sbcName": "SBC Common Components",
Expand Down Expand Up @@ -28,12 +28,13 @@
"@bcrs-shared-components/date-picker": "1.2.15",
"@bcrs-shared-components/document-delivery": "1.2.0",
"@bcrs-shared-components/effective-date-time": "1.1.15",
"@bcrs-shared-components/enums": "1.0.46",
"@bcrs-shared-components/enums": "1.1.1",
"@bcrs-shared-components/expandable-help": "1.0.1",
"@bcrs-shared-components/genesys-web-message": "1.0.0",
"@bcrs-shared-components/help-business-number": "1.1.1",
"@bcrs-shared-components/interfaces": "1.0.71",
"@bcrs-shared-components/interfaces": "1.1.1",
"@bcrs-shared-components/limited-restoration-panel": "1.0.5",
"@bcrs-shared-components/mixins": "1.1.21",
"@bcrs-shared-components/mixins": "1.1.29",
"@bcrs-shared-components/nature-of-business": "1.2.14",
"@bcrs-shared-components/relationships-panel": "1.0.9",
"@bcrs-shared-components/staff-comments": "1.3.15",
Expand Down
55 changes: 35 additions & 20 deletions src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -252,9 +252,9 @@ import { CommonMixin, DateMixin, FilingTemplateMixin, NameRequestMixin } from '@
import { AccountInformationIF, AddressIF, BreadcrumbIF, BusinessIF, BusinessWarningIF, CompletingPartyIF,
ConfirmDialogType, EmptyFees, FeesIF, FilingDataIF, NameRequestIF, OrgInformationIF, PartyIF, ResourceIF,
StepIF } from '@/interfaces'
import { DissolutionResources, IncorporationResources, RegistrationResources, RestorationResources,
getEntityDashboardBreadcrumb, getMyBusinessRegistryBreadcrumb, getRegistryDashboardBreadcrumb,
getSbcStaffDashboardBreadcrumb, getStaffDashboardBreadcrumb } from '@/resources'
import { AmalgamationRegResources, DissolutionResources, IncorporationResources, RegistrationResources,
RestorationResources, getEntityDashboardBreadcrumb, getMyBusinessRegistryBreadcrumb,
getRegistryDashboardBreadcrumb, getSbcStaffDashboardBreadcrumb, getStaffDashboardBreadcrumb } from '@/resources'
import { AuthServices, LegalServices, PayServices } from '@/services/'
// Enums and Constants
Expand Down Expand Up @@ -295,6 +295,7 @@ export default class App extends Mixins(CommonMixin, DateMixin, FilingTemplateMi
@Getter(useStore) getUserLastName!: string
@Getter(useStore) getUserEmail!: string
@Getter(useStore) getUserPhone!: string
@Getter(useStore) isAmalgamationFiling!: boolean
@Getter(useStore) isDissolutionFiling!: boolean
@Getter(useStore) isIncorporationFiling!: boolean
@Getter(useStore) isMobile!: boolean
Expand Down Expand Up @@ -361,7 +362,7 @@ export default class App extends Mixins(CommonMixin, DateMixin, FilingTemplateMi
readonly window = window
/** The Update Current JS Date timer id. */
private updateCurrentJsDateId = 0
private updateCurrentJsDateId = null // may be number or NodeJS.Timeout
/** The route breadcrumbs list. */
get breadcrumbs (): Array<BreadcrumbIF> {
Expand Down Expand Up @@ -674,14 +675,10 @@ export default class App extends Mixins(CommonMixin, DateMixin, FilingTemplateMi
if (!this.getBusinessId && !this.getTempId) throw new Error('Neither business id nor temp id exist')
if (this.getBusinessId) {
// this should be a Dissolution or Restoration filing
// (only dissolutions/restorations have a business id)
await this.handleDissolutionOrRestoration(this.getBusinessId)
await this.handleDraftWithBusinessId(this.getBusinessId)
}
if (this.getTempId) {
// this should be an Incorporation or Registration filing
// (only incorporations/registrations have a temp id)
await this.handleIaOrRegistration(this.getTempId)
await this.handleDraftWithTempId(this.getTempId)
}
} catch (error) {
// Log exception to Sentry due to incomplete business data.
Expand Down Expand Up @@ -733,22 +730,25 @@ export default class App extends Mixins(CommonMixin, DateMixin, FilingTemplateMi
// then try to re-route them
if (this.$route.meta.filingType !== this.getFilingType) {
switch (this.getFilingType) {
case FilingTypes.AMALGAMATION:
this.$router.push(RouteNames.AMALG_REG_INFORMATION).catch(() => {})
break
case FilingTypes.DISSOLUTION:
if (this.isTypeFirm) {
this.$router.push(RouteNames.DISSOLUTION_FIRM).catch(() => {})
} else {
this.$router.push(RouteNames.DISSOLUTION_DEFINE_DISSOLUTION).catch(() => {})
}
return
return // *** TODO: should this be "break"?
case FilingTypes.INCORPORATION_APPLICATION:
this.$router.push(RouteNames.INCORPORATION_DEFINE_COMPANY).catch(() => {})
return
return // *** TODO: should this be "break"?
case FilingTypes.REGISTRATION:
this.$router.push(RouteNames.REGISTRATION_DEFINE_BUSINESS).catch(() => {})
return
return // *** TODO: should this be "break"?
case FilingTypes.RESTORATION:
this.$router.push(RouteNames.RESTORATION_BUSINESS_NAME).catch(() => {})
return
return // *** TODO: should this be "break"?
default:
this.invalidRouteDialog = true
throw new Error(`fetchData(): invalid filing type = ${this.getFilingType}`) // go to catch()
Expand Down Expand Up @@ -794,8 +794,11 @@ export default class App extends Mixins(CommonMixin, DateMixin, FilingTemplateMi
}
}
/** Fetches draft Dissolution or Restoration and sets the resources. */
private async handleDissolutionOrRestoration (businessId: string): Promise<void> {
/**
* Fetches draft Dissolution / Restoration and sets the resources.
* (Only dissolutions/restorations have a Business ID.)
*/
private async handleDraftWithBusinessId (businessId: string): Promise<void> {
// ensure user is authorized to use this business
await this.checkAuth(businessId).catch(error => {
console.log('Auth error =', error) // eslint-disable-line no-console
Expand Down Expand Up @@ -836,7 +839,7 @@ export default class App extends Mixins(CommonMixin, DateMixin, FilingTemplateMi
resources = RestorationResources.find(x => x.entityType === this.getEntityType) as ResourceIF
break
default:
throw new Error(`handleDissolutionOrRestoration(): invalid filing type = ${this.getFilingType}`)
throw new Error(`handleDraftWithBusinessId(): invalid filing type = ${this.getFilingType}`)
}
// set the resources
Expand All @@ -853,8 +856,11 @@ export default class App extends Mixins(CommonMixin, DateMixin, FilingTemplateMi
}
}
/** Fetches draft IA or Registration and sets the resources. */
private async handleIaOrRegistration (tempId: string): Promise<void> {
/**
* Fetches draft Amalgamation / IA / Registration and sets the resources.
* (Only amalgamations/incorporations/registrations have a Temp ID.)
*/
private async handleDraftWithTempId (tempId: string): Promise<void> {
// ensure user is authorized to use this IA
await this.checkAuth(tempId).catch(error => {
console.log('Auth error =', error) // eslint-disable-line no-console
Expand All @@ -875,6 +881,14 @@ export default class App extends Mixins(CommonMixin, DateMixin, FilingTemplateMi
// parse draft filing into the store and get the resources
let resources: ResourceIF
switch (this.getFilingType) {
case FilingTypes.AMALGAMATION:
draftFiling = {
...this.buildAmalgamationFiling(),
...draftFiling
}
this.parseAmalgamationDraft(draftFiling)
resources = AmalgamationRegResources.find(x => x.entityType === this.getEntityType) as ResourceIF
break
case FilingTypes.INCORPORATION_APPLICATION:
draftFiling = {
...this.buildIncorporationFiling(),
Expand All @@ -892,7 +906,7 @@ export default class App extends Mixins(CommonMixin, DateMixin, FilingTemplateMi
resources = RegistrationResources.find(x => x.entityType === this.getEntityType) as ResourceIF
break
default:
throw new Error(`handleIaOrRegistration(): invalid filing type = ${this.getFilingType}`)
throw new Error(`handleDraftWithTempId(): invalid filing type = ${this.getFilingType}`)
}
// set the resources
Expand Down Expand Up @@ -1231,6 +1245,7 @@ export default class App extends Mixins(CommonMixin, DateMixin, FilingTemplateMi
// enable validation when review pages are shown
if (
this.isRouteName(RouteNames.AMALG_REG_REVIEW_CONFIRM) ||
this.isRouteName(RouteNames.DISSOLUTION_REVIEW_CONFIRM) ||
this.isRouteName(RouteNames.INCORPORATION_REVIEW_CONFIRM) ||
this.isRouteName(RouteNames.REGISTRATION_REVIEW_CONFIRM) ||
Expand Down
2 changes: 2 additions & 0 deletions src/components/common/Actions.vue
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,8 @@ export default class Actions extends Mixins(CommonMixin, DateMixin, FilingTempla
/** Prepare filing for saving/filing. */
private prepareFiling (): any {
switch (this.getFilingType) {
case FilingTypes.AMALGAMATION:
return this.buildAmalgamationFiling()
case FilingTypes.INCORPORATION_APPLICATION:
return this.buildIncorporationFiling()
case FilingTypes.REGISTRATION:
Expand Down
6 changes: 4 additions & 2 deletions src/components/common/EntityInfo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -86,12 +86,12 @@ import { Component, Mixins } from 'vue-property-decorator'
import { Getter } from 'pinia-class'
import { useStore } from '@/store/store'
import { FilingNames, FilingTypes } from '@/enums'
import { CorpTypeCd } from '@bcrs-shared-components/enums/'
import { ContactPointIF, RegistrationStateIF } from '@/interfaces'
import { DateMixin } from '@/mixins'
import { StaffComments } from '@bcrs-shared-components/staff-comments'
import { AxiosInstance as axios } from '@/utils'
import { GetCorpFullDescription, GetCorpNumberedDescription } from '@bcrs-shared-components/corp-type-module'
import { CorpTypeCd, GetCorpFullDescription, GetCorpNumberedDescription }
from '@bcrs-shared-components/corp-type-module'
@Component({
components: {
Expand Down Expand Up @@ -130,6 +130,8 @@ export default class EntityInfo extends Mixins(DateMixin) {
// name comes from different places depending on filing type
switch (this.getFilingType) {
case FilingTypes.AMALGAMATION:
return (this.getNameRequestApprovedName || numberedDescription)
case FilingTypes.DISSOLUTION:
return (this.getBusinessLegalName || numberedDescription)
case FilingTypes.INCORPORATION_APPLICATION:
Expand Down
Loading

0 comments on commit 30262ea

Please sign in to comment.