34 lines
1.2 KiB
C#
34 lines
1.2 KiB
C#
using ConfectioneryContracts.Attributes;
|
|
using ConfectioneryDataModels;
|
|
using ConfectioneryDataModels.Models;
|
|
using System.ComponentModel;
|
|
|
|
namespace ConfectioneryContracts.ViewModels
|
|
{
|
|
public class ShopViewModel : IShopModel
|
|
{
|
|
[Column("Название магазина", gridViewAutoSize: GridViewAutoSize.AllCells, isUseAutoSize: true)]
|
|
public string Name { get; set; } = string.Empty;
|
|
|
|
[Column("Адрес магазина", gridViewAutoSize: GridViewAutoSize.Fill, isUseAutoSize: true)]
|
|
public string Address { get; set; } = string.Empty;
|
|
|
|
[Column("Максимальное количество изделий в магазине", gridViewAutoSize: GridViewAutoSize.DisplayedCells, isUseAutoSize: true)]
|
|
public int MaxCountPastries { get; set; }
|
|
|
|
[Column("Время открытия", gridViewAutoSize: GridViewAutoSize.AllCells, isUseAutoSize: true, format: "f")]
|
|
public DateTime DateOpening { get; set; } = DateTime.Now;
|
|
|
|
[Column(visible: false)]
|
|
public Dictionary<int, (IPastryModel, int)> Pastries
|
|
{
|
|
get;
|
|
set;
|
|
} = new();
|
|
|
|
[Column(visible: false)]
|
|
public int Id { get; set; }
|
|
|
|
}
|
|
}
|