namespace Win_in.Sfs.Wms.Pda.Controllers.Inventories; using System.Collections.Generic; using System.Threading.Tasks; using Microsoft.AspNetCore.Mvc; using Volo.Abp.AspNetCore.Mvc; using Win_in.Sfs.Label.Application.Contracts; /// /// 采购标签控制器 /// [ApiController] [Route($"{PdaHostConst.ROOT_ROUTE}label/inventorylabel")] public class InventoryLabelController : AbpController { private readonly IInventoryLabelAppService _labelAppService; /// /// /// /// public InventoryLabelController( IInventoryLabelAppService labelAppService) { this._labelAppService = labelAppService; } /// /// 按标签号获取采购标签 /// /// 标签号 /// [HttpGet("by-code")] public virtual async Task GetByCode(string code) { return await _labelAppService.GetByCodeAsync(code).ConfigureAwait(false); } /// /// 生成箱码 /// /// /// /// [HttpPost("generate-and-create/many/{count}")] public virtual async Task> GenerateAndCreateManyAsync(InventoryLabelWithoutCodeCreateInput input, int count) { return await _labelAppService.GenerateAndCreateManyAsync(input, count).ConfigureAwait(false); } /// /// EOF系统接口 /// 插入箱码记录表、插入拆箱记录表 /// 是客户箱码,不需要LabelDefine /// /// /// [HttpPost("create-many-no-code-new")] public virtual async Task> CreateManyByNoCode_NewAsync(List inputs) { return await _labelAppService.CreateManyByNoCode_NewAsync(inputs).ConfigureAwait(false); } }