commitaf28476b76Merge:b76e16946c3b6a1e9cAuthor: Marcel Hirschle <marcel.hirschle@ownsoft.de> Date: Thu Jun 20 11:53:31 2024 +0200 Merge branch 'master' of ssh://float.ownsoft.de/git/beyondSoft/BeWo # Conflicts: # ReportImp/VkmHamm/CustomerMitarbeiterstundenkontoBerechnung.cs commitb76e169462Author: Marcel Hirschle <marcel.hirschle@ownsoft.de> Date: Thu Jun 20 11:40:08 2024 +0200 MH: vkm hamm stundenkonto commitc3b6a1e9c0Author: Christian <christian.baeurle@beyondsoft.de> Date: Thu Jun 20 10:58:05 2024 +0200 Mergemarker entfernt commit5ff8fe343bMerge:c1aa61f05fc57725f4Author: Christian <christian.baeurle@beyondsoft.de> Date: Thu Jun 20 10:52:16 2024 +0200 Merge branch 'master' of ssh://float.beyondsoft.de/git/beyondSoft/BeWo commitc1aa61f058Merge:12faccb711c0a94c60Author: Christian <christian.baeurle@beyondsoft.de> Date: Thu Jun 20 10:51:59 2024 +0200 Merge branch 'master' of ssh://float.beyondsoft.de/git/beyondSoft/BeWo # Conflicts: # BeWo/ServiceProxy/Generated.cs # Data/Security/UserRightHelper.cs # Shared/BeWoEntityEnums.cs # Shared/Core/EnumTranslations.cs commit12faccb71bAuthor: Christian <christian.baeurle@beyondsoft.de> Date: Wed Jun 19 16:13:56 2024 +0200 Perseh Hilfeplan Import + KI Prototyp,
75 lines
1.9 KiB
C#
75 lines
1.9 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel;
|
|
using System.IO;
|
|
using System.Linq;
|
|
using System.Windows;
|
|
using System.Windows.Controls;
|
|
using System.Windows.Forms;
|
|
using System.Windows.Input;
|
|
|
|
using BeWo.Annotations;
|
|
using BeWo.Core;
|
|
using BeWo.ServiceProxy;
|
|
using BeWo.Validation;
|
|
using BeWo.View;
|
|
using BeWo.View.Controls;
|
|
using BeWo.ViewModel;
|
|
using BeWo.ViewModel.ListViewModel;
|
|
|
|
using BS.Shared;
|
|
using BS.Shared.Core;
|
|
using BS.Shared.DataContracts;
|
|
using BS.Shared.Extensions;
|
|
using BS.Shared.Translation;
|
|
using DevExpress.Utils;
|
|
using DevExpress.Xpf.Editors;
|
|
using DevExpress.Xpf.Grid;
|
|
using MessageBox = System.Windows.MessageBox;
|
|
|
|
namespace BeWo.AI.View
|
|
{
|
|
public partial class AiChatView : BeWoView
|
|
{
|
|
|
|
public event Action CloseButtonClicked;
|
|
private long cb2scOid;
|
|
private DateTime startDate;
|
|
private DateTime endDate;
|
|
|
|
public AiChatView(long c2sOid, DateTime start, DateTime end)
|
|
{
|
|
InitializeComponent();
|
|
this.cb2scOid = c2sOid;
|
|
this.startDate = start;
|
|
this.endDate = end;
|
|
}
|
|
|
|
|
|
|
|
private void ReloadViewModel(AiChatDC dc)
|
|
{
|
|
TextBoxErgebnis.Text = dc.Result;
|
|
}
|
|
|
|
private void btnSend_Click(object sender, RoutedEventArgs e)
|
|
{
|
|
var acdc = new AiChatDC();
|
|
acdc.Prompt = TextBoxAnfrage.Text;
|
|
|
|
ServiceFacade.DoOperationsServiceAsync(s => s.CreateAiQueryForServiceRecords(acdc, cb2scOid, startDate, endDate),
|
|
dc =>
|
|
{
|
|
this.Dispatch(delegate
|
|
{
|
|
ReloadViewModel(dc);
|
|
});
|
|
});
|
|
}
|
|
private void btnClose_Click(object sender, RoutedEventArgs e)
|
|
{
|
|
CloseButtonClicked?.Invoke();
|
|
}
|
|
}
|
|
}
|