Merge branch 'main' of https://git.aycode.com/Adam/FruitBankHybridApp
This commit is contained in:
commit
6ec77266a2
|
|
@ -15,6 +15,18 @@ namespace FruitBank.Common.Server
|
|||
public static string MeasuringRevisorRoleSystemName = "MeasuringRevisor";
|
||||
public static string IsMeasureableAttributeName = "IsMeasurable";
|
||||
|
||||
/// <summary>
|
||||
/// DateTime generic attribute on Product.
|
||||
/// The start of the window during which this product is visible for preordering.
|
||||
/// </summary>
|
||||
public const string PreorderWindowStart = "PreorderWindowStart";
|
||||
|
||||
/// <summary>
|
||||
/// DateTime generic attribute on Product.
|
||||
/// The end of the window during which this product is visible for preordering.
|
||||
/// </summary>
|
||||
public const string PreorderWindowEnd = "PreorderWindowEnd";
|
||||
|
||||
static FruitBankConst()
|
||||
{
|
||||
ProjectId = Guid.Parse(ProjectIdString);
|
||||
|
|
|
|||
|
|
@ -0,0 +1,14 @@
|
|||
using AyCode.Interfaces.EntityComment;
|
||||
using FruitBank.Common.Interfaces;
|
||||
using Mango.Nop.Core.Entities;
|
||||
|
||||
namespace FruitBank.Common.Entities;
|
||||
|
||||
public class CustomerCredit: MgEntityBase, IEntityComment
|
||||
{
|
||||
public int CustomerId { get; set; }
|
||||
public decimal CreditLimit { get; set; }
|
||||
public string? Comment { get; set; }
|
||||
public DateTime CreatedOnUtc { get; set; }
|
||||
public DateTime UpdatedOnUtc { get; set; }
|
||||
}
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
using FruitBank.Common.Enums;
|
||||
using LinqToDB.Mapping;
|
||||
using Mango.Nop.Core.Entities;
|
||||
|
||||
namespace FruitBank.Common.Entities;
|
||||
|
||||
[Table(Name = FruitBankConstClient.PreOrderDbTableName)]
|
||||
[System.ComponentModel.DataAnnotations.Schema.Table(FruitBankConstClient.PreOrderDbTableName)]
|
||||
public class Preorder : MgEntityBase
|
||||
{
|
||||
public int CustomerId { get; set; }
|
||||
public int StoreId { get; set; }
|
||||
public DateTime DateOfReceipt { get; set; }
|
||||
public PreorderStatus Status { get; set; }
|
||||
public string? CustomerNote { get; set; }
|
||||
public DateTime CreatedOnUtc { get; set; }
|
||||
public DateTime UpdatedOnUtc { get; set; }
|
||||
public int? OrderId { get; set; }
|
||||
|
||||
public List<PreorderItem> PreorderItems { get; set; } = new();
|
||||
}
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
using FruitBank.Common.Enums;
|
||||
using LinqToDB.Mapping;
|
||||
using Mango.Nop.Core.Entities;
|
||||
|
||||
namespace FruitBank.Common.Entities;
|
||||
|
||||
[Table(Name = FruitBankConstClient.PreOrderItemDbTableName)]
|
||||
[System.ComponentModel.DataAnnotations.Schema.Table(FruitBankConstClient.PreOrderItemDbTableName)]
|
||||
public class PreorderItem : MgEntityBase
|
||||
{
|
||||
public int PreorderId { get; set; }
|
||||
public int ProductId { get; set; }
|
||||
public int RequestedQuantity { get; set; }
|
||||
public int FulfilledQuantity { get; set; }
|
||||
public decimal UnitPriceInclTax { get; set; }
|
||||
public PreorderItemStatus Status { get; set; }
|
||||
}
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
namespace FruitBank.Common.Enums;
|
||||
|
||||
public enum PreorderItemStatus
|
||||
{
|
||||
Pending = 0,
|
||||
Fulfilled = 10,
|
||||
PartiallyFulfilled = 20,
|
||||
Dropped = 30
|
||||
}
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
|
||||
|
||||
namespace FruitBank.Common.Enums;
|
||||
|
||||
public enum PreorderStatus
|
||||
{
|
||||
Pending = 0,
|
||||
Confirmed = 10,
|
||||
PartiallyFulfilled = 20,
|
||||
Cancelled = 30
|
||||
}
|
||||
|
|
@ -10,6 +10,7 @@ public static class FruitBankConstClient
|
|||
public static string BaseUrl = "https://localhost:59579"; //FrutiBank nop
|
||||
//public static string BaseUrl = "https://localhost:44372"; //FrutiBank nop
|
||||
//public static string BaseUrl = "https://shop.fruitbank.hu"; //FrutiBank nop
|
||||
//public static string BaseUrl = "https://fruitbank.mangoweb.hu"; //FrutiBank nop test
|
||||
#if RELEASE
|
||||
//public static string BaseUrl = "https://shop.fruitbank.hu"; //FrutiBank nop
|
||||
#endif
|
||||
|
|
@ -43,9 +44,12 @@ public static class FruitBankConstClient
|
|||
public const string StockTakingDbTableName = "fbStockTaking";
|
||||
public const string StockTakingItemDbTableName = "fbStockTakingItem";
|
||||
public const string StockTakingItemPalletDbTableName = "fbStockTakingItemPallet";
|
||||
|
||||
public const string CustomerCreditDbTableName = "fbCustomerCredit";
|
||||
public const string PreOrderDbTableName = "fbPreorder";
|
||||
public const string PreOrderItemDbTableName = "fbPreorderItem";
|
||||
|
||||
|
||||
|
||||
|
||||
//public static Guid[] DevAdminIds = new Guid[2] { Guid.Parse("dcf451d2-cc4c-4ac2-8c1f-da00041be1fd"), Guid.Parse("4cbaed43-2465-4d99-84f1-c8bc6b7025f7") };
|
||||
//public static Guid[] SysAdmins = new Guid[3]
|
||||
//{
|
||||
|
|
|
|||
|
|
@ -46,19 +46,19 @@
|
|||
<DxTabPage Text="Rendelés tételek">
|
||||
<GridDetailOrderItemDto OrderItemDtos="orderDto.OrderItemDtos" IsMasterGrid="false" />
|
||||
</DxTabPage>
|
||||
<DxTabPage Text="Mérések" Visible="@LoggedInModel.IsDeveloper">
|
||||
<DxTabPage Text="Mérések" Visible="@LoggedInModel.IsAdministrator">
|
||||
@{
|
||||
var orderItemPalletDtos = orderDto?.OrderItemDtos.SelectMany(oi => oi.OrderItemPallets).ToList() ?? [];
|
||||
<GridDetailOrderItemPallets OrderItemPallets="orderItemPalletDtos" IsMasterGrid="false"/>
|
||||
}
|
||||
</DxTabPage>
|
||||
<DxTabPage Text="Rendelés jegyzetek" Visible="@LoggedInModel.IsDeveloper">
|
||||
<DxTabPage Text="Rendelés jegyzetek" Visible="@LoggedInModel.IsAdministrator">
|
||||
@{
|
||||
// var orderItemPalletDtos = orderDto?.OrderItemDtos.SelectMany(oi => oi.OrderItemPallets).ToList() ?? [];
|
||||
// <GridDetailOrderItemPallets OrderItemPallets="orderItemPalletDtos" IsMasterGrid="false" />
|
||||
}
|
||||
</DxTabPage>
|
||||
<DxTabPage Text="Speciális jellemzők" Visible="@LoggedInModel.IsDeveloper">
|
||||
<DxTabPage Text="Speciális jellemzők" Visible="@LoggedInModel.IsAdministrator">
|
||||
@{
|
||||
var genericAttributeDtos = new AcObservableCollection<GenericAttributeDto>(orderDto.GenericAttributes);
|
||||
<GridGenericAttribute ParentDataItem="@orderDto" GenericAttributes="@genericAttributeDtos" />
|
||||
|
|
@ -74,7 +74,7 @@
|
|||
<MgGridToolbarTemplate Grid="Grid" OnReloadDataClick="() => ReloadDataFromDb(true)"/>
|
||||
}
|
||||
</ToolbarTemplate>
|
||||
<GroupSummary>
|
||||
@* <GroupSummary>
|
||||
<DxGridSummaryItem SummaryType="GridSummaryItemType.Sum"
|
||||
FieldName="Quantity"
|
||||
FooterColumnName="Quantity" />
|
||||
|
|
@ -84,7 +84,23 @@
|
|||
<DxGridSummaryItem SummaryType="GridSummaryItemType.Sum"
|
||||
FieldName="PriceInclTax"
|
||||
FooterColumnName="PriceInclTax" />
|
||||
</GroupSummary> *@
|
||||
<GroupSummary>
|
||||
<DxGridSummaryItem SummaryType="GridSummaryItemType.Count"
|
||||
FieldName="Id"
|
||||
ValueDisplayFormat="'{0} rendelés'" />
|
||||
<DxGridSummaryItem SummaryType="GridSummaryItemType.Count"
|
||||
FieldName="Id"
|
||||
FooterColumnName="Id" />
|
||||
<DxGridSummaryItem SummaryType="GridSummaryItemType.Sum"
|
||||
FieldName="OrderTotal"
|
||||
FooterColumnName="OrderTotal" />
|
||||
</GroupSummary>
|
||||
<TotalSummary>
|
||||
<DxGridSummaryItem SummaryType="GridSummaryItemType.Count"
|
||||
FieldName="Id"
|
||||
FooterColumnName="Id" />
|
||||
</TotalSummary>
|
||||
</MgGridBase>
|
||||
|
||||
@code {
|
||||
|
|
|
|||
|
|
@ -59,6 +59,7 @@
|
|||
<DxListEditorColumn FieldName="@nameof(Shipping.ShippingDate)" />
|
||||
<DxListEditorColumn FieldName="@nameof(Shipping.LicencePlate)" />
|
||||
<DxListEditorColumn FieldName="@nameof(Shipping.Comment)" />
|
||||
<DxListEditorColumn FieldName="@nameof(Shipping.CargoCompany)" />
|
||||
</Columns>
|
||||
</DxComboBoxSettings>
|
||||
</EditSettings>
|
||||
|
|
|
|||
|
|
@ -239,8 +239,10 @@
|
|||
var quantityOnDocument = (int)e.Grid.GetRowValue(e.VisibleIndex, nameof(ShippingItem.QuantityOnDocument));
|
||||
var measuredQuantity = (int)e.Grid.GetRowValue(e.VisibleIndex, nameof(ShippingItem.MeasuredQuantity));
|
||||
|
||||
if (quantityOnDocument > 0 && quantityOnDocument > measuredQuantity) e.CssClass = "text-danger";
|
||||
//else if (quantityOnDocument <= measuredQuantity) e.CssClass = "text-success";
|
||||
if (quantityOnDocument > 0 && quantityOnDocument > measuredQuantity)
|
||||
{ e.CssClass = "text-danger"; }
|
||||
else if (quantityOnDocument < measuredQuantity)
|
||||
{ e.CssClass = "text-success"; }
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
<ApplicationId>com.mango.fruitbank</ApplicationId>
|
||||
|
||||
<!-- Versions -->
|
||||
<ApplicationDisplayVersion>1.0.1</ApplicationDisplayVersion>
|
||||
<ApplicationDisplayVersion>1.0.2</ApplicationDisplayVersion>
|
||||
<ApplicationVersion>1</ApplicationVersion>
|
||||
|
||||
<RunAOTCompilation>false</RunAOTCompilation>
|
||||
|
|
|
|||
Loading…
Reference in New Issue