30 lines
832 B
C#
30 lines
832 B
C#
using ProjectTourAgency.Enities.Enums;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace ProjectTourAgency.Enities;
|
|
|
|
public class Tour
|
|
{
|
|
public int Id { get; private set; }
|
|
public int EmployeeId { get; private set; }
|
|
public int RouteId { get; private set; }
|
|
public DateTime DepartureDate { get; private set; }
|
|
public IEnumerable<ClientTour> ClientTours { get; private set; } = [];
|
|
public static Tour CreateEntity(int id, int employeeId, int routeId,
|
|
DateTime date,IEnumerable<ClientTour> clientTours)
|
|
{
|
|
return new Tour
|
|
{
|
|
Id = id,
|
|
EmployeeId = employeeId,
|
|
RouteId = routeId,
|
|
DepartureDate = date,
|
|
ClientTours = clientTours
|
|
};
|
|
}
|
|
}
|