Skip to content

Commit

Permalink
feat(cst): agency card form class
Browse files Browse the repository at this point in the history
  • Loading branch information
thekaveman committed Jul 9, 2024
1 parent 28f6b63 commit d7186ea
Show file tree
Hide file tree
Showing 3 changed files with 56 additions and 9 deletions.
29 changes: 29 additions & 0 deletions benefits/eligibility/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,35 @@ def clean(self):
raise forms.ValidationError("reCAPTCHA failed")


class CSTAgencyCard(EligibilityVerificationForm):
"""EligibilityVerification form for the CST Agency Card."""

def __init__(self, *args, **kwargs):
super().__init__(
title=_("Agency card information"),
headline=_("Let’s find the record of your transit benefit."),
blurb=_(
"We use the information on your CST Agency Card to find the record of your transit benefit in our system."
),
name_label=_("Last Name"),
name_placeholder="Hernandez-Demarcos",
name_help_text=_(
"Please enter your last name the same way it is printed on your card, including capital letters and hyphens."
),
sub_label=_("Agency Card number"),
sub_help_text=_("This is a 5-digit number on the front and back of your card."),
sub_placeholder="12345",
name_max_length=255,
sub_input_mode="numeric",
sub_max_length=5,
sub_pattern=r"\d{5}",
sub_custom_validity=_("Please enter a 5-digit number."),
name_custom_validity=_("Please enter your last name."),
*args,
**kwargs,
)


class MSTCourtesyCard(EligibilityVerificationForm):
"""EligibilityVerification form for the MST Courtesy Card."""

Expand Down
14 changes: 11 additions & 3 deletions benefits/locale/en/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
msgid ""
msgstr ""
"Report-Msgid-Bugs-To: https://github.com/cal-itp/benefits/issues \n"
"POT-Creation-Date: 2024-07-03 13:26-0700\n"
"POT-Creation-Date: 2024-07-09 10:43-0700\n"
"Language: English\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
Expand Down Expand Up @@ -333,7 +333,7 @@ msgid "Let’s find the record of your transit benefit."
msgstr ""

msgid ""
"We use the information on your MST Courtesy Card to find the record of your "
"We use the information on your CST Agency Card to find the record of your "
"transit benefit in our system."
msgstr ""

Expand All @@ -345,7 +345,7 @@ msgid ""
"including capital letters and hyphens."
msgstr ""

msgid "Courtesy Card number"
msgid "Agency Card number"
msgstr ""

msgid "This is a 5-digit number on the front and back of your card."
Expand All @@ -357,6 +357,14 @@ msgstr ""
msgid "Please enter your last name."
msgstr ""

msgid ""
"We use the information on your MST Courtesy Card to find the record of your "
"transit benefit in our system."
msgstr ""

msgid "Courtesy Card number"
msgstr ""

msgid ""
"We use the information on your SBMTD Reduced Fare Mobility ID card to find "
"the record of your transit benefit in our system."
Expand Down
22 changes: 16 additions & 6 deletions benefits/locale/es/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
msgid ""
msgstr ""
"Report-Msgid-Bugs-To: https://github.com/cal-itp/benefits/issues \n"
"POT-Creation-Date: 2024-07-03 13:26-0700\n"
"POT-Creation-Date: 2024-07-09 10:43-0700\n"
"Language: Español\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
Expand Down Expand Up @@ -444,11 +444,11 @@ msgid "Let’s find the record of your transit benefit."
msgstr "Veamos si podemos confirmar su elegibilidad."

msgid ""
"We use the information on your MST Courtesy Card to find the record of your "
"We use the information on your CST Agency Card to find the record of your "
"transit benefit in our system."
msgstr ""
"Usamos la información de su tarjeta de cortesía de MST para confirmar su "
"elegibilidad en nuestro sistema."
"Utilizamos la información de su Tarjeta de agencia CST para encontrar el "
"registro de su beneficio de tránsito en nuestro sistema."

msgid "Last Name"
msgstr "Apellido"
Expand All @@ -460,8 +460,8 @@ msgstr ""
"Ingrese su apellido de la misma manera que está impreso en su tarjeta, "
"incluyendo mayúsculas y guiones."

msgid "Courtesy Card number"
msgstr "Número de tarjeta de cortesía de MST"
msgid "Agency Card number"
msgstr "Número de tarjeta de agencia de CST"

msgid "This is a 5-digit number on the front and back of your card."
msgstr "Este es un número de 5 dígitos en el anverso y reverso de su tarjeta."
Expand All @@ -472,6 +472,16 @@ msgstr "Ingrese un número de 5 dígitos."
msgid "Please enter your last name."
msgstr "Ingrese su apellido."

msgid ""
"We use the information on your MST Courtesy Card to find the record of your "
"transit benefit in our system."
msgstr ""
"Usamos la información de su tarjeta de cortesía de MST para confirmar su "
"elegibilidad en nuestro sistema."

msgid "Courtesy Card number"
msgstr "Número de tarjeta de cortesía de MST"

msgid ""
"We use the information on your SBMTD Reduced Fare Mobility ID card to find "
"the record of your transit benefit in our system."
Expand Down

0 comments on commit d7186ea

Please sign in to comment.