* Extended CustomerOrdersController and CustomerOrderService
This commit is contained in:
@@ -72,6 +72,13 @@ namespace SytelineSaAppEfDataModel.Services
|
||||
.Where(x => x.CustNum == customerNumber && x.CustSeq == customerSequence && x.CustPo == poNumber)
|
||||
.Select(x => mapper.Map<CustomerOrderDto>(x)).FirstOrDefaultAsync();
|
||||
}
|
||||
|
||||
public async Task<CustomerOrderDto?> GetByPo(string poNumber)
|
||||
{
|
||||
return await context.CustomerOrders.Where(x => x.CustPo == poNumber && x.Stat == "O")
|
||||
.OrderByDescending(x => x.CreateDate).Select(x => mapper.Map<CustomerOrderDto>(x))
|
||||
.FirstOrDefaultAsync();
|
||||
}
|
||||
|
||||
public async Task<IList<CustomerOrderDto>> GetListByCustomerAndPo(string customerNumber, int customerSequence,
|
||||
string poNumber)
|
||||
|
||||
@@ -17,6 +17,7 @@ namespace SytelineSaAppEfDataModel.Services
|
||||
Task<IList<CustomerOrderDto>> GetListByCustomerAndPo(string customerNumber, int customerSequence,
|
||||
string poNumber);
|
||||
|
||||
Task<CustomerOrderDto?> GetByPo(string poNumber);
|
||||
Task<List<CustomerOrderDto>> GetListByCustomer(string customerNumber, int customerSequence);
|
||||
Task<IEnumerable<CustomerOrderLineDto>?> GetLinesByCoNumber(string customerOrderNumber);
|
||||
Task<IEnumerable<CustomerOrderLineItemDto>?> GetItemsByCoNumber(string customerOrderNumber);
|
||||
|
||||
Reference in New Issue
Block a user