lx
2025-10-28 bb3a3ddcad088ecaff2ba2100f053634fa43dfc4
ErrorAnalysis.Repository/CONearWOLRepository.cs
@@ -1,4 +1,4 @@
//using ErrorAnalysis.Repository.Entity;
using ErrorAnalysis.Repository.Entity;
using System;
using System.Collections.Generic;
using System.Linq;
@@ -11,13 +11,13 @@
    {
        public CONearWOLRepository(string connectionString) : base(connectionString) { }
        //public CONearWOLTable GetCONearWOL(string modelId, int sw)
        //{
        //    using (var context = new RetMcnpDbContext(_connectionString))
        //    {
        //        var result = context.CONearWOLTables.FirstOrDefault(x => x.ModelID == modelId && x.Sw == sw);
        //        return result;
        //    }
        //}
        public CONearWOLTable GetCONearWOL(string modelId, int sw)
        {
            using (var context = new RetMcnpDbContext(_connectionString))
            {
                var result = context.CONearWOLTables.FirstOrDefault(x => x.ModelID == modelId && x.Sw == sw);
                return result;
            }
        }
    }
}