| | |
| | | const BaseSettings = (props) => { |
| | | const translate = useTranslate(); |
| | | const notify = useNotify(); |
| | | const { children, value, userInfo } = props; |
| | | const { children, userInfo } = props; |
| | | |
| | | const { control, handleSubmit, watch, setValue, getValues, formState: { isDirty } } = useForm(); |
| | | const { |
| | | control, |
| | | handleSubmit, |
| | | watch, |
| | | setValue, |
| | | getValues, |
| | | reset, |
| | | formState: { |
| | | errors, |
| | | isDirty, |
| | | } |
| | | } = useForm(); |
| | | |
| | | const [loading, setLoading] = useState(false); |
| | | |
| | | useEffect(() => { |
| | |
| | | |
| | | return ( |
| | | <Box |
| | | hidden={value !== 0} |
| | | sx={{ |
| | | p: 3, |
| | | flex: 1, |