Files
Backend-Api/CompanyManagment.App.Contracts/Checkout/ICheckoutApplication.cs

101 lines
3.4 KiB
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using _0_Framework.Application;
namespace CompanyManagment.App.Contracts.Checkout;
public interface ICheckoutApplication
{
void Create(CreateCheckout command);
OperationResult Edit(EditCheckout command);
EditCheckout GetDetails(long id);
/// <summary>
/// لود لیست اولیه جهت ایجاد فیش حقوقی
/// </summary>
/// <param name="workshopId"></param>
/// <param name="employeeId"></param>
/// <param name="year"></param>
/// <param name="month"></param>
/// <param name="contractStart"></param>
/// <param name="contractEnd"></param>
/// <returns></returns>
/// <exception cref="NotImplementedException"></exception>
Task<CreateCheckoutListViewModel> GetContractResultToCreateCheckout(long workshopId, long employeeId, string year,
string month,
string contractStart, string contractEnd);
/// <summary>
/// لیست تصفیه حساب
/// جدید
///
/// </summary>
/// <param name="searchModel"></param>
/// <returns></returns>
Task<List<CheckoutViewModel>> SearchCheckoutOptimized(CheckoutSearchModel searchModel);
Task<List<CheckoutViewModel>> Search(CheckoutSearchModel searchModel);
List<CheckoutViewModel> SimpleSearch(CheckoutSearchModel searchModel);
List<CheckoutViewModel> PrintAll(List<long> id);
CheckoutViewModel PrintOne(long id);
CheckoutLeavePrintViewModel LeavePrint(long id);
OperationResult Sign(long id);
OperationResult UnSign(long id);
OperationResult Active(long id);
OperationResult DeActive(long id);
OperationResult RemoveCheckout(long id);
OperationResult CustomSet(long id, double rewardPay, double salaryAidDeduction);
List<CheckoutViewModel> SearchForClient(CheckoutSearchModel searchModel);
#region NewChangeByHeydari
List<long> CheckHasSignature(List<long> ids);
OperationResult DeleteAllCheckouts(List<long> ids);
OperationResult DeleteCheckout(long id);
Task<List<CheckoutViewModel>> SearchForMainCheckout(CheckoutSearchModel searchModel);
#endregion
#region Pooya
List<(long EmployeeId, DateTime CheckoutStart, DateTime CheckoutEnd)> GetLastCheckoutsByWorkshopIdForWorkFlow(
long workshopId, DateTime start, DateTime end);
#endregion
Task<PagedResult<CheckoutListClientDto>> GetListForClient(long workshopId,
CheckoutListClientSearchModel searchModel);
}
public class CheckoutListClientSearchModel:PaginationRequest
{
public long? EmployeeId { get; set; }
public string Year { get; set; }
public string Month { get; set; }
public string StartDate { get; set; }
public string EndDate { get; set; }
public CheckoutClientListOrderType? OrderType { get; set; }
}
public class CheckoutListClientDto
{
public long Id { get; set; }
public string Year { get; set; }
public string Month { get; set; }
public string EmployeeName { get; set; }
public string ContractNo { get; set; }
public string ContractStart { get; set; }
public string ContractEnd { get; set; }
public bool Signature { get; set; }
}
public enum CheckoutClientListOrderType
{
ByCheckoutCreationDate,
BySignedCheckout,
ByUnSignedCheckout,
ByPersonnelCode,
ByPersonnelCodeDescending,
ByCheckoutStartDate,
ByCheckoutStartDateDescending
}