123456789101112131415161718192021222324252627282930313233343536 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace GDNXFD.Data
- {
- public class WarningRepository
- {
- /// <summary>
- /// 获取所有有故障编码的报警
- /// </summary>
- /// <returns></returns>
- public static IList<Warning> GetWarningInfoHaveFaultCode()
- {
- IList<Warning> wList = new List<Warning>();
- try
- {
- using (GDNXFDDbContext ctx = new GDNXFDDbContext())
- {
- wList = ctx.Warning.Where(s => !string.IsNullOrEmpty(s.FaultCode)).ToList();
-
- }
- }
- catch (Exception ex)
- {
- }
- return wList;
- }
- }
- }
|