aktueller stand
This commit is contained in:
@@ -12,7 +12,7 @@ using static C4IT.Logging.cLogManager;
|
||||
namespace FasdDesktopUi.Basics.Services.SupportCase.Controllers
|
||||
{
|
||||
/// <summary>
|
||||
/// Used to manage the <see cref="ISupportCase"/> for the UI via the <see cref="SupportCaseProcessor"/>"
|
||||
/// Used to manage the <see cref="ISupportCase"/> for the UI via the <see cref="SupportCaseProcessor"/>
|
||||
/// </summary>
|
||||
public class SupportCaseController
|
||||
{
|
||||
@@ -81,8 +81,8 @@ namespace FasdDesktopUi.Basics.Services.SupportCase.Controllers
|
||||
}
|
||||
}
|
||||
|
||||
private void HandleAvailableCaseRelationsAdded(object sender, RelationEventArgs e)
|
||||
=> AvailableCaseRelationsAdded?.Invoke(this, e);
|
||||
private void HandleAvailableCaseRelationsAdded(object sender, RelationEventArgs e)
|
||||
=> AvailableCaseRelationsAdded?.Invoke(this, e);
|
||||
|
||||
private void HandleCaseDataChanged(object sender, SupportCaseDataEventArgs e)
|
||||
{
|
||||
@@ -127,13 +127,16 @@ namespace FasdDesktopUi.Basics.Services.SupportCase.Controllers
|
||||
|
||||
SupportCaseDataProviderArtifact.HealthCardDataHelper.TrySetSelectedHealthcard(requiredInformationClasses);
|
||||
|
||||
_focusedRelation = relation;
|
||||
|
||||
if (!_selectedRelations.Values.Contains(relation))
|
||||
_hasDirectionConnection = false;
|
||||
|
||||
_selectedRelations[cF4sdIdentityEntry.GetFromSearchResult(relation.Type)] = relation;
|
||||
_ = Task.Run(async () => await UpdateStatusOfSelectedRelations());
|
||||
_focusedRelation = relation;
|
||||
|
||||
if (!_selectedRelations.Values.Contains(relation) || relation.Type == enumF4sdSearchResultClass.Computer)
|
||||
{
|
||||
_hasDirectionConnection = false;
|
||||
SupportCaseDataProviderArtifact.DirectConnectionHelper.Reset();
|
||||
}
|
||||
|
||||
_selectedRelations[cF4sdIdentityEntry.GetFromSearchResult(relation.Type)] = relation;
|
||||
_ = Task.Run(async () => await UpdateStatusOfSelectedRelations());
|
||||
|
||||
var focusedRelations = new cF4sdApiSearchResultRelation[1] { _focusedRelation };
|
||||
FocusedRelationsChanged?.Invoke(this, new RelationEventArgs()
|
||||
@@ -147,7 +150,7 @@ namespace FasdDesktopUi.Basics.Services.SupportCase.Controllers
|
||||
}
|
||||
}
|
||||
|
||||
private async Task UpdateStatusOfSelectedRelations()
|
||||
private async Task UpdateStatusOfSelectedRelations()
|
||||
{
|
||||
const string StatusString = "Status";
|
||||
|
||||
@@ -220,9 +223,8 @@ namespace FasdDesktopUi.Basics.Services.SupportCase.Controllers
|
||||
catch (Exception ex)
|
||||
{
|
||||
LogException(ex);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public async Task RefreshDataForCurrentlyFocusedRelationAsync()
|
||||
{
|
||||
|
||||
@@ -65,18 +65,19 @@ namespace FasdDesktopUi.Basics.Services.SupportCase
|
||||
if (relations is null)
|
||||
return;
|
||||
|
||||
foreach (var relationType in relations)
|
||||
{
|
||||
if (_caseRelations.TryGetValue(relationType.Key, out var caseRelation))
|
||||
caseRelation = caseRelation.Union(relationType).ToList();
|
||||
else
|
||||
_caseRelations.Add(relationType.Key, relationType.ToList());
|
||||
|
||||
if (SupportCaseDataProviderArtifact?.CaseRelations?.TryGetValue(relationType.Key, out var caseRelations) ?? false)
|
||||
caseRelations = caseRelations.Union(relationType).ToList();
|
||||
else
|
||||
SupportCaseDataProviderArtifact?.CaseRelations?.Add(relationType.Key, relationType.ToList());
|
||||
}
|
||||
foreach (var relationType in relations)
|
||||
{
|
||||
//TODO Max fragen obs passt! Bug: in den Ticketrelations (Header Ticketauswahl) sind nur zwei Tickets sichtbar anstatt 5 oder mehr..
|
||||
if (_caseRelations.TryGetValue(relationType.Key, out var caseRelation))
|
||||
_caseRelations[relationType.Key] = caseRelation.Union(relationType).ToList();
|
||||
else
|
||||
_caseRelations.Add(relationType.Key, relationType.ToList());
|
||||
|
||||
if (SupportCaseDataProviderArtifact?.CaseRelations?.TryGetValue(relationType.Key, out var caseRelations) ?? false)
|
||||
SupportCaseDataProviderArtifact.CaseRelations[relationType.Key] = caseRelations.Union(relationType).ToList();
|
||||
else
|
||||
SupportCaseDataProviderArtifact?.CaseRelations?.Add(relationType.Key, relationType.ToList());
|
||||
}
|
||||
|
||||
CaseRelationsAdded?.Invoke(this, new RelationEventArgs() { Relations = relations });
|
||||
}
|
||||
|
||||
@@ -68,8 +68,6 @@ namespace FasdDesktopUi.Basics.UserControls
|
||||
};
|
||||
|
||||
private const string CategoryTableNamePrimary = "M42Wpm-Ticket-Categories";
|
||||
private const string CategoryTableNameLegacy = "M42Wpm-Ticket-CloseCase-Categories";
|
||||
private string activeCategoryTableName = CategoryTableNamePrimary;
|
||||
|
||||
private static readonly Brush SharedValidationBorderBrush = CreateValidationBrush();
|
||||
private static readonly Brush DefaultTextBoxBorderBrush = CreateDefaultTextBoxBorderBrush();
|
||||
@@ -1009,20 +1007,7 @@ namespace FasdDesktopUi.Basics.UserControls
|
||||
|
||||
isCategoryLoading = true;
|
||||
|
||||
var tableCandidates = new[] { CategoryTableNamePrimary, CategoryTableNameLegacy };
|
||||
bool initialized = false;
|
||||
|
||||
foreach (var tableName in tableCandidates)
|
||||
{
|
||||
if (await TryPopulateCategoryHierarchyAsync(tableName))
|
||||
{
|
||||
activeCategoryTableName = tableName;
|
||||
initialized = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (initialized)
|
||||
if (await TryPopulateCategoryHierarchyAsync(CategoryTableNamePrimary))
|
||||
{
|
||||
CategorySelectionControl.ItemsSource = categoryHierarchy;
|
||||
TrySelectTicketCategoryFromTicketInfos();
|
||||
|
||||
@@ -70,10 +70,8 @@ namespace FasdDesktopUi.Basics.UserControls
|
||||
};
|
||||
|
||||
private const string CategoryTableNamePrimary = "M42Wpm-Ticket-Categories";
|
||||
private const string CategoryTableNameLegacy = "M42Wpm-Ticket-CloseCase-Categories";
|
||||
private const string TicketDetailsTableName = "M42Wpm-Tickets";
|
||||
private const string TicketDetailsCategoryIdColumnName = "CategoryId";
|
||||
private string activeCategoryTableName = CategoryTableNamePrimary;
|
||||
|
||||
private static readonly Brush SharedValidationBorderBrush = CreateValidationBrush();
|
||||
private static readonly Brush DefaultTextBoxBorderBrush = CreateDefaultTextBoxBorderBrush();
|
||||
@@ -1014,20 +1012,7 @@ namespace FasdDesktopUi.Basics.UserControls
|
||||
|
||||
isCategoryLoading = true;
|
||||
|
||||
var tableCandidates = new[] { CategoryTableNamePrimary, CategoryTableNameLegacy };
|
||||
bool initialized = false;
|
||||
|
||||
foreach (var tableName in tableCandidates)
|
||||
{
|
||||
if (await TryPopulateCategoryHierarchyAsync(tableName))
|
||||
{
|
||||
activeCategoryTableName = tableName;
|
||||
initialized = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (initialized)
|
||||
if (await TryPopulateCategoryHierarchyAsync(CategoryTableNamePrimary))
|
||||
{
|
||||
CategorySelectionControl.ItemsSource = categoryHierarchy;
|
||||
TrySelectTicketCategoryFromTicketInfos();
|
||||
|
||||
@@ -880,33 +880,33 @@
|
||||
</UIItem>
|
||||
|
||||
<UIItem Name="QuickAction.Remote.Copy.Description">
|
||||
<Language Lang="EN">The Quick Action '{0}' was {3}executed remotely by F4SD on the device '{1}' at {2}.</Language>
|
||||
<Language Lang="DE">Die Quick Action "{0}" wurde durch F4SD remote auf dem Gerät "{1}" am {2} {3}ausgeführt.</Language>
|
||||
<Language Lang="EN">The Quick Action '{0}' was {3}executed remotely by F4SD on the device '{1}' at {2} UTC.</Language>
|
||||
<Language Lang="DE">Die Quick Action "{0}" wurde durch F4SD remote auf dem Gerät "{1}" am {2} UTC {3}ausgeführt.</Language>
|
||||
</UIItem>
|
||||
|
||||
<UIItem Name="QuickAction.Remote.Copy.Description.Html">
|
||||
<Language Lang="EN">The Quick Action <b>'{0}'</b> was <b>{3}</b>executed remotely by F4SD on the device <b>'{1}'</b> at {2}.</Language>
|
||||
<Language Lang="DE">Die Quick Action <b>"{0}"</b> wurde durch F4SD remote auf dem Gerät <b>"{1}"</b> am {2} <b>{3}</b>ausgeführt.</Language>
|
||||
<Language Lang="EN">The Quick Action <b>'{0}'</b> was <b>{3}</b>executed remotely by F4SD on the device <b>'{1}'</b> at {2} UTC.</Language>
|
||||
<Language Lang="DE">Die Quick Action <b>"{0}"</b> wurde durch F4SD remote auf dem Gerät <b>"{1}"</b> am {2} UTC <b>{3}</b>ausgeführt.</Language>
|
||||
</UIItem>
|
||||
|
||||
<UIItem Name="QuickAction.RemoteSession.Copy.Description">
|
||||
<Language Lang="EN">The Quick Action '{0}' was {3}executed remotely by F4SD for the session '{1}' at {2}.</Language>
|
||||
<Language Lang="DE">Die Quick Action "{0}" wurde durch F4SD remote für die Session "{1}" am {2} {3}ausgeführt.</Language>
|
||||
<Language Lang="EN">The Quick Action '{0}' was {3}executed remotely by F4SD for the session '{1}' at {2} UTC.</Language>
|
||||
<Language Lang="DE">Die Quick Action "{0}" wurde durch F4SD remote für die Session "{1}" am {2} UTC {3}ausgeführt.</Language>
|
||||
</UIItem>
|
||||
|
||||
<UIItem Name="QuickAction.RemoteSession.Copy.Description.Html">
|
||||
<Language Lang="EN">The Quick Action <b>'{0}'</b> was <b>{3}</b>executed remotely by F4SD on the session <b>'{1}'</b> at {2}.</Language>
|
||||
<Language Lang="DE">Die Quick Action <b>"{0}"</b> wurde durch F4SD remote für die Session <b>"{1}"</b> am {2} <b>{3}</b>ausgeführt.</Language>
|
||||
<Language Lang="EN">The Quick Action <b>'{0}'</b> was <b>{3}</b>executed remotely by F4SD on the session <b>'{1}'</b> at {2} UTC.</Language>
|
||||
<Language Lang="DE">Die Quick Action <b>"{0}"</b> wurde durch F4SD remote für die Session <b>"{1}"</b> am {2} UTC <b>{3}</b>ausgeführt.</Language>
|
||||
</UIItem>
|
||||
|
||||
<UIItem Name="QuickAction.Local.Copy.Description">
|
||||
<Language Lang="EN">The Quick Action '{0}' was {3}executed local by F4SD for the device '{1}' at {2}.</Language>
|
||||
<Language Lang="DE">Die Quick Action "{0}" wurde durch F4SD lokal für das Gerät "{1}" am {2} {3}ausgeführt.</Language>
|
||||
<Language Lang="EN">The Quick Action '{0}' was {3}executed local by F4SD for the device '{1}' at {2} UTC.</Language>
|
||||
<Language Lang="DE">Die Quick Action "{0}" wurde durch F4SD lokal für das Gerät "{1}" am {2} UTC {3}ausgeführt.</Language>
|
||||
</UIItem>
|
||||
|
||||
<UIItem Name="QuickAction.Local.Copy.Description.Html">
|
||||
<Language Lang="EN">The Quick Action <b>'{0}'</b> was <b>{3}</b>executed local by F4SD for the device <b>'{1}'</b> at {2}.</Language>
|
||||
<Language Lang="DE">Die Quick Action <b>"{0}"</b> wurde durch F4SD lokal für Gerät <b>"{1}"</b> am {2} <b>{3}</b>ausgeführt.</Language>
|
||||
<Language Lang="EN">The Quick Action <b>'{0}'</b> was <b>{3}</b>executed local by F4SD for the device <b>'{1}'</b> at {2} UTC.</Language>
|
||||
<Language Lang="DE">Die Quick Action <b>"{0}"</b> wurde durch F4SD lokal für Gerät <b>"{1}"</b> am {2} UTC<b>{3}</b>ausgeführt.</Language>
|
||||
</UIItem>
|
||||
|
||||
<UIItem Name="QuickAction.Copy.RevisionStatus.Successfull">
|
||||
|
||||
@@ -106,5 +106,4 @@
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
</ResourceDictionary>
|
||||
</ResourceDictionary>
|
||||
@@ -1461,4 +1461,4 @@
|
||||
|
||||
<!--#endregion-->
|
||||
|
||||
</ResourceDictionary>
|
||||
</ResourceDictionary>
|
||||
Reference in New Issue
Block a user