Skip to content

Commit

Permalink
Frontend logic work for ats_client_number as number
Browse files Browse the repository at this point in the history
  • Loading branch information
wilwong89 committed Feb 6, 2025
1 parent 2ea0ded commit 010160a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
6 changes: 4 additions & 2 deletions frontend/src/components/housing/enquiry/EnquiryForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import { Form } from 'vee-validate';
import { computed, onMounted, ref } from 'vue';
import { useI18n } from 'vue-i18n';
import { date, mixed, object, string } from 'yup';
import { date, mixed, number, object, string } from 'yup';
import {
CancelButton,
Expand Down Expand Up @@ -93,7 +93,8 @@ const intakeSchema = object({
})
.label('Assigned to'),
applicationStatus: string().oneOf(APPLICATION_STATUS_LIST).label('Activity state'),
waitingOn: string().notRequired().max(255).label('waiting on')
waitingOn: string().notRequired().max(255).label('waiting on'),
atsClientNumber: number().max(999999).notRequired()
});
// Actions
Expand Down Expand Up @@ -191,6 +192,7 @@ const onSubmit = async (values: any) => {
const valuesWithContact = omit(
{
...values,
atsClientNumber: parseInt(values.atsClientNumber) || '',
contacts: [
{
contactId: values.contactId,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ const formSchema = object({
naturalDisaster: string().oneOf(YES_NO_LIST).required().label('Affected by natural disaster'),
projectLocationDescription: string().notRequired().max(4000).label('Additional information about location'),
addedToATS: boolean().required().label('Authorized Tracking System (ATS) updated'),
atsClientNumber: string().notRequired().max(255).label('ATS Client #'),
atsClientNumber: number().notRequired().max(999999).label('ATS Client #'),
ltsaCompleted: boolean().required().label('Land Title Survey Authority (LTSA) completed'),
bcOnlineCompleted: boolean().required().label('BC Online completed'),
aaiUpdated: boolean().required().label('Authorization and Approvals Insight (AAI) updated'),
Expand Down Expand Up @@ -216,6 +216,7 @@ const onSubmit = async (values: any) => {
const valuesWithContact = omit(
{
...values,
atsClientNumber: parseInt(values.atsClientNumber) || '',
contacts: [
{
contactId: values.contactId,
Expand Down

0 comments on commit 010160a

Please sign in to comment.