/// <summary> /// 書籍を編集する /// </summary> /// <param name="o">コマンド引数</param> private void EditBook(object o) { if (SelectedBook != null) { var sub = new SubViewModel(SelectedBook); App.Views.ShowModalView(sub, this); } }
/// <summary> /// 書籍を追加する /// </summary> /// <param name="o">コマンド引数</param> private void AddBook(object o) { var sub = new SubViewModel(null); if (App.Views.ShowModalView(sub, this)) { if (sub.Book != null) { Books.Add(sub.Book); } } }