public MainPageViewModel( [Import(typeof(IClientModel))] IClientModel clientModel, [Import(typeof(ISystemModel))] ISystemModel systemModel, [Import(typeof(IGlobals))] IGlobals globals) { _clientModel = clientModel; _systemModel = systemModel; _globals = globals; this.LoginBoxVisibility = true; this.UserDetailsBoxVisibility = false; this.ErrorMessageVisibility = false; LoginCommand = new RelayCommand(LoginCommandAction); this.UserName = "******"; this.MenuItemCommand = new RelayCommand<SYStblMenu>((menuItemClicked) => { switch (menuItemClicked.Action) { case "VIEW": this.NavigateView(menuItemClicked.ActionObject, menuItemClicked.Name); break; case "DIALOG": break; default: throw new Exception(string.Format("Don't know what to do with the navigation action {0} ", menuItemClicked.Action)); } }); }
public MainPageViewModel( [Import(typeof(IClientModel))] IClientModel clientModel, [Import(typeof(ISystemModel))] ISystemModel systemModel, [Import(typeof(IGlobals))] IGlobals globals) { _clientModel = clientModel; _systemModel = systemModel; _globals = globals; this.LoginBoxVisibility = true; this.UserDetailsBoxVisibility = false; this.ErrorMessageVisibility = false; LoginCommand = new RelayCommand(LoginCommandAction); this.UserName = "******"; this.MenuItemCommand = new RelayCommand <SYStblMenu>((menuItemClicked) => { switch (menuItemClicked.Action) { case "VIEW": this.NavigateView(menuItemClicked.ActionObject, menuItemClicked.Name); break; case "DIALOG": break; default: throw new Exception(string.Format("Don't know what to do with the navigation action {0} ", menuItemClicked.Action)); } }); }