Example #1
0
 /// <summary>
 /// 根据ID获取功能表实体
 /// </summary>
 /// <param name="guid">主键ID</param>
 /// <returns>返回功能表实体</returns> 
 public FunctionInfo GetItemById(Guid guid)
 {
     FunctionInfo tem = new FunctionInfo();
     tem = Dal.Find<FunctionInfo>(FunctionInfo._.ID == guid);
     return tem;
 }
Example #2
0
 /// <summary>
 /// 是否存在相同编号,或名称
 /// </summary>
 /// <param name="entity"></param>
 /// <returns></returns>
 public bool ExitCodeAndName(FunctionInfo entity)
 {
     return Dal.Exists<FunctionInfo>(FunctionInfo._.ID != entity.ID && (FunctionInfo._.Code == entity.Code || FunctionInfo._.Name == entity.Name));
 }