Создание и заполнение ViewModels

This commit is contained in:
FLARJ 2023-04-05 22:29:39 +04:00
parent 2fda39d8cc
commit e38fd78481
8 changed files with 74 additions and 4 deletions

View File

@ -6,7 +6,7 @@ using System.Threading.Tasks;
namespace FurnitureContracts.SearchModels namespace FurnitureContracts.SearchModels
{ {
internal class HeadsetSearchModel public class HeadsetSearchModel
{ {
public int? Id { get; set; } public int? Id { get; set; }
} }

View File

@ -6,7 +6,7 @@ using System.Threading.Tasks;
namespace FurnitureContracts.SearchModels namespace FurnitureContracts.SearchModels
{ {
internal class OrderSearchModel public class OrderSearchModel
{ {
public int? Id { get; set; } public int? Id { get; set; }
} }

View File

@ -6,7 +6,7 @@ using System.Threading.Tasks;
namespace FurnitureContracts.SearchModels namespace FurnitureContracts.SearchModels
{ {
internal class RoleSearchModel public class RoleSearchModel
{ {
public string? Name { get; set; } public string? Name { get; set; }
public int? Id { get; set; } public int? Id { get; set; }

View File

@ -6,7 +6,7 @@ using System.Threading.Tasks;
namespace FurnitureContracts.SearchModels namespace FurnitureContracts.SearchModels
{ {
internal class SalesSalonsSearchModel public class SalesSalonsSearchModel
{ {
public string? Name { get; set; } public string? Name { get; set; }
public int? Id { get; set; } public int? Id { get; set; }

View File

@ -0,0 +1,21 @@
using FurnitureFactoryDataModels.Models;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace FurnitureContracts.ViewModel
{
public class HeadsetViewModel
{
public int Cost { get; set; }
[DisplayName("Размер")]
public string Size { get; set; } = string.Empty;
public int Id { get; set; }
public Dictionary<int, IHeadsetModuleModel> HeadsetModuleId { get; }
}
}

View File

@ -0,0 +1,22 @@
using FurnitureFactoryDataModels.Models;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace FurnitureContracts.ViewModel
{
public class OrdersViewModel
{
[DisplayName("Дата заказа")]
public DateTime Date { get; set; }
[DisplayName("Статус")]
public string Status { get; set; } = string.Empty;
public int Id { get; set; }
public Dictionary<int, IFurnitureModel> FurnitureId { get; set; }
public Dictionary<int, IHeadsetModel> HeadsetId { get; set; }
}
}

View File

@ -0,0 +1,12 @@
using FurnitureFactoryDataModels.Models;
using System.ComponentModel;
namespace FurnitureContracts.ViewModel
{
public class RoleViewModel
{
[DisplayName("Название роли")]
public string Name { get; set; } = string.Empty;
public int Id { get; set; }
}
}

View File

@ -0,0 +1,15 @@
using FurnitureFactoryDataModels.Models;
using System.ComponentModel;
namespace FurnitureContracts.ViewModel
{
public class SalesSalonsViewModel
{
[DisplayName("Название")]
public string Name { get; set; } = string.Empty;
[DisplayName("Адресс")]
public string Address { get; set; } = string.Empty;
public Dictionary<int, IOrdersModel> OrdersId { get; set; }
public int Id { get; set; }
}
}