/// <summary> /// ViewModelの取得 /// </summary> /// <param name="model">Model</param> /// <returns>ViewModel</returns> public IRecipeSearchConditionViewModel CreateRecipeSearchConditionViewModel(IRecipeSearchConditionModel model) { return(new AdviceSearchViewModel((AdviceSearch)model)); }
/// <summary> /// プラグイン検索条件削除 /// </summary> /// <param name="condition">削除するプラグイン検索条件</param> public void RemovePluginSearchCondition(IRecipeSearchConditionModel condition) { this.PluginSearchConditions.Remove(condition); }
internal static (UserControl View, IRecipeSearchConditionViewModel ViewModel) CreateRecipeSearchConditionViewAndViewModel(IRecipeSearchConditionModel model) { var plugin = RecipeSearchConditionPlugins.Single(p => p.ModelType == model.GetType()); var vm = plugin.CreateRecipeSearchConditionViewModel(model); var v = plugin.CreateRecipeSearchConditionView(vm); return(v, vm); }