diff --git a/atst/forms/financial.py b/atst/forms/financial.py
index 9f4afbb3..c3e00578 100644
--- a/atst/forms/financial.py
+++ b/atst/forms/financial.py
@@ -101,46 +101,43 @@ class BaseFinancialForm(ValidatedForm):
)
uii_ids = NewlineListField(
- "Unique Item Identifier (UII)s related to your application(s) if you already have them",
+ "Unique Item Identifier (UII)s related to your application(s) if you already have them.",
+ description="If you have more than one UII, place each one on a new line.",
validators=[Required()],
)
pe_id = StringField(
- "Program Element (PE) Number related to your request", validators=[Required()]
+ "Program Element Number",
+ description="PE numbers help the Department of Defense identify which offices' budgets are contributing towards this resource use.
It should be 7 digits followed by 1-3 letters, and should have a zero as the first and third digits.",
+ validators=[Required()],
)
treasury_code = StringField(
- "Program Treasury Code", validators=[Required(), Regexp(TREASURY_CODE_REGEX)]
+ "Program Treasury Code",
+ description="Program Treasury Code (or Appropriations Code) identifies resource types.
It should be a four digit or six digit number, optionally prefixed by one or more zeros.",
+ validators=[Required(), Regexp(TREASURY_CODE_REGEX)],
)
ba_code = StringField(
"Program Budget Activity (BA) Code",
+ description="BA Code is used to identify the purposes, projects, or types of activities financed by the appropriation fund.
It should be two digits, followed by a letter.",
validators=[Required(), Regexp(BA_CODE_REGEX)],
)
- fname_co = StringField("Contracting Officer First Name", validators=[Required()])
- lname_co = StringField("Contracting Officer Last Name", validators=[Required()])
+ fname_co = StringField("KO First Name", validators=[Required()])
+ lname_co = StringField("KO Last Name", validators=[Required()])
- email_co = EmailField("Contracting Officer Email", validators=[Required(), Email()])
+ email_co = EmailField("KO Email", validators=[Required(), Email()])
- office_co = StringField("Contracting Officer Office", validators=[Required()])
+ office_co = StringField("KO Office", validators=[Required()])
- fname_cor = StringField(
- "Contracting Officer Representative (COR) First Name", validators=[Required()]
- )
+ fname_cor = StringField("COR First Name", validators=[Required()])
- lname_cor = StringField(
- "Contracting Officer Representative (COR) Last Name", validators=[Required()]
- )
+ lname_cor = StringField("COR Last Name", validators=[Required()])
- email_cor = EmailField(
- "Contracting Officer Representative (COR) Email",
- validators=[Required(), Email()],
- )
+ email_cor = EmailField("COR Email", validators=[Required(), Email()])
- office_cor = StringField(
- "Contracting Officer Representative (COR) Office", validators=[Required()]
- )
+ office_cor = StringField("COR Office", validators=[Required()])
class FinancialForm(BaseFinancialForm):
diff --git a/js/lib/input_validations.js b/js/lib/input_validations.js
index 3806af8c..d326d0b8 100644
--- a/js/lib/input_validations.js
+++ b/js/lib/input_validations.js
@@ -52,5 +52,31 @@ export default {
match: /^\d{10}$/,
unmask: [],
validationError: 'Please enter a 10-digit DoD ID number'
+ },
+ peNumber: {
+ mask: val => {
+ if (val.length <= 7) return [/\d/,/\d/,/\d/,/\d/,/\d/,/\d/,/\d/,/[a-z,A-Z]/]
+ if (val.length === 8) return [/\d/,/\d/,/\d/,/\d/,/\d/,/\d/,/\d/,/[a-z,A-Z]/,/[a-z,A-Z]/]
+ return [/\d/,/\d/,/\d/,/\d/,/\d/,/\d/,/\d/,/[a-z,A-Z]/,/[a-z,A-Z]/,/[a-z,A-Z]/]
+ },
+ match: /(0\d)(0\d)(\d)(\d{2})([a-z,A-Z]{1,3})/,
+ unmask: ['_'],
+ validationError: 'Please enter a valid PE number. Note that it should be 7 digits followed by 1-3 letters, and should have a zero as the first and third digits.'
+ },
+ treasuryCode: {
+ mask: createNumberMask({ prefix: '', allowDecimal: false, allowLeadingZeroes: true, includeThousandsSeparator: false }),
+ match: /^0*([1-9]{4}|[1-9]{6})$/,
+ unmask: [],
+ validationError: 'Please enter a valid Program Treasury Code. Note that it should be a four digit or six digit number, optionally prefixed by one or more zeros.'
+ },
+ baCode: {
+ mask: val => {
+ if (val.length === 1) return [/\d/]
+ if (val.length === 2) return [/\d/, /\d/]
+ return [/\d/,/\d/,/[a-z,A-Z]/]
+ },
+ match: /[0-9]{2}\w?$/,
+ unmask: [],
+ validationError: 'Please enter a valid BA Code. Note that it should be two digits, followed by a letter.'
}
}
diff --git a/styles/components/_forms.scss b/styles/components/_forms.scss
index 6bfd17d2..db7ee296 100644
--- a/styles/components/_forms.scss
+++ b/styles/components/_forms.scss
@@ -21,11 +21,35 @@
@include media($medium-screen) {
@include grid-row;
align-items: flex-start;
+ justify-content: flex-start;
.form-col {
+ &.form-col--half {
+ flex-basis: 50%;
+ }
+
+ &.form-col--third {
+ flex-basis: 33.33%;
+ }
+
+ &.form-col--two-thirds {
+ flex-basis: 66.66%;
+ }
+
.usa-input {
margin-left: ($gap * 4);
margin-right: ($gap * 4);
+
+ label {
+ .icon-validation {
+ left: auto;
+ right: -$gap * 3;
+ }
+ }
+
+ input {
+ max-width: none;
+ }
}
&:first-child {
diff --git a/styles/elements/_inputs.scss b/styles/elements/_inputs.scss
index 9c664cdd..84167345 100644
--- a/styles/elements/_inputs.scss
+++ b/styles/elements/_inputs.scss
@@ -93,14 +93,14 @@
.icon-tooltip {
padding: 0 $gap/2;
cursor: default;
- margin-left: $gap/2;
+ margin: 0 0 0 ($gap / 2);
}
}
.usa-input__help {
- @include h4;
+ @include h5;
font-weight: normal;
- padding: $gap/2 0;
+
@include line-max;
.icon-link {
@@ -115,7 +115,6 @@
@include line-max;
margin: 0;
box-sizing: border-box;
- max-width: 32em;
resize: none;
&::placeholder {
@@ -215,7 +214,9 @@
&--integer,
&--dollars,
- &--gigabytes, {
+ &--gigabytes,
+ &--treasuryCode,
+ &--peNumber {
input {
max-width: 16em;
}
@@ -225,7 +226,8 @@
}
&--date,
- &--usPhone {
+ &--usPhone,
+ &--baCode {
input {
max-width: 10em;
}
diff --git a/templates/requests/financial_verification.html b/templates/requests/financial_verification.html
index 51eeccba..c43942ef 100644
--- a/templates/requests/financial_verification.html
+++ b/templates/requests/financial_verification.html
@@ -27,6 +27,25 @@
) }}
{% endif %}
+ {% block form_action %}
+ {% if extended %}
+