Skip to content

Commit

Permalink
11436 + 17937 - Framework for AGM Extension and AGM Location Change f…
Browse files Browse the repository at this point in the history
…ilings (bcgov#547)

* - app version = 6.9.0
- imported some updated shared components
- added routes
- added menus to Entity Menu
- added allowable actions enum keys
- added routes enum keys
- added allowable actions mixin cases
- added default FFs
- created initial AGM Extension view
- created initial AGM Location Chg view
- added some Entity Menu tests

* - added routes to "is local filing"
- added override to Allowable Actions mixin (TEMPORARY)
- updated initial AGM Extension view
- updated initial AGM Location Chg view
- fixed a lint warning

* - added shared Expandable Help component
- fixed FF in template not working
- added business config objects
- fixed section rows
- added initial help content
- created initial unit tests for views
- fixed unit tests
  • Loading branch information
severinbeauvais authored Oct 3, 2023
1 parent d6908f4 commit 23ee32c
Show file tree
Hide file tree
Showing 18 changed files with 3,006 additions and 336 deletions.
488 changes: 181 additions & 307 deletions package-lock.json

Large diffs are not rendered by default.

11 changes: 6 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "business-filings-ui",
"version": "6.8.2",
"version": "6.9.0",
"private": true,
"appName": "Filings UI",
"sbcName": "SBC Common Components",
Expand All @@ -14,16 +14,17 @@
},
"dependencies": {
"@babel/compat-data": "^7.21.5",
"@bcrs-shared-components/base-address": "2.0.3",
"@bcrs-shared-components/base-address": "2.0.7",
"@bcrs-shared-components/breadcrumb": "2.1.11",
"@bcrs-shared-components/confirm-dialog": "1.2.1",
"@bcrs-shared-components/corp-type-module": "1.0.11",
"@bcrs-shared-components/court-order-poa": "2.1.4",
"@bcrs-shared-components/document-delivery": "1.2.1",
"@bcrs-shared-components/enums": "1.0.39",
"@bcrs-shared-components/enums": "1.0.50",
"@bcrs-shared-components/expandable-help": "^1.0.0",
"@bcrs-shared-components/folio-number-input": "1.1.18",
"@bcrs-shared-components/interfaces": "1.0.61",
"@bcrs-shared-components/mixins": "1.1.21",
"@bcrs-shared-components/interfaces": "1.0.75",
"@bcrs-shared-components/mixins": "1.1.25",
"@bcrs-shared-components/staff-comments": "1.3.11",
"@bcrs-shared-components/staff-payment": "2.1.11",
"@mdi/font": "^5.9.55",
Expand Down
18 changes: 11 additions & 7 deletions src/components/EntityInfo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,17 @@ export default class EntityInfo extends Vue {
}
/** Is True if this is on local filing pages. */
get isInLocalFilingPage (): string {
return this.$route?.name === Routes.ANNUAL_REPORT ||
this.$route?.name === Routes.CONSENT_CONTINUATION_OUT ||
this.$route?.name === Routes.CONTINUATION_OUT ||
this.$route?.name === Routes.CORRECTION ||
this.$route?.name === Routes.STANDALONE_ADDRESSES ||
this.$route?.name === Routes.STANDALONE_DIRECTORS
get isInLocalFilingPage (): boolean {
return (
this.$route?.name === Routes.AGM_EXTENSION ||
this.$route?.name === Routes.AGM_LOCATION_CHG ||
this.$route?.name === Routes.ANNUAL_REPORT ||
this.$route?.name === Routes.CONSENT_CONTINUATION_OUT ||
this.$route?.name === Routes.CONTINUATION_OUT ||
this.$route?.name === Routes.CORRECTION ||
this.$route?.name === Routes.STANDALONE_ADDRESSES ||
this.$route?.name === Routes.STANDALONE_DIRECTORS
)
}
/** The Temporary Registration Number string (may be null). */
Expand Down
62 changes: 61 additions & 1 deletion src/components/EntityInfo/EntityMenu.vue
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,48 @@
</template>
Submit a Consent to Continue Out of the province of B.C.
</v-tooltip>

<!-- Request AGM Extension -->
<v-tooltip
right
content-class="right-tooltip"
>
<template #activator="{ on }">
<v-list-item
v-if="enableAgmExtension"
id="agm-ext-list-item"
:disabled="!isAllowed(AllowableActions.AGM_EXTENSION)"
v-on="on"
@click="goToAgmExtensionFiling()"
>
<v-list-item-title>
<span class="app-blue">Request AGM Extension</span>
</v-list-item-title>
</v-list-item>
</template>
Request an AGM extension. The longest extension granted at one time is six months.
</v-tooltip>

<!-- Request AGM Location Change -->
<v-tooltip
right
content-class="right-tooltip"
>
<template #activator="{ on }">
<v-list-item
v-if="enableAgmLocationChg"
id="agm-loc-chg-list-item"
:disabled="!isAllowed(AllowableActions.AGM_LOCATION_CHG)"
v-on="on"
@click="goToAgmLocationChgFiling()"
>
<v-list-item-title>
<span class="app-blue">Request AGM Location Change</span>
</v-list-item-title>
</v-list-item>
</template>
Request an AGM location change.
</v-tooltip>
</v-list-item-group>
</v-list>
</v-menu>
Expand All @@ -177,7 +219,7 @@ import axios from '@/axios-auth'
import { StaffComments } from '@bcrs-shared-components/staff-comments'
import { AllowableActions, NigsMessage, Routes } from '@/enums'
import { AllowableActionsMixin } from '@/mixins'
import { navigate } from '@/utils'
import { GetFeatureFlag, navigate } from '@/utils'
import { useBusinessStore, useConfigurationStore, useRootStore } from '@/stores'
@Component({
Expand All @@ -203,6 +245,14 @@ export default class EntityMenu extends Mixins(AllowableActionsMixin) {
return !!this.businessId
}
get enableAgmExtension (): boolean {
return !!GetFeatureFlag('enable-agm-extension')
}
get enableAgmLocationChg (): boolean {
return !!GetFeatureFlag('enable-agm-location-chg')
}
/**
* Emits an event to display NIGS dialog if company is not in good standing except Coop
* Otherwise, navigates to the Edit UI to view or change company information.
Expand Down Expand Up @@ -237,6 +287,16 @@ export default class EntityMenu extends Mixins(AllowableActionsMixin) {
this.$router.push({ name: Routes.CONSENT_CONTINUATION_OUT, params: { filingId: '0' } })
}
goToAgmExtensionFiling (): void {
// 0 means "new filing"
this.$router.push({ name: Routes.AGM_EXTENSION, params: { filingId: '0' } })
}
goToAgmLocationChgFiling (): void {
// 0 means "new filing"
this.$router.push({ name: Routes.AGM_LOCATION_CHG, params: { filingId: '0' } })
}
/** Emits an event to confirm dissolution. */
@Emit('confirmDissolution')
emitConfirmDissolution (): void {}
Expand Down
2 changes: 1 addition & 1 deletion src/components/common/FileUploadPdf.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<template>
<v-file-input
class="file-upload-pdf"
:key="count"
class="file-upload-pdf"
dense
filled
show-size
Expand Down
2 changes: 2 additions & 0 deletions src/enums/allowableActions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
export enum AllowableActions {
ADDRESS_CHANGE = 1, // skip 0 which is falsy
ADMINISTRATIVE_DISSOLUTION,
AGM_EXTENSION,
AGM_LOCATION_CHG,
ANNUAL_REPORT,
BUSINESS_INFORMATION,
BUSINESS_SUMMARY,
Expand Down
2 changes: 2 additions & 0 deletions src/enums/routes.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
export enum Routes {
AGM_EXTENSION = 'agm-extension',
AGM_LOCATION_CHG = 'agm-location-chg',
ANNUAL_REPORT = 'annual-report',
CONSENT_CONTINUATION_OUT = 'consent-continuation-out',
CONTINUATION_OUT = 'continuation-out',
Expand Down
10 changes: 10 additions & 0 deletions src/mixins/allowable-actions-mixin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,16 @@ export default class AllowableActionsMixin extends Vue {
return this.isAllowedFiling(FilingTypes.ANNUAL_REPORT)
}

case AllowableActions.AGM_EXTENSION: {
return true // *** FOR DEBUGGING ONLY
// return this.isAllowedFiling(FilingTypes.AGM_EXTENSION)
}

case AllowableActions.AGM_LOCATION_CHG: {
return true // *** FOR DEBUGGING ONLY
// return this.isAllowedFiling(FilingTypes.AGM_LOCATION_CHG)
}

case AllowableActions.BUSINESS_INFORMATION: {
if (this.isCoop) {
// NB: this feature is targeted via LaunchDarkly
Expand Down
56 changes: 56 additions & 0 deletions src/resources/business-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,20 @@ export const ConfigJson = [
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
},
{
feeCode: FilingCodes.AGM_EXTENSION,
displayName: 'AGM Extension',
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
},
{
feeCode: FilingCodes.AGM_LOCATION_CHG,
displayName: 'AGM Location Change',
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
}
],
obligations: {
Expand Down Expand Up @@ -333,6 +347,20 @@ export const ConfigJson = [
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
},
{
feeCode: FilingCodes.AGM_EXTENSION,
displayName: 'AGM Extension',
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
},
{
feeCode: FilingCodes.AGM_LOCATION_CHG,
displayName: 'AGM Location Change',
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
}
],
obligations: {
Expand Down Expand Up @@ -412,6 +440,20 @@ export const ConfigJson = [
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
},
{
feeCode: FilingCodes.AGM_EXTENSION,
displayName: 'AGM Extension',
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
},
{
feeCode: FilingCodes.AGM_LOCATION_CHG,
displayName: 'AGM Location Change',
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
}
],
obligations: {
Expand Down Expand Up @@ -491,6 +533,20 @@ export const ConfigJson = [
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
},
{
feeCode: FilingCodes.AGM_EXTENSION,
displayName: 'AGM Extension',
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
},
{
feeCode: FilingCodes.AGM_LOCATION_CHG,
displayName: 'AGM Location Change',
certifyText: 'Note: It is an offence to make or assist in making a false or' +
' misleading statement in a record filed under the Business Corporations Act.' +
' A person who commits this offence is subject to a maximum fine of $5,000.'
}
],
obligations: {
Expand Down
34 changes: 34 additions & 0 deletions src/routes.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
import Dashboard from '@/views/Dashboard.vue'
import AgmExtension from '@/views/AgmExtension.vue'
import AgmLocationChg from '@/views/AgmLocationChg.vue'
import AnnualReport from '@/views/AnnualReport.vue'
import StandaloneDirectorsFiling from '@/views/StandaloneDirectorsFiling.vue'
import StandaloneOfficeAddressFiling from '@/views/StandaloneOfficeAddressFiling.vue'
Expand All @@ -19,6 +21,38 @@ export default [
requiresAuth: true
}
},
{
path: '/agm-extension',
name: Routes.AGM_EXTENSION,
component: AgmExtension,
meta: {
requiresAuth: true,
breadcrumb: [
{
text: `File ${FilingNames.AGM_EXTENSION}`,
disabled: false,
exact: true,
to: { name: Routes.AGM_EXTENSION }
}
]
}
},
{
path: '/agm-location-chg',
name: Routes.AGM_LOCATION_CHG,
component: AgmLocationChg,
meta: {
requiresAuth: true,
breadcrumb: [
{
text: `File ${FilingNames.AGM_LOCATION_CHG}`,
disabled: false,
exact: true,
to: { name: Routes.AGM_LOCATION_CHG }
}
]
}
},
{
path: '/annual-report',
name: Routes.ANNUAL_REPORT,
Expand Down
2 changes: 2 additions & 0 deletions src/utils/feature-flags.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ declare const window: any
*/
const defaultFlagSet: LDFlagSet = {
'banner-text': '', // by default, there is no banner text
'enable-agm-extension': false,
'enable-agm-location-chg': false,
'enable-digital-credentials': false,
'sentry-enable': false, // by default, no sentry logs
'show-alert-phone-numbers-firm': false,
Expand Down
Loading

0 comments on commit 23ee32c

Please sign in to comment.