diff --git a/GPW.CORE.UI/Components/AddRA.razor b/GPW.CORE.UI/Components/AddRA.razor
index 101066a..3113709 100644
--- a/GPW.CORE.UI/Components/AddRA.razor
+++ b/GPW.CORE.UI/Components/AddRA.razor
@@ -48,7 +48,10 @@
// recupero ultima fase x utente...
newItem = await GDataServ.RegAttLastByDip(1);
}
- durata = newItem.Durata;
+ // calcolo durata arrotondata ai 5 minuti...
+ TimeOnly step = new TimeOnly(0, 5);
+ long ticks = (newItem.Durata.Ticks + step.Ticks - 1) / step.Ticks;
+ durata = new TimeSpan(ticks * step.Ticks);
newItem.IdxRa = 0;
newItem.Inizio = InizioPer;
newItem.Fine = InizioPer.AddMinutes(durata.TotalMinutes);
diff --git a/GPW.CORE.UI/Components/DayHoriz.razor b/GPW.CORE.UI/Components/DayHoriz.razor
index 8f35dc8..18fdcae 100644
--- a/GPW.CORE.UI/Components/DayHoriz.razor
+++ b/GPW.CORE.UI/Components/DayHoriz.razor
@@ -26,6 +26,7 @@
}
else
{
+
@if (@DayDTO != null && @DayDTO.ListTimbr != null)
{
@@ -35,10 +36,11 @@
}
}
+
@if (@noData)
{
-
+
}
else if (@DayDTO != null && @DayDTO.ListRA != null)
{
diff --git a/GPW.CORE.UI/Components/DayHoriz.razor.cs b/GPW.CORE.UI/Components/DayHoriz.razor.cs
index b692699..55ddb68 100644
--- a/GPW.CORE.UI/Components/DayHoriz.razor.cs
+++ b/GPW.CORE.UI/Components/DayHoriz.razor.cs
@@ -173,6 +173,11 @@ namespace GPW.CORE.UI.Components
}
}
+ ///
+ /// record prima timbratura x
+ ///
+ protected DateTime FirstTimb = DateTime.Now;
+
private List
ListTimb()
{
// init
@@ -190,6 +195,20 @@ namespace GPW.CORE.UI.Components
var timbOUT = DayDTO.ListTimbr.Where(x => x.Entrata == false).ToList();
DateTime fineLav = currHour;
+ // sistemo la prima timbratura
+ if (timbIN.Count > 0)
+ {
+ var firstRec = timbIN.OrderBy(x => x.DataOra).FirstOrDefault();
+ if (firstRec != null)
+ {
+ // calcolo dataora approssimata arrotondando ai 5 minuti x difetto...
+ // https://stackoverflow.com/questions/1393696/rounding-datetime-objects
+ TimeOnly step = new TimeOnly(0, 5);
+ long ticks = (firstRec.DataOra.Ticks + step.Ticks - 1) / step.Ticks;
+ FirstTimb = new DateTime(ticks * step.Ticks, firstRec.DataOra.Kind);
+ }
+ }
+
// ciclo partendo dal primo evento timbratura IN ed aggiungendo eventuali periodi in testa / coda / intermedi
foreach (var item in timbIN)
{
diff --git a/GPW.CORE.UI/GPW.CORE.UI.csproj b/GPW.CORE.UI/GPW.CORE.UI.csproj
index 91f810e..bd78804 100644
--- a/GPW.CORE.UI/GPW.CORE.UI.csproj
+++ b/GPW.CORE.UI/GPW.CORE.UI.csproj
@@ -2,7 +2,7 @@
net6.0
- 3.0.2201.1119
+ 3.0.2201.1210
enable
enable
diff --git a/GPW.CORE.UI/Pages/Planner.razor b/GPW.CORE.UI/Pages/Planner.razor
index 90ea455..959a2b5 100644
--- a/GPW.CORE.UI/Pages/Planner.razor
+++ b/GPW.CORE.UI/Pages/Planner.razor
@@ -38,44 +38,24 @@ else if (ListTimbr != null)
-
-
MoveWeek(-4)" title="-4 settimane">
+ MoveWeek(-4)" title="-4 settimane" disabled="@isLoading">
@currWeekSel.inizio.ToString("dd.MM.yy")
- ShowSelPeriodo()" title="Imposta periodo">
+ ShowSelPeriodo()" title="Imposta periodo" disabled="@isLoading">
Week @currWeekNum.ToString("00")
@currYear
- MoveWeek(4)" title="+4 settimane">
+ MoveWeek(4)" title="+4 settimane" disabled="@isLoading">
@currWeekSel.fine.ToString("dd.MM.yy")
- @*
-
-
MoveWeek(-4)">
- @currWeekSel.inizio.ToString("dd.MM.yy")
-
-
-
-
-
ShowSelPeriodo()">
- W @currWeekNum.ToString("00")
- @currYear
-
-
-
-
MoveWeek(4)">
- @currWeekSel.fine.ToString("dd.MM.yy")
-
-
-
-
*@
@if (weekStatList != null)
diff --git a/Resources/ChangeLog.html b/Resources/ChangeLog.html
index 7368c90..557f98a 100644
--- a/Resources/ChangeLog.html
+++ b/Resources/ChangeLog.html
@@ -1,6 +1,6 @@
GPW - Gestione Presenze Web
-
Versione: 3.0.2201.1119
+
Versione: 3.0.2201.1210
Note di rilascio:
-
diff --git a/Resources/VersNum.txt b/Resources/VersNum.txt
index c432321..70e3b5e 100644
--- a/Resources/VersNum.txt
+++ b/Resources/VersNum.txt
@@ -1 +1 @@
-3.0.2201.1119
+3.0.2201.1210
diff --git a/Resources/manifest.xml b/Resources/manifest.xml
index b645831..abf405e 100644
--- a/Resources/manifest.xml
+++ b/Resources/manifest.xml
@@ -1,6 +1,6 @@
-
- 3.0.2201.1119
+ 3.0.2201.1210
http://nexus.steamware.net/repository/SWS/GWMS/stable/0/GWMS.UI.zip
http://nexus.steamware.net/repository/SWS/GWMS/stable/0/ChangeLog.html
false