| | |
| | | using System.Web.Http; |
| | | using WebAPI.Models; |
| | | using SyntacticSugar.constant; |
| | | using WebAPI.Utility; |
| | | |
| | | namespace WebAPI.Controllers |
| | | { |
| | | [Permission(HModName = "Cg_POInStockBill")] |
| | | //收料通知单Controller |
| | | public class Cg_POInStockBillController : ApiController |
| | | { |
| | |
| | | { |
| | | |
| | | ds = oCN.RunProcReturn("select * from h_v_IF_POInStockBillEdit where hmainid=" + HInterID, "h_v_IF_POInStockBillList"); |
| | | if (ds == null || ds.Tables[0].Rows.Count == 0) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "false!"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | else |
| | | { |
| | | objJsonResult.code = "1"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = "Sucess!"; |
| | | objJsonResult.data = ds.Tables[0]; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "Exception!" + e.ToString(); |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | [Route("Cg_POInStockBill/cx1")] |
| | | [HttpGet] |
| | | public object cx1(long HInterID,long HSubID) |
| | | { |
| | | try |
| | | { |
| | | |
| | | ds = oCN.RunProcReturn("select * from h_v_IF_POInStockBillEdit where hmainid=" + HInterID + " and hsubid=" + HSubID, "h_v_IF_POInStockBillList"); |
| | | if (ds == null || ds.Tables[0].Rows.Count == 0) |
| | | { |
| | | objJsonResult.code = "0"; |
| | |
| | | /// </summary> |
| | | [Route("Cg_POInStockBill/list")] |
| | | [HttpGet] |
| | | [Permission(HModName = "Cg_POInStockBillQuery")] |
| | | public object list(string sWhere, string user) |
| | | { |
| | | try |