74 lines
2.9 KiB
C#
74 lines
2.9 KiB
C#
using System;
|
||
using _0_Framework.Domain;
|
||
using static System.Net.Mime.MediaTypeNames;
|
||
|
||
namespace Company.Domain.LeaveAgg;
|
||
|
||
public class Leave: EntityBase
|
||
{
|
||
public Leave(DateTime startLeave, DateTime endLeave,
|
||
string leaveHourses, long workshopId, long employeeId,
|
||
string paidLeaveType, string leaveType, string employeeFullName, string workshopName,
|
||
bool isAccepted, string decription, int year, int month, TimeSpan shiftDuration,
|
||
bool hasShiftDuration,bool isInvalid)
|
||
{
|
||
StartLeave = startLeave;
|
||
EndLeave = endLeave;
|
||
LeaveHourses = leaveHourses;
|
||
WorkshopId = workshopId;
|
||
EmployeeId = employeeId;
|
||
PaidLeaveType = paidLeaveType;
|
||
LeaveType = leaveType;
|
||
EmployeeFullName = employeeFullName;
|
||
WorkshopName = workshopName;
|
||
IsAccepted = isAccepted;
|
||
Decription = decription;
|
||
Year = year;
|
||
Month = month;
|
||
ShiftDuration = shiftDuration;
|
||
HasShiftDuration = hasShiftDuration;
|
||
IsInvalid = isInvalid;
|
||
}
|
||
|
||
public DateTime StartLeave { get; private set; }
|
||
public DateTime EndLeave { get; private set; }
|
||
public string LeaveHourses { get; private set; }
|
||
public long WorkshopId { get; private set; }
|
||
public long EmployeeId { get; private set; }
|
||
public string PaidLeaveType { get; private set; }
|
||
public string LeaveType { get; private set; }
|
||
public string EmployeeFullName { get; private set; }
|
||
public string WorkshopName { get; private set; }
|
||
public bool IsAccepted { get; private set; }
|
||
public string Decription { get; private set; }
|
||
public int Year { get; private set; }
|
||
public int Month { get; private set; }
|
||
|
||
public TimeSpan ShiftDuration { get; private set; }
|
||
public bool HasShiftDuration { get; private set; }
|
||
/// <summary>
|
||
///آیا فاقد اعتبار است. فاقد اعتبار ها فقط برای فیش های غیررسمی مورد استفاده قرار میگیرند
|
||
/// </summary>
|
||
public bool IsInvalid { get; private set; }
|
||
|
||
public void Edit(DateTime startLeave, DateTime endLeave,
|
||
string leaveHourses, long workshopId, long employeeId,
|
||
string paidLeaveType, string leaveType, string employeeFullName, string workshopName, bool isAccepted, string decription, int year, int month,bool hasShiftDuration,TimeSpan shiftDuration)
|
||
{
|
||
StartLeave = startLeave;
|
||
EndLeave = endLeave;
|
||
LeaveHourses = leaveHourses;
|
||
WorkshopId = workshopId;
|
||
EmployeeId = employeeId;
|
||
PaidLeaveType = paidLeaveType;
|
||
LeaveType = leaveType;
|
||
EmployeeFullName = employeeFullName;
|
||
WorkshopName = workshopName;
|
||
IsAccepted = isAccepted;
|
||
Decription = decription;
|
||
Year = year;
|
||
Month = month;
|
||
ShiftDuration = shiftDuration;
|
||
HasShiftDuration = hasShiftDuration;
|
||
}
|
||
} |