From a5dc6f6472f96505cfd6e19e4b9a09c3ab6fd0d6 Mon Sep 17 00:00:00 2001 From: sophia-massie <96220951+sophia-massie@users.noreply.github.com> Date: Wed, 11 Dec 2024 16:23:26 -0600 Subject: [PATCH] bug/WP-820-exp-date-exception-edit-modal (#402) * bug/WP-820-exp-date-exception-edit-modal * - Adds new label for clarity --- .../EditExceptionModal/EditExceptionModal.tsx | 29 ++++--------------- 1 file changed, 6 insertions(+), 23 deletions(-) diff --git a/apcd_cms/src/client/src/components/Admin/EditExceptionModal/EditExceptionModal.tsx b/apcd_cms/src/client/src/components/Admin/EditExceptionModal/EditExceptionModal.tsx index ec621a46..e48467b9 100644 --- a/apcd_cms/src/client/src/components/Admin/EditExceptionModal/EditExceptionModal.tsx +++ b/apcd_cms/src/client/src/components/Admin/EditExceptionModal/EditExceptionModal.tsx @@ -1,31 +1,14 @@ import React, { useState, useEffect } from 'react'; -import { - Modal, - ModalBody, - ModalHeader, - Label, - FormGroup, - Row, - Col, - Alert, -} from 'reactstrap'; -import { - Field, - ErrorMessage, - useFormik, - FormikHelpers, - FormikProvider, -} from 'formik'; +import { Modal, ModalBody, ModalHeader, Row, Col, Alert } from 'reactstrap'; +import { Field, useFormik, FormikHelpers, FormikProvider } from 'formik'; import { fetchUtil } from 'utils/fetchUtil'; import * as Yup from 'yup'; import { ExceptionRow } from 'hooks/admin'; import { formatDate } from 'utils/dateUtil'; import styles from './EditExceptionModal.module.css'; - import QueryWrapper from 'core-wrappers/QueryWrapper'; import FieldWrapper from 'core-wrappers/FieldWrapperFormik'; import Button from 'core-components/Button'; -import Message from 'core-components/Message'; interface EditRecordModalProps { isOpen: boolean; @@ -287,7 +270,7 @@ const EditExceptionModal: React.FC = ({ = ({ className="form-text text-muted" style={{ fontStyle: 'italic' }} > - Current:{' '} - {exception.approved_expiration_date + Requested Expy Date:{' '} + {exception.view_modal_content.requested_expiration_date ? new Date( - exception.approved_expiration_date + exception.view_modal_content.requested_expiration_date ).toLocaleDateString() : 'None'}