Ejemplo n.º 1
0
 private void SeedPharmacyNotification(PharmacyDbContext context)
 {
     context.Add(new PharmacyNotification {
         Content = "Lexapro on sale! Get 15% off!", Approved = true, PharmacyId = "Jankovic"
     });
     context.Add(new PharmacyNotification {
         Content = "Aspirin on sale! Get 11% off!", Approved = true, PharmacyId = "Liman"
     });
     context.SaveChanges();
 }
Ejemplo n.º 2
0
        private void SeedUrgentMedicationProcurement(PharmacyDbContext context)
        {
            context.Add(new UrgentMedicationProcurement
            {
                MedicationName     = "Brufen",
                MedicationDosage   = "600mg",
                MedicationQuantity = 5
            });

            context.SaveChanges();
        }
Ejemplo n.º 3
0
        public void SeedAllEntities(PharmacyDbContext context)
        {
            SeedPharmacies(context);
            SeedPharmacyNotification(context);
            // TODO(Jovan): Remove once MedbayTech.Medication is fully finished

            /*SeedMedicationCategory(context);
             * SeedMedicationIngredient(context);
             * SeedMedication(context);
             * SeedMedicationUsage(context);*/
            SeedUrgentMedicationProcurement(context);
        }
Ejemplo n.º 4
0
 private void SeedPharmacies(PharmacyDbContext context)
 {
     context.Add(new Pharmacy {
         Id = "Jankovic", APIKey = "ID1APIKEYAAAA", APIEndpoint = "jankovic.rs", Email = "*****@*****.**", RecieveNotificationFrom = true
     });
     context.Add(new Pharmacy {
         Id = "Liman", APIKey = "ID2APIKEYAAAA", APIEndpoint = "liman.li", Email = "*****@*****.**", RecieveNotificationFrom = true
     });
     context.Add(new Pharmacy {
         Id = "SchnabelRemote", APIKey = "ID3APIKEYAAAA", APIEndpoint = "http://schnabel.herokuapp.com/pswapi/drugs/name/", Email = "*****@*****.**", RecieveNotificationFrom = true
     });
     context.Add(new Pharmacy {
         Id = "SchnabellLocal", APIKey = "ID4APIKEYAAAA", APIEndpoint = "localhost:6565", Email = "*****@*****.**", RecieveNotificationFrom = true
     });
     context.SaveChanges();
 }
Ejemplo n.º 5
0
 public bool IsAlreadyFull(PharmacyDbContext context) =>
 context.Pharmacies.Count() > 0;