王 垚
2022-04-21 3bd5db2a574a1280355de503813ba4d5cdca20b5
齐套分析列表
1个文件已修改
1个文件已添加
84 ■■■■■ 已修改文件
WebAPI/Controllers/SCGL/日计划管理/JIT_CompleteController..cs 83 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/WebAPI.csproj 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
WebAPI/Controllers/SCGL/Èռƻ®¹ÜÀí/JIT_CompleteController..cs
New file
@@ -0,0 +1,83 @@
using DBUtility;
using Newtonsoft.Json.Linq;
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Http;
using WebAPI.Models;
namespace WebAPI.Controllers.SCGL
{
    public class JIT_CompleteController : ApiController
    {
        private json objJsonResult = new json();
        SQLHelper.ClsCN oCN = new SQLHelper.ClsCN();
        DataSet ds;
        #region é½å¥—分析信息明细列表
        /// <summary>
        ///
        /// </summary>
        /// <param name="sWhere">查询条件</param>
        /// <param name="HMainICMOEntryID">生产订单明细表id</param>
        /// <returns></returns>
        [Route("JIT_Complete/JIT_CompleteDetailList")]
        [HttpGet]
        public object JIT_CompleteDetailList(string sWhere, string HMainICMOEntryID)
        {
            try
            {
                ds = oCN.RunProcReturn("select * from h_v_JIT_MOMaterReadysBill where ä¸»ç”Ÿäº§è®¢å•子内码 = '" + HMainICMOEntryID + "' " + sWhere + "  order by æ—¥è®¡åˆ’日期,物料ID  desc ", "h_v_JIT_Gy_WorkWarehouseBillList");
                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 = e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region é½å¥—分析物料占用明细列表
        /// <summary>
        ///
        /// </summary>
        /// <param name="sWhere">查询条件</param>
        /// <param name="HMaterID">物料ID</param>
        /// <returns></returns>
        [Route("JIT_Complete/JIT_CompleteMaterialDetailList")]
        [HttpGet]
        public object JIT_CompleteMaterialDetailList(string sWhere, string HMaterID)
        {
            try
            {
                ds = oCN.RunProcReturn("select * from h_v_JIT_MOMaterReadysBill where ç‰©æ–™ID = '" + HMaterID + "' " + sWhere + " ORDER BY æ—¥è®¡åˆ’日期 ASC,可用数量 DESC,生产车间 ", "h_v_JIT_Gy_WorkWarehouseBillList");
                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 = e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
    }
}
WebAPI/WebAPI.csproj
@@ -364,6 +364,7 @@
    <Compile Include="Controllers\SCGL\Sc_ComplementGoodsController.cs" />
    <Compile Include="Controllers\SCGL\Sc_ICBomBillController.cs" />
    <Compile Include="Controllers\SCGL\Sc_JIT_ComplementGoodBillController.cs" />
    <Compile Include="Controllers\SCGL\日计划管理\JIT_CompleteController..cs" />
    <Compile Include="Controllers\Sc_PckSplitBillController.cs" />
    <Compile Include="Controllers\GZGL\Gy_DuSubsidyItemBillController.cs" />
    <Compile Include="Controllers\GZGL\Gy_WorkPayTypeBillController.cs" />