Skip to content

Conversation

@Rajandeep98
Copy link
Collaborator

@Rajandeep98 Rajandeep98 commented Jan 13, 2026

Issue #: /bcgov/entity#31921
/bcgov/entity#31924

Description of changes:
Dissolution Completing Party Check

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of the lear license (Apache 2.0).

@Rajandeep98 Rajandeep98 changed the title 31921 - Dissolution Compelting Party 31921 - Dissolution Completing Party Jan 13, 2026
@Rajandeep98 Rajandeep98 marked this pull request as ready for review January 14, 2026 16:12
Comment on lines 483 to 485
document_optional_email = dissolution.get("filing", {}).get("header", {}).get("documentOptionalEmail")
if document_optional_email and account_id:
email_validation_result = validate_document_delivery_email_changed(document_optional_email, int(account_id))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure about this validation, documentOptionalEmail is used to provide the user email if a staff is filing. Does the UI loads this value by default (and not editable)?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

its pre-populates as completingparty email then if edited goes in header as document optional email and users shows not editable prepopulated

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is it for staff or a user?

Copy link
Collaborator Author

@Rajandeep98 Rajandeep98 Jan 15, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is for user for staff its editable, but that can be determined by if they have permission for edit completing party

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds completing party validation and permission checks for dissolution filings. It ensures that when completing party information is changed (email, name, or address), appropriate permissions are validated for SOLE_PROP and PARTNERSHIP business types.

Changes:

  • Added completing party validation logic to dissolution filing validation
  • Updated feature flag reference in good standing permission check
  • Introduced new function to validate both permissions and completing party information

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.

File Description
dissolution.py Added completing party validation with permission checks for dissolution filings; created new function _validate_permission_and_completing_party to handle validation logic
common_validations.py Updated feature flag name from "enable-list-actions-permissions" to "enabled-deeper-permission-action" and fixed trailing whitespace

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Rajandeep98
Copy link
Collaborator Author

Adding unit test

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 5 comments.

Comments suppressed due to low confidence (1)

legal-api/src/legal_api/services/filings/validations/common_validations.py:1

  • Dictionary formatting is inconsistent with spacing. Add a space after the colon for each key-value pair to follow Python style conventions (e.g., 'check_name': True).
# Copyright © 2019 Province of British Columbia

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

"""Test suite to ensure Voluntary Dissolution is validated correctly."""
import copy
from datetime import datetime, timedelta
from email.policy import default
Copy link

Copilot AI Jan 15, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The import from email.policy import default is unused in this file. This import should be removed as it serves no purpose and may cause confusion.

Suggested change
from email.policy import default

Copilot uses AI. Check for mistakes.
Rajandeep98 and others added 4 commits January 15, 2026 10:19
…tion.py

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…lidations.py

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…tion.py

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…on.py

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@Rajandeep98 Rajandeep98 self-assigned this Jan 15, 2026
@Rajandeep98 Rajandeep98 requested a review from argush3 January 15, 2026 21:58
@Rajandeep98 Rajandeep98 merged commit 79cdc5a into bcgov:main Jan 15, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants