refactor
This commit is contained in:
@@ -376,25 +376,15 @@ let CreateCase = (props) => {
|
||||
|
||||
const { LPAData, onSubmit, handleSubmit, formData } = props;
|
||||
|
||||
const appealOptionsObj = _.isEmpty(props)
|
||||
? [{}]
|
||||
: _.isEmpty(props.appealType)
|
||||
? [{}]
|
||||
: _.isEmpty(props.appealType.appealTypeOptions)
|
||||
? [{}]
|
||||
: _.isEmpty(props.appealType.appealTypeOptions.value)
|
||||
? [{}]
|
||||
: props.appealType.appealTypeOptions.value;
|
||||
const appealOptionsObj =
|
||||
props?.appealType?.appealTypeOptions?.value?.length > 0
|
||||
? props.appealType.appealTypeOptions.value
|
||||
: [{}];
|
||||
|
||||
let lpaOptionsObj = _.isEmpty(props)
|
||||
? [{}]
|
||||
: _.isEmpty(props.LPAData)
|
||||
? [{}]
|
||||
: _.isEmpty(props.LPAData.LPAData)
|
||||
? [{}]
|
||||
: _.isEmpty(props.LPAData.LPAData)
|
||||
? [{}]
|
||||
: props.LPAData.LPAData.value;
|
||||
const lpaOptionsObj =
|
||||
props?.LPAData?.LPAData?.value?.length > 0
|
||||
? props.LPAData.LPAData.value
|
||||
: [{}];
|
||||
|
||||
const required = (value) => (value ? undefined : "Required");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user