wtt
2 天以前 c464f72ac383e8dbc98d8a43f05098fbaff64a19
WebAPI/Controllers/CJGL/Cj_StationOutBillController.cs
@@ -154,8 +154,8 @@
                int HMouldID = list[0].HMouldID;//模具id
                double HMachineWorkTimes = list[0].HMachineWorkTimes;//设备工时
                int HIsTimeFlag = list[0].HIsTimeFlag;//是否计时
                DateTime HRelBeginTime = list[0].HRelBeginTime;//开工时间
                DateTime HRelEndTime = list[0].HRelEndTime;//完工时间
                string HRelBeginTime = list[0].HRelBeginTime;//开工时间
                string HRelEndTime = list[0].HRelEndTime;//完工时间
                LogService.Write($"1.字段赋值,用时" + sw.Elapsed );
                //单据完整性判断
@@ -475,9 +475,9 @@
                    ",HBackWorkByMaterQty=" + HBackWorkByMaterQty +
                    ",HMouldID=" + HMouldID +
                    ",HMachineWorkTimes=" + HMachineWorkTimes +
                    ",HIsTimeFlag=" + HIsTimeFlag +
                    ",HRelBeginTime='" + HRelBeginTime + "'" +
                    ",HRelEndTime='" + HRelEndTime + "'" +
                    //",HIsTimeFlag=" + HIsTimeFlag +
                    //",HRelBeginTime='" + HRelBeginTime + "'" +
                    //",HRelEndTime='" + HRelEndTime + "'" +
                    " where HInterID=" + HInterID);
                    LogService.Write("用户:" + user + ",日期:" + DateTime.Now + ",修改工序出站单据:" + HBillNo);
@@ -3263,7 +3263,86 @@
        }
        #endregion
        #region 工序汇报单流水号回车获取工序信息(带子序列)
        [Route("Cj_StationOutBill/txtHProcNo_KeyDown")]
        [HttpGet]
        public object txtHProcNo_KeyDown(string sBillNo, string sProcNo,string HSEQNumber)
        {
            try
            {
                if (sBillNo.Equals("") || sProcNo.Equals(""))
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "[0000-2-019]条形码不能为空!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                //得到信息(委外标记为0时,流转标记为1时)
                ds = oCN.RunProcReturn("select top 1 * from h_v_Sc_ProcessExchangeBillList_Sec  where 单据号= '" + sBillNo + "' and 下道流转工序<>'转' and 委外标记=0 and 流转标记=1  and 工序号='" + sProcNo + "' and 序列号='"+ HSEQNumber+"'", "h_v_Sc_ProcessExchangeBillList_Sec");
                //Ds = oCn.RunProcReturn("select top 1 * from h_v_Sc_ProcessExchangeBillList  where 单据号= '" + sBillNo + "' and 工序号='" + sProcNo + "' and 委外标记=0 and 流转标记=1 ", "h_v_Sc_ProcessExchangeBillList");
                //写入信息
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "[3790-2-013]工序号错误或者当前工序号不允许进站,请重新输入!";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                objJsonResult.code = "1";
                objJsonResult.count = 1;
                objJsonResult.Message = "[0000-1-037]Sucess!";
                objJsonResult.data = ds.Tables[0];
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "[0000-1-038]Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region 工序汇报单获取对应所以序列
        [Route("Cj_StationOutBill/getAllHSEQ")]
        [HttpGet]
        public object getAllHSEQ(string HInterID)
        {
            try
            {
                //得到信息(委外标记为0时,流转标记为1时
                ds = oCN.RunProcReturn("select * from Sc_ProcessExchangeBillSEQ  where HInterID= " + HInterID, "Sc_ProcessExchangeBillSEQ");
                //写入信息
                if (ds == null || ds.Tables[0].Rows.Count == 0)
                {
                    objJsonResult.code = "0";
                    objJsonResult.count = 0;
                    objJsonResult.Message = "子序列缺失";
                    objJsonResult.data = null;
                    return objJsonResult;
                }
                objJsonResult.code = "1";
                objJsonResult.count = 1;
                objJsonResult.Message = "[0000-1-037]Sucess!";
                objJsonResult.data = ds.Tables[0];
                return objJsonResult;
            }
            catch (Exception e)
            {
                objJsonResult.code = "0";
                objJsonResult.count = 0;
                objJsonResult.Message = "[0000-1-038]Exception!" + e.ToString();
                objJsonResult.data = null;
                return objJsonResult;
            }
        }
        #endregion
        #region //是否被关联
        public bool Cj_StationInBillisUse(Int64 lngBillKey, ref string sReturn)