bcgov / entity

ServiceBC Registry Team working on Legal Entities
Apache License 2.0
23 stars 57 forks source link

API - Cancel Transport Permit #19004

Closed mstanton1 closed 1 week ago

mstanton1 commented 5 months ago

UI Design:https://www.figma.com/file/fCRMmkSloLFnb0WK5WR6mS/Transport-Permits?type=design&node-id=766-42433&mode=design&t=7VFCoi31wim1rc4u-0

Developer Note: Use existing admin-registrations endpoint, allow for non-staff for the CANCEL_PERMIT document type.

Comment history retained, scroll to after April 20, 2024 for active comments.

doug-lovett commented 5 months ago

Request example: updateDocumentId must be the document ID of the permit registration that is to be cancelled. POST https://bcregistry-dev.apigee.net/mhr/api/v1/admin-registrations/107899 { "clientReferenceId": "UT-CANCEL-PERMIT-001", "attentionReference": "JACK JOHNSON", "updateDocumentId": "80888261", "documentId": "89888263", "documentType": "CANCEL_PERMIT", "submittingParty": { "businessName": "ABC TEST COMPANY", "address": { "street": "222 SUMMER STREET", "city": "VICTORIA", "region": "BC", "country": "CA", "postalCode": "V8W 2V8" }, "emailAddress": "bsmith@abc-test.com" }, "location": { "locationType": "MH_PARK", "parkName": "GALLAGHER LAKE VILLAGE PARK", "pad": "114", "address": { "street": "8300 GALLAGHER LK FRONTAGE RD", "city": "PARKSVILLE", "region": "BC", "country": "CA", "postalCode": " " }, "leaveProvince": false, "taxCertificate": true, "taxExpiryDate": "2024-01-20T08:01:00+00:00" } }

doug-lovett commented 5 months ago

@LizGovier report example: registration-staff-example.pdf

chdivyareddy commented 5 months ago

Hey @doug-lovett , little confused on the Document registration number here, in the postman response for MHR 107937 in DEV, the "documentRegistrationNumber": "00502198", and in the output it is displayed as "00502199". Am I missing something here? Can you please take a look, thanks!!

image.png

Output:

image.png

2023-12-20_BCMHR_Registration_107937.pdf

doug-lovett commented 5 months ago

@chdivyareddy The report and response are correct: The transport permit document reg number is 00502198. The cancel permit document reg number is 00502199. The note returned in the cancel permit registration is for the original transport permit and is included for the report transport permit information. The cancel permit document reg number is in the root of the response, not in the note: { "mhrNumber": "107937", "createDateTime": "2023-12-20T22:40:55+00:00", "registrationType": "REG_STAFF_ADMIN", "status": "ACTIVE", "documentDescription": "CANCEL TRANSPORT PERMIT", "documentId": "12846394", "documentRegistrationNumber": "00502199", "clientReferenceId": "UT-CANCEL-PERMIT-001", "attentionReference": "JACK JOHNSON", "submittingParty": { "businessName": "ABC TEST COMPANY", "address": { "street": "222 SUMMER STREET", "city": "VICTORIA", "region": "BC", "country": "CA", "postalCode": "V8W 2V8" }, "emailAddress": "bsmith@abc-test.com" }, "documentType": "CANCEL_PERMIT", "note": { "documentId": "12846398", "documentType": "REG_103", "status": "CANCELLED", "remarks": "", "createDateTime": "2023-12-20T22:33:23+00:00", "documentDescription": "TRANSPORT PERMIT", "documentRegistrationNumber": "00502198", "expiryDateTime": "2024-01-19T00:00:00+00:00", "cancelledDocumentType": "REG_103", "cancelledDocumentDescription": "TRANSPORT PERMIT", "cancelledDocumentRegistrationNumber": "00502198" }, "location": { "locationId": 198910, "status": "ACTIVE", "locationType": "MH_PARK", "address": { "street": "8300 GALLAGHER LK FRONTAGE RD", "city": "PARKSVILLE", "region": "BC", "country": "CA", "postalCode": "" }, "parkName": "GALLAGHER LAKE VILLAGE PARK", "pad": "114", "leaveProvince": false, "taxCertificate": true, "taxExpiryDate": "2024-01-25T08:01:00+00:00" }, "hasCaution": false, "payment": { "invoiceId": "33041", "receipt": "/api/v1/payment-requests/33041/receipts" }, "usergroup": "ppr_staff", "username": "Business Registry Test 1", "ownerGroups": [ { "groupId": 1, "type": "NA", "status": "ACTIVE", "interest": "UNDIVIDED", "interestNumerator": 1, "interestDenominator": 2, "tenancySpecified": true, "owners": [ { "type": "JOINT", "individualName": { "first": "WERWER", "last": "WERWE" }, "address": { "city": "EDSON", "street": "55-851 63 ST", "region": "AB", "country": "CA", "postalCode": "T7E 0A2" }, "partyType": "EXECUTOR", "description": "EXECUTOR OF THE WILL OF SUE SMITH", "ownerId": 1 }, { "type": "JOINT", "individualName": { "first": "DFGDFG", "last": "DFGDFG" }, "address": { "city": "EDMONTON", "street": "44-6608 158 AVE NW", "region": "AB", "country": "CA", "postalCode": "T5Z 3H2" }, "partyType": "EXECUTOR", "description": "EXECUTOR OF THE WILL OF SUE SMITH", "ownerId": 2 } ] }, { "groupId": 2, "type": "NA", "status": "ACTIVE", "interest": "UNDIVIDED", "interestNumerator": 1, "interestDenominator": 2, "tenancySpecified": true, "owners": [ { "type": "COMMON", "individualName": { "first": "SSAS", "last": "ASAS" }, "address": { "city": "LONDON", "street": "66-50 FIDDLERS GREEN RD", "region": "ON", "country": "CA", "postalCode": "N6H 4T4" }, "partyType": "EXECUTOR", "description": "OWNER_IND EXECUTOR OF THE WILL OF SUE SMITH", "ownerId": 3 } ] } ] }

LizGovier commented 5 months ago

Thanks @doug-lovett ! This looks great so far. The design is still in process so will probably have some updates in the new year. /cc @chdivyareddy

chdivyareddy commented 5 months ago

@doug-lovett , thanks for confirming!

Verified!

image.png
LizGovier commented 3 weeks ago

Hey team! Please add your planning poker estimate with Zenhub @cameron-eyds @chdivyareddy @dimak1 @doug-lovett

arlentees commented 3 weeks ago

Update - we reviewed this with Sharon, and the detailed the following scenario: If a home is exempt due to an out of province location, then is re-registered and made active for the purpose of creating a transport permit, then that permit is cancelled, the request from staff is to keep the registration active and then to manually exempt the home at a later date if a new transport permit is not issued.

The reasoning behind this is to prevent new decals from being distributed at the point of re-registering and re-issuing a permit, which is seen by staff as a riskier outcome than simply having homes with out of province locations staying active for a period of time.

doug-lovett commented 3 weeks ago

Cancel Permit API request example: POST /mhr/api/v1/admin-registrations/099039

{
  "clientReferenceId": "UT-CANCEL-PERMIT",
  "attentionReference": "JAMES IRVING",
  "documentId": "80888391",
  "documentType": "CANCEL_PERMIT",
  "submittingParty": {
    "businessName": "ABC TEST COMPANY",
    "address": {
      "street": "222 SUMMER STREET",
      "city": "VICTORIA",
      "region": "BC",
      "country": "CA",
      "postalCode": "V8W 2V8"
    },
    "emailAddress": "test1@abc-ut.com"
  }
}
doug-lovett commented 3 weeks ago

Sample report attached below: registration-staff-example.pdf

doug-lovett commented 2 weeks ago

Verified in DEV with 108310.

chdivyareddy commented 1 week ago

Verified in DEV!

MHR 108314 2024-05-07_BCMHR_Registration_108314.pdf