diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Base/SystemModule/DataItem/DataItemService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Base/SystemModule/DataItem/DataItemService.cs index e53ae1d1e..2573255e1 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Base/SystemModule/DataItem/DataItemService.cs +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Base/SystemModule/DataItem/DataItemService.cs @@ -24,6 +24,7 @@ namespace Learun.Application.Base.SystemModule t.F_ItemId, t.F_ParentId, t.F_ItemCode, + t.F_ItemCodeGB, t.F_ItemName, t.F_IsTree, t.F_IsNav, @@ -43,6 +44,7 @@ namespace Learun.Application.Base.SystemModule t.F_ItemId, t.F_ParentId, t.F_ItemCode, + t.F_ItemCodeGB, t.F_ItemName, t.F_ItemValue, t.F_QuickQuery, @@ -72,7 +74,7 @@ namespace Learun.Application.Base.SystemModule try { StringBuilder strSql = new StringBuilder(); - strSql.Append("SELECT " + fieldSql + " FROM LR_Base_DataItem t WHERE t.F_DeleteMark = 0 Order By t.F_ParentId,t.F_SortCode "); + strSql.Append("SELECT " + fieldSql + " FROM LR_Base_DataItem t WHERE t.F_DeleteMark = 0 and t.F_EnabledMark=1 Order By t.F_ParentId,t.F_SortCode "); return this.BaseRepository().FindList(strSql.ToString()); } catch (Exception ex) @@ -147,6 +149,38 @@ namespace Learun.Application.Base.SystemModule #endregion #region 数据字典明细 + + /// + /// 获取数据字典明细 + /// + /// + public IEnumerable GetAllDetailList() + { + try + { + StringBuilder strSql = new StringBuilder(); + strSql.Append("SELECT " + @"t.F_ItemId, + t.F_ParentId, + t2.F_ItemCode, + t.F_ItemName, + t.F_ItemValue " + @" FROM LR_Base_DataItemDetail t + INNER JOIN LR_Base_DataItem t2 ON t.F_ItemId = t2.F_ItemId + WHERE t.F_DeleteMark = 0 and t.F_EnabledMark=1 Order By t.F_SortCode + "); + return this.BaseRepository().FindList(strSql.ToString()); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } /// /// 获取数据字典明显根据分类编号 /// @@ -159,7 +193,7 @@ namespace Learun.Application.Base.SystemModule StringBuilder strSql = new StringBuilder(); strSql.Append("SELECT " + detailFieldSql + @" FROM LR_Base_DataItemDetail t INNER JOIN LR_Base_DataItem t2 ON t.F_ItemId = t2.F_ItemId - WHERE t2.F_ItemCode = @itemCode AND t.F_DeleteMark = 0 Order By t.F_SortCode + WHERE t2.F_ItemCode = @itemCode AND t.F_DeleteMark = 0 Order By t.F_SortCode "); return this.BaseRepository().FindList(strSql.ToString(), new { itemCode = itemCode }); }