diff options
| author | Roy Ben-Shabat <Roy@Twine-s.com> | 2018-12-27 15:14:10 +0200 |
|---|---|---|
| committer | Roy Ben-Shabat <Roy@Twine-s.com> | 2018-12-27 15:14:10 +0200 |
| commit | 9e42e1c87f3a206f0babc74760ac9a02d8d328f4 (patch) | |
| tree | be3be4cf23f524f430146af472883f63dd8bdfb7 /Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels | |
| parent | 894d05d59c0e1612903f1adbf908914f2df67ccc (diff) | |
| download | Tango-9e42e1c87f3a206f0babc74760ac9a02d8d328f4.tar.gz Tango-9e42e1c87f3a206f0babc74760ac9a02d8d328f4.zip | |
Implemented Deployment Slots!
Implemented Environment AD Groups.
Implemented Machine Studio environment selection.
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels')
| -rw-r--r-- | Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoginViewVM.cs | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoginViewVM.cs b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoginViewVM.cs index 730027a67..edae820e7 100644 --- a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoginViewVM.cs +++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UI/ViewModels/LoginViewVM.cs @@ -46,6 +46,9 @@ namespace Tango.MachineStudio.UI.ViewModels } private String _password; + /// <summary> + /// Gets or sets the password. + /// </summary> [Required(ErrorMessage = "Password is required")] public String Password { @@ -53,6 +56,16 @@ namespace Tango.MachineStudio.UI.ViewModels set { _password = value; RaisePropertyChangedAuto(); } } + private DeploymentSlots _deploymentSlot; + /// <summary> + /// Gets or sets the deployment slot. + /// </summary> + public DeploymentSlots DeploymentSlot + { + get { return _deploymentSlot; } + set { _deploymentSlot = value; RaisePropertyChangedAuto(); } + } + private bool _isLogging; /// <summary> /// Gets or sets a value indicating whether this instance is logging. @@ -96,6 +109,7 @@ namespace Tango.MachineStudio.UI.ViewModels cryptographer = new Rfc2898Cryptographer(); Email = _settings.LastLoginEmail; + DeploymentSlot = _settings.DeploymentSlot; RememberMe = _settings.RememberMe; try @@ -122,14 +136,16 @@ namespace Tango.MachineStudio.UI.ViewModels await Task.Factory.StartNew(() => { + _settings.DeploymentSlot = DeploymentSlot; + _authenticationProvider.Login(Email, Password); _eventLogger.Log(EventTypes.ApplicationStarted, "Application Started!"); _navigationManager.NavigateTo(NavigationView.MainView); + _settings.LastLoginEmail = Email; _settings.RememberMe = RememberMe; - _settings.LastLoginPassword = RememberMe ? cryptographer.Encrypt(Password) : null; _settings.Save(); |
