Skip to content

Commit f79778f

Browse files
Efsp integration updates (#306)
Mostly adds defaults values and questions that had been set in the Petition to Seal Eviction or the Motion to Stay Eviction e-filing interviews that we want to share across interviews. Does also ask for `is_initial_filing` in the efiling check part, ask that value is required for the EfileProxyServer vetting process.
1 parent d6b8747 commit f79778f

2 files changed

Lines changed: 71 additions & 2 deletions

File tree

docassemble/EFSPIntegration/data/questions/efiling_integration.yml

Lines changed: 70 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -222,6 +222,7 @@ need:
222222
id: ready_to_efile
223223
code: |
224224
# Ask for the clerk comments, they'll go in the lead filing doc comments
225+
is_initial_filing
225226
ready_to_efile_user_hook
226227
check_resp
227228
remaining_to_check = check_resp.data
@@ -479,6 +480,24 @@ fields:
479480
datatype: yesnoradio
480481
---
481482
generic object: DAObject
483+
id: filing courtesy copy info
484+
question: |
485+
Would you like to send anyone a copy of your ${ x.title } by email?
486+
fields:
487+
- I would like to send someone a copy: x.has_courtesy_copies
488+
datatype: yesnoradio
489+
- What emails do you want to send to? (one per line): x.courtesy_copies_raw
490+
datatype: area
491+
show if: x.has_courtesy_copies
492+
validation code: |
493+
if x.has_courtesy_copies:
494+
x.courtesy_copies = x.courtesy_copies_raw.splitlines()
495+
for copy in x.courtesy_copies:
496+
if not '@' in copy:
497+
validation_error("Enter a valid email address.", field="x.courtesy_copies_raw")
498+
break
499+
---
500+
generic object: DAObject
482501
code: |
483502
if not x.optional_service_options:
484503
x.optional_services.there_are_any = False
@@ -524,11 +543,11 @@ code: |
524543
---
525544
generic object: DAObject
526545
code: |
527-
x.optional_services_defaults = []
546+
x.optional_services_defaults = [None]
528547
---
529548
generic object: DAObject
530549
code: |
531-
x.optional_services_filters = []
550+
x.optional_services_filters = [[]]
532551
---
533552
generic object: DAObject
534553
code: |
@@ -805,6 +824,18 @@ code: |
805824
timing = 'Initial' if is_initial_filing else 'Subsequent'
806825
case_type_options, case_type_map = choices_and_map(proxy_conn.get_case_types(court_id, efile_case_category, timing=timing).data)
807826
---
827+
code: |
828+
efile_case_category_default = None
829+
---
830+
code: |
831+
efile_case_type_default = None
832+
---
833+
code: |
834+
efile_case_category_exclude = None
835+
---
836+
code: |
837+
efile_case_type_exclude = None
838+
---
808839
code: |
809840
party_type_options, party_type_map = \
810841
choices_and_map(proxy_conn.get_party_types(court_id, efile_case_type).data)
@@ -818,6 +849,33 @@ code: |
818849
code: |
819850
court_policy = proxy_conn.get_policy(court_id).data or {}
820851
---
852+
if: can_check_efile
853+
only sets:
854+
- max_total_exhibit_size
855+
- max_mb_per_file
856+
code: |
857+
allowed_sizes = get_max_allowed_sizes(proxy_conn, court_id)
858+
one_mb = 1024 * 1024
859+
if allowed_sizes:
860+
max_mb_per_file = allowed_sizes[0] / 1024 / 1024
861+
if allowed_sizes[0] > one_mb:
862+
# OCR will increase file sizes a bit, so save some room
863+
max_per_file = allowed_sizes[0] - one_mb
864+
else:
865+
max_per_file = allowed_sizes[0]
866+
max_total_exhibit_size = allowed_sizes[1] - one_mb
867+
else:
868+
max_mb_per_file = 15
869+
max_total_exhibit_size = 50 * 1024 * 1024
870+
---
871+
if: not can_check_efile
872+
only sets:
873+
- max_total_exhibit_size
874+
- max_mb_per_file
875+
code: |
876+
max_mb_per_file = 15
877+
max_total_exhibit_size = 50 * 1024 * 1024
878+
---
821879
code: |
822880
filing_attorney_required_datafield = proxy_conn.get_datafield(court_id, 'FilingFilingAttorneyView').data or {}
823881
---
@@ -980,6 +1038,12 @@ code: |
9801038
users[i].attorney_ids
9811039
users[i].complete = True
9821040
---
1041+
code: |
1042+
users[i].party_type_default = None
1043+
---
1044+
code: |
1045+
other_parties[i].party_type_default = None
1046+
---
9831047
if: not can_check_efile
9841048
code: |
9851049
users[i].is_form_filler
@@ -1014,6 +1078,10 @@ if: full_court_info.get("efmType", "ecf") != "ecf"
10141078
code: |
10151079
users[0].is_form_filler = False
10161080
---
1081+
if: not can_check_efile
1082+
code: |
1083+
users[0].is_form_filler = False
1084+
---
10171085
code: |
10181086
if i > 0:
10191087
users[i].is_form_filler = False

docassemble/EFSPIntegration/data/questions/unauthenticated_actions.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,7 @@ question: |
123123
What is your account email?
124124
fields:
125125
- Email: unauthed_user_email
126+
# TODO: should be an email datatype?
126127
---
127128
only sets: reset_user_password
128129
code: |

0 commit comments

Comments
 (0)