File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -59,10 +59,12 @@ export const ApplicationForm = (): ReactElement => {
5959 // effects
6060 const resetFields = form . resetFields ;
6161
62+ console . log ( form . getFieldsValue ( ) ) ;
63+
6264 useEffect ( ( ) => {
6365 if ( alreadySubmitted || isBeforeRegistration || isAfterRegistration ) {
6466 setDisabled ( true ) ;
65- resetFields ( ) ;
67+ form . setFieldsValue ( submittedFormData . current ) ;
6668 }
6769 getStatusData ( ) . then ( ( status ) => {
6870 setAppStatus ( status ?. applicationStatus ) ;
@@ -88,7 +90,6 @@ export const ApplicationForm = (): ReactElement => {
8890 newFormData [ String ( questionIndex + 1 ) ] = response ;
8991 submittedFormData . current = newFormData ;
9092 } ) ;
91- console . log ( 'setting' , newFormData ) ;
9293 form . setFieldsValue ( newFormData ) ;
9394 } , [ userResponses ] ) ;
9495
@@ -215,6 +216,7 @@ export const ApplicationForm = (): ReactElement => {
215216 className = "cancel-edit-button"
216217 onClick = { ( ) => {
217218 setDisabled ( true ) ;
219+ console . log ( form . getFieldsValue ( ) ) ;
218220 form . resetFields ( ) ;
219221 } }
220222 >
You can’t perform that action at this time.
0 commit comments