Exemplo 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();
            }
        }
Exemplo n.º 2
0
 public VaccinesController(SheepSiteV2Context db)
 {
     this.db = db;
 }
 public HomeController(SheepSiteV2Context db)
 {
     this.db = db;
 }
 public PregnanciesController(SheepSiteV2Context db)
 {
     this.db = db;
 }
Exemplo n.º 5
0
 public AnimalsController(SheepSiteV2Context db)
 {
     this.db = db;
 }
 public TreatmentsController(SheepSiteV2Context db)
 {
     this.db = db;
 }