diff --git a/Sources/ConsoleDbSQLite/Program.cs b/Sources/ConsoleDbSQLite/Program.cs index 4469601..8ea6fc8 100644 --- a/Sources/ConsoleDbSQLite/Program.cs +++ b/Sources/ConsoleDbSQLite/Program.cs @@ -80,7 +80,7 @@ List characteristics = new List }; -List runePages = new List +/*List runePages = new List { new RunePageEntity { @@ -95,7 +95,7 @@ List runePages = new List { Category.OtherMinor2, new RuneEntity { Name = "Inébranlable", Description = "Vous gagnez +5% de Ténacité et +5% de résistance aux ralentissements. Ces valeurs augmentent avec vos PV manquants, jusqu'à +20% de Ténacité et +20% de résistance aux ralentissements supplémentaires. Les valeurs max sont atteintes à 30% de vos PV. ", RuneFamily = RuneFamily.Unknown} } } } -}; +};*/ using (var context = new SQLiteLolContext()) @@ -109,7 +109,7 @@ using (var context = new SQLiteLolContext()) Image = image, Skins = skins, Characteristics = characteristics, - RunePages = runePages + //RunePages = runePages }; context.Champions.Add(jax); context.SaveChanges(); diff --git a/Sources/EntityFrameworkLib/projet.Champions.db b/Sources/ConsoleDbSQLite/projet.Champions.db similarity index 99% rename from Sources/EntityFrameworkLib/projet.Champions.db rename to Sources/ConsoleDbSQLite/projet.Champions.db index 5ff60a7..b93633a 100644 Binary files a/Sources/EntityFrameworkLib/projet.Champions.db and b/Sources/ConsoleDbSQLite/projet.Champions.db differ diff --git a/Sources/EntityFrameworkLib/LolContext.cs b/Sources/EntityFrameworkLib/LolContext.cs index 6296cc4..1403514 100644 --- a/Sources/EntityFrameworkLib/LolContext.cs +++ b/Sources/EntityFrameworkLib/LolContext.cs @@ -53,10 +53,10 @@ namespace EntityFrameworkLib //Relation many-to-many entre les champions et pages de runes : Un Champion peut avoir plusieurs pages de runes et plusieurs pages de runes peuvent être définies sur un champion - modelBuilder.Entity() + /*modelBuilder.Entity() .HasMany(c => c.RunePages) .WithMany(r => r.Champions) - .UsingEntity(x => x.ToTable("ChampionRunePages")); + .UsingEntity(x => x.ToTable("ChampionRunePages"));*/ } } } diff --git a/Sources/EntityFrameworkLib/RunePageEntity.cs b/Sources/EntityFrameworkLib/RunePageEntity.cs index 3719dc2..1ea37ce 100644 --- a/Sources/EntityFrameworkLib/RunePageEntity.cs +++ b/Sources/EntityFrameworkLib/RunePageEntity.cs @@ -14,12 +14,12 @@ namespace EntityFrameworkLib [Key] [MaxLength(256)] public string Name { get; set; } - public RuneEntity? this[Category category] + /*public RuneEntity? this[Category category] { get { return Runes.ContainsKey(category) ? Runes[category] : null; } set { Runes[category] = value; } - } - public Dictionary Runes { get; set; } + }*/ + //public Dictionary? Runes { get; set; } public ICollection? Champions { get; set; } } } diff --git a/Sources/Web_Api/Program.cs b/Sources/Web_Api/Program.cs index dda2b35..e4aaf71 100644 --- a/Sources/Web_Api/Program.cs +++ b/Sources/Web_Api/Program.cs @@ -45,7 +45,7 @@ builder.Services.AddSwaggerGen(c => c.SwaggerDoc("v2", new OpenApiInfo { Title = "API_LOL", Version = "v2" }); }); -var app = builder.Build(); +app = builder.Build(); // Configure the HTTP request pipeline. if (app.Environment.IsDevelopment())