public void UpdateShop(string obj) { //MessageBox.Show("Great! You've updated your shop space !!", "Great", MessageBoxButton.OK, MessageBoxImage.Exclamation); CurrentModel.shop.UpdateLists(); updateShopUC = new UpdateShopUC(CurrentModel.shop); ((MainWindow)System.Windows.Application.Current.MainWindow).inner_grid.Children.Clear(); ((MainWindow)System.Windows.Application.Current.MainWindow).content_grid.Children.Clear(); //((MainWindow)System.Windows.Application.Current.MainWindow).profile_grid.Children.Clear(); ((MainWindow)System.Windows.Application.Current.MainWindow).content_grid.Children.Add(updateShopUC); }
public UpdateShopVM(UpdateShopUC updateShopUC) { CurrentModel = new UpdateShopModel(); CurrentModel.MyShop = updateShopUC.shop; this.UpdateShopUC = updateShopUC; updateShopUC.Password.Password = CurrentModel.MyShop.Password; updateShopUC.ConfirmPassword.Password = CurrentModel.MyShop.Password; this.MyCommand = new SpecialCommand(); MyCommand.callComplete += UpdateShop; ImageCommand = new Command(); ImageCommand.callComplete += OpenFileCommand; }