Save settings on switching a source
This commit is contained in:
		
							parent
							
								
									c8f54a899d
								
							
						
					
					
						commit
						698f905145
					
				
					 1 changed files with 2 additions and 0 deletions
				
			
		|  | @ -175,6 +175,7 @@ class SettingsComponent extends React.Component<Props> { | ||||||
|     if (from === 'form' && value === 'json') { |     if (from === 'form' && value === 'json') { | ||||||
|       this.props.dispatch(settingActions.switchToJson( |       this.props.dispatch(settingActions.switchToJson( | ||||||
|         this.props.form as FormSettings)); |         this.props.form as FormSettings)); | ||||||
|  |       this.save(); | ||||||
|     } else if (from === 'json' && value === 'form') { |     } else if (from === 'json' && value === 'form') { | ||||||
|       let b = window.confirm(DO_YOU_WANT_TO_CONTINUE); |       let b = window.confirm(DO_YOU_WANT_TO_CONTINUE); | ||||||
|       if (!b) { |       if (!b) { | ||||||
|  | @ -183,6 +184,7 @@ class SettingsComponent extends React.Component<Props> { | ||||||
|       } |       } | ||||||
|       this.props.dispatch( |       this.props.dispatch( | ||||||
|         settingActions.switchToForm(this.props.json as JSONSettings)); |         settingActions.switchToForm(this.props.json as JSONSettings)); | ||||||
|  |       this.save(); | ||||||
|     } |     } | ||||||
|   } |   } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Reference in a new issue