147 lines
5.1 KiB
C#
147 lines
5.1 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using _0_Framework.Application;
|
|
using CompanyManagment.App.Contracts.Workshop;
|
|
using System.Threading.Tasks;
|
|
using _0_Framework.Application.Enums;
|
|
|
|
namespace CompanyManagment.App.Contracts.Contract;
|
|
|
|
public interface IContractApplication
|
|
{
|
|
/// <summary>
|
|
/// دریافت مزد ارتقاء یافته
|
|
/// </summary>
|
|
/// <param name="workshopId"></param>
|
|
/// <param name="employeeId"></param>
|
|
/// <param name="yearlySalaryId"></param>
|
|
/// <returns></returns>
|
|
Task<double> GetManualDailWage(long workshopId, long employeeId, long yearlySalaryId, DateTime contractStart);
|
|
OperationResult Create(CreateContract command);
|
|
OperationResult CreateNew(createContractModel command);
|
|
OperationResult Edit(EditContract command);
|
|
OperationResult EditCompute(EditContract command);
|
|
void EditAgreement(long id);
|
|
Task<OperationResult> EditComputeAsync(EditContract command);
|
|
ComputingViewModel MandatoryHours(CreateContract command);
|
|
|
|
ContractSeparationViewModel contractSeparation(string year, string month, DateTime contractStart,
|
|
DateTime ContractEnd, long employeeId, long workshopId);
|
|
|
|
EditContract GetDetails(long id);
|
|
OperationResult Active(long id);
|
|
OperationResult DeActive(long id);
|
|
OperationResult Sign(long id);
|
|
OperationResult UnSign(long id);
|
|
List<ContractViweModel> Search(ContractSearchModel searchModel);
|
|
List<ContractViweModel> SearchForextension(ContractSearchModel searchModel);
|
|
List<ContractViweModel> SearchForCheckout(ContractSearchModel searchModel);
|
|
|
|
bool CheckNextContractExist(long employeeId, DateTime startContract, DateTime endContract, long WorkshopId);
|
|
bool CkeckBetween(long employeeId, DateTime EndOfContract, DateTime StartOfExtension, long WorkshopId);
|
|
List<ContractViweModel> PrintAll(List<long> id);
|
|
TimeSpan Over22Check(DateTime date1, DateTime date2);
|
|
TimeSpan Over22Complex(DateTime date1, DateTime date2);
|
|
TimeSpan Over22Complex2424(DateTime date1, DateTime date2);
|
|
|
|
#region Client
|
|
|
|
OperationResult Remove(long id);
|
|
|
|
[Obsolete("این متد منسوخ شده است. لطفاً از متد GetContractListForClient استفاده کنید.")]
|
|
List<ContractViweModel> SearchForClient(ContractSearchModel searchModel);
|
|
|
|
/// <summary>
|
|
/// لیست قراردادها برای کلاینت
|
|
/// </summary>
|
|
/// <param name="searchModel"></param>
|
|
/// <returns></returns>
|
|
Task<PagedResult<GetContractListForClientResponse>>
|
|
GetContractListForClient(GetContractListForClientRequest searchModel);
|
|
Task<ContractPrintViewModel> PrintOneAsync(long id);
|
|
Task<List<ContractPrintViewModel>> PrintAllAsync(List<long> ids);
|
|
|
|
#endregion
|
|
|
|
#region NewChangeByHeydari
|
|
|
|
OperationResult DeleteAllContarcts(List<long> ids);
|
|
OperationResult DeleteContarcts(long id);
|
|
List<long> CheckHasCheckout(List<long> ids);
|
|
List<long> CheckHasSignature(List<long> ids);
|
|
List<ContractViweModel> SearchForMainContract(ContractSearchModel searchModel);
|
|
|
|
#endregion
|
|
}
|
|
|
|
public class ContractPrintViewModel
|
|
{
|
|
public string ContractNo { get; set; }
|
|
public ContractPrintEmployerViewModel Employer { get; set; }
|
|
public ContractPrintEmployeeViewModel Employee { get; set; }
|
|
public ContractPrintTypeOfContractViewModel TypeOfContract { get; set; }
|
|
public ContractPrintFeesViewModel Fees { get; set; }
|
|
public string ConditionAndDetials { get; set; }
|
|
|
|
|
|
}
|
|
|
|
public class ContractPrintFeesViewModel
|
|
{
|
|
public string DailyWage { get; set; }
|
|
public string FamilyAllowance { get; set; }
|
|
public string ConsumableItems { get; set; }
|
|
public string HousingAllowance { get; set; }
|
|
}
|
|
|
|
public class ContractPrintTypeOfContractViewModel
|
|
{
|
|
public string ContractType { get; set; }
|
|
public string JobName { get; set; }
|
|
public string SetContractDate { get; set; }
|
|
public string ContarctStart { get; set; }
|
|
public string ContractEnd { get; set; }
|
|
public string WorkingHoursWeekly { get; set; }
|
|
public List<string> WorkshopAddress { get; set; }
|
|
|
|
|
|
|
|
}
|
|
|
|
public class ContractPrintEmployeeViewModel
|
|
{
|
|
public string FullName { get; set; }
|
|
public string NationalCode { get; set; }
|
|
public string IdNumber { get; set; }
|
|
public string DateOfBirth { get; set; }
|
|
public string FatherName { get; set; }
|
|
public string LevelOfEducation { get; set; }
|
|
public string Address { get; set; }
|
|
|
|
|
|
}
|
|
|
|
public class ContractPrintEmployerViewModel
|
|
{
|
|
public LegalType LegalType { get; set; }
|
|
public ContractPrintRealEmployerViewModel RealEmployer { get; set; }
|
|
public ContractPrintLegalEmployerViewModel LegalEmployer { get; set; }
|
|
public string WorkshopName { get; set; }
|
|
public string Address { get; set; }
|
|
public string WorkshopCode { get; set; }
|
|
|
|
}
|
|
|
|
public class ContractPrintLegalEmployerViewModel
|
|
{
|
|
public string CompanyName { get; set; }
|
|
public string NationalId { get; set; }
|
|
public string RegisterId { get; set; }
|
|
}
|
|
|
|
public class ContractPrintRealEmployerViewModel
|
|
{
|
|
public string FullName { get; set; }
|
|
public string NationalCode { get; set; }
|
|
public string IdNumber { get; set; }
|
|
} |