Files
Backend-Api/CompanyManagment.App.Contracts/Employee/IEmployeeApplication.cs
mahan a121e62102 Merge branch 'master' into Main
# Conflicts:
#	0_Framework/Application/Sms/ISmsService.cs
#	ServiceHost/Program.cs
#	ServiceHost/Properties/launchSettings.json
2025-12-18 11:01:54 +03:30

101 lines
4.6 KiB
C#

using System.Collections.Generic;
using System.Threading.Tasks;
using _0_Framework.Application;
using CompanyManagment.App.Contracts.Employee.DTO;
using CompanyManagment.App.Contracts.EmployeeInsuranceRecord;
namespace CompanyManagment.App.Contracts.Employee;
public interface IEmployeeApplication
{
OperationResult Create(CreateEmployee command);
OperationResult Edit(EditEmployee command);
EditEmployee GetDetails(long id);
OperationResult Active(long id);
OperationResult DeActive(long id);
Task<List<EmployeeSelectListViewModel>> GetEmployeeToList();
List<EmployeeViewModel> GetEmployee();
Task<List<EmployeeViewModel>> Search(EmployeeSearchModel searchModel);
List<EmployeeInsuranceRecordViewModel> SearchInsuranceRecord(EmployeeInsuranceRecordSearchModel searchModel);
OperationResult CreateEmployeeInsuranceRecord(CreateEmployeeInsuranceRecord command);
OperationResult EditEmployeeInsuranceRecord(EditEmployeeInsuranceRecord command);
void RemoveEmployeeInsuranceRecord(long Id);
OperationResult ValidationEmployeeInsuranceRecord(EmployeeInsuranceRecordViewModel eir);
OperationResult ValidationEmployeeInsuranceRecord(List<CreateEmployeeInsuranceRecord> eir_lst);
OperationResult ValidationEmployeeCompleteItem(long employeeId);
List<EmployeeViewModel> GetEmployeeByTextSearch(string textSearch);
List<EmployeeViewModel> SearchForClient(EmployeeSearchModel searchModel);
OperationResult Remove(long id);
List<EmployeeViewModel> GetEmployeeByTextSearchForClient(string textSearch, long workshopId);
List<EmployeeViewModel> GetEmployeeByTextSearchNationalCodeForClient(string textSearch, long workshopId);
List<EmployeeViewModel> GetEmployeeByTextSearchInsuranceCodeForClient(string textSearch, long workshopId);
OperationResult CreateEmployeeForClient(CreateEmployee command);
OperationResult EditEmployeeForClient(EditEmployee command);
EditEmployee GetDetailsForClient(long id, long workshopId);
#region NewByHeydari
List<EmployeeViewModel> SearchForMain(EmployeeSearchModel searchModel);
#endregion
#region Pooya
List<EmployeeViewModel> GetRangeByIds(IEnumerable<long> employeeIds);
EmployeeViewModel GetEmployeeByNationalCodeIfHasActiveLeftWork(string nationalCode, List<long> workshopIds);
List<EmployeeViewModel> GetWorkingEmployeesByWorkshopId(long workshopId);
EmployeeViewModel GetEmployeeByNationalCodeIfHasLeftWork(string nationalCode, List<long> workshopIds);
#endregion
#region Mahan
OperationResult CreateEmployeeByClient(CreateEmployeeByClient command);
/// <summary>
/// اطلاعات پرسنل با کد ملی در کارگاه. اگر در کارگاه کار نکرده باشه وجود نداشته باشه اطلاعات خالی داده میشه
/// </summary>
/// <param name="nationalCode"></param>
/// <param name="birthDate"></param>
/// <param name="workshopId"></param>
/// <returns></returns>
Task<OperationResult<EmployeeByNationalCodeInWorkshopViewModel>>
ValidateCreateEmployeeClientByNationalCodeAndWorkshopId(string nationalCode,
string birthDate,bool authorizedCanceled, long workshopId);
/// <summary>
/// پرسنل هایی که در کارگاهی از سمت ادمین شروع به کار کرده اند
/// </summary>
/// <param name="workshopId"></param>
/// <returns></returns>
Task<ICollection<ClientStartedWorkEmployeesDto>> GetClientEmployeesStartWork(long workshopId);
Task<ICollection<ClientLeftWorkWorkEmployeesDto>> GetEmployeesForLeftWorkTemp(long workshopId);
Task<GetEditEmployeeInEmployeeDocumentViewModel> GetEmployeeEditInEmployeeDocumentWorkFlow(long employeeId,
long workshopId);
Task<OperationResult> EditEmployeeInEmployeeDocumentWorkFlow(EditEmployeeInEmployeeDocument command);
Task<List<EmployeeSelectListViewModel>> WorkedEmployeesInWorkshopSelectList(long workshopId);
Task<OperationResult<EmployeeDataFromApiViewModel>> GetEmployeeDataFromApi(string nationalCode, string birthDate);
Task<List<EmployeeSelectListViewModel>> GetWorkingEmployeesSelectList(long workshopId);
#endregion
#region Api
/// <summary>
/// لیست پرسنل برای جستجو
/// </summary>
/// <param name="searchText"></param>
/// <param name="id"></param>
/// <returns></returns>
Task<List<EmployeeSelectListViewModel>> GetSelectList(string searchText, long id);
/// <summary>
/// لیست کل پرسنل
/// </summary>
/// <returns></returns>
Task<List<GetEmployeeListViewModel>> GetList(GetEmployeeListSearchModel searchModel);
#endregion
}