mirror of
				https://github.com/gyurix1968/guacamole-client.git
				synced 2025-10-31 09:03:21 +00:00 
			
		
		
		
	GUAC-586: Ensure model is set prior to region in time zone field.
This commit is contained in:
		| @@ -697,15 +697,15 @@ angular.module('form').controller('timeZoneFieldController', ['$scope', '$inject | ||||
|      */ | ||||
|     $scope.region = ''; | ||||
|  | ||||
|     // Restore time zone selection when region changes | ||||
|     $scope.$watch('region', function restoreSelection(region) { | ||||
|         $scope.model = selectedTimeZone[region] || null; | ||||
|     }); | ||||
|  | ||||
|     // Ensure corresponding region is selected | ||||
|     $scope.$watch('model', function setModel(model) { | ||||
|         $scope.region = timeZoneRegions[model] || ''; | ||||
|         selectedTimeZone[$scope.region] = model; | ||||
|     }); | ||||
|  | ||||
|     // Restore time zone selection when region changes | ||||
|     $scope.$watch('region', function restoreSelection(region) { | ||||
|         $scope.model = selectedTimeZone[region] || null; | ||||
|     }); | ||||
|  | ||||
| }]); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user