Skip to content

Commit

Permalink
21114 - Continuation application (Outputs) (#2780)
Browse files Browse the repository at this point in the history
* 21114 - Output:continuation application

* 21114 - update logic and file names
  • Loading branch information
ketaki-deodhar authored Jun 21, 2024
1 parent aded858 commit a4b57b7
Show file tree
Hide file tree
Showing 8 changed files with 188 additions and 4 deletions.
55 changes: 55 additions & 0 deletions legal-api/report-templates/continuationApplication.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
[[macros.html]]
<!DOCTYPE html>
<html lang="en">
<head>
<title>Continuation Application</title>
<meta charset="UTF-8">
<meta name="author" content="BC Registries and Online Services">
[[common/style.html]]
</head>
<body>
<div class="header">
<table class="header-table" role="presentation">
<tr class="no-page-break">
<td>
[[logo.html]]
</td>
<td>
<div class="report-type">
CONTINUATION APPLICATION
</div>
<div class="report-type-desc">{{ entityDescription }} - {{ entityAct }}</div>
</td>
</tr>
</table>
<div class="business-name-header">
<label class="lbl-business-name">
{% if nameRequest.legalName %}
{{ nameRequest.legalName }}
{% else %}
{{ numberedDescription }}
{% endif %}
</label>
</div>
</div>
[[common/businessDetails.html]]

<div class="section-header mt-5 pt-4">CONTINUATION APPLICATION</div>
<div class="container pt-4">
[[incorporation-application/nameRequest.html]]
[[continuation/effectiveDate.html]]
[[continuation/foreignJurisdiction.html]]
[[continuation/exproRegistrationInBc.html]]
[[continuation/authorization.html]]
[[incorporation-application/completingParty.html]]
</div>
<div class="section-header mt-7 pt-4">NOTICE OF ARTICLES</div>
<div class="container pt-4">
[[common/statement.html]]
[[incorporation-application/benefitCompanyStmt.html]]
[[common/addresses.html]]
[[common/directors.html]]
[[common/shareStructure.html]]
</div>
</body>
</html>
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@
<div class="pt-2">{{filing_date_time}}</div>
<div class="pt-2">{{report_date_time}}</div>
</td>
{% elif header.name in ['incorporationApplication', 'restoration'] %}
{% elif header.name in ['continuationIn', 'incorporationApplication', 'restoration'] %}
<td class="col-33">
{% if header.status == 'COMPLETED' %}
<div class="bold">Incorporation Number:</div>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{% if business.legalType == 'BEN' %}
{% if business.legalType in ['BEN', 'CBEN'] %}
<div class="no-page-break">
<div class="section-title mt-4">BC Benefit Company Statement</div>
<div class="section-data mt-4">
This company is a benefit company and, as such, has purposes that include conducting its
business in a responsible and sustainable manner and promoting one or more public benefits.
</div>
</div>
{% elif business.legalType == 'CC' %}
{% elif business.legalType in ['CC', 'CCC'] %}
<div class="no-page-break">
<div class="section-title mt-4">BC Community Contribution Company Statement</div>
<div class="section-data mt-4">
Expand All @@ -15,7 +15,7 @@
distribute its assets on dissolution or otherwise.
</div>
</div>
{% elif business.legalType == 'ULC' %}
{% elif business.legalType in ['ULC', 'CUL'] %}
<div class="no-page-break">
<div class="section-title mt-4">BC Unlimited Liability Company Statement</div>
<div class="section-data mt-4">
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<div class="no-page-break">
<div class="separator mt-4"></div>
<div class="section-title mt-4">Authorization for Continuation</div>
<table class="section-data nr-name-table mt-4" role="presentation">
<tr>
<td>
The authorization for the continuation into B.C. from the foreign corporation’s jurisdiction was filed.
</td>
</tr>
</table>
</div>
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<div class="no-page-break">
<div class="separator mt-4"></div>
<div class="section-title mt-4">Continuation Effective Date</div>
<div class="section-data mt-4">
{% if header.isFutureEffective %}
{{effective_date_time}}
{% else %}
The incorporation is to take effect at the time that this application is filed with the Registrar.
{% endif %}
</div>
</div>
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{% if exproBusiness %}
<div class="no-page-break">
<div class="separator mt-4"></div>
<div class="section-title mt-4">Extraprovincial Registration in British Columbia</div>
<table class="section-data nr-name-table mt-4" role="presentation">
<tr>
<td class="bold col-33">Registration Number:</td>
<td class="pt-2">
{{exproBusiness.identifier}}
</td>
</tr>
<tr>
<td class="bold col-33">Business Name in B.C.:</td>
<td class="pt-2">
{{exproBusiness.legalName}}
</td>
</tr>
</table>
</div>
{% endif %}
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<div class="no-page-break">
<div class="separator mt-4"></div>
<div class="section-title mt-4">Previous Foreign Jurisdiction Information</div>
<table class="section-data nr-name-table mt-4" role="presentation">
<tr>
<td class="bold col-33">Identifying Number in Foreign Jurisdiction:</td>
<td>
{{foreignJurisdiction.identifier}}
</td>
</tr>
<tr>
<td class="bold pt-2">Name in Foreign Jurisdiction:</td>
<td class="pt-2">
{{foreignJurisdiction.legalName}}
</td>
</tr>
<tr>
<td class="bold pt-2">Foreign Jurisdiction:</td>
<td class="pt-2">
{% if foreignJurisdiction.region %}
{{foreignJurisdiction.region}}
{% else %}
{{foreignJurisdiction.country}}
{% endif %}

</td>
</tr>
<tr>
<td class="bold pt-2">Date of Incorporation, Continuation, or Amalgamation in Foreign Jurisdiction:</td>
<td class="pt-2">
{{foreignJurisdiction.incorporationDate}}
</td>
</tr>
</table>
</div>
52 changes: 52 additions & 0 deletions legal-api/src/legal_api/reports/report.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,10 @@ def _substitute_template_parts(template_code):
'common/businessDetails',
'common/footerMOCS',
'common/directors',
'continuation/authorization',
'continuation/effectiveDate',
'continuation/exproRegistrationInBc',
'continuation/foreignJurisdiction',
'common/completingParty',
'correction/businessDetails',
'correction/addresses',
Expand Down Expand Up @@ -296,6 +300,8 @@ def _format_filing_json(self, filing): # pylint: disable=too-many-branches, too
self._format_amalgamation_data(filing)
elif self._report_key == 'certificateOfAmalgamation':
self._format_certificate_of_amalgamation_data(filing)
elif self._report_key == 'continuationIn':
self._format_continuation_in_data(filing)
else:
# set registered office address from either the COA filing or status quo data in AR filing
with suppress(KeyError):
Expand Down Expand Up @@ -899,6 +905,48 @@ def _format_change_of_registration_data(self, filing, filing_type): # noqa: E50
parties_deleted = [p for p in existing_party_json if p['officer']['id'] not in parties_to_edit]
filing['ceasedParties'] = parties_deleted

def _format_continuation_in_data(self, filing):
self._format_address(filing['continuationIn']['offices']['registeredOffice']['deliveryAddress'])
self._format_address(filing['continuationIn']['offices']['registeredOffice']['mailingAddress'])
if 'recordsOffice' in filing['continuationIn']['offices']:
self._format_address(filing['continuationIn']['offices']['recordsOffice']['deliveryAddress'])
self._format_address(filing['continuationIn']['offices']['recordsOffice']['mailingAddress'])
self._format_directors(filing['continuationIn']['parties'])
# create helper lists
filing['nameRequest'] = filing['continuationIn'].get('nameRequest')
filing['listOfTranslations'] = filing['continuationIn'].get('nameTranslations', [])
filing['offices'] = filing['continuationIn']['offices']
filing['parties'] = filing['continuationIn']['parties']
if filing['continuationIn'].get('shareClasses', None):
filing['shareClasses'] = filing['continuationIn']['shareClasses']
elif 'shareStructure' in filing['continuationIn']:
filing['shareClasses'] = filing['continuationIn']['shareStructure']['shareClasses']

# set expro business
if filing['continuationIn'].get('business'):
filing['exproBusiness'] = filing['continuationIn']['business']

filing['authorization'] = filing['continuationIn'].get('authorization')
filing['foreignJurisdiction'] = filing['continuationIn'].get('foreignJurisdiction')

# set foreign jurisdiction region and country name
foreign_jurisdiction = filing['continuationIn'].get('foreignJurisdiction')
region_code = None
if filing.get('continuationIn').get('foreignJurisdiction').get('region'):
region_code = foreign_jurisdiction['region']
country_code = foreign_jurisdiction['country']
country = pycountry.countries.get(alpha_2=country_code)
region = None
if region_code and region_code.upper() != 'FEDERAL':
region = pycountry.subdivisions.get(code=f'{country_code}-{region_code}')
filing['foreignJurisdiction']['region'] = region.name.upper() if region_code else ''
filing['foreignJurisdiction']['country'] = country.name.upper()

# format incorporation date
incorp_date = \
LegislationDatetime.as_legislation_timezone_from_date_str(foreign_jurisdiction.get('incorporationDate'))
filing['foreignJurisdiction']['incorporationDate'] = incorp_date.strftime(OUTPUT_DATE_FORMAT)

@staticmethod
def _get_party_name(party_json):
party_name = ''
Expand Down Expand Up @@ -1374,6 +1422,10 @@ class ReportMeta: # pylint: disable=too-few-public-methods
'letterOfAgmLocationChange': {
'filingDescription': 'Letter Of AGM Location Change',
'fileName': 'letterOfAgmLocationChange'
},
'continuationIn': {
'filingDescription': 'Continuation Application',
'fileName': 'continuationApplication'
}
}

Expand Down

0 comments on commit a4b57b7

Please sign in to comment.