Aggiunto forzatura update pagina dettaglio progetto
This commit is contained in:
@@ -8,9 +8,3 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@code {
|
||||
protected DateTime adesso = DateTime.Now;
|
||||
|
||||
Version version = typeof(Program).Assembly.GetName().Version;
|
||||
|
||||
}
|
||||
@@ -0,0 +1,69 @@
|
||||
// Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this
|
||||
// file to you under the MIT license.
|
||||
namespace MagMan.UI.Components
|
||||
{
|
||||
public partial class CmpFooter : IDisposable
|
||||
{
|
||||
#region Public Methods
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (aTimer != null)
|
||||
{
|
||||
aTimer.Elapsed -= ElapsedTimer;
|
||||
aTimer.Stop();
|
||||
aTimer.Dispose();
|
||||
}
|
||||
}
|
||||
|
||||
#endregion Public Methods
|
||||
|
||||
#region Protected Fields
|
||||
|
||||
protected DateTime adesso = DateTime.Now;
|
||||
|
||||
#endregion Protected Fields
|
||||
|
||||
#region Protected Methods
|
||||
|
||||
protected void ElapsedTimer(object? source, System.Timers.ElapsedEventArgs e)
|
||||
{
|
||||
var pUpd = Task.Run(async () =>
|
||||
{
|
||||
adesso = DateTime.Now;
|
||||
await InvokeAsync(StateHasChanged);
|
||||
});
|
||||
pUpd.Wait();
|
||||
}
|
||||
|
||||
protected override void OnParametersSet()
|
||||
{
|
||||
var rawVers = typeof(Program).Assembly.GetName().Version;
|
||||
version = rawVers != null ? rawVers : new Version("0.0.0.0");
|
||||
StartTimer();
|
||||
}
|
||||
|
||||
protected void StartTimer()
|
||||
{
|
||||
if (aTimer != null)
|
||||
{
|
||||
aTimer.Stop();
|
||||
aTimer.Dispose();
|
||||
}
|
||||
int tOutPeriod = 1000;
|
||||
aTimer = new System.Timers.Timer(tOutPeriod);
|
||||
aTimer.Elapsed += ElapsedTimer;
|
||||
aTimer.Enabled = true;
|
||||
aTimer.Start();
|
||||
}
|
||||
|
||||
#endregion Protected Methods
|
||||
|
||||
#region Private Fields
|
||||
|
||||
private System.Timers.Timer aTimer = null!;
|
||||
private Version version = null!;
|
||||
|
||||
#endregion Private Fields
|
||||
}
|
||||
}
|
||||
@@ -5,6 +5,7 @@
|
||||
<h5>Risorse Consumate</h5>
|
||||
</div>
|
||||
<div class="px-2">
|
||||
<button class="btn btn-primary btn-sm" @onclick="() => ForceReload(true)"><i class="fa-solid fa-rotate"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -77,6 +77,8 @@ namespace MagMan.UI.Components
|
||||
|
||||
protected async Task ForceReload(bool force)
|
||||
{
|
||||
isLoading = true;
|
||||
await Task.Delay(1);
|
||||
CurrItem = null;
|
||||
await ReloadData();
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
<h5>Previsione Consumi Risorse</h5>
|
||||
</div>
|
||||
<div class="px-2">
|
||||
<button class="btn btn-primary btn-sm" @onclick="() => ForceReload(true)"><i class="fa-solid fa-rotate"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -76,6 +76,8 @@ namespace MagMan.UI.Components
|
||||
|
||||
protected async Task ForceReload(bool force)
|
||||
{
|
||||
isLoading = true;
|
||||
await Task.Delay(1);
|
||||
CurrItem = null;
|
||||
await ReloadData();
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<Version>1.0.2406.2911</Version>
|
||||
<Version>1.0.2406.2913</Version>
|
||||
<Nullable>enable</Nullable>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<EnableNETAnalyzers>true</EnableNETAnalyzers>
|
||||
|
||||
@@ -54,6 +54,7 @@ namespace MagMan.UI.Pages
|
||||
protected void SaveProj(ProjModel? newRec)
|
||||
{
|
||||
ProjSel = newRec;
|
||||
ProjDbId = newRec != null ? newRec.ProjDbId : 0;
|
||||
}
|
||||
|
||||
#endregion Protected Methods
|
||||
@@ -62,14 +63,14 @@ namespace MagMan.UI.Pages
|
||||
|
||||
private int KeyNum = 0;
|
||||
|
||||
private ProjModel? ProjSel = null;
|
||||
|
||||
#endregion Private Fields
|
||||
|
||||
#region Private Properties
|
||||
|
||||
private int CustomerID { get; set; } = 0;
|
||||
private bool isLoading { get; set; } = false;
|
||||
private int ProjDbId { get; set; } = 0;
|
||||
private ProjModel? ProjSel { get; set; } = null;
|
||||
|
||||
#endregion Private Properties
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<body>
|
||||
<i>MagMan - Wood Warehouse Management System</i>
|
||||
<h4>Versione: 1.0.2406.2911</h4>
|
||||
<h4>Versione: 1.0.2406.2913</h4>
|
||||
<br /> Note di rilascio:
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
@@ -1 +1 @@
|
||||
1.0.2406.2911
|
||||
1.0.2406.2913
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<item>
|
||||
<version>1.0.2406.2911</version>
|
||||
<version>1.0.2406.2913</version>
|
||||
<url>http://nexus.steamware.net/repository/SWS/MagMan/stable/0/MagMan.UI.zip</url>
|
||||
<changelog>http://nexus.steamware.net/repository/SWS/MagMan/stable/0/ChangeLog.html</changelog>
|
||||
<mandatory>false</mandatory>
|
||||
|
||||
Reference in New Issue
Block a user