Browse Source

Merge pull request #134 from bcgov/DIV-1020

DIV-1020: Update Initial Filing page front-end
pull/172/head
Michael Olund 5 years ago
committed by GitHub
parent
commit
1f267ba09b
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
19 changed files with 465 additions and 319 deletions
  1. +14
    -0
      edivorce/apps/core/models.py
  2. +1
    -1
      edivorce/apps/core/static/css/main.css
  3. +30
    -10
      edivorce/apps/core/static/css/main.scss
  4. +23
    -0
      edivorce/apps/core/static/js/filing.js
  5. +2
    -2
      edivorce/apps/core/templates/dashboard/help_saving_pdf.html
  6. +37
    -0
      edivorce/apps/core/templates/dashboard/help_scanning.html
  7. +119
    -32
      edivorce/apps/core/templates/dashboard/initial_filing.html
  8. +8
    -0
      edivorce/apps/core/templates/dashboard/partials/question_incomplete_warning.html
  9. +22
    -28
      edivorce/apps/core/templates/dashboard/print_form.html
  10. +10
    -0
      edivorce/apps/core/templates/partials/tooltips/certificate_of_pleading.html
  11. +1
    -1
      edivorce/apps/core/templates/partials/tooltips/form_desk_order_38.html
  12. +1
    -1
      edivorce/apps/core/templates/partials/tooltips/joint_family_claim.html
  13. +10
    -0
      edivorce/apps/core/templates/partials/tooltips/requisition_form.html
  14. +5
    -2
      edivorce/apps/core/tests/test_storage.py
  15. +54
    -3
      edivorce/apps/core/utils/cso_filing.py
  16. +26
    -9
      edivorce/apps/core/views/main.py
  17. +79
    -81
      vue/package-lock.json
  18. +15
    -12
      vue/src/components/Uploader/Uploader.vue
  19. +8
    -137
      vue/src/pages/initial-filing/InitialFiling.vue

+ 14
- 0
edivorce/apps/core/models.py View File

@ -144,6 +144,18 @@ class Document(models.Model):
date_uploaded = models.DateTimeField(auto_now_add=True)
""" Date the record was last updated """
form_types = {
'AAI': "Agreement as to Annual Income (F9)",
'AFDO': "Affidavit - Desk Order Divorce Form (F38)",
'AFTL': "Affidavit of Translation Form",
'CSA': "Child Support Affidavit (F37)",
'EFSS': "Electronic Filing Statement (F96)",
'MC': "Proof of Marriage",
'NCV': "Identification of Applicant (VSA 512)",
'OFI': "Draft Final Order Form (F52)",
'RDP': "Registration of Joint Divorce Proceedings (JUS280)",
}
class Meta:
unique_together = ("bceid_user", "doc_type", "party_code", "filename", "size")
ordering = ('sort_order',)
@ -156,6 +168,8 @@ class Document(models.Model):
if not self.sort_order:
num_docs = self.get_documents_in_form().count()
self.sort_order = num_docs + 1
if self.doc_type not in self.form_types:
raise ValueError(f"Invalid doc_type '{self.doc_type}'")
super(Document, self).save(*args, **kwargs)


+ 1
- 1
edivorce/apps/core/static/css/main.css
File diff suppressed because it is too large
View File


+ 30
- 10
edivorce/apps/core/static/css/main.scss View File

@ -21,6 +21,7 @@ $color-gold-light: #e6ca85;
$color-red: #D8292F;
$color-red-light: #F7D4D5;
$color-red-dark: #AC2025;
$color-yellow-light: #fcf8e3;
$font-custom: Myriad-Pro, Calibri, Arial, Sans Serif;
$font-custom-bold: Myriad-Pro-Bold, Calibri, Arial, Sans Serif;
@ -370,9 +371,9 @@ div.percent-suffix {
.bg-danger {
position: relative;
padding: 30px 30px 30px 75px;
border-radius: 10px;
border-radius: 8px;
margin-bottom: 20px;
background-color: #fcf8e3;
background-color: $color-yellow-light;
&:after {
content: "\f071";
@ -733,16 +734,26 @@ i.fa.fa-question-circle {
.review-warning {
background-color: $color-red-light;
padding: 20px;
margin: 30px 0;
border-radius: 8px;
display: flex;
.exclamation i {
font-size: 25px;
color: $color-red-dark;
position: relative;
padding: 30px 30px 30px 75px;
margin-bottom: 20px;
ul {
padding-left: 15px;
}
div {
margin: 10px;
&:after {
content: "\f06a";
font-family: FontAwesome;
font-style: normal;
font-weight: normal;
text-decoration: inherit;
position: absolute;
font-size: 24px;
color: $color-red-dark;
top: 30px;
left: 27px;
}
.warning, .progress-status i {
color: $color-red-dark;
@ -1501,10 +1512,19 @@ textarea {
}
.no-bullets {
padding-left: 0;
li {
list-style: none;
}
}
.upload-area {
padding: 32px 20px 32px 20px;
margin-bottom: 50px;
background-color: $color-grey-lightest;
border: 1px solid $color-grey-medium;
border-radius: 8px;
}
}
/* Column Grid in flexbox */


+ 23
- 0
edivorce/apps/core/static/js/filing.js View File

@ -0,0 +1,23 @@
$(window).ready(function () {
$('#submitDocuments').on('click', function (e) {
var missingForms = []
$('div#app').children().each(function (i, child) {
if ($(child).find("div.placeholder").length > 0) {
missingForms.push($(child).find("h5 a").text());
}
})
var errorBox = $('#error-message-box');
if (missingForms.length > 0) {
e.preventDefault();
var messageList = $('#error-messages');
messageList.empty();
missingForms.forEach(function (formName) {
messageList.append(`<li>Missing documents for ${formName}</li>`);
});
errorBox.show();
window.scrollTo(0, 0);
} else {
errorBox.hide();
}
});
});

+ 2
- 2
edivorce/apps/core/templates/dashboard/help_saving_pdf.html View File

@ -15,7 +15,7 @@
&ldquo;Review and Print&rdquo; button next to each form. This will open or
download a PDF version of the form.</p>
<p>&ldquo;PDF&rdquo; stand for Portable Document Format, which is a file
<p>&ldquo;PDF&rdquo; stands for Portable Document Format, which is a file
format created by Adobe and is a standard format for printed documents. A
PDF retains the design and layout of the document so it appears the same
wherever it is viewed or printed.</p>
@ -52,7 +52,7 @@
<div class="question-well">
<h3>Save the forms to your computer</h3>
<p>It's a great idea to save the PDFs of your forms to your computer so
<p>It's a great idea to save the PDFs of your forms to your computer so
you have a backup, and can print it later. You must have Adobe Reader
installed (or Preview on Mac), otherwise, you can
<a href="https://get2.adobe.com/reader/" target="_blank">download it


+ 37
- 0
edivorce/apps/core/templates/dashboard/help_scanning.html View File

@ -0,0 +1,37 @@
{% extends 'base.html' %}
{% block title %}{{ block.super }}: Overview{% endblock %}
{% block progress %}
{% include "partials/dashnav.html" with active_page=active_page %}
{% endblock %}
{% block content %}
<h1>Placeholder</h1>
<div>
<p>
Some content
</p>
</div>
{% endblock %}
{% block backToDashboard %}
<div class="mid_banner-dash">
<a href="{% url 'dashboard_nav' 'initial_filing' %}">
<i class="fa fa-arrow-circle-o-left" aria-hidden="true"></i> View
Application Stages
</a>
</div>
{% endblock %}
{% block formbuttons %}
<!-- no button -->
{% endblock %}
{% block sidebarNav %}
<!-- no sidebarNav -->
{% endblock %}
{% block sidebar %}
<!-- no sidebar -->
{% endblock %}

+ 119
- 32
edivorce/apps/core/templates/dashboard/initial_filing.html View File

@ -5,35 +5,107 @@
{% block progress %}{% include "partials/dashnav.html" with active_page=active_page %}{% endblock %}
{% block container_col %}dashboard-content{% endblock %}
{% block content %}
<h1>Initial Filing</h1>
{% if how_to_file == 'Online' %}
{% if initial_filing_submitted %}
<p>
You have already completed this step.
</p>
<p>
<b>Your {% include "partials/tooltips/online_package_number.html" with with_cso=True %} is {{ initial_filing_package_number }}</b>
</p>
<p class="no-margin-bottom">
You can view the following items at any time:
</p>
<ul>
<li><a href="{{ initial_filing_receipt_link }}" target="_blank">Your eFiling Receipt</a> on the CSO eFiling Hub</li>
<li><a href="{{ initial_filing_package_link }}" target="_blank">The package of all documents</a> you have submitted for filing</li>
</ul>
<p>
In order to complete your divorce you’ll need to file the final set of documents.
To do this you’ll require a {% include "partials/tooltips/court_file_number.html" %}
which will be provided from the Court Registry once they have reviewed and approved
your initial filing. <b>This review can take up to a week to complete.</b>
You'll receive an e-mail with details of your initial filing.
</p>
<p>
If you have any questions, concerns or mistakes about your initial filing, please contact
CSO Online Support at <a href="mailto:Courts.CSO@gov.bc.ca" target="_blank">Courts.CSO@gov.bc.ca</a>
and include your {% include "partials/tooltips/online_package_number.html" %}.
</p>
{% elif how_to_file == 'Online' %}
<div class="review-warning" id="error-message-box" {% if not messages %}hidden{% endif %}>
<ul id="error-messages" class="{% if messages|length == 1 %}no-bullets {% endif %}no-margin-bottom">
{% for message in messages %}
<li>{{ message }}</li>
{% endfor %}
</ul>
</div>
{% if derived.any_errors %}
{% include "dashboard/partials/question_incomplete_warning.html" %}
{% endif %}
<p>
Your filing (submitting completed documents to the court registry) occurs in two parts. The initial filing initiates the divorce
proceeding. Once
initial filing is complete you will receive a Court Filing Number. This number is important as it will allow you or your spouse to file
the
Your filing (submitting completed documents to the court registry) occurs in two parts.
The initial filing initiates the divorce proceeding.
Once initial filing is complete you will receive a Court Filing Number.
This number is important as it will allow you or your spouse to file the
remaining documents required to complete your divorce.
</p>
<p>Missing a form required on this page? Check the <a href="{% url 'dashboard_nav' 'print_form' %}">Review Forms</a> step.</p>
<p><a>Need help with Scanning your documents?</a></p>
<p><b>Missing a form required on this page?</b> Check the <a href="{% url 'dashboard_nav' 'print_form' %}">Review Forms</a> step.</p>
<p><a href="{% url 'dashboard_nav' 'help_scanning' %}">Need help with Scanning your documents?</a></p>
<div id="vue-app">
<initial-filing-uploader
signing-location="{{ signing_location }}"
signing-location-you="{{ signing_location_you }}"
signing-location-spouse="{{ signing_location_spouse }}"
proxy-root-path="{{ proxy_root_path }}">
</initial-filing-uploader>
<div class="upload-area">
{% if how_to_sign == 'Together' and signing_location == 'In-person' %}
<div>
<p>The {% include "partials/tooltips/joint_family_claim.html" with text="Notice of Joint Family Claim Form (F1)" %} will be
automatically filed for you.</p>
</div>
{% elif how_to_sign == 'Separately' and signing_location_you == 'In-person' %}
<div>
<p>The {% include "partials/tooltips/joint_family_claim.html" with text="Notice of Joint Family Claim Form (F1)" %} will be
automatically filed for you.</p>
</div>
{% else %}
<p>The following forms will be automatically filed for you:</p>
<ul>
<li>{% include "partials/tooltips/joint_family_claim.html" with text="Notice of Joint Family Claim Form (F1)" %}</li>
<li>{% include "partials/tooltips/requisition_form.html" %}</li>
<li>{% include "partials/tooltips/certificate_of_pleading.html" %}</li>
</ul>
<p>
The following forms will be submitted for you but
require {% include "partials/tooltips/swear_affirm.html" with text="swearing/affirming" %}
before filing (see next step for details)
</p>
<ul>
<li>{% include "partials/tooltips/form_child_support_37.html" %}</li>
<li>{% include "partials/tooltips/form_desk_order_38.html" %}</li>
</ul>
{% endif %}
<div id="vue-app">
<initial-filing-uploader
:form-types="{{ form_types }}"
proxy-root-path="{{ proxy_root_path }}">
</initial-filing-uploader>
</div>
</div>
<h3>Filing with Court Services Online</h3>
<p>When you click Next, you will be taken to the Court Services Online e-filing hub. In the next few steps you will be able to do a final
review of your filed documentation, pay for your filing and (if completed successfully) receive a Package Number.</p>
<p>Once your filings have been reviewed by the Court Registry (?), you will be provided a Court Filing Number (?) via e-mail. This may
take up
to one week.</p>
<p>You will need your Court Filing Number if you are filing any additional documentation.</p>
<p>
When you click Next, you will be taken to the Court Services Online e-filing hub.
In the next few steps you will be able to do a final review of the documents you are submitting for filing,
pay for your filing and (if completed successfully) receive a Package Number.
</p>
<p>
Once your filings have been reviewed by the {% include "partials/tooltips/court_registry.html" %},
you will be provided a {% include "partials/tooltips/court_file_number.html" %} via e-mail.
This may take up to one week.
</p>
<p>
<b>You will need your Court Filing Number if you are filing any additional documentation.</b>
</p>
{% elif how_to_file == 'In-person' %}
<p>
You don't need to complete this step. Go to <a href="{% url 'dashboard_nav' 'swear_forms' %}">Swear Forms</a> for further instruction.
@ -53,21 +125,35 @@
{% block formbuttons %}
<div class="form-buttons clearfix">
<a class="btn btn-primary" href="{% url 'dashboard_nav' 'print_form' %}"><i class="fa fa-arrow-circle-o-left"></i>&nbsp;&nbsp;&nbsp;Back</a>
{% if initial_filing_submitted %}
<a class="btn btn-success pull-right" href="{% url 'dashboard_nav' 'wait_for_number' %}">Next&nbsp;&nbsp;&nbsp;<i
class="fa fa-arrow-circle-o-right"></i></a>
{% else %}
<a class="btn btn-success pull-right" href="{% url 'dashboard_nav' 'wait_for_number' %}">Next</a>
{% endif %}
<a class="btn btn-primary pull-right save-spinner" href="{% url 'submit_initial_files' %}"><i class="fa fa-floppy-o"></i>&nbsp;&nbsp;&nbsp;
Submit Documents</a>
{% if initial_filing_submitted %}
<a class="btn btn-success pull-right" href="{% url 'dashboard_nav' 'wait_for_number' %}">Next&nbsp;&nbsp;&nbsp;<i
class="fa fa-arrow-circle-o-right"></i></a>
{% else %}
<a class="btn btn-success pull-right" href="{% url 'submit_initial_files' %}" id="submitDocuments">
<i class="fa fa-paper-plane"></i>&nbsp;&nbsp;&nbsp;
Submit Documents</a>
{% endif %}
<a class="btn btn-primary pull-right save-spinner" href="{% url 'overview' %}"><i class="fa fa-floppy-o"></i>&nbsp;&nbsp;&nbsp;Save and return
later</a>
</div>
{% endblock %}
{% block sidebarNav %}
<!-- no sidebar -->
{% endblock %}
{% block sidebarText %}
{% include "dashboard/partials/sidebar_help.html" %}
<h3>What happens with the initial filing?</h3>
<p>
The registry staff will review the documents you have submitted for filing
and providing that all required fields have been properly completed,
they will process the $210.00 fee, assign a file number to the documents
and stamp/seal them.
</p>
<p>
Note: There is an additional $7.00 fee for submitting each package online.
</p>
<p>
You will be notified via email whether your initial filing was accepted or not.
If corrections should be required, you will need to make the corrections identified
and resubmit your initial filing.
</p>
{% endblock %}
{% block extra_css %}
@ -82,4 +168,5 @@
<script type="text/javascript" src="{% static 'dist/vue/js/chunk-vendors.js' %}"></script>
<script type="text/javascript" src="{% static 'dist/vue/js/chunk-common.js' %}"></script>
<script type="text/javascript" src="{% static 'dist/vue/js/initialFiling.js' %}"></script>
<script type="text/javascript" src="{% static 'js/filing.js' %}"></script>
{% endblock %}

+ 8
- 0
edivorce/apps/core/templates/dashboard/partials/question_incomplete_warning.html View File

@ -0,0 +1,8 @@
<div class="information-message bg-danger">
<div>
At least one question in the <a href="{% url 'question_steps' 'review' %}">Questionnaire</a> portion of
this application is incomplete.
Generally, filing incomplete forms will cause your filing to be rejected by the Court Registry.
We recommend you go back to the <a href="{% url 'question_steps' 'review' %}">Questionnaire</a> and complete all pages.
</div>
</div>

+ 22
- 28
edivorce/apps/core/templates/dashboard/print_form.html View File

@ -8,15 +8,7 @@
{% block content %}
<h1>Review and Print your Divorce Forms</h1>
{% if derived.any_errors %}
<div class="review-warning">
<div><span class="exclamation"><i class="fa fa-fw fa-exclamation-circle"></i></span></div>
<div>
At least one question in the <a href="{% url 'question_steps' 'review' %}">Questionnaire</a> portion of
this application is incomplete.
Generally, filing incomplete forms will cause your filing to be rejected by the Court Registry.
We recommend you go back to the <a href="{% url 'question_steps' 'review' %}">Questionnaire</a> and complete all pages.
</div>
</div>
{% include "dashboard/partials/question_incomplete_warning.html" %}
{% endif %}
<p>
To get divorced, you need to get a divorce order. Only the court has the
@ -459,25 +451,27 @@
- Does not require signatures.
">Completed Registration of Divorce form (Federal)<i class="fa fa-question-circle" aria-hidden="true"></i></span>
</li>
{% if name_change_you == 'YES' or name_change_spouse == 'YES' %}
<li>
<span class="tooltip-link" data-toggle="tooltip" data-placement="right"
data-html="true"
title="
<b>Identification of Applicant (VSA 512)</b>
<br /><br />
This form is used by the Court to notify Vital Statistics of court-ordered legal changes of name.
<br /><br />
- Does not require signatures.
">Completed Identification of Applicant (VSA 512)<i class="fa fa-question-circle" aria-hidden="true"></i></span>
for anyone requesting a name change
<ul>
{% if name_change_you == 'YES' %}
<li>Claimant 1 ({% you_name %})</li>{% endif %}
{% if name_change_spouse == 'YES' %}
<li>Claimant 2 ({% spouse_name %})</li>{% endif %}
</ul>
</li>
{% if derived.wants_other_orders %}
{% if name_change_you == 'YES' or name_change_spouse == 'YES' %}
<li>
<span class="tooltip-link" data-toggle="tooltip" data-placement="right"
data-html="true"
title="
<b>Identification of Applicant (VSA 512)</b>
<br /><br />
This form is used by the Court to notify Vital Statistics of court-ordered legal changes of name.
<br /><br />
- Does not require signatures.
">Completed Identification of Applicant (VSA 512)<i class="fa fa-question-circle" aria-hidden="true"></i></span>
for anyone requesting a name change
<ul>
{% if name_change_you == 'YES' %}
<li>Claimant 1 ({% you_name %})</li>{% endif %}
{% if name_change_spouse == 'YES' %}
<li>Claimant 2 ({% spouse_name %})</li>{% endif %}
</ul>
</li>
{% endif %}
{% endif %}
{% if derived.has_children_of_marriage %}
<li>


+ 10
- 0
edivorce/apps/core/templates/partials/tooltips/certificate_of_pleading.html View File

@ -0,0 +1,10 @@
<span class="tooltip-link" data-toggle="{% if hover %}tooltip-hover{% else %}tooltip{% endif %}" data-placement="right"
data-html="true"
title="
<b>Certificate of Pleadings Form (F36)</b>
<br /><br />
This form is completed by registry staff after your application has been reviewed by them.
It shows the judge that your application has been checked and is complete.
<br /><br />
- Does not require signatures when filed online.">
Certificate of Pleadings Form (F36)<i class="fa fa-question-circle" aria-hidden="true"></i></span>

+ 1
- 1
edivorce/apps/core/templates/partials/tooltips/form_desk_order_38.html View File

@ -5,4 +5,4 @@
<br /><br />
This form sets out all the facts of your marriage and separation for the court and gives information about parenting time if you have children.
It requires swearing/affirming and signatures by both you and your spouse in front of a commissioner.">
Affidavit — Desk Order Divorce (Form 38)<i class="fa fa-question-circle" aria-hidden="true"></i></span>
Affidavit — Desk Order Divorce Form (F38)<i class="fa fa-question-circle" aria-hidden="true"></i></span>

+ 1
- 1
edivorce/apps/core/templates/partials/tooltips/joint_family_claim.html View File

@ -6,4 +6,4 @@
This form starts your divorce proceeding. It gives the court details about you and your spouse, your marriage and separation, and what you're asking the court for.
<br /><br />
- Does not require signatures when filed online.">
Notice of Joint Family Claim<i class="fa fa-question-circle" aria-hidden="true"></i></span>
{% if text %}{{ text }}{% else %}Notice of Joint Family Claim{% endif %}<i class="fa fa-question-circle" aria-hidden="true"></i></span>

+ 10
- 0
edivorce/apps/core/templates/partials/tooltips/requisition_form.html View File

@ -0,0 +1,10 @@
<span class="tooltip-link" data-toggle="{% if hover %}tooltip-hover{% else %}tooltip{% endif %}" data-placement="right"
data-html="true"
title="
<b>Requisition Form (F35)</b>
<br /><br />
This form is a request to the Court for your application for divorce.
It tells the court that you want a divorce and outlines all the documents you are filing in support of your application.
<br /><br />
- Does not require signatures when filed online.">
Requisition Form (F35)<i class="fa fa-question-circle" aria-hidden="true"></i></span>

+ 5
- 2
edivorce/apps/core/tests/test_storage.py View File

@ -23,6 +23,7 @@ class UploadStorageTests(TransactionTestCase):
file = SimpleUploadedFile('file.txt', b'this is some content')
test = Document()
test.file = file
test.doc_type = 'MC'
test.bceid_user = self.user
test.save()
except ConnectionError:
@ -40,6 +41,7 @@ class UploadStorageTests(TransactionTestCase):
file = SimpleUploadedFile('file.txt', b'this is some content')
test = Document()
test.file = file
test.doc_type = 'MC'
test.bceid_user = self.user
test.save()
@ -55,6 +57,7 @@ class UploadStorageTests(TransactionTestCase):
file = SimpleUploadedFile('file.txt', b'this is some content')
test = Document()
test.file = file
test.doc_type = 'MC'
test.bceid_user = self.user
test.save()
@ -90,11 +93,11 @@ class UploadStorageTests(TransactionTestCase):
file = SimpleUploadedFile('file.txt', b'this is some content')
test = Document()
test.bceid_user = self.user
test.file = file
test.doc_type = 'MC'
test.bceid_user = self.user
test.save()
test.delete()
self.assertTrue(mock_redis_delete.called)

+ 54
- 3
edivorce/apps/core/utils/cso_filing.py View File

@ -2,11 +2,22 @@ import random
from django.conf import settings
from edivorce.apps.core.models import UserResponse
from edivorce.apps.core.models import Document, UserResponse
from edivorce.apps.core.utils.derived import get_derived_data
def file_documents(user, initial=False):
""" Save dummy data for now. Eventually replace with data from CSO. """
def file_documents(user, responses, initial=False):
forms = forms_to_file(responses, initial)
missing_forms = []
for form in forms:
docs = Document.objects.filter(bceid_user=user, doc_type=form['doc_type'], party_code=form.get('party_code', 0))
if docs.count() == 0:
missing_forms.append(Document.form_types[form['doc_type']])
if missing_forms:
return missing_forms
# Save dummy data for now. Eventually replace with data from CSO
prefix = 'initial' if initial else 'final'
_save_response(user, f'{prefix}_filing_submitted', True)
@ -39,3 +50,43 @@ def _save_response(user, question, value):
response, _ = UserResponse.objects.get_or_create(bceid_user=user, question_id=question)
response.value = value
response.save()
def forms_to_file(responses_dict, initial=False):
forms = []
derived = responses_dict.get('derived', get_derived_data(responses_dict))
if initial:
forms.append({'doc_type': 'MC', 'party_code': 0})
how_to_sign = responses_dict.get('how_to_sign')
signing_location_both = responses_dict.get('signing_location') if how_to_sign == 'Together' else None
signing_location_you = responses_dict.get('signing_location_you') if how_to_sign == 'Separately' else None
signing_location_spouse = responses_dict.get('signing_location_spouse') if how_to_sign == 'Separately' else None
if signing_location_both == 'In-person' or signing_location_you == 'In-person':
forms.append({'doc_type': 'AFTL', 'party_code': 0})
forms.append({'doc_type': 'RDP', 'party_code': 0})
elif signing_location_you == 'Virtual' and signing_location_spouse == 'In-person':
forms.append({'doc_type': 'AFTL', 'party_code': 0})
forms.append({'doc_type': 'OFI', 'party_code': 0})
forms.append({'doc_type': 'EFSS', 'party_code': 1})
forms.append({'doc_type': 'RDP', 'party_code': 0})
if derived['has_children_of_marriage']:
forms.append({'doc_type': 'AAI', 'party_code': 0})
if derived['wants_other_orders'] and responses_dict.get('name_change_you') == 'YES':
forms.append({'doc_type': 'NCV', 'party_code': 1})
elif signing_location_both == 'Virtual' or (signing_location_you == 'Virtual' and signing_location_spouse == 'Virtual'):
forms.append({'doc_type': 'AFTL', 'party_code': 0})
forms.append({'doc_type': 'OFI', 'party_code': 0})
forms.append({'doc_type': 'EFSS', 'party_code': 1})
forms.append({'doc_type': 'EFSS', 'party_code': 2})
forms.append({'doc_type': 'RDP', 'party_code': 0})
if derived['has_children_of_marriage']:
forms.append({'doc_type': 'AAI', 'party_code': 0})
if derived['wants_other_orders'] and responses_dict.get('name_change_you') == 'YES':
forms.append({'doc_type': 'NCV', 'party_code': 1})
if derived['wants_other_orders'] and responses_dict.get('name_change_spouse') == 'YES':
forms.append({'doc_type': 'NCV', 'party_code': 2})
else:
return []
return forms

+ 26
- 9
edivorce/apps/core/views/main.py View File

@ -1,6 +1,7 @@
import datetime
from django.conf import settings
from django.contrib import messages
from django.shortcuts import render, redirect
from django.urls import reverse
from django.utils import timezone
@ -8,7 +9,7 @@ from django.contrib.auth.decorators import login_required
from edivorce.apps.core.utils.derived import get_derived_data
from ..decorators import intercept, prequal_completed
from ..utils.cso_filing import file_documents
from ..utils.cso_filing import file_documents, forms_to_file
from ..utils.question_step_mapping import list_of_registries
from ..utils.step_completeness import get_error_dict, get_missed_question_keys, get_step_completeness, is_complete, get_formatted_incomplete_list
from ..utils.template_step_order import template_step_order
@ -179,11 +180,23 @@ def dashboard_nav(request, nav_step):
if nav_step in ('print_form', 'swear_forms', 'next_steps') and responses_dict.get('court_registry_for_filing'):
responses_dict['court_registry_for_filing_address'] = f"123 {responses_dict.get('court_registry_for_filing')} St"
responses_dict['court_registry_for_filing_postal_code'] = 'V0A 1A1'
if nav_step in ('print_form',):
if nav_step in ('print_form', 'initial_filing'):
responses_dict_by_step = get_step_responses(responses_dict)
responses_dict.update(get_error_dict(responses_dict_by_step))
responses_dict['derived'] = get_derived_data(responses_dict)
if nav_step == 'initial_filing':
forms = forms_to_file(responses_dict, initial=True)
responses_dict['form_types'] = forms
if request.GET.get('cancelled'):
messages.add_message(request, messages.ERROR,
'You have cancelled the filing of your documents. '
'You can complete the filing process at your convenience.')
elif request.GET.get('no_connection'):
messages.add_message(request, messages.ERROR,
'The connection to the BC Government’s eFiling Hub is currently not working. '
'This is a temporary problem. '
'Please try again now and if this issue persists try again later.')
return render(request, template_name=template_name, context=responses_dict)
@ -202,14 +215,18 @@ def submit_final_files(request):
def _submit_files(request, initial=False):
responses_dict = get_data_for_user(request.user)
if initial:
nav_step = 'wait_for_number'
file_documents(request.user, initial=True)
original_step = 'initial_filing'
next_page = 'wait_for_number'
else:
nav_step = 'next_steps'
file_documents(request.user, initial=False)
responses_dict['active_page'] = nav_step
return redirect(reverse('dashboard_nav', kwargs={'nav_step': nav_step}), context=responses_dict)
original_step = 'final_filing'
next_page = 'next_steps'
missing_forms = file_documents(request.user, responses_dict, initial=initial)
if missing_forms:
next_page = original_step
for form_name in missing_forms:
messages.add_message(request, messages.ERROR, f'Missing documents for {form_name}')
responses_dict['active_page'] = next_page
return redirect(reverse('dashboard_nav', kwargs={'nav_step': next_page}), context=responses_dict)
@login_required


+ 79
- 81
vue/package-lock.json View File

@ -1687,6 +1687,16 @@
"integrity": "sha512-+G7P8jJmCHr+S+cLfQxygbWhXy+8YTVGzAkpEbcLo2mLoL7tij/VG41QSHACSf5QgYRhMZYHuNc6drJaO0Da+w==",
"dev": true
},
"ansi-styles": {
"version": "4.3.0",
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
"integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
"dev": true,
"optional": true,
"requires": {
"color-convert": "^2.0.1"
}
},
"cacache": {
"version": "13.0.1",
"resolved": "https://registry.npmjs.org/cacache/-/cacache-13.0.1.tgz",
@ -1713,6 +1723,34 @@
"unique-filename": "^1.1.1"
}
},
"chalk": {
"version": "4.1.0",
"resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz",
"integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==",
"dev": true,
"optional": true,
"requires": {
"ansi-styles": "^4.1.0",
"supports-color": "^7.1.0"
}
},
"color-convert": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
"integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
"dev": true,
"optional": true,
"requires": {
"color-name": "~1.1.4"
}
},
"color-name": {
"version": "1.1.4",
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
"dev": true,
"optional": true
},
"find-cache-dir": {
"version": "3.3.1",
"resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-3.3.1.tgz",
@ -1734,6 +1772,25 @@
"path-exists": "^4.0.0"
}
},
"has-flag": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
"integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
"dev": true,
"optional": true
},
"loader-utils": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.0.tgz",
"integrity": "sha512-rP4F0h2RaWSvPEkD7BLDFQnvSf+nK+wr3ESUjNTyAGobqrijmW92zc+SO6d4p4B1wh7+B/Jg1mkQe5NYUEHtHQ==",
"dev": true,
"optional": true,
"requires": {
"big.js": "^5.2.2",
"emojis-list": "^3.0.0",
"json5": "^2.1.2"
}
},
"locate-path": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz",
@ -1798,6 +1855,16 @@
"minipass": "^3.1.1"
}
},
"supports-color": {
"version": "7.2.0",
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
"integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
"dev": true,
"optional": true,
"requires": {
"has-flag": "^4.0.0"
}
},
"terser-webpack-plugin": {
"version": "2.3.8",
"resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-2.3.8.tgz",
@ -1814,6 +1881,18 @@
"terser": "^4.6.12",
"webpack-sources": "^1.4.3"
}
},
"vue-loader-v16": {
"version": "npm:vue-loader@16.0.0-beta.8",
"resolved": "https://registry.npmjs.org/vue-loader/-/vue-loader-16.0.0-beta.8.tgz",
"integrity": "sha512-oouKUQWWHbSihqSD7mhymGPX1OQ4hedzAHyvm8RdyHh6m3oIvoRF+NM45i/bhNOlo8jCnuJhaSUf/6oDjv978g==",
"dev": true,
"optional": true,
"requires": {
"chalk": "^4.1.0",
"hash-sum": "^2.0.0",
"loader-utils": "^2.0.0"
}
}
}
},
@ -10956,87 +11035,6 @@
}
}
},
"vue-loader-v16": {
"version": "npm:vue-loader@16.0.0-beta.8",
"resolved": "https://registry.npmjs.org/vue-loader/-/vue-loader-16.0.0-beta.8.tgz",
"integrity": "sha512-oouKUQWWHbSihqSD7mhymGPX1OQ4hedzAHyvm8RdyHh6m3oIvoRF+NM45i/bhNOlo8jCnuJhaSUf/6oDjv978g==",
"dev": true,
"optional": true,
"requires": {
"chalk": "^4.1.0",
"hash-sum": "^2.0.0",
"loader-utils": "^2.0.0"
},
"dependencies": {
"ansi-styles": {
"version": "4.3.0",
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
"integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
"dev": true,
"optional": true,
"requires": {
"color-convert": "^2.0.1"
}
},
"chalk": {
"version": "4.1.0",
"resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.0.tgz",
"integrity": "sha512-qwx12AxXe2Q5xQ43Ac//I6v5aXTipYrSESdOgzrN+9XjgEpyjpKuvSGaN4qE93f7TQTlerQQ8S+EQ0EyDoVL1A==",
"dev": true,
"optional": true,
"requires": {
"ansi-styles": "^4.1.0",
"supports-color": "^7.1.0"
}
},
"color-convert": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
"integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
"dev": true,
"optional": true,
"requires": {
"color-name": "~1.1.4"
}
},
"color-name": {
"version": "1.1.4",
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
"dev": true,
"optional": true
},
"has-flag": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
"integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
"dev": true,
"optional": true
},
"loader-utils": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-2.0.0.tgz",
"integrity": "sha512-rP4F0h2RaWSvPEkD7BLDFQnvSf+nK+wr3ESUjNTyAGobqrijmW92zc+SO6d4p4B1wh7+B/Jg1mkQe5NYUEHtHQ==",
"dev": true,
"optional": true,
"requires": {
"big.js": "^5.2.2",
"emojis-list": "^3.0.0",
"json5": "^2.1.2"
}
},
"supports-color": {
"version": "7.2.0",
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
"integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
"dev": true,
"optional": true,
"requires": {
"has-flag": "^4.0.0"
}
}
}
},
"vue-style-loader": {
"version": "4.1.2",
"resolved": "https://registry.npmjs.org/vue-style-loader/-/vue-style-loader-4.1.2.tgz",


+ 15
- 12
vue/src/components/Uploader/Uploader.vue View File

@ -5,8 +5,8 @@
<a href="javascript:void(0)" :id="'Tooltip-' + uniqueId">
{{ formDef.name }} <i class="fa fa-question-circle"></i>
</a>
<strong v-if="party === 1"> - For You</strong>
<strong v-if="party === 2"> - For Your Spouse</strong>
<span v-if="party === 1"> - For You</span>
<span v-if="party === 2"> - For Your Spouse</span>
</h5>
<tooltip :text="formDef.help" :target="'#Tooltip-' + uniqueId"></tooltip>
<label :for="inputId" class="sr-only">
@ -96,12 +96,13 @@
</template>
</file-upload>
</div>
<div class="pull-right" v-if="!tooBig">
<div class="pull-left">
<a v-if="files.length" :href="pdfURL" target="_blank">{{ pdfURL }}</a>
</div>
<div class="text-right" v-if="!tooBig">
<em>(Maximum {{ maxMegabytes }} MB)</em>
</div>
<a v-if="files.length" :href="pdfURL" target="_blank">{{ pdfURL }}</a>
<modal ref="warningModal" class="warning-modal" v-model="showWarning">
{{ warningText }}
</modal>
@ -267,7 +268,7 @@
});
},
});
}
}
else {
newFile.compressed = true;
}
@ -550,9 +551,9 @@
width: 100%;
display: block;
text-align: left;
border: 2px #365ebe dashed;
border-radius: 6px;
padding: 18px 32px 0 18px;
border: 1px #365ebe dashed;
border-radius: 8px;
padding: 20px 32px 0 24px;
margin-bottom: 5px;
&.dragging {
@ -600,10 +601,12 @@
h5.uploader-label {
display: block;
margin-top: 30px;
margin-bottom: 10px;
margin-top: 20px;
margin-bottom: 20px;
font-weight: normal;
font-size: 1em;
font-size: 21px;
color: #365ebe;
text-decoration: underline;
a {
font-weight: bold;


+ 8
- 137
vue/src/pages/initial-filing/InitialFiling.vue View File

@ -1,137 +1,9 @@
<template>
<div class="question-well-border-less" id="app">
<template
v-if="
signingLocation === 'In-person' || signingLocationYou === 'In-person'
"
>
<div>
<div id="app">
<template v-for="item in formTypes">
<div>
<p>
The Notice of Joint Family Claim Form (F1) will be automatically
filed for you.
</p>
<Uploader v-bind:doc-type="item.doc_type" :party="item.party_code"/>
</div>
<div>
<!-- MC - Marriage Certificate -->
<Uploader doc-type="MC" />
</div>
<div>
<!-- AFTL - Affidavit of Translator -->
<Uploader doc-type="AFTL" />
</div>
<div>
<!-- RDP - Registration of Divorce Proceeding -->
<Uploader doc-type="RDP" />
</div>
</div>
</template>
<template
v-else-if="
signingLocationYou === 'Virtual' &&
signingLocationSpouse === 'In-person'
"
>
<div>
<p>The following forms will be automatically filed for you:</p>
<ul>
<li>Notice of Joint Family Claim Form (F1)</li>
<li>Requisition Form (F35)</li>
<li>Certificate of Pleadings Form (F36)</li>
</ul>
<p>
The following forms will be submitted for you but require swearing /
affirming <i class="fa fa-question-circle"></i> before filing (see
next step for details)
</p>
<ul>
<li>Child Support Affidavit (F37)</li>
<li>Affidavit - Desk Order Divorce Form (F38)</li>
</ul>
<div>
<!-- MC - Marriage Certificate -->
<Uploader doc-type="MC" />
</div>
<div>
<!-- AFTL - Affidavit of Translator -->
<Uploader doc-type="AFTL" />
</div>
<div>
<!-- OFI - Final Order (F52) -->
<Uploader doc-type="OFI" />
</div>
<div>
<!-- EFSS - Electronic Filing Statement - Supreme (F96) -->
<Uploader doc-type="EFSS" :party="1" />
</div>
<div>
<!-- RDP - Registration of Divorce Proceeding -->
<Uploader doc-type="RDP" />
</div>
<div>
<!-- AAI - Agreement as to Annual Income (F9) -->
<Uploader doc-type="AAI" />
</div>
<div>
<!-- NCV Name Change Form Vital Statistics -->
<Uploader doc-type="NCV" :party="1" />
</div>
</div>
</template>
<template v-else>
<div>
<p>The following forms will be automatically filed for you:</p>
<ul>
<li>Notice of Joint Family Claim Form (F1)</li>
<li>Requisition Form (F35)</li>
<li>Certificate of Pleadings Form (F36)</li>
</ul>
<p>
The following forms will be submitted for you but require swearing /
affirming <i class="fa fa-question-circle"></i> before filing (see
next step for details)
</p>
<ul>
<li>Child Support Affidavit (F37)</li>
<li>Affidavit - Desk Order Divorce Form (F38)</li>
</ul>
<div>
<!-- MC - Marriage Certificate -->
<Uploader doc-type="MC" />
</div>
<div>
<!-- AFTL - Affidavit of Translator -->
<Uploader doc-type="AFTL" />
</div>
<div>
<!-- OFI - Final Order (F52) -->
<Uploader doc-type="OFI" />
</div>
<div>
<!-- EFSS - Electronic Filing Statement - Supreme (F96) -->
<Uploader doc-type="EFSS" :party="1" />
</div>
<div>
<!-- EFSS - Electronic Filing Statement - Supreme (F96) -->
<Uploader doc-type="EFSS" :party="2" />
</div>
<div>
<!-- RDP - Registration of Divorce Proceeding -->
<Uploader doc-type="RDP" />
</div>
<div>
<!-- AAI - Agreement as to Annual Income (F9) -->
<Uploader doc-type="AAI" />
</div>
<div>
<!-- NCV Name Change Form Vital Statistics -->
<Uploader doc-type="NCV" :party="1" />
</div>
<div>
<!-- NCV Name Change Form Vital Statistics -->
<Uploader doc-type="NCV" :party="2" />
</div>
</div>
</template>
</div>
</template>
@ -145,19 +17,18 @@
Uploader,
},
props: {
signingLocation: String,
signingLocationYou: String,
signingLocationSpouse: String,
formTypes: Array,
proxyRootPath: String,
},
};
</script>
<style scoped lang="scss">
.question-well-border-less {
padding: 10px 20px 30px 20px;
.upload-area {
padding: 32px 20px 32px 20px;
margin-bottom: 50px;
background-color: #f2f2f2;
border: 1px solid #ddd;
border-radius: 6px;
border-radius: 8px;
}
</style>

Loading…
Cancel
Save