private static void UpdateDatabase()
 {
     using (var db = new FluentModel())
     {
     var schemaHandler = db.GetSchemaHandler();
     EnsureDB(schemaHandler);
     }
 }
        public void WriteReports(IEnumerable<PartReportInputModel> reports)
        {
            using (var db = new FluentModel())
            {
                UpdateDatabase();

                db.Add(reports);

                db.SaveChanges();
            }
        }
        public IEnumerable<PartReportInputModel> ReadReports()
        {
            var reports = new List<PartReportInputModel>();

            using (var db = new FluentModel())
            {
                reports = db.PartReportInputModels.ToList();
            }

            return reports;
        }