46 lines
1.0 KiB
C#
46 lines
1.0 KiB
C#
using BeWo.Services;
|
|
using BeWo.ViewModel.ListViewModel;
|
|
using DevExpress.Mvvm;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using System.Windows.Forms;
|
|
using System.Windows.Input;
|
|
|
|
namespace BeWo.ViewModel.View.AI
|
|
{
|
|
public class AiPromptbausteinSelectionViewModel : DialogViewModel
|
|
{
|
|
public AiPromptbausteinSelectionViewModel()
|
|
{
|
|
Func<bool> isPrompt = () => SelectedNode is object && !SelectedNode.IsKategorie;
|
|
|
|
SendCommand = new DelegateCommand(Send, isPrompt);
|
|
|
|
//if (BeWoApp.IsInDesignMode)
|
|
//{
|
|
ListVM = new AiPromptbausteinTreeListVM();
|
|
//}
|
|
}
|
|
|
|
public AiPromptbausteinSelectionViewModel(AiPromptbausteinTreeListVM viewModel) : this()
|
|
{
|
|
ListVM = viewModel;
|
|
}
|
|
|
|
public AiPromptbausteinTreeVM SelectedNode { get; set; }
|
|
public AiPromptbausteinTreeListVM ListVM { get; set; }
|
|
|
|
public ICommand SendCommand { get; set; }
|
|
|
|
public void Send()
|
|
{
|
|
MessageBox.Show("Hi");
|
|
|
|
CloseDialogCommand.Execute(null);
|
|
}
|
|
}
|
|
}
|