Skip to content

Commit

Permalink
Merge pull request #4826 from bcgov/dev-rook-AH-4671
Browse files Browse the repository at this point in the history
ticket 4671. removed mandatory requirement for inquiry fields
  • Loading branch information
Aman-Hundal authored Dec 4, 2023
2 parents 50e5b0c + b01d930 commit 0a3b669
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -367,8 +367,6 @@ const OIPCItem = (props) => {
InputLabelProps={{ shrink: true }}
InputProps={{inputProps: { min: oipc.receiveddate ? formatDate(new Date(oipc.receiveddate)) : null } }}
type="date"
error={(!oipc.outcomeid || oipc.outcomeid === 5) && oipc.inquiryattributes.inquirydate === null}
required
disabled={oipc.outcomeid && oipc.outcomeid !== 5}
/>
</Grid>
Expand All @@ -380,8 +378,6 @@ const OIPCItem = (props) => {
value={oipc.inquiryattributes.orderno}
onChange = {(event) => handleInquiryFields(event.target.value, "ORDERNO")}
InputLabelProps={{ shrink: true }}
error={(!oipc.outcomeid || oipc.outcomeid === 5) && oipc.inquiryattributes.orderno === ""}
required
disabled={oipc.outcomeid && oipc.outcomeid !== 5}
placeholder="Order Number"
/>
Expand All @@ -395,8 +391,6 @@ const OIPCItem = (props) => {
fullWidth
value={oipc.inquiryattributes.inquiryoutcome ? oipc.inquiryattributes.inquiryoutcome : -1}
label="Outcome"
error={(!oipc.outcomeid || oipc.outcomeid === 5) && oipc.inquiryattributes.inquiryoutcome === null}
required
disabled={oipc.outcomeid && oipc.outcomeid !== 5}
>
<MenuItem disabled value={-1}>
Expand Down
3 changes: 1 addition & 2 deletions forms-flow-web/src/components/FOI/FOIRequest/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -349,8 +349,7 @@ export const checkValidationError = (
!requiredRequestDetailsValues.requestStartDate ||
!requiredAxisDetails.axisRequestId ||
(oipcData?.length > 0 && isOipcReview && oipcData?.some((oipc) => {
return oipc.oipcno === "" || oipc.receiveddate === null || oipc.receiveddate === "" || oipc.reviewtypeid === null || oipc.reasonid === null || oipc.statusid === null ||
oipc.inquiryattributes?.orderno === "" || oipc.inquiryattributes?.inquiryoutcome === null || oipc.inquiryattributes?.inquirydate === null || oipc.inquiryattributes?.inquirydate === "";
return oipc.oipcno === "" || oipc.receiveddate === null || oipc.receiveddate === "" || oipc.reviewtypeid === null || oipc.reasonid === null || oipc.statusid === null;
}))
);
};
Expand Down

0 comments on commit 0a3b669

Please sign in to comment.