Files
U8-Import/NX.ERP.WebAPi/Controllers/Sale/DispatchController.cs

44 lines
1.2 KiB
C#
Raw Normal View History

2021-01-13 14:02:33 +08:00
using NX.ERP.Model.Sale;
using NX.ERP.U8.Sale;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Http;
namespace NX.ERP.WebAPi.Controllers.Sale
{
public class DispatchController : ApiController
{
2021-01-15 09:26:17 +08:00
[Route("api/Dispatch/List")]
2021-01-13 14:02:33 +08:00
// GET api/values
[HttpGet]
public IEnumerable<Model.Sale.DispatchList> List()
{
var customerDAL = new DispatchListDAL();
return customerDAL.GetList();
}
[HttpGet]
public Model.Sale.DispatchList Model(int id)
{
var customerDAL = new DispatchListDAL();
return customerDAL.GetModel(id);
}
2021-01-15 09:26:17 +08:00
[Route("api/Dispatch/{Code}")]
2021-01-13 14:02:33 +08:00
[HttpGet]
public Model.Sale.DispatchList ModelByCode(string Code)
{
var customerDAL = new DispatchListDAL();
return customerDAL.GetModel(Code);
}
2021-01-15 09:26:17 +08:00
[Route("api/Dispatch/List/{id}")]
2021-01-13 14:02:33 +08:00
[HttpGet]
2021-01-15 09:26:17 +08:00
public IEnumerable<Model.Sale.DispatchList> GetListByLastID(int id)
2021-01-13 14:02:33 +08:00
{
var customerDAL = new DispatchListDAL();
2021-01-15 09:26:17 +08:00
return customerDAL.GetListByLastID(id);
2021-01-13 14:02:33 +08:00
}
}
}