added new property to ReportInitDto - rebuilt production

This commit is contained in:
Frede Hundewadt 2023-11-13 08:43:13 +01:00
parent b0f1712b16
commit 50a41ebd59
3 changed files with 8 additions and 5 deletions

View file

@ -116,7 +116,6 @@ public partial class AdvisorReportCreatePage : IDisposable
Report.Figures.Distance = 0;
Report.Figures.DistancePrivate = 0;
Report.Figures.DistancePrivateMonth = 0;
await GetKeyFigures();
Logger.LogDebug("OnInitializedAsync => GetKeyFigures <= {}", JsonSerializer.Serialize(Report));
@ -244,7 +243,8 @@ public partial class AdvisorReportCreatePage : IDisposable
}
// distance day check - only if not leave
if (Report.Figures.KmMorning > Report.Figures.KmEvening && !Report.DayTypeEnum.ToLower().Contains("leave"))
if (Report.Figures.KmMorning > Report.Figures.KmEvening &&
!Report.DayTypeEnum.Contains("leave", StringComparison.CurrentCultureIgnoreCase))
{
Toaster.ShowError("Km udregning er negativ - kontroller venligst km tal");
return;
@ -255,8 +255,10 @@ public partial class AdvisorReportCreatePage : IDisposable
DateTime checkOut;
// create a list of activity ids for the report
Report.ActivityIdList = _reportData.ReportItems.Select(x => x.ActivityId).ToList();
// Report.ActivityIdList = _reportData.ReportItems.Select(x => x.ActivityId).ToList();
Report.ActivityIdList = _reportData.ActivityIdList;
Logger.LogDebug("ActivityIdList => {}", JsonSerializer.Serialize(Report.ActivityIdList));
// create a date time object using workDate and workHour input
if (Report.DayTypeEnum.Contains("leave", StringComparison.CurrentCultureIgnoreCase))
{

View file

@ -1,8 +1,8 @@
{
"appInfo": {
"name": "Wonky Online",
"version": "301.0",
"rc": false,
"version": "302.0",
"rc": true,
"sandBox": true,
"image": "grumpy-coder.png",
"sdk": "dotnet 8.0"

View file

@ -24,4 +24,5 @@ public class ReportInitDto
public bool ReportClosed { get; set; }
public ReportFiguresView ReportData { get; set; } = new();
public List<ReportItemView> ReportItems { get; set; } = new();
public List<string> ActivityIdList { get; set; } = new();
}