Create SubmitConfirmation modal
- includes html component and js component - styling on modal is not ready
This commit is contained in:
32
templates/components/submit_confirmation.html
Normal file
32
templates/components/submit_confirmation.html
Normal file
@@ -0,0 +1,32 @@
|
||||
{% from "components/alert.html" import Alert %}
|
||||
{% from "components/checkbox_input.html" import CheckboxInput %}
|
||||
|
||||
{% macro SubmitConfirmation(modal_id, submit_text, submit_action, form, task_order) %}
|
||||
<submit-confirmation inline-template name="{{ modal_id }}" key="{{ modal_id }}">
|
||||
<div>
|
||||
<div class="usa-input">
|
||||
<label for="{{ modal_id }}-deleted-text">
|
||||
<span class="usa-input__help">
|
||||
Signature confirmation: Task Order #{{task_order.number}}
|
||||
</span>
|
||||
{{ Alert('',
|
||||
message="All task orders require a Contracting Officer signature."
|
||||
) }}
|
||||
</label>
|
||||
<span v-on:change="toggleValid">
|
||||
{{ CheckboxInput(field=form.signature) }}
|
||||
</span>
|
||||
</div>
|
||||
<div class="action-group">
|
||||
<form method="POST" action="{{ submit_action }}">
|
||||
{{ form.csrf_token }}
|
||||
<button class="usa-button usa-button-primary" v-bind:disabled="!valid">
|
||||
{{ submit_text }}
|
||||
</button>
|
||||
<button v-on:click="deleteText = ''; $root.closeModal('{{ modal_id }}')" class="usa-button usa-button-secondary">{{ "common.cancel" | translate }}</button>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</submit-confirmation>
|
||||
{% endmacro %}
|
@@ -1,14 +1,29 @@
|
||||
{% from "components/icon.html" import Icon %}
|
||||
{% from "components/totals_box.html" import TotalsBox %}
|
||||
{% from "components/modal.html" import Modal %}
|
||||
{% from "components/semi_collapsible_text.html" import SemiCollapsibleText %}
|
||||
{% from "components/sticky_cta.html" import StickyCTA %}
|
||||
{% from "components/submit_confirmation.html" import SubmitConfirmation %}
|
||||
{% from "components/totals_box.html" import TotalsBox %}
|
||||
|
||||
{% extends 'portfolios/base.html' %}
|
||||
|
||||
{% block portfolio_content %}
|
||||
{% set submit_modal_id = "submit-to-1" %}
|
||||
{% call Modal(name=submit_modal_id) %}
|
||||
{{
|
||||
SubmitConfirmation(
|
||||
modal_id=submit_modal_id,
|
||||
submit_text="Confirm & Submit",
|
||||
submit_action=url_for('task_orders.submit_task_order', task_order_id=task_order.id),
|
||||
form=signature_form,
|
||||
task_order=task_order,
|
||||
)
|
||||
}}
|
||||
{% endcall %}
|
||||
|
||||
{% call StickyCTA(text="Review Funding") %}
|
||||
<a href="{{ url_for("task_orders.edit", portfolio_id=portfolio.id) }}" class="usa-button usa-button-secondary" type="submit">Edit</a>
|
||||
<a href="{{ url_for("task_orders.edit", portfolio_id=portfolio.id) }}" class="usa-button usa-button-primary" type="submit">Submit task order</a>
|
||||
<a v-on:click="openModal('submit-to-1')" class="usa-button usa-button-primary" type="submit">Submit task order</a>
|
||||
{% endcall %}
|
||||
|
||||
<div class="task-order-summary">
|
||||
|
Reference in New Issue
Block a user