using DS.Module.Core; using DS.WMS.Core.Code.Dtos; using DS.WMS.Core.Code.Interface; using DS.WMS.Core.Sys.Dtos; using Microsoft.AspNetCore.Mvc; namespace DS.WMS.AdminApi.Controllers; /// /// 基础信息导入服务 /// public class CodeInfoImportController : ApiController { private readonly ICodeInfoImportService _invokeService; /// /// 构造函数 /// /// public CodeInfoImportController(ICodeInfoImportService invokeService) { _invokeService = invokeService; } /// /// 按Excel导入包装信息 /// /// Excel文件 /// [HttpPost] [Route("ImportPackageByExcel")] public async Task> ImportPackageByExcel(IFormFile file) { var res = await _invokeService.ImportPackageByExcel(file); return res; } /// /// 按Excel导入集装箱信息 /// /// Excel文件 /// [HttpPost] [Route("ImportCtnByExcel")] public async Task> ImportCtnByExcel(IFormFile file) { var res = await _invokeService.ImportCtnByExcel(file); return res; } /// /// 按Excel导入国家信息 /// /// Excel文件 /// [HttpPost] [Route("ImportCountryByExcel")] public async Task> ImportCountryByExcel(IFormFile file) { var res = await _invokeService.ImportCountryByExcel(file); return res; } /// /// 按Excel导入商品信息 /// /// Excel文件 /// [HttpPost] [Route("ImportGoodsByExcel")] public async Task> ImportGoodsByExcel(IFormFile file) { var res = await _invokeService.ImportGoodsByExcel(file); return res; } /// /// 按Excel导入港口信息 /// /// Excel文件 /// [HttpPost] [Route("ImportPortByExcel")] public async Task> ImportPortByExcel(IFormFile file) { var res = await _invokeService.ImportPortByExcel(file); return res; } }