using Mapster; using MapsterMapper; using Microsoft.Extensions.Configuration; using SqlSugar; using System.DirectoryServices.Protocols; using System.Text.Json; using WIDESEA_Common.LocationEnum; using WIDESEA_Common.StockEnum; using WIDESEA_Common.TaskEnum; using WIDESEA_Common.WareHouseEnum; using WIDESEA_Core; using WIDESEA_Core.BaseRepository; using WIDESEA_Core.BaseServices; using WIDESEA_Core.Core; using WIDESEA_Core.Enums; using WIDESEA_Core.Helper; using WIDESEA_DTO.GradingMachine; using WIDESEA_DTO.MES; using WIDESEA_DTO.Stock; using WIDESEA_DTO.Task; using WIDESEA_IBasicService; using WIDESEA_IStockService; using WIDESEA_ITaskInfoService; using WIDESEA_Model.Models; namespace WIDESEA_TaskInfoService { public partial class TaskService : ServiceBase>, ITaskService { private readonly IMapper _mapper; private readonly IStockInfoService _stockInfoService; private readonly ILocationInfoService _locationInfoService; private readonly HttpClientHelper _httpClientHelper; private readonly IConfiguration _configuration; private readonly RoundRobinService _roundRobinService; private readonly IMesService _mesService; private readonly ITask_HtyService _task_HtyService; private readonly IStockInfo_HtyService _stockInfo_HtyService; private readonly IUnitOfWorkManage _unitOfWorkManage; public IRepository Repository => BaseDal; private readonly Dictionary _taskOrderBy = new() { { nameof(Dt_Task.Grade), OrderByType.Desc }, { nameof(Dt_Task.CreateDate), OrderByType.Asc }, }; public List TaskTypes => typeof(TaskTypeEnum).GetEnumIndexList(); public List TaskOutboundTypes => typeof(TaskTypeEnum).GetEnumIndexList(); public TaskService( IRepository BaseDal, IMapper mapper, IStockInfoService stockInfoService, ILocationInfoService locationInfoService, HttpClientHelper httpClientHelper, IConfiguration configuration, RoundRobinService roundRobinService, IMesService mesService, ITask_HtyService task_HtyService, IStockInfo_HtyService stockInfo_HtyService, IUnitOfWorkManage unitOfWorkManage) : base(BaseDal) { _mapper = mapper; _stockInfoService = stockInfoService; _locationInfoService = locationInfoService; _httpClientHelper = httpClientHelper; _configuration = configuration; _roundRobinService = roundRobinService; _mesService = mesService; _task_HtyService = task_HtyService; _stockInfo_HtyService = stockInfo_HtyService; _unitOfWorkManage = unitOfWorkManage; } } }