From d247a8069bce4d94efbb155058cb9d89ef0b0cdc Mon Sep 17 00:00:00 2001 From: "songnan.zhang" Date: Tue, 14 Jun 2022 09:59:02 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=AF=BC=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- APP/QMAPP.Web/App_Data/MainPower.xml | 6 +- APP/QMAPP.Web/App_Data/Menu.xml | 11 +- .../QMAPP.FJC.BLL/Bucket/TSWeighRecoreBLL.cs | 20 + .../QMAPP.FJC.BLL/CheckTime/ProductTimeBLL.cs | 227 ++++++++++ APPQ5/QMAPP.FJC.BLL/QMAPP.FJC.BLL.csproj | 1 + .../QMAPP.FJC.DAL/Bucket/TSWeighRecoreDAL.cs | 28 ++ .../QMAPP.FJC.DAL/CheckTime/ProductTimeDAL.cs | 399 ++++++++++++++++++ APPQ5/QMAPP.FJC.DAL/QMAPP.FJC.DAL.csproj | 1 + .../DataValidators/TimeValidator.cs | 17 +- .../App_Data/Excel/TSWeighRecoreExp.xlsx | Bin 0 -> 9364 bytes .../App_Data/Excel/TSWeighRecoreExp.xml | 39 ++ APPQ5/QMAPP.FJC.Web/App_Data/Menu.xml | 19 +- .../Controllers/ProductTimeController.cs | 211 +++++++++ .../Controllers/TSWeighRecoreController.cs | 35 ++ .../Models/Bucket/TSWeighRecoreModel.cs | 4 +- .../Models/CheckTime/ProductTimeModel.cs | 297 +++++++++++++ APPQ5/QMAPP.FJC.Web/QMAPP.FJC.Web.csproj | 11 + .../Views/ProductTime/ProductTimeEdit.aspx | 166 ++++++++ .../Views/ProductTime/ProductTimeList.aspx | 115 +++++ AppCommon/QMAPP.ServicesAgent/ServiceEnums.cs | 10 + .../App_Data/FJCServiceList.xml | 7 + 21 files changed, 1607 insertions(+), 17 deletions(-) create mode 100644 APPQ5/QMAPP.FJC.BLL/CheckTime/ProductTimeBLL.cs create mode 100644 APPQ5/QMAPP.FJC.DAL/CheckTime/ProductTimeDAL.cs create mode 100644 APPQ5/QMAPP.FJC.Web/App_Data/Excel/TSWeighRecoreExp.xlsx create mode 100644 APPQ5/QMAPP.FJC.Web/App_Data/Excel/TSWeighRecoreExp.xml create mode 100644 APPQ5/QMAPP.FJC.Web/Controllers/ProductTimeController.cs create mode 100644 APPQ5/QMAPP.FJC.Web/Models/CheckTime/ProductTimeModel.cs create mode 100644 APPQ5/QMAPP.FJC.Web/Views/ProductTime/ProductTimeEdit.aspx create mode 100644 APPQ5/QMAPP.FJC.Web/Views/ProductTime/ProductTimeList.aspx diff --git a/APP/QMAPP.Web/App_Data/MainPower.xml b/APP/QMAPP.Web/App_Data/MainPower.xml index 5a6f189..b681869 100644 --- a/APP/QMAPP.Web/App_Data/MainPower.xml +++ b/APP/QMAPP.Web/App_Data/MainPower.xml @@ -168,10 +168,14 @@ - + + + + + diff --git a/APP/QMAPP.Web/App_Data/Menu.xml b/APP/QMAPP.Web/App_Data/Menu.xml index 775d271..427bc11 100644 --- a/APP/QMAPP.Web/App_Data/Menu.xml +++ b/APP/QMAPP.Web/App_Data/Menu.xml @@ -242,12 +242,18 @@ 查询 - + 查询 修改 + + + 查询 + 修改 + + 查询 @@ -427,7 +433,8 @@ - 查询 + 查询 + 导出 diff --git a/APPQ5/QMAPP.FJC.BLL/Bucket/TSWeighRecoreBLL.cs b/APPQ5/QMAPP.FJC.BLL/Bucket/TSWeighRecoreBLL.cs index 1fa19ee..d764bf4 100644 --- a/APPQ5/QMAPP.FJC.BLL/Bucket/TSWeighRecoreBLL.cs +++ b/APPQ5/QMAPP.FJC.BLL/Bucket/TSWeighRecoreBLL.cs @@ -10,6 +10,7 @@ using QMFrameWork.Log; using QMAPP.FJC.Entity; using QMAPP.MD.Entity.Bucket; using QMAPP.FJC.DAL.Bucket; +using System.Data; namespace QMAPP.FJC.BLL.Bucket { @@ -161,5 +162,24 @@ namespace QMAPP.FJC.BLL.Bucket } } #endregion + + #region 导出数据 + /// + /// 获取导出的数据 + /// + /// 查询条件 + /// 数据 + public DataTable GetExportData(TSWeighRecore model) + { + try + { + return new TSWeighRecoreDAL().GetExportData(model); + } + catch (Exception ex) + { + throw ex; + } + } + #endregion } } diff --git a/APPQ5/QMAPP.FJC.BLL/CheckTime/ProductTimeBLL.cs b/APPQ5/QMAPP.FJC.BLL/CheckTime/ProductTimeBLL.cs new file mode 100644 index 0000000..d3f7bf5 --- /dev/null +++ b/APPQ5/QMAPP.FJC.BLL/CheckTime/ProductTimeBLL.cs @@ -0,0 +1,227 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using QMAPP.BLL; + +using QMFrameWork.Data; + +using QMAPP.Entity; +using QMFrameWork.Log; +using System.Data; +using QMAPP.MD.Entity; +using QMAPP.MD.DAL; +using QMAPP.FJC.Entity.CheckTime; +using QMAPP.FJC.DAL.CheckTime; +using QMAPP.FJC.BLL.BZD; + +namespace QMAPP.FJC.BLL.CheckTime +{ + /// + /// 模块名称:本地库无记录的 时间验证 + /// 作 者:张松男 + /// 编写日期:2020年03月00日 + /// + public class ProductTimeBLL : BaseBLL + { + + #region 获取信息 + /// + /// 获取信息 + /// + /// 条件 + /// 信息 + public DataResult Get(ProductTime model) + { + DataResult result = new DataResult(); + try + { + result.Result = new ProductTimeDAL().Get(model); + } + catch (Exception ex) + { + result.IsSuccess = false; + result.Msg = Resource.SystemException; + throw ex; + } + result.IsSuccess = true; + return result; + } + #endregion + + #region 获取列表(分页) + /// + /// 获取列表 + /// + /// 条件 + /// 数据页 + /// 数据页 + public DataResult GetList(ProductTime condition, DataPage page) + { + DataResult result = new DataResult(); + try + { + //获取物料信息列表 + DataPage dataPage = new ProductTimeDAL().GetList(condition, page); + + result.Result = dataPage; + } + catch (Exception ex) + { + result.IsSuccess = false; + result.Msg = Resource.SystemException; + throw ex; + } + result.IsSuccess = true; + return result; + + } + /// + /// 获取全部条码格式规则 + /// + /// + public List GetAllList(string str) + { + return new ProductTimeDAL().GetAllList(); + } + #endregion + + #region 信息是否重复 + /// + /// 判断名称是否存在 + /// + /// 信息 + /// true:已存在;fasel:不存在。 + public bool Exists(ProductTime info) + { + try + { + return new ProductTimeDAL().Exists(info); + } + catch (Exception ex) + { + throw ex; + } + } + + #endregion + + #region 插入信息 + /// + /// 插入信息(单表) + /// + /// 信息 + /// 插入行数 + public DataResult Insert(ProductTime info) + { + DataResult result = new DataResult(); + try + { + + //基本信息 + info.PID = Guid.NewGuid().ToString(); + info.CREATEUSER = this.LoginUser.UserID; + info.CREATEDATE = DateTime.Now; + info.UPDATEUSER = info.CREATEUSER; + info.UPDATEDATE = info.CREATEDATE; + ProductTimeDAL cmdDAL = new ProductTimeDAL(); + result.Result = new ProductTimeDAL().Insert(info); + result.IsSuccess = true; + return result; + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 更新信息 + /// + /// 更新信息 + /// + /// 信息 + /// 更新行数 + public DataResult Update(ProductTime info) + { + DataResult result = new DataResult(); + try + { + info.UPDATEUSER = this.LoginUser.UserID; + info.UPDATEDATE = DateTime.Now; + result.Result = new ProductTimeDAL().Update(info); + result.IsSuccess = true; + return result; + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 删除 + /// + /// 删除信息 + /// + /// 主键串 + /// 删除个数 + public DataResult Delete(string strs) + { + int count = 0; + DataResult result = new DataResult(); + string[] list = strs.Split(":".ToCharArray()); + try + { + foreach (string str in list) + { + count += this.DeleteBarcodeRules(new ProductTime { PID = str }); + } + result.Result = count; + result.IsSuccess = true; + return result; + } + catch (Exception ex) + { + throw ex; + } + } + + /// + /// 删除信息 + /// + /// 信息 + /// 删除个数 + public int DeleteBarcodeRules(ProductTime info) + { + try + { + return new ProductTimeDAL().Delete(info); + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 导出数据 + /// + /// 获取导出的数据 + /// + /// 查询条件 + /// 数据 + public DataTable GetExportData(ProductTime model) + { + try + { + return new ProductTimeDAL().GetExportData(model); + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + } +} diff --git a/APPQ5/QMAPP.FJC.BLL/QMAPP.FJC.BLL.csproj b/APPQ5/QMAPP.FJC.BLL/QMAPP.FJC.BLL.csproj index 64cf804..f90278e 100644 --- a/APPQ5/QMAPP.FJC.BLL/QMAPP.FJC.BLL.csproj +++ b/APPQ5/QMAPP.FJC.BLL/QMAPP.FJC.BLL.csproj @@ -116,6 +116,7 @@ + diff --git a/APPQ5/QMAPP.FJC.DAL/Bucket/TSWeighRecoreDAL.cs b/APPQ5/QMAPP.FJC.DAL/Bucket/TSWeighRecoreDAL.cs index a9cbfb2..0182b37 100644 --- a/APPQ5/QMAPP.FJC.DAL/Bucket/TSWeighRecoreDAL.cs +++ b/APPQ5/QMAPP.FJC.DAL/Bucket/TSWeighRecoreDAL.cs @@ -340,5 +340,33 @@ namespace QMAPP.FJC.DAL.Bucket } #endregion + #region 获取导出的数据 + /// + /// 获取导出的数据 + /// + /// 查询条件 + /// 数据 + public DataTable GetExportData(TSWeighRecore model) + { + DataTable dt = null; + string sql = null; + List parameters = new List(); + try + { + //构成查询语句 + sql = this.GetQuerySql(model, ref parameters); + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + dt = session.GetTable(sql, parameters.ToArray()); + dt.TableName = "T_AW_TSWeighRecore"; + } + return dt; + } + catch (Exception ex) + { + throw ex; + } + } + #endregion } } diff --git a/APPQ5/QMAPP.FJC.DAL/CheckTime/ProductTimeDAL.cs b/APPQ5/QMAPP.FJC.DAL/CheckTime/ProductTimeDAL.cs new file mode 100644 index 0000000..29bab52 --- /dev/null +++ b/APPQ5/QMAPP.FJC.DAL/CheckTime/ProductTimeDAL.cs @@ -0,0 +1,399 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using QMAPP.FJC.Entity.CheckTime; +using QMFrameWork.Data; +using System.Data; +using QMAPP.Entity; + +namespace QMAPP.FJC.DAL.CheckTime +{ + /// + /// 模块名称:本地库无记录的 时间验证 + /// 作 者:张松男 + /// 编写日期:2020年03月00日 + /// + public class ProductTimeDAL + { + + #region 获取信息 + /// + /// 获取信息 + /// + /// 条件 + /// *信息 + public ProductTime Get(ProductTime info) + { + try + { + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + //获取信息 + info = session.Get(info); + } + return info; + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 获取列表 + /// + /// 获取列表 + /// + /// 条件 + /// 数据页 + /// 数据页 + public DataPage GetList(ProductTime condition, DataPage page) + { + string sql = null; + List parameters = new List(); + try + { + sql = this.GetQuerySql(condition, ref parameters); + //分页关键字段及排序 + page.KeyName = "PID"; + //if (string.IsNullOrEmpty(page.SortExpression)) + // page.SortExpression = "CREATEDATE DESC"; + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + // 对应多种数据库 + //string sqlChange = this.ChangeSqlByDB(sql, session); + page = session.GetDataPage(sql, parameters.ToArray(), page); + } + return page; + } + catch (Exception ex) + { + throw ex; + } + } + /// + /// 获取全部规则 + /// + /// + public List GetAllList() + { + try + { + string sql = "SELECT * FROM [T_MD_PRODUCT_TIMECHECK]"; + List parameters = new List(); + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + return session.GetList(sql, parameters.ToArray()).ToList(); + } + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 获取查询语句 + /// + /// 获取查询语句 + /// + /// 查询条件 + /// 参数 + /// 查询语句 + private string GetQuerySql(ProductTime condition, ref List parameters) + { + StringBuilder sqlBuilder = new StringBuilder(); + StringBuilder whereBuilder = new StringBuilder(); + try + { + sqlBuilder.Append("SELECT [PID],[CWorkLoc_Code],[PWorkLoc_Code],[PWorkLoc_Column],[Product_Column],[Check],[Operator],[Check_Type],[Check_Value],[Check_Table],[Check_Column],[Pwhere],[Remark],[CREATEDATE],[CREATEUSER],[UPDATEDATE],[UPDATEUSER]"); + sqlBuilder.Append("FROM [T_MD_PRODUCT_TIMECHECK] "); + //whereBuilder.Append(" AND FLGDEL<> '1' "); + //查询条件 + + ////查询条件 + //if (string.IsNullOrEmpty(condition.FACTORY_CODE) == false) + //{ + // whereBuilder.Append(" AND FACTORY_CODE = @FACTORY_CODE "); + // parameters.Add(new DataParameter { ParameterName = "FACTORY_CODE", DataType = DbType.String, Value = condition.FACTORY_CODE }); + //} + //if (string.IsNullOrEmpty(condition.REGEX) == false) + //{ + // whereBuilder.Append(" AND REGEX LIKE @REGEX "); + // parameters.Add(new DataParameter { ParameterName = "REGEX", DataType = DbType.String, Value = "%" + condition.REGEX + "%" }); + //} + + + if (whereBuilder.Length > 0) + { + sqlBuilder.Append(" WHERE " + whereBuilder.ToString().Substring(4)); + } + return sqlBuilder.ToString(); + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 信息是否重复 + /// + /// 判断名称是否存在 + /// + /// + /// true:已存在;fasel:不存在。 + public bool Exists(ProductTime info) + { + StringBuilder sqlBuilder = new StringBuilder(); + StringBuilder whereBuilder = new StringBuilder(); + List parameters = new List(); + int count = 0; + try + { + sqlBuilder.Append("SELECT COUNT(0) FROM T_MD_PRODUCT_TIMECHECK"); + if (info.PID == null) + { + info.PID = ""; + } + whereBuilder.Append(" AND PID <> @PID "); + parameters.Add(new DataParameter { ParameterName = "PID", DataType = DbType.String, Value = info.PID }); + + //添加进行无重复字段判断代码 + + if (whereBuilder.Length > 0) + { + sqlBuilder.Append(" WHERE " + whereBuilder.ToString().Substring(4)); + } + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + count = Convert.ToInt32(session.ExecuteSqlScalar(sqlBuilder.ToString(), parameters.ToArray())); + } + return count > 0; + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 插入信息 + /// + /// 插入信息(单表) + /// + /// 信息 + /// 插入行数 + public int Insert(ProductTime info) + { + int count = 0; + try + { + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + //插入基本信息 + count = session.Insert(info); + } + return count; + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 更新信息 + /// + /// 更新信息 + /// + /// + /// 更新行数 + public int Update(ProductTime info) + { + int count = 0; + try + { + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + //更新基本信息 + count = session.Update(info); + } + return count; + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 逻辑删除 + /// + /// 逻辑删除信息 + /// + /// + /// 删除个数 + public int Delete(ProductTime info) + { + StringBuilder sqlBuilder = new StringBuilder(); + List parameters = new List(); + int count = 0; + try + { + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + //删除基本信息 + sqlBuilder.Append("delete T_MD_PRODUCT_TIMECHECK "); + sqlBuilder.Append("WHERE PID = @PID "); + parameters.Add(new DataParameter { ParameterName = "PID", DataType = DbType.String, Value = info.PID }); + count = session.ExecuteSql(sqlBuilder.ToString(), parameters.ToArray()); + } + return count; + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + public DateTime GetServiceDateTime() + { + StringBuilder sql = new StringBuilder(); + try + { + List parameters = new List(); + string sqlScript = @"select GetDATE() as time "; + DataTable datatable = new DataTable(); + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + //插入基本信息 + datatable = session.GetTable(sqlScript, parameters.ToArray()); + } + + if (datatable.Rows.Count > 0) + { + string datetimestr = datatable.Rows[0]["time"].ToString(); + return DateTime.Parse(datetimestr); + } + + return DateTime.Now; + } + catch (Exception ex) + { + throw ex; + } + } + + /// + /// 根据工位查询出配置 + /// + /// + /// + public ProductTime GetTimeCheckCfg(string locCode, string DAI_Code) + { + List parameters = new List(); + DateTime dateTime = DateTime.MinValue; + DataTable dataTable = new DataTable(); + ProductTime timeCheck = new ProductTime(); + string sqlScript = $" select * from T_MD_PRODUCT_TIMECHECK where CWorkLoc_Code ='{locCode}' and DAI_Code = '{DAI_Code}' and [Check]='1' order by UPDATEDATE desc,CREATEDATE desc "; + + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + //更新基本信息 + dataTable = session.GetTable(sqlScript, parameters.ToArray()); + } + + + if (dataTable.Rows.Count == 0) + { + return null; ; + } + else + { + DataRow row = dataTable.Rows[0]; + + timeCheck.PID = row["PID"].ToString(); + timeCheck.CWorkLoc_Code = row["CWorkLoc_Code"].ToString(); + timeCheck.PWorkLoc_Code = row["PWorkLoc_Code"].ToString(); + timeCheck.PWorkLoc_Column = row["PWorkLoc_Column"].ToString(); + timeCheck.Product_Column = row["Product_Column"].ToString(); + timeCheck.Check = row["Check"].ToString(); + timeCheck.Operator = row["Operator"].ToString(); + timeCheck.Check_Type = row["Check_Type"].ToString(); + timeCheck.Check_Value = row["Check_Value"].ToString(); + timeCheck.Check_Table = row["Check_Table"].ToString(); + timeCheck.Check_Column = row["Check_Column"].ToString(); + timeCheck.Remark = row["Remark"].ToString(); + if (DateTime.TryParse(row["CREATEDATE"].ToString(), out dateTime)) + { + timeCheck.CREATEDATE = dateTime; + } + timeCheck.CREATEUSER = row["CREATEUSER"].ToString(); + timeCheck.UPDATEUSER = row["UPDATEUSER"].ToString(); + if (DateTime.TryParse(row["CREATEDATE"].ToString(), out dateTime)) + { + timeCheck.UPDATEDATE = dateTime; + } + timeCheck.Column1 = row["Column1"].ToString(); + timeCheck.Column2 = row["Column2"].ToString(); + timeCheck.PWhere = row["PWhere"].ToString(); + timeCheck.DAI_Code = row["DAI_Code"].ToString(); + timeCheck.Check_ValueTo = row["Check_ValueTo"].ToString(); + } + return timeCheck; + } + + public DataTable GetConfigValue(ProductTime timeCheckModel, string productCode) + { + DataTable dataTable = new DataTable(); + List parameters = new List(); + string sqlScript = $" select {timeCheckModel.Check_Column} as CheckColumnValue from {timeCheckModel.Check_Table} where {timeCheckModel.PWorkLoc_Column} ='{timeCheckModel.PWorkLoc_Code}' and {timeCheckModel.Product_Column}='{productCode}' "; + if (!string.IsNullOrEmpty(timeCheckModel.PWhere)) + { + sqlScript = sqlScript + " and " + timeCheckModel.PWhere; + } + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + //更新基本信息 + dataTable = session.GetTable(sqlScript, parameters.ToArray()); + } + + //DataSet dataSet = SqlHelper.ExecuteDataset(Config.maindbConnectionString, CommandType.Text, sqlScript); + return dataTable; + + } + + #region 获取导出的数据 + /// + /// 获取导出的数据 + /// + /// 查询条件 + /// 数据 + public DataTable GetExportData(ProductTime model) + { + DataTable dt = null; + string sql = null; + List parameters = new List(); + try + { + //构成查询语句 + sql = this.GetQuerySql(model, ref parameters); + using (IDataSession session = AppDataFactory.CreateMainSession()) + { + dt = session.GetTable(sql, parameters.ToArray()); + dt.TableName = "T_MD_PRODUCT_TIMECHECK"; + } + return dt; + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + } +} diff --git a/APPQ5/QMAPP.FJC.DAL/QMAPP.FJC.DAL.csproj b/APPQ5/QMAPP.FJC.DAL/QMAPP.FJC.DAL.csproj index e9d58fb..673e01e 100644 --- a/APPQ5/QMAPP.FJC.DAL/QMAPP.FJC.DAL.csproj +++ b/APPQ5/QMAPP.FJC.DAL/QMAPP.FJC.DAL.csproj @@ -108,6 +108,7 @@ + diff --git a/APPQ5/QMAPP.FJC.TRACING/DataValidators/TimeValidator.cs b/APPQ5/QMAPP.FJC.TRACING/DataValidators/TimeValidator.cs index 0252eda..1f31c01 100644 --- a/APPQ5/QMAPP.FJC.TRACING/DataValidators/TimeValidator.cs +++ b/APPQ5/QMAPP.FJC.TRACING/DataValidators/TimeValidator.cs @@ -2,6 +2,7 @@ using QMAPP.FJC.TRACING.DAInterface; using QMAPP.FJC.Entity.QT; using System.Data; +using QMAPP.FJC.Entity.CheckTime; using QMAPP.FJC.DAL.CheckTime; namespace QMAPP.FJC.TRACING.DataValidators @@ -11,12 +12,11 @@ namespace QMAPP.FJC.TRACING.DataValidators /// public class TimeValidator : IDataValidator { - public ValidateResult Validate(DAObject data,DAIValidation validOption) + public ValidateResult Validate(DAObject data, DAIValidation validOption) { - CHECKTIMEDAL dal = new CHECKTIMEDAL(); - var timeCheck = dal.GetTimeCheckCfg(data.WorkLocState.WORKLOC_CODE, data.DAI.DA_CODE); - //T_MD_PRODUCT_TIMECHECK timeCheck = LocSwitchDataAccess.GetTimeCheckCfg(data.WorkLocState.WORKCELL_CODE, data.DAI.DA_CODE); - if(timeCheck == null) return new ValidateResult(true, ""); + ProductTimeDAL dal = new ProductTimeDAL(); + ProductTime timeCheck = dal.GetTimeCheckCfg(data.WorkLocState.WORKCELL_CODE, data.DAI.DA_CODE); + if (timeCheck == null) return new ValidateResult(true, ""); DataTable checkTable = dal.GetConfigValue(timeCheck, data.DAValue.ToString()); if (checkTable == null || checkTable.Rows.Count == 0) { @@ -27,9 +27,9 @@ namespace QMAPP.FJC.TRACING.DataValidators var ispass = TimeOutCompare(dataRow["CheckColumnValue"].ToString(), timeCheck.Operator, timeCheck.Check_Value, timeCheck.Check_ValueTo, timeCheck.Check_Type); - if(ispass) return new ValidateResult(true, ""); + if (ispass) return new ValidateResult(true, ""); else return new ValidateResult(false, "未达到时间验证标准!"); - + } /// @@ -53,7 +53,6 @@ namespace QMAPP.FJC.TRACING.DataValidators /// public static bool TimeOutCompare(string pCheckColumnValue, string pOperator, string pCheck_Value, string pCheck_ValueTo, string pCheck_Type) { - CHECKTIMEDAL dal = new CHECKTIMEDAL(); var preStatTime = DateTime.Now; if (!DateTime.TryParse(pCheckColumnValue, out preStatTime)) { @@ -73,7 +72,7 @@ namespace QMAPP.FJC.TRACING.DataValidators throw new Exception("验证值pCheck_ValueTo必须是int类型"); } } - + ProductTimeDAL dal = new ProductTimeDAL(); DateTime serviceTime = dal.GetServiceDateTime(); TimeSpan ts = serviceTime.Subtract(preStatTime); if (pCheck_Type == "1") diff --git a/APPQ5/QMAPP.FJC.Web/App_Data/Excel/TSWeighRecoreExp.xlsx b/APPQ5/QMAPP.FJC.Web/App_Data/Excel/TSWeighRecoreExp.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..7c9f74930ce127b01514e4ec6f5276279786a744 GIT binary patch literal 9364 zcmaJ{WmsHG62)B;+}+(RI0R>KcMtCF7A(OXg1fr}g1ZI}?(Pztg=F^$`*!=s%>8Cc zx=(di_pQ?aNl-8tpqCabv&R4O{htQ?{9tHp0I;*Rv8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l~-cZ6S*|KRZd-t*Ti{)_JKs5$(X?w_1KKob1dVnu$w-U9h7=S=XT_b<4{4NCw3 literal 0 HcmV?d00001 diff --git a/APPQ5/QMAPP.FJC.Web/App_Data/Excel/TSWeighRecoreExp.xml b/APPQ5/QMAPP.FJC.Web/App_Data/Excel/TSWeighRecoreExp.xml new file mode 100644 index 0000000..6f471cc --- /dev/null +++ b/APPQ5/QMAPP.FJC.Web/App_Data/Excel/TSWeighRecoreExp.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/APPQ5/QMAPP.FJC.Web/App_Data/Menu.xml b/APPQ5/QMAPP.FJC.Web/App_Data/Menu.xml index 2de4d0f..c67f9d0 100644 --- a/APPQ5/QMAPP.FJC.Web/App_Data/Menu.xml +++ b/APPQ5/QMAPP.FJC.Web/App_Data/Menu.xml @@ -242,12 +242,18 @@ 查询 - + 查询 修改 + + + 查询 + 修改 + + 查询 @@ -427,7 +433,8 @@ - 查询 + 查询 + 导出 @@ -442,6 +449,12 @@ 导出 + + + 查询 + 导出 + +