diff --git a/atst/routes/requests/financial_verification.py b/atst/routes/requests/financial_verification.py index 728f7f39..0be12e7b 100644 --- a/atst/routes/requests/financial_verification.py +++ b/atst/routes/requests/financial_verification.py @@ -38,7 +38,7 @@ def financial_verification(request_id=None): return render_template( "requests/financial_verification.html", f=form, - request_id=request_id, + request=request, extended=is_extended(request), ) @@ -49,7 +49,7 @@ def update_financial_verification(request_id): existing_request = Requests.get(g.current_user, request_id) form = financial_form(existing_request, post_data) rerender_args = dict( - request_id=request_id, f=form, extended=is_extended(existing_request) + request=existing_request, f=form, extended=is_extended(existing_request) ) if form.validate(): diff --git a/atst/routes/requests/requests_form.py b/atst/routes/requests/requests_form.py index 80f76931..8e14b0e2 100644 --- a/atst/routes/requests/requests_form.py +++ b/atst/routes/requests/requests_form.py @@ -132,6 +132,10 @@ def view_request_details(request_id=None): or request.is_approved or request.is_pending_financial_verification_changes ) + requires_fv_action = ( + request.is_pending_financial_verification + or request.is_pending_financial_verification_changes + ) data = request.body if financial_review and request.task_order: @@ -140,10 +144,6 @@ def view_request_details(request_id=None): return render_template( "requests/details.html", data=data, - request_id=request.id, - status=request.status_displayname, - pending_review=request.is_pending_ccpo_action, - financial_verification=request.is_pending_financial_verification - or request.is_pending_financial_verification_changes, - financial_review=financial_review, + request=request, + requires_fv_action=requires_fv_action, ) diff --git a/templates/fragments/pending_ccpo_approval_alert.html b/templates/fragments/pending_ccpo_acceptance_alert.html similarity index 100% rename from templates/fragments/pending_ccpo_approval_alert.html rename to templates/fragments/pending_ccpo_acceptance_alert.html diff --git a/templates/requests/details.html b/templates/requests/details.html index 07bd49a7..89bdd105 100644 --- a/templates/requests/details.html +++ b/templates/requests/details.html @@ -5,21 +5,28 @@ {% block content %}
- {% if financial_verification %} - {% include 'requests/review_menu.html' %} - {% endif %} + {% if request.is_pending_ccpo_acceptance %} + + {{ Alert('Request submitted. Approval pending.', fragment="fragments/pending_ccpo_acceptance_alert.html") }} + + {% elif request.is_pending_ccpo_approval %} + + {% call Alert('Pending CCPO Approval') %} +

The CCPO will review and respond to your Financial Verification submission in 3 business days. You will be notified via email or phone.

+

Once the financial verification is approved you will be invited to create your JEDI Workspace and set-up your projects. Click here for more details.

+ {% endcall %} + + {% elif requires_fv_action %} + + {{ Alert('Pending Financial Verification', fragment="fragments/pending_financial_verification.html") }} + {% include 'requests/review_menu.html' %} - {% if pending_review %} - {{ Alert('Your request is being reviewed', - message="

You cannot edit your submitted request while it is under review. Your request will be reviewed within 3 business days.

", - level='warning' - ) }} {% endif %}

Request Details


-

#{{ request_id }} {{ status }}

+

#{{ request.id }} {{ request.status_displayname }}

diff --git a/templates/requests/financial_verification.html b/templates/requests/financial_verification.html index f3950f00..25a1c0b9 100644 --- a/templates/requests/financial_verification.html +++ b/templates/requests/financial_verification.html @@ -8,6 +8,10 @@ {% include 'requests/review_menu.html' %} +{% if request.is_pending_financial_verification %} + {{ Alert('Pending Financial Verification', fragment="fragments/pending_financial_verification.html") }} +{% endif %} +
@@ -19,21 +23,18 @@ {% endif %} {% if f.is_missing_task_order_number %} - {% set extended_url = url_for('requests.financial_verification', request_id=request_id, extended=True) %} - {{ Alert('Task Order not found in EDA', - message="We could not find your Task Order in our system of record, EDA. - Please confirm that you have entered it correctly.
- Enter Task Order information manually - "|format(extended_url), - level='warning' - ) }} + {% set extended_url = url_for('requests.financial_verification', request_id=request.id, extended=True) %} + {% call Alert('Task Order not found in EDA', level='warning') %} + We could not find your Task Order in our system of record, EDA. Please confirm that you have entered it correctly.
+ Enter Task Order information manually + {% endcall %} {% endif %} {% block form_action %} {% if extended %} -
+ {% else %} - + {% endif %} {% endblock %} @@ -52,7 +53,7 @@

Financial Verification

-

Order #{{ request_id }}

+

Order #{{ request.id }}

diff --git a/templates/requests/index.html b/templates/requests/index.html index dfee7184..9411776d 100644 --- a/templates/requests/index.html +++ b/templates/requests/index.html @@ -45,18 +45,6 @@ {% else %} - {% if pending_financial_verification %} - - {{ Alert('Pending Financial Verification', fragment="fragments/pending_financial_verification.html") }} - - {% endif %} - - {% if pending_ccpo_approval %} - - {{ Alert('Request submitted. Approval pending.', fragment="fragments/pending_ccpo_approval_alert.html") }} - - {% endif %} - {% if extended_view %}
diff --git a/templates/requests/review_menu.html b/templates/requests/review_menu.html index b8546233..f6f36aa0 100644 --- a/templates/requests/review_menu.html +++ b/templates/requests/review_menu.html @@ -1,5 +1,5 @@ -{% set pending_url=url_for('requests.view_request_details', request_id=request_id) %} -{% set financial_url=url_for('requests.financial_verification', request_id=request_id) %} +{% set pending_url=url_for('requests.view_request_details', request_id=request.id) %} +{% set financial_url=url_for('requests.financial_verification', request_id=request.id) %}