2025-03-17 22:17:28 +08:00

24 lines
637 B
C#

using Seyounth.Core.Extensions;
using Seyounth.Hyosung.Data.Entities;
namespace Seyounth.Hyosung.Data.Models;
public class Pallet : PalletEntity
{
public string Name =>
$"{Type.GetDescription()}({Width}*{Height}*{Length})({HoleCount}|{(IsBigHole != null && IsBigHole.Value ? "" : "")})";
public static Pallet FromEntity(PalletEntity p)
{
return new Pallet()
{
Height = p.Height,
Width = p.Width,
Length = p.Length,
HoleCount = p.HoleCount,
Id = p.Id,
IsBigHole = p.IsBigHole,
Type = p.Type
};
}
}