Update the UI after importing an ASA scenario.

master
Pacman Ghost 2 years ago
parent 0312fa2fc7
commit 7e070c3b68
  1. 5
      vasl_templates/webapp/static/scenarios.js

@ -733,6 +733,10 @@ function doImportScenario( scenario )
scenario.roar ? scenario.roar.scenario_id : null scenario.roar ? scenario.roar.scenario_id : null
) ; ) ;
// update the UI
on_scenario_date_change() ;
on_scenario_theater_change() ;
// all done - we can now close the dialog // all done - we can now close the dialog
$gDialog.dialog( "close" ) ; $gDialog.dialog( "close" ) ;
} }
@ -909,6 +913,7 @@ function doImportField_player( importField, newVal, scenario ) {
var playerNo = importField.paramName.substring( importField.paramName.length-1 ) ; var playerNo = importField.paramName.substring( importField.paramName.length-1 ) ;
on_player_change( playerNo ) ; on_player_change( playerNo ) ;
$elem.val( newVal ).trigger( "change" ) ; $elem.val( newVal ).trigger( "change" ) ;
on_player_change( playerNo ) ; // nb: to update the UI for the new player
} }
} }

Loading…
Cancel
Save