This commit is contained in:
Adam 2025-10-21 09:03:49 +02:00
commit fb2d7fbe59
7 changed files with 199 additions and 160 deletions

View File

@ -35,7 +35,8 @@
<HintPath>..\..\..\..\Aycode\Source\AyCode.Core\AyCode.Services.Server\bin\FruitBank\Debug\net9.0\AyCode.Services.Server.dll</HintPath>
</Reference>
<Reference Include="Microsoft.AspNetCore.SignalR.Core">
<HintPath>C:\Program Files\dotnet\packs\Microsoft.AspNetCore.App.Ref\9.0.9\ref\net9.0\Microsoft.AspNetCore.SignalR.Core.dll</HintPath>
<!--<HintPath>C:\Program Files\dotnet\packs\Microsoft.AspNetCore.App.Ref\9.0.9\ref\net9.0\Microsoft.AspNetCore.SignalR.Core.dll</HintPath>-->
<HintPath>C:\Program Files\dotnet\packs\Microsoft.AspNetCore.App.Ref\9.0.10\ref\net9.0\Microsoft.AspNetCore.SignalR.Core.dll</HintPath>
</Reference>
<Reference Include="Mango.Nop.Core">
<HintPath>..\..\NopCommerce.Common\4.70\Libraries\Mango.Nop.Core\bin\FruitBank\Debug\net9.0\Mango.Nop.Core.dll</HintPath>

View File

@ -5,16 +5,29 @@ namespace FruitBankHybrid.Shared.Extensions;
public static class DevextremeComponentExtension
{
public static async Task ShowMessageBoxAsync(this IDialogService messageBox, string title, string text, MessageBoxRenderStyle messageBoxRenderStyle, MessageBoxType messageBoxType = MessageBoxType.Alert)
public static async Task ShowMessageBoxAsync(this IDialogService messageBox, string title, string text, MessageBoxRenderStyle messageBoxRenderStyle)
{
var messageBoxOptions = CreateMessageBoxOptions(title, text, messageBoxRenderStyle);
await messageBox.AlertAsync(messageBoxOptions);
}
public static async Task<bool> ShowConfirmBoxAsync(this IDialogService messageBox, string title, string text, MessageBoxRenderStyle messageBoxRenderStyle)
{
var messageBoxOptions = CreateMessageBoxOptions(title, text, messageBoxRenderStyle);
return await messageBox.ConfirmAsync(messageBoxOptions);
}
private static MessageBoxOptions CreateMessageBoxOptions(string title, string text, MessageBoxRenderStyle messageBoxRenderStyle)
{
var messageBoxOptions = new MessageBoxOptions
{
Title = title,
Text = text,
RenderStyle = messageBoxRenderStyle,
ShowIcon = false
};
if (messageBoxType == MessageBoxType.Alert) await messageBox.AlertAsync(messageBoxOptions);
else await messageBox.ConfirmAsync(messageBoxOptions);
return messageBoxOptions;
}
}

View File

@ -11,51 +11,59 @@
<h3>Bejövő mérés</h3>
<div style="margin-top: 50px;">
<DxFormLayout CaptionPosition="CaptionPosition.Vertical" CssClass="w-100">
<DxFormLayoutItem Caption="Érkezés dátuma" ColSpanMd="2" CaptionCssClass="@(SelectedShipping != null && _measuringDates.Where(x => MeasuringService.DaysEqual(x.DateTime, SelectedShipping.ShippingDate)).All(x => x.IsMeasured) ? "text-success" : "")">
<DxDateEdit CssClass="cw-320"
DisplayFormat="m"
Format="m"
Context="ctxShippingDate"
Date="@(SelectedShipping?.ShippingDate.Date ?? DateTime.Now.Date)"
CustomDisabledDate="@OnCustomDisabledMeasuringDate"
DateChanged="@((DateTime newValue) => OnMeasuringDateChanged(newValue))"
InputId="deDisabledDates">
<DayCellTemplate>
@{
var cssClass = GetMeasuringDateCssClassNames(ctxShippingDate);
if (!cssClass.IsNullOrWhiteSpace())
{
<a class="@GetMeasuringDateCssClassNames(ctxShippingDate)">@ctxShippingDate.Day.ToString()</a>
}
else
{
<a>@ctxShippingDate.Day.ToString()</a>
}
}
<DxLoadingPanel @bind-Visible="LoadingPanelVisible"
IsContentBlocked="true"
ApplyBackgroundShading="true"
IndicatorAreaVisible="true"
IsContentVisible="true"
IndicatorAnimationType="WaitIndicatorAnimationType.Spin"
Text="Adatok szinkronizálása folyamatban...">
</DayCellTemplate>
</DxDateEdit>
</DxFormLayoutItem>
<DxFormLayout CaptionPosition="CaptionPosition.Vertical" CssClass="w-100">
<DxFormLayoutItem Caption="Érkezés dátuma" ColSpanMd="2" CaptionCssClass="@(SelectedShipping != null && _measuringDates.Where(x => MeasuringService.DaysEqual(x.DateTime, SelectedShipping.ShippingDate)).All(x => x.IsMeasured) ? "text-success" : "")">
<DxDateEdit CssClass="cw-320"
DisplayFormat="m"
Format="m"
Context="ctxShippingDate"
Date="@(SelectedShipping?.ShippingDate.Date ?? DateTime.Now.Date)"
CustomDisabledDate="@OnCustomDisabledMeasuringDate"
DateChanged="@((DateTime newValue) => OnMeasuringDateChanged(newValue))"
InputId="deDisabledDates">
<DayCellTemplate>
@{
var cssClass = GetMeasuringDateCssClassNames(ctxShippingDate);
if (!cssClass.IsNullOrWhiteSpace())
{
<a class="@GetMeasuringDateCssClassNames(ctxShippingDate)">@ctxShippingDate.Day.ToString()</a>
}
else
{
<a>@ctxShippingDate.Day.ToString()</a>
}
}
<DxFormLayoutItem Caption="Kamion rendszáma:" ColSpanMd="2" CaptionCssClass="@(SelectedShipping?.IsAllMeasured == true ? "text-success" : "")">
<DxComboBox Data="@NotMeasuredShippings"
@bind-Value="@SelectedShipping"
Text="Select licence plate"
ValueFieldName="@nameof(Shipping.Id)"
TextFieldName="@nameof(Shipping.LicencePlate)"
CssClass="cw-480"
DropDownBodyCssClass="dd-body-class"
Context="ctxShipping"
SelectedDataItemChanged="@((SelectedDataItemChangedEventArgs<Shipping> args) => OnSelectedShippingChanged(args))"
InputId="cbNotMeasuredShippings">
<ItemDisplayTemplate>
<span class="@(ctxShipping.DataItem.IsAllMeasured ? "text-success" : "")">@ctxShipping.DisplayText</span>
</ItemDisplayTemplate>
</DxComboBox>
</DxFormLayoutItem>
@* <DxFormLayoutItem Caption="Partner:" ColSpanMd="3" CaptionCssClass="@(SelectedShippingDocument?.IsAllMeasured == true ? "text-success" : "")">
</DayCellTemplate>
</DxDateEdit>
</DxFormLayoutItem>
<DxFormLayoutItem Caption="Kamion rendszáma:" ColSpanMd="2" CaptionCssClass="@(SelectedShipping?.IsAllMeasured == true ? "text-success" : "")">
<DxComboBox Data="@NotMeasuredShippings"
@bind-Value="@SelectedShipping"
Text="Select licence plate"
ValueFieldName="@nameof(Shipping.Id)"
TextFieldName="@nameof(Shipping.LicencePlate)"
CssClass="cw-480"
DropDownBodyCssClass="dd-body-class"
Context="ctxShipping"
SelectedDataItemChanged="@((SelectedDataItemChangedEventArgs<Shipping> args) => OnSelectedShippingChanged(args))"
InputId="cbNotMeasuredShippings">
<ItemDisplayTemplate>
<span class="@(ctxShipping.DataItem.IsAllMeasured ? "text-success" : "")">@ctxShipping.DisplayText</span>
</ItemDisplayTemplate>
</DxComboBox>
</DxFormLayoutItem>
@* <DxFormLayoutItem Caption="Partner:" ColSpanMd="3" CaptionCssClass="@(SelectedShippingDocument?.IsAllMeasured == true ? "text-success" : "")">
<DxComboBox Data="@SelectedShipping?.ShippingDocuments"
@bind-Value="@SelectedShippingDocument"
Text="Select partner"
@ -72,26 +80,26 @@
</DxComboBox>
</DxFormLayoutItem>
*@
<DxFormLayoutItem Caption="Termék:" ColSpanMd="5" CaptionCssClass="@(SelectedShippingItem?.IsMeasured == true ? "text-success" : "")">
<DxComboBox Data="@_shippingItemsDataSource"
@bind-Value="@SelectedShippingItem"
Text="Select item"
ValueFieldName="@nameof(ShippingItem.Id)"
TextFieldName="@(nameof(ShippingItem.Name))"
CssClass="cw-480"
SearchMode="ListSearchMode.AutoSearch"
SearchFilterCondition="ListSearchFilterCondition.Contains"
SearchTextParseMode="ListSearchTextParseMode.GroupWordsByAnd"
ClearButtonDisplayMode="DataEditorClearButtonDisplayMode.Auto"
DropDownTriggerMode="DropDownTriggerMode.Click"
ListRenderMode="ListRenderMode.Entire"
ShowDropDownButton="false"
DropDownBodyCssClass="dd-body-class"
Context="ctxShippingitem"
SelectedDataItemChanged="@((SelectedDataItemChangedEventArgs<ShippingItem> args) => OnSelectedShippingItemChanged(args))"
InputId="cbShippingItem">
<ItemDisplayTemplate>
@* <div class="combobox-item-template">
<DxFormLayoutItem Caption="Termék:" ColSpanMd="5" CaptionCssClass="@(SelectedShippingItem?.IsMeasured == true ? "text-success" : "")">
<DxComboBox Data="@_shippingItemsDataSource"
@bind-Value="@SelectedShippingItem"
Text="Select item"
ValueFieldName="@nameof(ShippingItem.Id)"
TextFieldName="@(nameof(ShippingItem.Name))"
CssClass="cw-480"
SearchMode="ListSearchMode.AutoSearch"
SearchFilterCondition="ListSearchFilterCondition.Contains"
SearchTextParseMode="ListSearchTextParseMode.GroupWordsByAnd"
ClearButtonDisplayMode="DataEditorClearButtonDisplayMode.Auto"
DropDownTriggerMode="DropDownTriggerMode.Click"
ListRenderMode="ListRenderMode.Entire"
ShowDropDownButton="false"
DropDownBodyCssClass="dd-body-class"
Context="ctxShippingitem"
SelectedDataItemChanged="@((SelectedDataItemChangedEventArgs<ShippingItem> args) => OnSelectedShippingItemChanged(args))"
InputId="cbShippingItem">
<ItemDisplayTemplate>
@* <div class="combobox-item-template">
<img src="/images/ok_green_lt.jpg" alt="" />
<span class="icon counter-icon" aria-hidden="true"></span>
<div class="combobox-item-template-text">
@ -100,76 +108,77 @@
</div>
*@
<span class="@(ctxShippingitem.DataItem.IsMeasured ? "text-success" : "")">@ctxShippingitem.DisplayText)</span>
</ItemDisplayTemplate>
</DxComboBox>
</DxFormLayoutItem>
<DxFormLayoutItem Caption="Partner:" ColSpanMd="3" CaptionCssClass="@(SelectedShippingItem?.ShippingDocument?.IsAllMeasured == true ? "text-success" : "")">
@{
var sd = SelectedShippingItem?.ShippingDocument;
if (sd != null)
{
var partnerName = sd.Partner?.Name;
<span class="@(sd.IsAllMeasured == true ? " text-success" : "")">
@($"{partnerName}, {sd.ShippingItems?.Count(si => si.IsMeasured) ?? 0}/{sd.ShippingItems?.Count ?? 0} kész.")
</span>
}
}
</DxFormLayoutItem>
</DxFormLayout>
</div>
<div style="margin-top: 50px;">
@if (SelectedShippingItem is { ProductId: > 0 })
{
<h3 style="margin-bottom: 30px;" class="@(SelectedShippingItem.IsMeasured && SelectedShippingItem.ShippingItemPallets!.All(x => x.IsMeasuredAndValid(SelectedShippingItem.IsMeasurable)) ? "text-success" : "")">
@SelectedShippingItem.Name
</h3>
<DxFormLayout Data="@SelectedShippingItem" CaptionPosition="CaptionPosition.Vertical" CssClass="w-100">
<DxFormLayoutItem Context="ctxShippingItemFromLayoutItem" ColSpanMd="12">
@for (var index = 0; index < (SelectedShippingItem?.ShippingItemPallets?.Count ?? 0); index++)
{
var localI = index + 1;
var currentShippingItemPallet = SelectedShippingItem!.ShippingItemPallets![index];
<PalletItemComponent IsMeasurable="@SelectedShippingItem.IsMeasurable"
MeasuringIndex="@localI"
PalletItem="@currentShippingItemPallet"
ProductId="@SelectedShippingItem.ProductId!.Value"
AddOrUpdateSignalRTag="SignalRTags.AddOrUpdateMeasuredShippingItemPallet"
OnPalletItemSaved="pallet => OnShippingItemPalletSaved(pallet)"
OnPalletItemValueChanged="pallet => OnShippingItemPalletValueChanged(pallet, SelectedShippingItem)">
</PalletItemComponent>
}
</ItemDisplayTemplate>
</DxComboBox>
</DxFormLayoutItem>
<DxFormLayoutItem Context="vfdfgfd" ColSpanMd="12" BeginRow="true">
<DxFormLayout CssClass="w-100">
<DxFormLayoutItem ColSpanMd="1" BeginRow="false"><strong>TOTAL:</strong></DxFormLayoutItem>
<DxFormLayoutItem ColSpanMd="2" BeginRow="false"/>
<DxFormLayoutItem ColSpanMd="2" BeginRow="false"/>
<DxFormLayoutItem ColSpanMd="1" BeginRow="false"/>
<DxFormLayoutItem ColSpanMd="2" BeginRow="false"><strong>@(SelectedShippingItem.MeasuredQuantity) db</strong></DxFormLayoutItem>
<DxFormLayoutItem ColSpanMd="2" BeginRow="false"><strong>@(SelectedShippingItem.MeasuredGrossWeight) kg</strong></DxFormLayoutItem>
<DxFormLayoutItem ColSpanMd="1" BeginRow="false"><strong>@(SelectedShippingItem.MeasuredNetWeight) kg</strong></DxFormLayoutItem>
<DxFormLayoutItem ColSpanMd="1" BeginRow="false"/>
</DxFormLayout>
</DxFormLayoutItem>
<DxFormLayoutItem Caption="Partner:" ColSpanMd="3" CaptionCssClass="@(SelectedShippingItem?.ShippingDocument?.IsAllMeasured == true ? "text-success" : "")">
@{
var sd = SelectedShippingItem?.ShippingDocument;
if (sd != null)
{
var partnerName = sd.Partner?.Name;
@* <DxFormLayoutItem ColSpanMd="12" BeginRow="true">
<span class="@(sd.IsAllMeasured == true ? " text-success" : "")">
@($"{partnerName}, {sd.ShippingItems?.Count(si => si.IsMeasured) ?? 0}/{sd.ShippingItems?.Count ?? 0} kész.")
</span>
}
}
</DxFormLayoutItem>
</DxFormLayout>
<div style="margin-top: 50px;">
@if (SelectedShippingItem is { ProductId: > 0 })
{
<h3 style="margin-bottom: 30px;" class="@(SelectedShippingItem.IsMeasured && SelectedShippingItem.ShippingItemPallets!.All(x => x.IsMeasuredAndValid(SelectedShippingItem.IsMeasurable)) ? "text-success" : "")">
@SelectedShippingItem.Name
</h3>
<DxFormLayout Data="@SelectedShippingItem" CaptionPosition="CaptionPosition.Vertical" CssClass="w-100">
<DxFormLayoutItem Context="ctxShippingItemFromLayoutItem" ColSpanMd="12">
@for (var index = 0; index < (SelectedShippingItem?.ShippingItemPallets?.Count ?? 0); index++)
{
var localI = index + 1;
var currentShippingItemPallet = SelectedShippingItem!.ShippingItemPallets![index];
<PalletItemComponent IsMeasurable="@SelectedShippingItem.IsMeasurable"
MeasuringIndex="@localI"
PalletItem="@currentShippingItemPallet"
ProductId="@SelectedShippingItem.ProductId!.Value"
AddOrUpdateSignalRTag="SignalRTags.AddOrUpdateMeasuredShippingItemPallet"
OnPalletItemSaved="pallet => OnShippingItemPalletSaved(pallet)"
OnPalletItemValueChanged="pallet => OnShippingItemPalletValueChanged(pallet, SelectedShippingItem)">
</PalletItemComponent>
}
</DxFormLayoutItem>
<DxFormLayoutItem Context="vfdfgfd" ColSpanMd="12" BeginRow="true">
<DxFormLayout CssClass="w-100">
<DxFormLayoutItem ColSpanMd="1" BeginRow="false"><strong>TOTAL:</strong></DxFormLayoutItem>
<DxFormLayoutItem ColSpanMd="2" BeginRow="false" />
<DxFormLayoutItem ColSpanMd="2" BeginRow="false" />
<DxFormLayoutItem ColSpanMd="1" BeginRow="false" />
<DxFormLayoutItem ColSpanMd="2" BeginRow="false"><strong>@(SelectedShippingItem.MeasuredQuantity) db</strong></DxFormLayoutItem>
<DxFormLayoutItem ColSpanMd="2" BeginRow="false"><strong>@(SelectedShippingItem.MeasuredGrossWeight) kg</strong></DxFormLayoutItem>
<DxFormLayoutItem ColSpanMd="1" BeginRow="false"><strong>@(SelectedShippingItem.MeasuredNetWeight) kg</strong></DxFormLayoutItem>
<DxFormLayoutItem ColSpanMd="1" BeginRow="false" />
</DxFormLayout>
</DxFormLayoutItem>
@* <DxFormLayoutItem ColSpanMd="12" BeginRow="true">
<ValidationSummary/>
</DxFormLayoutItem> *@
@if (!_errorText.IsNullOrWhiteSpace())
{
<DxFormLayoutItem ColSpanMd="12" BeginRow="true">
<text>HIBA! @_errorText</text>
</DxFormLayoutItem>
//_errorText = string.Empty;
@if (!_errorText.IsNullOrWhiteSpace())
{
<DxFormLayoutItem ColSpanMd="12" BeginRow="true">
<text>HIBA! @_errorText</text>
</DxFormLayoutItem>
//_errorText = string.Empty;
}
</DxFormLayout>
}
</DxFormLayout>
}
</div>
</DxLoadingPanel>
</div>

View File

@ -29,6 +29,7 @@ namespace FruitBankHybrid.Shared.Pages
//private ShippingDocument? SelectedShippingDocument { get; set; }
private ShippingItem? SelectedShippingItem { get; set; }
public bool LoadingPanelVisible { get; set; } = true;
protected bool BtnSaveEnabled { get; set; }
private List<ShippingItem>? _shippingItemsDataSource;
@ -36,6 +37,8 @@ namespace FruitBankHybrid.Shared.Pages
protected override async Task OnInitializedAsync()
{
LoadingPanelVisible = true;
_logger = new LoggerClient<MeasuringIn>(LogWriters.ToArray());
_logger.Info("OnInitializedAsync");
@ -51,6 +54,8 @@ namespace FruitBankHybrid.Shared.Pages
NotMeasuredShippings = shippings.Where(shipping => MeasuringService.DaysEqual(shipping.ShippingDate.Date, dateTime)).ToList();
SelectedShipping = NotMeasuredShippings.FirstOrDefault();
LoadingPanelVisible = false;
}
private static List<ShippingItem>? GetShippingItemsDataSource(Shipping? shipping)

View File

@ -12,13 +12,14 @@
<DxDialogProvider />
<div style="margin-top: 50px;">
<DxLoadingPanel @bind-Visible="LoadingPanelVisible"
IsContentBlocked="true"
ApplyBackgroundShading="true"
IndicatorAreaVisible="true"
IsContentVisible="true"
IndicatorAnimationType="WaitIndicatorAnimationType.Spin"
Text="Adatok betöltése...">
Text="Adatok szinkronizálása folyamatban...">
<DxFormLayout CaptionPosition="CaptionPosition.Vertical" CssClass="w-100">
<DxFormLayoutItem Caption="Átvétel dátuma" ColSpanMd="2"
@ -69,19 +70,25 @@
</DxComboBox>
</DxFormLayoutItem>
@if (HasMeasuringAccess && SelectedOrder?.MeasurementOwnerId == 0)
@switch (SelectedOrder)
{
<DxFormLayoutItem ColSpanMd="2">
<DxButton Enabled="@(HasMeasuringAccess && SelectedOrder?.MeasurementOwnerId == 0)" Visible="@(SelectedOrder != null)" CssClass="w-100"
Text="@(HasMeasuringAccess && SelectedOrder?.MeasurementOwnerId == 0 ? "Mérés indítása" : "Mérés folyamatban...")"
Click="() => OnStartMeasuringClick()" />
</DxFormLayoutItem>
}
else
{
<DxFormLayoutItem ColSpanMd="2" Caption="Mérést indította" CaptionCssClass="@(SelectedOrder?.IsMeasured == true ? "text-success" : "")">
<DxTextBox Enabled="false" Text="@(LoggedInModel.MeasuringUsers.FirstOrDefault(x => x.Id == SelectedOrder?.MeasurementOwnerId)?.Email)" />
</DxFormLayoutItem>
case null:
<DxFormLayoutItem ColSpanMd="2" />
break;
case { MeasurementOwnerId: 0, IsComplete: false } when HasMeasuringAccess:
<DxFormLayoutItem ColSpanMd="2">
<DxButton Enabled="@(HasMeasuringAccess && SelectedOrder?.MeasurementOwnerId == 0)" Visible="@(SelectedOrder != null)" CssClass="w-100"
Text="@(HasMeasuringAccess && SelectedOrder?.MeasurementOwnerId == 0 ? "Mérés indítása" : "Mérés folyamatban...")"
Click="() => OnStartMeasuringClick()" />
</DxFormLayoutItem>
break;
default:
<DxFormLayoutItem ColSpanMd="2" Caption="Mérést indította" CaptionCssClass="@(SelectedOrder?.IsMeasured == true ? "text-success" : "")">
<DxTextBox Enabled="false" Text="@(LoggedInModel.MeasuringUsers.FirstOrDefault(x => x.Id == SelectedOrder?.MeasurementOwnerId)?.FullName)" />
</DxFormLayoutItem>
break;
}
<DxFormLayoutItem ColSpanMd="1"></DxFormLayoutItem>
@ -96,7 +103,7 @@
}
</DxFormLayout>
@if (SelectedOrder == null)
@if (SelectedOrder == null || LoadingPanelVisible)
{
}
else if (!HasMeasuringAccess)
@ -110,9 +117,9 @@
//Átvétel dátuma október 23. [AUDITED] 15:51 - Vegetable Kft. Rendelés azonosító: #8
<div style="margin-top: 50px;">
<h3 style="margin-bottom: 30px;" class="@(SelectedOrder?.IsMeasured == true ? "text-success" : "")">
<h4 style="margin-bottom: 30px;" class="@(SelectedOrder?.IsMeasured == true ? "text-success" : "")">
Rendelés azonosító: #@(SelectedOrder?.CustomOrderNumber)
</h3>
</h4>
<DxAccordion Data="@SelectedOrder?.OrderItemDtos" Enabled="@(HasMeasuringAccess && SelectedOrder?.MeasurementOwnerId > 0 && !(SelectedOrder?.IsComplete ?? false))"
ExpandMode="AccordionExpandMode.SingleOrNone"

View File

@ -56,7 +56,7 @@ namespace FruitBankHybrid.Shared.Pages
private async Task RefreshOrdersFromDb(DateTime dateTime)
{
LoadingPanelVisible = true;
var orders = (await FruitBankSignalRClient.GetPendingOrderDtos() ?? []);//.Where(o => o.HasMeasuringAccess(LoggedInModel.CustomerDto?.Id, LoggedInModel.IsRevisor)).ToList();
var orders = (await FruitBankSignalRClient.GetPendingOrderDtos() ?? []).Where(o => o.HasMeasuringAccess(LoggedInModel.CustomerDto?.Id, LoggedInModel.IsRevisor)).ToList();
_measuringDates = orders.Select(order => new MeasuringDateSelectorModel(order.Id, order.DateOfReceiptOrCreated, order.IsMeasured)).ToList();
@ -140,7 +140,7 @@ namespace FruitBankHybrid.Shared.Pages
selectedOrderItemDto.OrderItemPallets.UpdateCollection(orderItemPallet, false);
//MeasuringValuesHelper.SetShippingItemTotalMeasuringValues(SelectedShippingItem);
}
else await DialogService.ShowMessageBoxAsync("Hiba", "Adatok mentése sikertelen volt!", MessageBoxRenderStyle.Danger);
else await DialogService.ShowMessageBoxAsync("Hiba", "Adatok mentése sikertelen volt, ellenőrizze a mérés adatait!", MessageBoxRenderStyle.Danger);
StateHasChanged();
}
@ -195,19 +195,22 @@ namespace FruitBankHybrid.Shared.Pages
{
if (SelectedOrder != null && LoggedInModel.IsRevisor && SelectedOrder.IsMeasured && SelectedOrder.OrderStatus != OrderStatus.Complete)
{
var responseOrderDto = await FruitBankSignalRClient.SetOrderStatusToComplete(SelectedOrder.Id, LoggedInModel.CustomerDto!.Id);
if (responseOrderDto != null)
if (await DialogService.ShowConfirmBoxAsync("Megerősítés", "Biztoan jóváhagyja a rendelést? Jóváhagyás után a mérések nem módosíthatóak!", MessageBoxRenderStyle.Danger))
{
PrepareOrderDto(responseOrderDto);
var responseOrderDto = await FruitBankSignalRClient.SetOrderStatusToComplete(SelectedOrder.Id, LoggedInModel.CustomerDto!.Id);
if (responseOrderDto != null)
{
PrepareOrderDto(responseOrderDto);
SelectedDayOrders.UpdateCollection(responseOrderDto, false);
SelectedOrder = responseOrderDto;
SelectedDayOrders.UpdateCollection(responseOrderDto, false);
SelectedOrder = responseOrderDto;
//await DialogService.ShowMessageBoxAsync("Információ", "Adatok mentése sikeres volt!", MessageBoxRenderStyle.Info);
//await DialogService.ShowMessageBoxAsync("Információ", "Adatok mentése sikeres volt!", MessageBoxRenderStyle.Info);
}
else await DialogService.ShowMessageBoxAsync("Hiba", "Rendelés jóváhagyása sikertelen volt, ellenőrizze a mérés adatait!", MessageBoxRenderStyle.Danger);
StateHasChanged();
}
else await DialogService.ShowMessageBoxAsync("Hiba", "Rendelés jóváhagyása sikertelen volt!", MessageBoxRenderStyle.Danger);
StateHasChanged();
}
}

View File

@ -1,5 +1,6 @@
html, body {
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
min-height: 100vh;
}
a, .btn-link {