详情接口
This commit is contained in:
@@ -8,6 +8,8 @@ using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using WMS.Web.Core;
|
||||
using WMS.Web.Core.Dto;
|
||||
using WMS.Web.Core.Dto.InStock;
|
||||
using WMS.Web.Core.Help;
|
||||
using WMS.Web.Core.Internal.Results;
|
||||
using WMS.Web.Domain.Entitys;
|
||||
using WMS.Web.Domain.Infrastructure;
|
||||
@@ -178,5 +180,25 @@ namespace WMS.Web.Repositories
|
||||
{
|
||||
return await GetPagedList(dto);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取详情
|
||||
/// </summary>
|
||||
/// <param name="id"></param>
|
||||
/// <returns></returns>
|
||||
public async Task<InStockInfoResponse> GetInfo(int id)
|
||||
{
|
||||
var res = await _context.Instock
|
||||
.FirstOrDefaultAsync(f => id == f.Id);
|
||||
if (res == null) return null;
|
||||
var response = new InStockInfoResponse()
|
||||
{
|
||||
CreateTime = res.CreateTime.DateToStringSeconds(),
|
||||
SyncTime = res.SyncTime.DateToStringSeconds(),
|
||||
Creator = _singleDataService.GetSingleData(SingleAction.Staffs, _loginRepositories.CompanyId, res.CreatorId),
|
||||
Operate = _singleDataService.GetSingleData(SingleAction.Staffs, _loginRepositories.CompanyId, res.OperateId)
|
||||
};
|
||||
return response;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user