From 6b08819c323a7613002be322c32fee8531b95171 Mon Sep 17 00:00:00 2001 From: Jia Xu Date: Tue, 10 Mar 2026 14:21:16 -0700 Subject: [PATCH 1/3] Price list - update design pricing columns --- app/pages/product-fees.vue | 30 +++++++++++++++++++++--------- i18n/locales/en-CA.ts | 7 ++++--- i18n/locales/fr-CA.ts | 7 ++++--- 3 files changed, 29 insertions(+), 15 deletions(-) diff --git a/app/pages/product-fees.vue b/app/pages/product-fees.vue index 5e76841..d96d5ae 100644 --- a/app/pages/product-fees.vue +++ b/app/pages/product-fees.vue @@ -20,11 +20,12 @@ interface ProductFee { corpType: string corpTypeDescription: string fee: number | string + feeGst: number filingType: string productCode: string service: string serviceCharge: number - gst: number + serviceChargeGst: number total: number | string variable: boolean url?: string @@ -41,8 +42,9 @@ function groupAndTotalProducts(inputProducts: ProductFee[]): GroupedProductFee[] const { service, fee, + feeGst, serviceCharge, - gst, + serviceChargeGst, url, productCode, corpType, @@ -50,7 +52,8 @@ function groupAndTotalProducts(inputProducts: ProductFee[]): GroupedProductFee[] filingType, variable } = currentItem - const total = typeof fee === 'string' ? fee : fee + serviceCharge + gst + + const total = typeof fee === 'string' ? fee : fee + feeGst + serviceCharge + serviceChargeGst let serviceString = corpTypeDescription + ' - ' + service if (variable) { @@ -59,8 +62,9 @@ function groupAndTotalProducts(inputProducts: ProductFee[]): GroupedProductFee[] const productFee: ProductFee = { service: serviceString, fee, + feeGst, serviceCharge, - gst, + serviceChargeGst, total, url, filingType, @@ -123,24 +127,32 @@ const serviceColumns = [ }, { accessorKey: 'fee', - header: textHeader(t('page.productFees.table.header.fee'), 'right'), + header: textHeader(t('page.productFees.table.header.statutoryFee'), 'right'), cell: currencyCell('fee'), meta: { class: { td: 'w-[170px]' } } }, + { + accessorKey: 'feeGst', + header: textHeader(t('page.productFees.table.header.statutoryFeeGst'), 'right'), + cell: currencyCell('feeGst'), + meta: { + class: { td: 'w-[170px]' } + } + }, { accessorKey: 'serviceCharge', - header: textHeader(t('page.productFees.table.header.serviceCharge'), 'right'), + header: textHeader(t('page.productFees.table.header.serviceFee'), 'right'), cell: currencyCell('serviceCharge'), meta: { class: { td: 'w-[170px]' } } }, { - accessorKey: 'gst', - header: textHeader(t('page.productFees.table.header.gst'), 'right'), - cell: currencyCell('gst'), + accessorKey: 'serviceChargeGst', + header: textHeader(t('page.productFees.table.header.serviceFeeGst'), 'right'), + cell: currencyCell('serviceChargeGst'), meta: { class: { td: 'w-[170px]' } } diff --git a/i18n/locales/en-CA.ts b/i18n/locales/en-CA.ts index 79dc2ad..70bbe39 100644 --- a/i18n/locales/en-CA.ts +++ b/i18n/locales/en-CA.ts @@ -322,9 +322,10 @@ export default { table: { header: { service: 'Description', - fee: 'Fee', - serviceCharge: 'Service Charge', - gst: 'GST', + statutoryFee: 'Statutory Fee', + statutoryFeeGst: 'Statutory Fee GST', + serviceFee: 'Service Fee', + serviceFeeGst: 'Service Fee GST', total: 'Total' } } diff --git a/i18n/locales/fr-CA.ts b/i18n/locales/fr-CA.ts index bcd0150..b8b12fb 100644 --- a/i18n/locales/fr-CA.ts +++ b/i18n/locales/fr-CA.ts @@ -318,9 +318,10 @@ export default { table: { header: { service: 'Service', - fee: 'Frais', - serviceCharge: 'Frais de Service', - gst: 'TPS', + statutoryFee: 'Frais statutaires', + statutoryFeeGst: 'TPS frais statutaires', + serviceFee: 'Frais de service', + serviceFeeGst: 'TPS frais de service', total: 'Total' } } From 4022525a02acdf3ee6f76601ecc4bc09494f686d Mon Sep 17 00:00:00 2001 From: Jia Xu Date: Tue, 10 Mar 2026 14:21:18 -0700 Subject: [PATCH 2/3] 3.0.21 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 63f4591..60bcbe3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "bc-registry", - "version": "3.0.20", + "version": "3.0.21", "private": true, "type": "module", "scripts": { From a0e0e1649548b648d72f1dbd4af61f1e5ee01ad7 Mon Sep 17 00:00:00 2001 From: Jia Xu Date: Tue, 10 Mar 2026 14:33:50 -0700 Subject: [PATCH 3/3] tweaks --- app/pages/product-fees.vue | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/app/pages/product-fees.vue b/app/pages/product-fees.vue index d96d5ae..5be95e1 100644 --- a/app/pages/product-fees.vue +++ b/app/pages/product-fees.vue @@ -26,8 +26,8 @@ interface ProductFee { service: string serviceCharge: number serviceChargeGst: number - total: number | string - variable: boolean + total?: number | string + variable: boolean | null url?: string } @@ -53,7 +53,7 @@ function groupAndTotalProducts(inputProducts: ProductFee[]): GroupedProductFee[] variable } = currentItem - const total = typeof fee === 'string' ? fee : fee + feeGst + serviceCharge + serviceChargeGst + const total = calculateTotal(fee, feeGst, serviceCharge, serviceChargeGst) let serviceString = corpTypeDescription + ' - ' + service if (variable) { @@ -96,6 +96,9 @@ function groupAndTotalProducts(inputProducts: ProductFee[]): GroupedProductFee[] const groupedProducts = computed(() => groupAndTotalProducts(productsRaw.value)) +const calculateTotal = (fee: number | string, feeGst: number, serviceCharge: number, serviceChargeGst: number) => + typeof fee === 'string' ? fee : fee + feeGst + serviceCharge + serviceChargeGst + const formatCurrency = (value: number | null | undefined) => new Intl.NumberFormat('en-CA', { style: 'currency', currency: 'CAD' }) .format(value ?? 0)