using System.Collections.Generic; using System.Threading.Tasks; using Microsoft.AspNetCore.Mvc; using Volo.Abp.AspNetCore.Mvc; using Win_in.Sfs.Basedata.Application.Contracts; namespace Win_in.Sfs.Wms.Pda.Controllers.BaseDatas; /// /// /// [ApiController] [Route($"{PdaHostConst.ROOT_ROUTE}customer-address")] public class CustomerAddressController : AbpController { private readonly ICustomerAddressAppService _customerAddressAppService; /// /// /// /// public CustomerAddressController(ICustomerAddressAppService customerAddressAppService) { _customerAddressAppService = customerAddressAppService; } /// /// 按代码获取客户地址信息 /// /// 客户地址代码 /// [HttpGet("{code}")] public virtual async Task GetAsync(string code) { var result = await _customerAddressAppService.GetByCodeAsync(code).ConfigureAwait(false); return result; } /// /// /// /// /// [HttpGet("by-customer")] public virtual async Task> GetByCustomerCodeAsync(string customerCode) { var entities = await _customerAddressAppService.GetByCustomerCodeAsync(customerCode).ConfigureAwait(false); return entities; } }