Skip to content

Commit af9858e

Browse files
committed
DTO
1 parent fee483d commit af9858e

4 files changed

Lines changed: 21 additions & 34 deletions

File tree

WebApiLab.BLL/DTOs/Category.cs

Lines changed: 0 additions & 8 deletions
This file was deleted.

WebApiLab.BLL/DTOs/DTO.cs

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
using System;
2+
using System.Collections.Generic;
3+
using WebApiLab.DAL.Entities;
4+
5+
namespace WebApiLab.BLL.DTO
6+
{
7+
public record Category(int Id, string Name);
8+
9+
public record Order(int Id, DateTime OrderDate);
10+
11+
public record Product
12+
{
13+
public int Id { get; init; }
14+
public string Name { get; init; }
15+
public int UnitPrice { get; init; }
16+
public ShipmentRegion ShipmentRegion { get; init; }
17+
public int CategoryId { get; init; }
18+
public Category Category { get; init; }
19+
public List<Order> Orders { get; init; }
20+
}
21+
}

WebApiLab.BLL/DTOs/Order.cs

Lines changed: 0 additions & 10 deletions
This file was deleted.

WebApiLab.BLL/DTOs/Product.cs

Lines changed: 0 additions & 16 deletions
This file was deleted.

0 commit comments

Comments
 (0)