Add view models
This commit is contained in:
parent
1cd297eec8
commit
c4b5f00cb8
@ -7,10 +7,8 @@
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Folder Include="BusinessLogicsContracts" />
|
||||
<Folder Include="SearchModels" />
|
||||
<Folder Include="StoragesContracts" />
|
||||
<Folder Include="ViewModels" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
@ -0,0 +1,9 @@
|
||||
using HotelDataModels.Models;
|
||||
|
||||
namespace HotelContracts.ViewModels;
|
||||
|
||||
public class CleaningInstrumentsViewModel : ICleaningInstrumentsModel
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string Type { get; set; } = string.Empty;
|
||||
}
|
11
Hotel/HotelContracts/ViewModels/CleaningViewModel.cs
Normal file
11
Hotel/HotelContracts/ViewModels/CleaningViewModel.cs
Normal file
@ -0,0 +1,11 @@
|
||||
using HotelDataModels.Models;
|
||||
|
||||
namespace HotelContracts.ViewModels;
|
||||
|
||||
public class CleaningViewModel : ICleaningModel
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public DateTime Date { get; set; }
|
||||
public int RoomId { get; set; }
|
||||
public Dictionary<int, ICleaningInstrumentsModel> CleaningInstruments { get; set; }
|
||||
}
|
11
Hotel/HotelContracts/ViewModels/GuestViewModel.cs
Normal file
11
Hotel/HotelContracts/ViewModels/GuestViewModel.cs
Normal file
@ -0,0 +1,11 @@
|
||||
using HotelDataModels.Models;
|
||||
|
||||
namespace HotelContracts.ViewModels;
|
||||
|
||||
public class GuestViewModel : IGuestModel
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string SecondName { get; set; } = string.Empty;
|
||||
public string LastName { get; set; } = string.Empty;
|
||||
}
|
13
Hotel/HotelContracts/ViewModels/MaitreViewModel.cs
Normal file
13
Hotel/HotelContracts/ViewModels/MaitreViewModel.cs
Normal file
@ -0,0 +1,13 @@
|
||||
using HotelDataModels.Models;
|
||||
|
||||
namespace HotelContracts.ViewModels;
|
||||
|
||||
public class MaitreViewModel : IMaitreModel
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string Name { get; set; } = string.Empty;
|
||||
public string SecondName { get; set; } = string.Empty;
|
||||
public string LastName { get; set; } = string.Empty;
|
||||
public string Login { get; set; } = string.Empty;
|
||||
public string Password { get; set; } = string.Empty;
|
||||
}
|
16
Hotel/HotelContracts/ViewModels/ReservationViewModel.cs
Normal file
16
Hotel/HotelContracts/ViewModels/ReservationViewModel.cs
Normal file
@ -0,0 +1,16 @@
|
||||
using System.ComponentModel;
|
||||
using HotelDataModels.Models;
|
||||
|
||||
namespace HotelContracts.ViewModels;
|
||||
|
||||
public class ReservationViewModel : IReservationModel
|
||||
{
|
||||
public int Id { get; set; }
|
||||
[DisplayName("Start or reservation")]
|
||||
public DateTime StartDate { get; set; }
|
||||
[DisplayName("End or reservation")]
|
||||
public DateTime EndDate { get; set; }
|
||||
public int GuestId { get; set; }
|
||||
public int MaitreId { get; set; }
|
||||
public Dictionary<int, IRoomModel> ReservationsRooms { get; set; }
|
||||
}
|
11
Hotel/HotelContracts/ViewModels/RoomViewModel.cs
Normal file
11
Hotel/HotelContracts/ViewModels/RoomViewModel.cs
Normal file
@ -0,0 +1,11 @@
|
||||
using System.ComponentModel;
|
||||
using HotelDataModels.Models;
|
||||
|
||||
namespace HotelContracts.ViewModels;
|
||||
|
||||
public class RoomViewModel : IRoomModel
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string Type { get; set; } = string.Empty;
|
||||
public double Cost { get; set; }
|
||||
}
|
Loading…
Reference in New Issue
Block a user