Esempio n. 1
0
        public AnimalsController(SheepSiteV2Context db)
        {
            this.db = db;

            if (this.db.Animals.Count() == 0)
            {
                this.db.Animals.Add(new Animal {
                    Id          = 1,
                    sheepDOB    = default(DateTime),
                    sheepGender = "F"
                });

                this.db.Animals.Add(new Animal
                {
                    Id          = 2,
                    sheepDOB    = default(DateTime),
                    sheepGender = "M"
                });

                this.db.SaveChanges();
            }
        }
Esempio n. 2
0
 public VaccinesController(SheepSiteV2Context db)
 {
     this.db = db;
 }
 public HomeController(SheepSiteV2Context db)
 {
     this.db = db;
 }
 public PregnanciesController(SheepSiteV2Context db)
 {
     this.db = db;
 }
Esempio n. 5
0
 public AnimalsController(SheepSiteV2Context db)
 {
     this.db = db;
 }
 public TreatmentsController(SheepSiteV2Context db)
 {
     this.db = db;
 }