示例#1
0
        public BillViewModel(String stt_rec)
        {
            var db = new LVTDBContext();

            this.soph1  = db.soph1.Where(x => x.stt_rec == stt_rec).SingleOrDefault();
            this.lsoct1 = this.soph1 != null?db.soct1.Where(x => x.stt_rec == this.soph1.stt_rec).ToList() : new List <soct1>()
            {
                new soct1()
            };
        }
示例#2
0
        //private static LVTDBContext _db;

        public CommonController()
        {
            db = new LVTDBContext();
            //_db = new LVTDBContext();
        }