Completata UI + API x richiesta task e display task specifici (da completare lato EgwAppControlCenter ora)

This commit is contained in:
Samuele Locatelli
2025-01-18 16:58:59 +01:00
parent 228d2af96c
commit 247f74a575
16 changed files with 91 additions and 86 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
<body>
<i>License Manager</i>
<h4>Versione: 2.1.2501.1815</h4>
<h4>Versione: 2.1.2501.1816</h4>
<br /> Note di rilascio:
<ul>
<li>
+1 -1
View File
@@ -1 +1 @@
2.1.2501.1815
2.1.2501.1816
+1 -1
View File
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<item>
<version>2.1.2501.1815</version>
<version>2.1.2501.1816</version>
<url>https://nexus.steamware.net/repository/SWS/LiMan/stable/LAST/LiMan.UI.zip</url>
<changelog>https://nexus.steamware.net/repository/SWS/LiMan/stable/LAST/ChangeLog.html</changelog>
<mandatory>false</mandatory>
+1 -1
View File
@@ -1,6 +1,6 @@
<body>
<i>License Manager</i>
<h4>Versione: 2.1.2501.1815</h4>
<h4>Versione: 2.1.2501.1816</h4>
<br />
Note di rilascio:
<ul>
+1 -1
View File
@@ -1 +1 @@
2.1.2501.1815
2.1.2501.1816
+1 -1
View File
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<item>
<version>2.1.2501.1815</version>
<version>2.1.2501.1816</version>
<url>https://nexus.steamware.net/repository/SWS/LiMan/stable/LAST/LiMan.Transfer.zip</url>
<changelog>https://nexus.steamware.net/repository/SWS/LiMan/stable/LAST/ChangeLog.html</changelog>
<mandatory>false</mandatory>
+16 -51
View File
@@ -55,59 +55,24 @@
</div>
</div>
</div>
<div class="@CssDivDetail px-1">
<div class="@CssDivDetail px-2">
@if (HasFiltImp)
{
<div class="card shadow">
<div class="card-body p-2">
<div class="row">
<div class="col-5 px-1">
<ListAppShort AppList="AppInstList"></ListAppShort>
<div class="card shadow mt-2">
<div class="card-header">
<b>Detail Info</b>
</div>
<div class="card-body p-1">
<ul class="list-group">
<li class="list-group-item">TDB Info 5</li>
<li class="list-group-item">TDB Info 6</li>
<li class="list-group-item">TDB Info 7</li>
<li class="list-group-item">TDB Info 8</li>
<li class="list-group-item">TDB Info 9</li>
</ul>
</div>
</div>
</div>
<div class="col-7 px-1">
<div class="card shadow">
<div class="card-header">
<b>Device Info</b>
</div>
<div class="card-body p-1">
@if (DevInfo != null && DevInfo.Count > 0)
{
<ListInfoShort DetailInfo="DevInfo"></ListInfoShort>
// <ul class="list-group small">
// @foreach (var item in DevInfo)
// {
// <li class="list-group-item d-flex justify-content-between align-items-start px-1">
// <div class="px-1">
// @item.Key
// </div>
// <div class="px-1">
// <b>@item.Value</b>
// </div>
// </li>
// }
// </ul>
}
else
{
<div class="alert alert-warning p-2 text-center">No Info Present</div>
}
</div>
</div>
</div>
<div class="row">
<div class="col-6 px-1">
<div class="mb-1">
<ListAppShort AppList="AppInstList"></ListAppShort>
</div>
<div class="mb-1">
<ListInfoShort Title="License Data" DetailInfo="LicInfo"></ListInfoShort>
</div>
</div>
<div class="col-6 px-1">
<div class="mb-1">
<ListInfoShort Title="Device Info" DetailInfo="DevInfo"></ListInfoShort>
</div>
<div class="mb-1">
<ListInfoShort Title="Updater Stats" DetailInfo="RunStats"></ListInfoShort>
</div>
</div>
</div>
+29 -2
View File
@@ -223,6 +223,8 @@ namespace LiMan.UI.Components
private bool showDetail = false;
private Dictionary<string, string> DevInfo = new Dictionary<string, string>();
private Dictionary<string, string> RunStats = new Dictionary<string, string>();
private Dictionary<string, string> LicInfo = new Dictionary<string, string>();
#region Private Properties
@@ -460,17 +462,42 @@ namespace LiMan.UI.Components
private void ReloadTaskResults()
{
DevInfo = new Dictionary<string, string>();
RunStats = new Dictionary<string, string>();
LicInfo = new Dictionary<string, string>();
if (TaskDone != null && TaskDone.Count > 0)
{
if (TaskDone.ContainsKey($"{EgwAccTask.DeviceInfoGet}"))
// cerco Device Info specifiche
string devInfoKey = $"{EgwAccTask.DeviceInfoGet}";
if (TaskDone.ContainsKey(devInfoKey))
{
string rawData = TaskDone[$"{EgwAccTask.DeviceInfoGet}"];
string rawData = TaskDone[devInfoKey];
if (!string.IsNullOrEmpty(rawData) && rawData.Count() > 2)
{
DevInfo = JsonConvert.DeserializeObject<Dictionary<string, string>>(rawData);
}
}
// cerco Info Stats
if (TaskDone.ContainsKey("RunStats"))
{
string rawData = TaskDone["RunStats"];
if (!string.IsNullOrEmpty(rawData) && rawData.Count() > 2)
{
RunStats = JsonConvert.DeserializeObject<Dictionary<string, string>>(rawData);
}
}
// cerco Info License
if (TaskDone.ContainsKey("LicInfo"))
{
string rawData = TaskDone["LicInfo"];
if (!string.IsNullOrEmpty(rawData) && rawData.Count() > 2)
{
LicInfo = JsonConvert.DeserializeObject<Dictionary<string, string>>(rawData);
}
}
}
}
+1 -1
View File
@@ -119,7 +119,7 @@
<button class="btn w-100 btn-sm btn-info" @onclick="() => SendTask(Core.Enum.EgwAccTask.DeviceInfoGet)">Update Device Info</button>
</div>
<div class="py-1">
<button class="btn w-100 btn-sm btn-warning disabled" @onclick="() => SendTask(Core.Enum.EgwAccTask.OxyLicenseGet)">Update Info Licenza</button>
<button class="btn w-100 btn-sm btn-warning" @onclick="() => SendTask(Core.Enum.EgwAccTask.OxyLicenseGet)">Update Info Licenza</button>
</div>
<div class="py-1">
<button class="btn w-100 btn-sm btn-danger" @onclick="() => SendTask(Core.Enum.EgwAccTask.ForceUpdate)">Force Reboot</button>
+3
View File
@@ -1,4 +1,7 @@
<div class="card shadow">
<div class="card-header">
<b>App Info</b>
</div>
<div class="card-body p-1">
<table class="table table-sm table-striped table-responsive-lg small">
<thead>
+31 -21
View File
@@ -1,28 +1,38 @@
<div class="card shadow">
<div class="card-header">
<b>Device Info</b>
</div>
<div class="card-body p-1">
<table class="table table-sm table-striped table-responsive-lg small">
<thead>
<tr>
<th>
Key
<Sorter ParamName="Key" IsAsc="@sortAsc" CurrParam="@sortField" sortReq="SortRequested"></Sorter>
</th>
<th class="text-right">
Value
<Sorter ParamName="Value" IsAsc="@sortAsc" CurrParam="@sortField" sortReq="SortRequested"></Sorter>
</th>
</tr>
</thead>
<tbody>
@foreach (var item in ListRecord)
{
@if (DetailInfo == null && totalCount == 0)
{
<div class="alert alert-warning p-2 text-center">No Info Present</div>
}
else
{
<table class="table table-sm table-striped table-responsive-lg small">
<thead>
<tr>
<td>@item.Key</td>
<td class="text-right small">@item.Value</td>
<th>
Key
<Sorter ParamName="Key" IsAsc="@sortAsc" CurrParam="@sortField" sortReq="SortRequested"></Sorter>
</th>
<th class="text-right">
Value
<Sorter ParamName="Value" IsAsc="@sortAsc" CurrParam="@sortField" sortReq="SortRequested"></Sorter>
</th>
</tr>
}
</tbody>
</table>
</thead>
<tbody>
@foreach (var item in ListRecord)
{
<tr>
<td>@item.Key</td>
<td class="text-right small">@item.Value</td>
</tr>
}
</tbody>
</table>
}
</div>
<div class="card-footer p-0 small">
<DataPager PageSize="numRecord" currPage="currPage" numRecordChanged="setNumRec" numPageChanged="setNumPage" totalCount="totalCount" showLoading="isLoading" DisplSize="DataPager.ObjSize.small" NumPages="3" />
+1 -1
View File
@@ -63,7 +63,7 @@ namespace LiMan.UI.Components
private int currPage = 1;
private bool isLoading = false;
private Dictionary<string, string> ListRecord = new Dictionary<string, string>();
private int numRecord = 10;
private int numRecord = 5;
private Dictionary<string, string> SearchRecord = new Dictionary<string, string>();
private string sKey = "ListAppShort";
private int totalCount = 0;
+1 -1
View File
@@ -2,7 +2,7 @@
<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<Version>2.1.2501.1815</Version>
<Version>2.1.2501.1816</Version>
<RootNamespace>LiMan.UI</RootNamespace>
<AssemblyName>LiMan.UI</AssemblyName>
</PropertyGroup>
+1 -1
View File
@@ -1,6 +1,6 @@
<body>
<i>License Manager</i>
<h4>Versione: 2.1.2501.1815</h4>
<h4>Versione: 2.1.2501.1816</h4>
<br /> Note di rilascio:
<ul>
<li>
+1 -1
View File
@@ -1 +1 @@
2.1.2501.1815
2.1.2501.1816
+1 -1
View File
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<item>
<version>2.1.2501.1815</version>
<version>2.1.2501.1816</version>
<url>https://nexus.steamware.net/repository/SWS/LiMan/stable/LAST/LiMan.UI.zip</url>
<changelog>https://nexus.steamware.net/repository/SWS/LiMan/stable/LAST/ChangeLog.html</changelog>
<mandatory>false</mandatory>