コード例 #1
0
        private static void InitAppInfo(OrganiDbContext db)
        {
            if (!db.AppInfo.Any(a => a.DeletedDate == null))
            {
                AppInfo entity = new AppInfo
                {
                    Email         = "*****@*****.**",
                    HashTag       = "#developerləri qoruyaq",
                    PhoneNumber   = "+012-312-21-12",
                    Address       = "Nizami küçəsi 203B, AF Business House, 2-ci mərtəbə",
                    FacebookLink  = "https://www.facebook.com/code.edu.az",
                    InstagramLink = "https://www.instagram.com/code.edu.az",
                };

                db.AppInfo.Add(entity);

                db.SaveChanges();
            }
        }
コード例 #2
0
 private static void InitProducts(OrganiDbContext db)
 {
     var category = db.Categories.FirstOrDefault();
 }