diff --git a/frontend/src/components/housing/submission/SubmissionIntakeForm.vue b/frontend/src/components/housing/submission/SubmissionIntakeForm.vue index cf2d6220..9d0c2fc2 100644 --- a/frontend/src/components/housing/submission/SubmissionIntakeForm.vue +++ b/frontend/src/components/housing/submission/SubmissionIntakeForm.vue @@ -64,7 +64,7 @@ import type { Ref } from 'vue'; import type { AutoCompleteCompleteEvent } from 'primevue/autocomplete'; import type { DropdownChangeEvent } from 'primevue/dropdown'; import type { IInputEvent } from '@/interfaces'; -import type { Document, Permit, SubmissionIntake } from '@/types'; +import type { Document, IntakeAppliedPermit, Permit, SubmissionIntake } from '@/types'; import type { GenericObject } from 'vee-validate'; // Types @@ -462,7 +462,15 @@ onBeforeMount(async () => { if (draftId) { response = (await submissionService.getDraft(draftId)).data; - initialFormValues.value = { ...response.data, activityId: response.activityId }; + + initialFormValues.value = { + ...response.data, + activityId: response.activityId, + appliedPermits: response.data.appliedPermits.map((x: IntakeAppliedPermit) => ({ + ...x, + statusLastVerified: x.statusLastVerified ? new Date(x.statusLastVerified) : undefined + })) + }; if (response.activityId) { documents = (await documentService.listDocuments(response.activityId)).data; @@ -1549,6 +1557,7 @@ onBeforeMount(async () => { :name="`appliedPermits[${idx}].statusLastVerified`" :disabled="!editable" placeholder="Status last verified" + :max-date="new Date()" />