You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
using System; using System.Collections.Generic; using System.Linq; using System.Text; using ICSSoft.Frame.Data.Entity; using ICSSoft.Base.Config.AppConfig;
namespace ICSSoft.Frame.Data.DAL { public class ICSDataAcquiseDAL { public static int IncludingRes(string recCode, string dsconn) { FramDataContext db = new FramDataContext(dsconn); db.Connection.Open(); db.Transaction = db.Connection.BeginTransaction(); try { var line = db.ICSRES.SingleOrDefault(a => a.RESCODE == recCode); if (line == null) return 0; else { var lineone = db.ICSUser2Res.SingleOrDefault(a => a.RESCODE == recCode && a.USERCODE == AppConfig.UserCode); if (lineone == null) return 1; else return 2; } } catch (Exception ex) { db.Transaction.Rollback(); throw ex; }
}
} }
|