This commit is contained in:
mmrbnjd
2024-07-25 17:18:03 +03:30
parent 466f26e986
commit 630d535962
15 changed files with 312 additions and 14 deletions

22
Shared/DTOs/OrderDto.cs Normal file
View File

@@ -0,0 +1,22 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Shared.DTOs
{
public class OrderDto
{
public int ID { get; set; }
public StatusOrder Status { get; set; }
public string StatusTitle { get { return Status.GetEnumDisplayName(); } }
public string DateCreate { get; set; }
public string ApprovalDate { get; set; }
public decimal PreDiscount { get; set; }
public decimal TDiscount { get; set; }
public decimal lstDiscount { get; set; }
public decimal TTax { get; set; }
public decimal TPrice { get; set; }
}
}

View File

@@ -0,0 +1,21 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Shared.DTOs
{
public class OrderItemDto
{
public int ID { get; set; }
public int OrderID { get; set; }
public string Type { get; set; }
public int IDForType { get; set; }
public int CreditAmount { get; set; }
public decimal APrice { get; set; }
public decimal Discount { get; set; }
public decimal Tax { get; set; }
public decimal Total { get { return (CreditAmount * APrice) - Discount + Tax; } }
}
}

15
Shared/DTOs/PricingDto.cs Normal file
View File

@@ -0,0 +1,15 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Shared.DTOs
{
public class PricingDto
{
public int PermissionID { get; set; }
public string PermissionTitle { get; set; }
public decimal Price { get; set; }
}
}

View File

@@ -0,0 +1,18 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Shared.DTOs
{
public class PromotionDetailDto
{
public int ID { get; set; }
public int PermissionID { get; set; }
public string PermissionTitle { get; set; }
public int CreditAmount { get; set; }
public decimal APrice { get; set; }
public decimal TPrice { get { return APrice * CreditAmount; } }
}
}

View File

@@ -0,0 +1,15 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Shared.DTOs
{
public class PromotionDto
{
public int ID { get; set; }
public string Name { get; set; }
public ICollection<PromotionDetailDto> promotionDetails { get; set; }
}
}

View File

@@ -0,0 +1,14 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Shared.DTOs.Serch
{
public class ItemSerachOrder
{
public int? ID { get; set; }
public StatusOrder? Status { get; set; }
}
}

View File

@@ -5,10 +5,10 @@ namespace Shared.DTOs
public enum StatusOrder
{
[Display(Name = "ساخته شده")]
Create,
Create=1,
[Display(Name = "پرداخت شده")]
Paid,
Paid=2,
[Display(Name = "انصراف داده شده")]
Cancel
Cancel=3
}
}