| | |
| | | using Volo.Abp.Application.Dtos; |
| | | using Volo.Abp.Data; |
| | | using Volo.Abp.ObjectExtending; |
| | | using CMS.Plugin.HIAWms.Domain.Shared.Util; |
| | | |
| | | namespace CMS.Plugin.HIAWms.Application.Implements; |
| | | |
| | |
| | | } |
| | | |
| | | var specification = new WmsAreaSpecification(input.Name); |
| | | var count = await _wmsareaRepository.GetCountAsync(input.Filter, specification); |
| | | var list = await _wmsareaRepository.GetListAsync(input.Sorting, input.MaxResultCount, input.SkipCount, input.Filter, specification); |
| | | var area = ObjectMapper.Map<GetWmsAreasInput, WmsArea>(input); |
| | | var count = await _wmsareaRepository.GetCountAsync(area,input.Filter, specification); |
| | | var list = await _wmsareaRepository.GetListAsync(area,input.Sorting, input.MaxResultCount, input.SkipCount, input.Filter, specification); |
| | | |
| | | return new PagedResultDto<WmsAreaDto>(count, ObjectMapper.Map<List<WmsArea>, List<WmsAreaDto>>(list)); |
| | | } |
| | |
| | | /// <inheritdoc /> |
| | | public virtual async Task AdjustSortAsync(Guid id, int sort) |
| | | { |
| | | var list = await _wmsareaRepository.GetListAsync(nameof(WmsArea.Sort)); |
| | | var list = await _wmsareaRepository.GetListAsync(null,nameof(WmsArea.Sort)); |
| | | if (list != null && list.Any()) |
| | | { |
| | | var initSort = 1; |
| | |
| | | } |
| | | |
| | | var specification = new WmsAreaSpecification(input.Name); |
| | | var list = await _wmsareaRepository.GetListAsync(input.Sorting, input.MaxResultCount, input.SkipCount, input.Filter, specification, includeDetails: true); |
| | | var area = ObjectMapper.Map<GetWmsAreasInput, WmsArea>(input); |
| | | var list = await _wmsareaRepository.GetListAsync(area,input.Sorting, input.MaxResultCount, input.SkipCount, input.Filter, specification, includeDetails: true); |
| | | var result = ObjectMapper.Map<List<WmsArea>, List<WmsAreaDto>>(list); |
| | | |
| | | var sheets = new Dictionary<string, object> |
| | | { |
| | | ["配置"] = result.Select(x => x.GetExportData()).ToList(), |
| | | ["配置"] = ExportHelper.ConvertListToExportData(result), |
| | | }; |
| | | |
| | | var fileName = result.Count > 1 ? "WmsArea列表" : result.Count == 1 ? result.First()?.AreaName : "WmsArea模版"; |