From c58e1dd91b03ef55329a1b2c4800efa32395f3f4 Mon Sep 17 00:00:00 2001 From: "arthur.valin" Date: Wed, 1 Feb 2023 17:05:25 +0100 Subject: [PATCH 1/6] Adding simple Champion table --- .../DbContexts/ChampionDbContext.cs | 19 ++++++++ .../Entities/ChampionEntity.cs | 17 +++++++ .../EntityFramework.Champions.db | Bin 0 -> 20480 bytes .../EntityFramework.Champions.db-shm | Bin 0 -> 32768 bytes .../EntityFramework.Champions.db-wal | 0 .../EntityFramework/EntityFramework.csproj | 25 ++++++++++ .../20230201154310_migr.Designer.cs | 44 ++++++++++++++++++ .../Migrations/20230201154310_migr.cs | 34 ++++++++++++++ .../ChampionDbContextModelSnapshot.cs | 41 ++++++++++++++++ .../Sources/EntityFramework/Program.cs | 2 + .../Sources/LeagueOfLegends.sln | 8 +++- 11 files changed, 189 insertions(+), 1 deletion(-) create mode 100644 EntityFramework_LoL/Sources/EntityFramework/DbContexts/ChampionDbContext.cs create mode 100644 EntityFramework_LoL/Sources/EntityFramework/Entities/ChampionEntity.cs create mode 100644 EntityFramework_LoL/Sources/EntityFramework/EntityFramework.Champions.db create mode 100644 EntityFramework_LoL/Sources/EntityFramework/EntityFramework.Champions.db-shm create mode 100644 EntityFramework_LoL/Sources/EntityFramework/EntityFramework.Champions.db-wal create mode 100644 EntityFramework_LoL/Sources/EntityFramework/EntityFramework.csproj create mode 100644 EntityFramework_LoL/Sources/EntityFramework/Migrations/20230201154310_migr.Designer.cs create mode 100644 EntityFramework_LoL/Sources/EntityFramework/Migrations/20230201154310_migr.cs create mode 100644 EntityFramework_LoL/Sources/EntityFramework/Migrations/ChampionDbContextModelSnapshot.cs create mode 100644 EntityFramework_LoL/Sources/EntityFramework/Program.cs diff --git a/EntityFramework_LoL/Sources/EntityFramework/DbContexts/ChampionDbContext.cs b/EntityFramework_LoL/Sources/EntityFramework/DbContexts/ChampionDbContext.cs new file mode 100644 index 0000000..532648c --- /dev/null +++ b/EntityFramework_LoL/Sources/EntityFramework/DbContexts/ChampionDbContext.cs @@ -0,0 +1,19 @@ +using EntityFramework.Entities; +using Microsoft.EntityFrameworkCore; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace EntityFramework.DbContexts +{ + internal class ChampionDbContext : DbContext + { + public DbSet champions { get; set; } + protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder) + { + optionsBuilder.UseSqlite($"Data Source=EntityFramework.Champions.db"); + } + } +} diff --git a/EntityFramework_LoL/Sources/EntityFramework/Entities/ChampionEntity.cs b/EntityFramework_LoL/Sources/EntityFramework/Entities/ChampionEntity.cs new file mode 100644 index 0000000..631bfca --- /dev/null +++ b/EntityFramework_LoL/Sources/EntityFramework/Entities/ChampionEntity.cs @@ -0,0 +1,17 @@ +using System.ComponentModel.DataAnnotations; + +namespace EntityFramework.Entities +{ + internal class ChampionEntity + { + [Key] + [MaxLength(256)] + public string Name { get; set; } + [Required] + [MaxLength(500)] + public string Bio { get; set; } + [Required] + public string Icon { get; set; } + + } +} diff --git a/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.Champions.db b/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.Champions.db new file mode 100644 index 0000000000000000000000000000000000000000..2643996e4069079cab2a9c289dd5eca80da0fc2f GIT binary patch literal 20480 zcmeI&zi!h&9Ki9jleQ4a4HK5ikdr5nP-MrTtfZ9@R?{S;2DJmSOk%)N6H~{PU~FH6 zC*Wmx1t!!NVB}npv{=r@((3z@Prf_bcm93s#eWW8_me!9AJS|V<8)~iHsIRN)q8;uS&EKMKT#D@<&F{wL_P2FA(~kfG2q1s}0tg_000Iag z@LvSZo!XY!YH1fv9=$(_C!eC(=OmpkR+akR*y{zJ40^kLPg<*fOFlLlQiU~$X0as$ z?**A+GI4I zIQ31_YiS~xPvb9((-ZZq8b)V%dey$3D|A-VZk!)!TV}VbT@0_%3`6hbLGm$+@*>w) z$s$j)ua%wpzv)-*b4{@t)1Q`3yDYM1pbDK)mQK$m`P(>KsFN)Xt2BIl(|p%mr%^di z=u~#s)E#xNxT_3RwB}Et76JhT5I_I{1Q0*~0R#|0009JUufQX%=9(S5 + + + Exe + net6.0 + enable + enable + + + + + + all + runtime; build; native; contentfiles; analyzers; buildtransitive + + + + + + all + runtime; build; native; contentfiles; analyzers; buildtransitive + + + + diff --git a/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230201154310_migr.Designer.cs b/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230201154310_migr.Designer.cs new file mode 100644 index 0000000..7d92db0 --- /dev/null +++ b/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230201154310_migr.Designer.cs @@ -0,0 +1,44 @@ +// +using EntityFramework.DbContexts; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; + +#nullable disable + +namespace EntityFramework.Migrations +{ + [DbContext(typeof(ChampionDbContext))] + [Migration("20230201154310_migr")] + partial class migr + { + /// + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder.HasAnnotation("ProductVersion", "7.0.2"); + + modelBuilder.Entity("EntityFramework.Entities.ChampionEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("Bio") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("Icon") + .IsRequired() + .HasColumnType("TEXT"); + + b.HasKey("Name"); + + b.ToTable("champions"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230201154310_migr.cs b/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230201154310_migr.cs new file mode 100644 index 0000000..adfed99 --- /dev/null +++ b/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230201154310_migr.cs @@ -0,0 +1,34 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace EntityFramework.Migrations +{ + /// + public partial class migr : Migration + { + /// + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.CreateTable( + name: "champions", + columns: table => new + { + Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), + Bio = table.Column(type: "TEXT", maxLength: 500, nullable: false), + Icon = table.Column(type: "TEXT", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_champions", x => x.Name); + }); + } + + /// + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropTable( + name: "champions"); + } + } +} diff --git a/EntityFramework_LoL/Sources/EntityFramework/Migrations/ChampionDbContextModelSnapshot.cs b/EntityFramework_LoL/Sources/EntityFramework/Migrations/ChampionDbContextModelSnapshot.cs new file mode 100644 index 0000000..171949d --- /dev/null +++ b/EntityFramework_LoL/Sources/EntityFramework/Migrations/ChampionDbContextModelSnapshot.cs @@ -0,0 +1,41 @@ +// +using EntityFramework.DbContexts; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; + +#nullable disable + +namespace EntityFramework.Migrations +{ + [DbContext(typeof(ChampionDbContext))] + partial class ChampionDbContextModelSnapshot : ModelSnapshot + { + protected override void BuildModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder.HasAnnotation("ProductVersion", "7.0.2"); + + modelBuilder.Entity("EntityFramework.Entities.ChampionEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("Bio") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("Icon") + .IsRequired() + .HasColumnType("TEXT"); + + b.HasKey("Name"); + + b.ToTable("champions"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/EntityFramework_LoL/Sources/EntityFramework/Program.cs b/EntityFramework_LoL/Sources/EntityFramework/Program.cs new file mode 100644 index 0000000..3751555 --- /dev/null +++ b/EntityFramework_LoL/Sources/EntityFramework/Program.cs @@ -0,0 +1,2 @@ +// See https://aka.ms/new-console-template for more information +Console.WriteLine("Hello, World!"); diff --git a/EntityFramework_LoL/Sources/LeagueOfLegends.sln b/EntityFramework_LoL/Sources/LeagueOfLegends.sln index db008a1..da2dfc5 100644 --- a/EntityFramework_LoL/Sources/LeagueOfLegends.sln +++ b/EntityFramework_LoL/Sources/LeagueOfLegends.sln @@ -17,7 +17,9 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "StubLib", "StubLib\StubLib. EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "API_LoL_Project", "API_LoL_Project\API_LoL_Project.csproj", "{4EDC93E0-35B8-4EF1-9318-24F7A606BA97}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DTO", "DTO\DTO.csproj", "{7F6A519E-98F8-429E-B34F-9B0D20075CFB}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DTO", "DTO\DTO.csproj", "{7F6A519E-98F8-429E-B34F-9B0D20075CFB}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EntityFramework", "EntityFramework\EntityFramework.csproj", "{59CC9D86-8D5A-4D38-B0F3-99B4073C7885}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -49,6 +51,10 @@ Global {7F6A519E-98F8-429E-B34F-9B0D20075CFB}.Debug|Any CPU.Build.0 = Debug|Any CPU {7F6A519E-98F8-429E-B34F-9B0D20075CFB}.Release|Any CPU.ActiveCfg = Release|Any CPU {7F6A519E-98F8-429E-B34F-9B0D20075CFB}.Release|Any CPU.Build.0 = Release|Any CPU + {59CC9D86-8D5A-4D38-B0F3-99B4073C7885}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {59CC9D86-8D5A-4D38-B0F3-99B4073C7885}.Debug|Any CPU.Build.0 = Debug|Any CPU + {59CC9D86-8D5A-4D38-B0F3-99B4073C7885}.Release|Any CPU.ActiveCfg = Release|Any CPU + {59CC9D86-8D5A-4D38-B0F3-99B4073C7885}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE From 8c404922e9c73c91f2c559ea133bf0eab70201fc Mon Sep 17 00:00:00 2001 From: "arthur.valin" Date: Wed, 1 Feb 2023 17:34:45 +0100 Subject: [PATCH 2/6] Inserting mock data --- .../EntityFramework.Champions.db-wal | Bin 0 -> 8272 bytes .../EntityFramework/EntityFramework.csproj | 5 +++++ .../Sources/EntityFramework/Program.cs | 19 ++++++++++++++++-- 3 files changed, 22 insertions(+), 2 deletions(-) diff --git a/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.Champions.db-wal b/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.Champions.db-wal index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..e531c0b22fb2d5d8718ab75acfdc7b9921fb8bef 100644 GIT binary patch literal 8272 zcmeI$Eepa>6vpv8oQi@tkb&{qECazHSbYOg24b*Y^#);E7|dW1?1JCN&tMg^Rm7;# zyCC=#l>fsy^Pivdo3GZ4J!Vzg2etX|@g66z7>5P-MXDa)3;qNnW=v~xzAD2lvepA%n$?+KmY**5I_I{1Q0*~0R#~EGl6`@Eu?>gH?qSg AT>t<8 literal 0 HcmV?d00001 diff --git a/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.csproj b/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.csproj index b6dee0a..06df015 100644 --- a/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.csproj +++ b/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.csproj @@ -5,6 +5,7 @@ net6.0 enable enable + $(MSBuildProjectDirectory) @@ -22,4 +23,8 @@ + + + + diff --git a/EntityFramework_LoL/Sources/EntityFramework/Program.cs b/EntityFramework_LoL/Sources/EntityFramework/Program.cs index 3751555..8772279 100644 --- a/EntityFramework_LoL/Sources/EntityFramework/Program.cs +++ b/EntityFramework_LoL/Sources/EntityFramework/Program.cs @@ -1,2 +1,17 @@ -// See https://aka.ms/new-console-template for more information -Console.WriteLine("Hello, World!"); +using EntityFramework.DbContexts; +using EntityFramework.Entities; +using Model; + +ChampionEntity dave = new ChampionEntity() +{ + Name = "Dave", + Bio = "Le meilleur Jazzman de France", + Icon = "aaa" +}; +using (var context = new ChampionDbContext()) +{ + // Crée des nounours et les insère dans la base + Console.WriteLine("Creates and inserts new Champion"); + context.Add(dave); + context.SaveChanges(); +} From 22ed13d5351e7321d03ccfaa9d8af016612dd636 Mon Sep 17 00:00:00 2001 From: "arthur.valin" Date: Sat, 4 Feb 2023 11:06:02 +0100 Subject: [PATCH 3/6] Better Project Structure --- .vs/League-of-Legends_Project3/v17/.wsuo | Bin 0 -> 14336 bytes .../Sources/Entities/ChampionDbContext.cs | 29 +++++++++ .../Sources/Entities/ChampionEntity.cs | 15 +++++ .../Sources/Entities/Entities.Champions.db | Bin 0 -> 20480 bytes .../Entities/Entities.Champions.db-shm | Bin 0 -> 32768 bytes .../Entities/Entities.Champions.db-wal | Bin 0 -> 82432 bytes .../Sources/Entities/Entities.csproj | 24 ++++++++ ...0230204100209_myFirstMigration.Designer.cs | 55 ++++++++++++++++++ .../20230204100209_myFirstMigration.cs | 45 ++++++++++++++ .../ChampionDbContextModelSnapshot.cs | 52 +++++++++++++++++ .../Sources/Entities/Program.cs | 14 +++++ .../EntityFramework/EntityFramework.csproj | 2 +- .../Sources/LeagueOfLegends.sln | 13 +++-- EntityFramework_LoL/Sources/Stub/Program.cs | 15 +++++ EntityFramework_LoL/Sources/Stub/Stub.csproj | 15 +++++ 15 files changed, 273 insertions(+), 6 deletions(-) create mode 100644 .vs/League-of-Legends_Project3/v17/.wsuo create mode 100644 EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs create mode 100644 EntityFramework_LoL/Sources/Entities/ChampionEntity.cs create mode 100644 EntityFramework_LoL/Sources/Entities/Entities.Champions.db create mode 100644 EntityFramework_LoL/Sources/Entities/Entities.Champions.db-shm create mode 100644 EntityFramework_LoL/Sources/Entities/Entities.Champions.db-wal create mode 100644 EntityFramework_LoL/Sources/Entities/Entities.csproj create mode 100644 EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.Designer.cs create mode 100644 EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.cs create mode 100644 EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs create mode 100644 EntityFramework_LoL/Sources/Entities/Program.cs create mode 100644 EntityFramework_LoL/Sources/Stub/Program.cs create mode 100644 EntityFramework_LoL/Sources/Stub/Stub.csproj diff --git a/.vs/League-of-Legends_Project3/v17/.wsuo b/.vs/League-of-Legends_Project3/v17/.wsuo new file mode 100644 index 0000000000000000000000000000000000000000..5e22404fe5fe2e1d66d4552f005e77589fd4dd91 GIT binary patch literal 14336 zcmeHN%X1V(81H}}C_WHHMbr=@qO!@pNH(idgglh0L?W9I4qKI)%ubReyE|Ju8)A4^ zdh+kE%8NI>>Ol|O;mXC*D(~JbE)svgndxlLK4)h`Ah^BNJN^E;zyA8`Uw_?q?;QT) zyPuBzDXQFAu~$6UJSg@n={-tVyePy$#F_SBb90kf3?tZeyNCmqgo$5S^oj{lz_%ne zIF-KLQL%4p&iAyab=RD_c|CEj=Mc*M_MB6A1{6(kRa^k|C4?r#mn~ZHW*-%Mw&;`X z-rV}JAtXb5ZFfcFMNZ5JP3U43|I5M<7ex`A$f7p|VY%fRefq^7dpysefM5EjQT7{m zG0E|B+(q=n1V0S;6ndb+8;uCN>7d{C_>Z9Os$2hMeE+SI*VmDzCUJe!9Ys2)?RoeY z;K{?o@WmDx-?Bx3Y@kC|)fBgv8{~5?*cm0D2a8eqj z9^l&Lp8qub0eG%ymSOs<2-jQxFCks(2(EvYr;|F-iFN-UM-Fh_{Ce)&)n%#wWg2Bj zhWV9xUrl=xW!{2+8@?C*1biR-JMjJR@4}yie-Hi?{QK}9z<&tOc0%|Lzz@QQ;Un-- zc$EgjUFVMj#2rK#C14#5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-(d!6wk# zr#43AsrYjn%}F~f?;rS{h-=y}ePRa5|7PP?>Cd7Uln|cUR2w+ozwkXtZyWS^W|s7w z`%UU!9pjR(P%ePm)CbF$f#y1h?+=2^zr25JHvaDXSLE+Wo&Re5C*On7cGrFX;p_cJ z+v`ugf2!vHPQU-?zW?&Rzp4NJ1q!=?qyFtf-Vu1e`w#cN$L0N38-|PS`M-_~a3AOU OGa~;W_J>DpKll$%$9mNO literal 0 HcmV?d00001 diff --git a/EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs b/EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs new file mode 100644 index 0000000..d7f3cd0 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs @@ -0,0 +1,29 @@ +using Microsoft.EntityFrameworkCore; + +namespace Entities +{ + public class ChampionDbContext : DbContext + { + public DbSet champions { get; set; } + protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder) + { + optionsBuilder.UseSqlite($"Data Source=Entities.Champions.db"); + } + + protected override void OnModelCreating(ModelBuilder modelBuilder) + { + modelBuilder.Entity().HasData(new List() { + new ChampionEntity + { + Name = "Dave", + Bio = "Le meilleur Jazzman de France", + }, + new ChampionEntity + { + Name = "Armure", + Bio = "Solide", + } + }); + } + } +} diff --git a/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs b/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs new file mode 100644 index 0000000..27499d9 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs @@ -0,0 +1,15 @@ +using System.ComponentModel.DataAnnotations; +namespace Entities +{ + public class ChampionEntity + { + [Key] + [MaxLength(256)] + public string? Name { get; set; } + [Required] + [MaxLength(500)] + public string Bio { get; set; } + public string? Icon { get; set; } + + } +} diff --git a/EntityFramework_LoL/Sources/Entities/Entities.Champions.db b/EntityFramework_LoL/Sources/Entities/Entities.Champions.db new file mode 100644 index 0000000000000000000000000000000000000000..2643996e4069079cab2a9c289dd5eca80da0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0tg_000IagfB*srJh(uyJc8S1N5mcZweBu?1m)tYGM12Q@_k|K;C}K5 z$`x;=o; zW;TyN)(FVor!baYJ@4sn&MlUC1e$(a(XZ-f#Eyml0tg_000IagfB*srAb3{s-E`3J^ELTaL=yW$F*}{-YIn_oE=9T1b6uwGzC!?QnxPdzt0R$t(xvtB?yS^86F1_&U4 z00IagfB*srAb + + + net6.0 + enable + enable + $(MSBuildProjectDirectory) + Exe + + + + + + + + + + + all + runtime; build; native; contentfiles; analyzers; buildtransitive + + + + diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.Designer.cs b/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.Designer.cs new file mode 100644 index 0000000..b71d075 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.Designer.cs @@ -0,0 +1,55 @@ +// +using Entities; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; + +#nullable disable + +namespace Entities.Migrations +{ + [DbContext(typeof(ChampionDbContext))] + [Migration("20230204100209_myFirstMigration")] + partial class myFirstMigration + { + /// + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder.HasAnnotation("ProductVersion", "7.0.2"); + + modelBuilder.Entity("Entities.ChampionEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("Bio") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("Icon") + .HasColumnType("TEXT"); + + b.HasKey("Name"); + + b.ToTable("champions"); + + b.HasData( + new + { + Name = "Dave", + Bio = "Le meilleur Jazzman de France" + }, + new + { + Name = "Armure", + Bio = "Solide" + }); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.cs b/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.cs new file mode 100644 index 0000000..30af7dd --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.cs @@ -0,0 +1,45 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +#pragma warning disable CA1814 // Prefer jagged arrays over multidimensional + +namespace Entities.Migrations +{ + /// + public partial class myFirstMigration : Migration + { + /// + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.CreateTable( + name: "champions", + columns: table => new + { + Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), + Bio = table.Column(type: "TEXT", maxLength: 500, nullable: false), + Icon = table.Column(type: "TEXT", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_champions", x => x.Name); + }); + + migrationBuilder.InsertData( + table: "champions", + columns: new[] { "Name", "Bio", "Icon" }, + values: new object[,] + { + { "Armure", "Solide", null }, + { "Dave", "Le meilleur Jazzman de France", null } + }); + } + + /// + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropTable( + name: "champions"); + } + } +} diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs b/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs new file mode 100644 index 0000000..3595433 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs @@ -0,0 +1,52 @@ +// +using Entities; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; + +#nullable disable + +namespace Entities.Migrations +{ + [DbContext(typeof(ChampionDbContext))] + partial class ChampionDbContextModelSnapshot : ModelSnapshot + { + protected override void BuildModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder.HasAnnotation("ProductVersion", "7.0.2"); + + modelBuilder.Entity("Entities.ChampionEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("Bio") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("Icon") + .HasColumnType("TEXT"); + + b.HasKey("Name"); + + b.ToTable("champions"); + + b.HasData( + new + { + Name = "Dave", + Bio = "Le meilleur Jazzman de France" + }, + new + { + Name = "Armure", + Bio = "Solide" + }); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/EntityFramework_LoL/Sources/Entities/Program.cs b/EntityFramework_LoL/Sources/Entities/Program.cs new file mode 100644 index 0000000..2acf068 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/Program.cs @@ -0,0 +1,14 @@ +using Entities; + +ChampionEntity dave = new() +{ + Name = "Imri Cartel", + Bio = "Fou Furieux", +}; +using (var context = new ChampionDbContext()) +{ + // Crée des nounours et les insère dans la base + Console.WriteLine("Creates and inserts new Champion"); + context.Add(dave); + context.SaveChanges(); +} diff --git a/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.csproj b/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.csproj index 06df015..95f8b96 100644 --- a/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.csproj +++ b/EntityFramework_LoL/Sources/EntityFramework/EntityFramework.csproj @@ -5,7 +5,7 @@ net6.0 enable enable - $(MSBuildProjectDirectory) + $(MSBuildProjectDirectory) diff --git a/EntityFramework_LoL/Sources/LeagueOfLegends.sln b/EntityFramework_LoL/Sources/LeagueOfLegends.sln index da2dfc5..5e32aeb 100644 --- a/EntityFramework_LoL/Sources/LeagueOfLegends.sln +++ b/EntityFramework_LoL/Sources/LeagueOfLegends.sln @@ -19,7 +19,9 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "API_LoL_Project", "API_LoL_ EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DTO", "DTO\DTO.csproj", "{7F6A519E-98F8-429E-B34F-9B0D20075CFB}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EntityFramework", "EntityFramework\EntityFramework.csproj", "{59CC9D86-8D5A-4D38-B0F3-99B4073C7885}" +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Entity Framework", "Entity Framework", "{BC2FFCA4-3801-433F-A83E-B55345F3B31E}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Entities", "Entities\Entities.csproj", "{C463E2E1-237A-4339-A4C4-6EA3BE7002AE}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -51,10 +53,10 @@ Global {7F6A519E-98F8-429E-B34F-9B0D20075CFB}.Debug|Any CPU.Build.0 = Debug|Any CPU {7F6A519E-98F8-429E-B34F-9B0D20075CFB}.Release|Any CPU.ActiveCfg = Release|Any CPU {7F6A519E-98F8-429E-B34F-9B0D20075CFB}.Release|Any CPU.Build.0 = Release|Any CPU - {59CC9D86-8D5A-4D38-B0F3-99B4073C7885}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {59CC9D86-8D5A-4D38-B0F3-99B4073C7885}.Debug|Any CPU.Build.0 = Debug|Any CPU - {59CC9D86-8D5A-4D38-B0F3-99B4073C7885}.Release|Any CPU.ActiveCfg = Release|Any CPU - {59CC9D86-8D5A-4D38-B0F3-99B4073C7885}.Release|Any CPU.Build.0 = Release|Any CPU + {C463E2E1-237A-4339-A4C4-6EA3BE7002AE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {C463E2E1-237A-4339-A4C4-6EA3BE7002AE}.Debug|Any CPU.Build.0 = Debug|Any CPU + {C463E2E1-237A-4339-A4C4-6EA3BE7002AE}.Release|Any CPU.ActiveCfg = Release|Any CPU + {C463E2E1-237A-4339-A4C4-6EA3BE7002AE}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -62,6 +64,7 @@ Global GlobalSection(NestedProjects) = preSolution {1889FA6E-B7C6-416E-8628-9449FB9070B9} = {C76D0C23-1FFA-4963-93CD-E12BD643F030} {B01D7EF2-2D64-409A-A29A-61FB7BB7A9DB} = {2C607793-B163-4731-A4D1-AFE8A7C4C170} + {C463E2E1-237A-4339-A4C4-6EA3BE7002AE} = {BC2FFCA4-3801-433F-A83E-B55345F3B31E} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {92F3083D-793F-4552-8A9A-0AD6534159C9} diff --git a/EntityFramework_LoL/Sources/Stub/Program.cs b/EntityFramework_LoL/Sources/Stub/Program.cs new file mode 100644 index 0000000..9c2e3c3 --- /dev/null +++ b/EntityFramework_LoL/Sources/Stub/Program.cs @@ -0,0 +1,15 @@ +using Entities; + +ChampionEntity dave = new() +{ + Name = "Dave", + Bio = "Le meilleur Jazzman de France", + Icon = "aaa" +}; +using (var context = new ChampionDbContext()) +{ + // Crée des nounours et les insère dans la base + Console.WriteLine("Creates and inserts new Champion"); + context.Add(dave); + context.SaveChanges(); +} diff --git a/EntityFramework_LoL/Sources/Stub/Stub.csproj b/EntityFramework_LoL/Sources/Stub/Stub.csproj new file mode 100644 index 0000000..36bc2be --- /dev/null +++ b/EntityFramework_LoL/Sources/Stub/Stub.csproj @@ -0,0 +1,15 @@ + + + + Exe + net6.0 + enable + enable + $(MSBuildProjectDirectory) + + + + + + + From ee739ed478d30c23452c6c73e1f0fd4e78591001 Mon Sep 17 00:00:00 2001 From: "arthur.valin" Date: Sat, 4 Feb 2023 11:59:39 +0100 Subject: [PATCH 4/6] Adding One Champion To Many Skins --- .../Sources/Entities/ChampionDbContext.cs | 32 ++++- .../Sources/Entities/ChampionEntity.cs | 7 +- .../Entities/Entities.Champions.db-wal | Bin 82432 -> 193672 bytes .../Sources/Entities/Entities.csproj | 4 + ...0230204100209_myFirstMigration.Designer.cs | 55 -------- .../20230204100209_myFirstMigration.cs | 45 ------- ...0230204105739_myFirstMigration.Designer.cs | 118 ++++++++++++++++++ .../20230204105739_myFirstMigration.cs | 84 +++++++++++++ .../ChampionDbContextModelSnapshot.cs | 67 +++++++++- .../Sources/Entities/Program.cs | 6 +- .../Sources/Entities/SkinEntity.cs | 32 +++++ EntityFramework_LoL/Sources/Model/Champion.cs | 3 +- .../Sources/Model/Model.csproj | 3 - EntityFramework_LoL/Sources/Model/Rune.cs | 2 +- EntityFramework_LoL/Sources/Model/RunePage.cs | 2 +- EntityFramework_LoL/Sources/Model/Skill.cs | 2 +- .../{Model => Shared}/enums/ChampionClass.cs | 3 +- .../{Model => Shared}/enums/RuneFamily.cs | 3 +- .../enums}/RunePage.Category.cs | 6 +- .../{Model => Shared}/enums/SkillType.cs | 3 +- .../Sources/StubLib/StubData.Champions.cs | 1 + .../Sources/StubLib/StubData.Runes.cs | 1 + .../Sources/Tests/ConsoleTests/Program.cs | 1 + 23 files changed, 353 insertions(+), 127 deletions(-) delete mode 100644 EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.Designer.cs delete mode 100644 EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.cs create mode 100644 EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.Designer.cs create mode 100644 EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.cs create mode 100644 EntityFramework_LoL/Sources/Entities/SkinEntity.cs rename EntityFramework_LoL/Sources/{Model => Shared}/enums/ChampionClass.cs (77%) rename EntityFramework_LoL/Sources/{Model => Shared}/enums/RuneFamily.cs (68%) rename EntityFramework_LoL/Sources/{Model => Shared/enums}/RunePage.Category.cs (60%) rename EntityFramework_LoL/Sources/{Model => Shared}/enums/SkillType.cs (69%) diff --git a/EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs b/EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs index d7f3cd0..3a5665b 100644 --- a/EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs +++ b/EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs @@ -1,9 +1,13 @@ using Microsoft.EntityFrameworkCore; +using Shared; +using System.Security.Claims; +using System.Xml.Linq; namespace Entities { public class ChampionDbContext : DbContext { + public DbSet skins { get; set; } public DbSet champions { get; set; } protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder) { @@ -13,17 +17,39 @@ namespace Entities protected override void OnModelCreating(ModelBuilder modelBuilder) { modelBuilder.Entity().HasData(new List() { - new ChampionEntity + new() { Name = "Dave", Bio = "Le meilleur Jazzman de France", + Class = ChampionClass.Fighter }, - new ChampionEntity + new() { - Name = "Armure", + Name = "Armure", Bio = "Solide", + Class = ChampionClass.Tank } }); + + + modelBuilder.Entity().HasData(new List() { + new SkinEntity + { + Name = "Dave de glace", + Description = "Enneigé", + Icon = "aaa", + ChampionForeignKey = "Dave", + Price=7.99F + }, + new SkinEntity + { + Name = "Armure Fullspeed", + Description = "Deja vu", + Icon = "aaa", + ChampionForeignKey = "Armure", + Price=9.99F + }, + }); } } } diff --git a/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs b/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs index 27499d9..8ed2a5c 100644 --- a/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs +++ b/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs @@ -1,15 +1,18 @@ -using System.ComponentModel.DataAnnotations; +using Shared; +using System.ComponentModel.DataAnnotations; namespace Entities { public class ChampionEntity { [Key] [MaxLength(256)] - public string? Name { get; set; } + public string Name { get; set; } [Required] [MaxLength(500)] public string Bio { get; set; } public string? Icon { get; set; } + [Required] + public ChampionClass Class { get; set;} } } diff --git a/EntityFramework_LoL/Sources/Entities/Entities.Champions.db-wal b/EntityFramework_LoL/Sources/Entities/Entities.Champions.db-wal index c1c99f15ddc9f861e237105f73dc9cf342acd402..c9dd03312ea6cff13b2470c6ae0af47294a4cf80 100644 GIT binary patch delta 2582 zcmb_ee@q)y9KUO64_e9t3zWjhj)PgyQA&Xj$2KVCicnT)sRBxZC!Ekx3Ta^(0s-b0 zS=@rl{jp`534$>WCsfQ(_Rk#7U}iRE$V}!IgTz0UKyV?j#cA-pqpkcLBKs!qUUKjI zzCSCX3u^*_xz%&>I zXF!eHTnZ9YenO){tI?)tw3^gpjW#(sy`rw!U~{?}580}nOrx#dk*?OLwVd){d&GhL z@~|T3L0ZC_YQw+-a2@o5Hn+JB#Kj7Y_!gG@&gyWyKJ?WSa=Eo{{(TgY0E}T^28_AQ zBY;o|L}9rY&Xs4yWC)(aMM@=x>zs8>PPVw-ZmVL&a0A~NZ{O~n`n^@Hy6T4l5`b9@ zEP~mm)_q#)N(w#t)fK+(0bX-xHyib=uS z%WD@snAkx+lXu4I1>b!h4TC|lHI4?PKc6(Kq*;7Es0u4_B;j!+c{VtTR8uAD{by=N zP?jQ)>BAAobej`_MI~B|q|~%ckhCqxMgB7SZCgH_@gbiZDDy!Ml)25h;N>--+sLVC zjm}08_W*OWZ)t4m^%?ojfr(GWHXg3CR{m#TKABmVJO5YoTYMv>o<^c(B4A2+U`n?Q z%-N-^+J&S$w|5TAjKv=_zy70j2nK^>Yhb?H`Nlin&vi}m`2@l(h~&Hygz||B^a7KR z4)_Qz@OjxM(gC+QS=!!A5DL8l@7!Z^RIx|%N-JEoHixT1U&GWjKw2`?J6T(`!^k%C z|NZqAT4$vp{pHZ5B=r<^iYzpd6u*fg{jm(>NmRIIKVvifE zF1vu{t#GEnBq3bmuBsK%9M)Cov^5~w8<6HU#{m0kHrX&n@oF9I4q55)do7JG_8hwTzgfxm%(*;O^Fw3zZ(nZ4N^vM@ zbV$ATtEH%@$X8 zvUV?A>n@L9MC)o?oERl1l*>0cX=t+BT@5T-mBSup$RkZiJND11+%G~~mNlS%^aS$- zk^igZeCq5Zw;c6dbiLwt;oIsaI2a;S;j2Or$c2dkYaKybh<*IMSzUXSP4souU-@(* H1P}fPYO2r? delta 10 RcmeBp$=%Sx+OUMt2>=+x1ML6+ diff --git a/EntityFramework_LoL/Sources/Entities/Entities.csproj b/EntityFramework_LoL/Sources/Entities/Entities.csproj index 3707fee..ef6f098 100644 --- a/EntityFramework_LoL/Sources/Entities/Entities.csproj +++ b/EntityFramework_LoL/Sources/Entities/Entities.csproj @@ -21,4 +21,8 @@ + + + + diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.Designer.cs b/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.Designer.cs deleted file mode 100644 index b71d075..0000000 --- a/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.Designer.cs +++ /dev/null @@ -1,55 +0,0 @@ -// -using Entities; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; - -#nullable disable - -namespace Entities.Migrations -{ - [DbContext(typeof(ChampionDbContext))] - [Migration("20230204100209_myFirstMigration")] - partial class myFirstMigration - { - /// - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder.HasAnnotation("ProductVersion", "7.0.2"); - - modelBuilder.Entity("Entities.ChampionEntity", b => - { - b.Property("Name") - .HasMaxLength(256) - .HasColumnType("TEXT"); - - b.Property("Bio") - .IsRequired() - .HasMaxLength(500) - .HasColumnType("TEXT"); - - b.Property("Icon") - .HasColumnType("TEXT"); - - b.HasKey("Name"); - - b.ToTable("champions"); - - b.HasData( - new - { - Name = "Dave", - Bio = "Le meilleur Jazzman de France" - }, - new - { - Name = "Armure", - Bio = "Solide" - }); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.cs b/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.cs deleted file mode 100644 index 30af7dd..0000000 --- a/EntityFramework_LoL/Sources/Entities/Migrations/20230204100209_myFirstMigration.cs +++ /dev/null @@ -1,45 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -#pragma warning disable CA1814 // Prefer jagged arrays over multidimensional - -namespace Entities.Migrations -{ - /// - public partial class myFirstMigration : Migration - { - /// - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.CreateTable( - name: "champions", - columns: table => new - { - Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), - Bio = table.Column(type: "TEXT", maxLength: 500, nullable: false), - Icon = table.Column(type: "TEXT", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_champions", x => x.Name); - }); - - migrationBuilder.InsertData( - table: "champions", - columns: new[] { "Name", "Bio", "Icon" }, - values: new object[,] - { - { "Armure", "Solide", null }, - { "Dave", "Le meilleur Jazzman de France", null } - }); - } - - /// - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropTable( - name: "champions"); - } - } -} diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.Designer.cs b/EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.Designer.cs new file mode 100644 index 0000000..78252d6 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.Designer.cs @@ -0,0 +1,118 @@ +// +using Entities; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; + +#nullable disable + +namespace Entities.Migrations +{ + [DbContext(typeof(ChampionDbContext))] + [Migration("20230204105739_myFirstMigration")] + partial class myFirstMigration + { + /// + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder.HasAnnotation("ProductVersion", "7.0.2"); + + modelBuilder.Entity("Entities.ChampionEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("Bio") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("Class") + .HasColumnType("INTEGER"); + + b.Property("Icon") + .HasColumnType("TEXT"); + + b.HasKey("Name"); + + b.ToTable("champions"); + + b.HasData( + new + { + Name = "Dave", + Bio = "Le meilleur Jazzman de France", + Class = 2 + }, + new + { + Name = "Armure", + Bio = "Solide", + Class = 6 + }); + }); + + modelBuilder.Entity("Entities.SkinEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("ChampionForeignKey") + .IsRequired() + .HasColumnType("TEXT"); + + b.Property("Description") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("Icon") + .IsRequired() + .HasColumnType("TEXT"); + + b.Property("Price") + .HasColumnType("REAL"); + + b.HasKey("Name"); + + b.HasIndex("ChampionForeignKey"); + + b.ToTable("skins"); + + b.HasData( + new + { + Name = "Dave de glace", + ChampionForeignKey = "Dave", + Description = "Enneigé", + Icon = "aaa", + Price = 7.99f + }, + new + { + Name = "Armure Fullspeed", + ChampionForeignKey = "Armure", + Description = "Deja vu", + Icon = "aaa", + Price = 9.99f + }); + }); + + modelBuilder.Entity("Entities.SkinEntity", b => + { + b.HasOne("Entities.ChampionEntity", "Champion") + .WithMany() + .HasForeignKey("ChampionForeignKey") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Champion"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.cs b/EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.cs new file mode 100644 index 0000000..a628a29 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.cs @@ -0,0 +1,84 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +#pragma warning disable CA1814 // Prefer jagged arrays over multidimensional + +namespace Entities.Migrations +{ + /// + public partial class myFirstMigration : Migration + { + /// + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.CreateTable( + name: "champions", + columns: table => new + { + Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), + Bio = table.Column(type: "TEXT", maxLength: 500, nullable: false), + Icon = table.Column(type: "TEXT", nullable: true), + Class = table.Column(type: "INTEGER", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_champions", x => x.Name); + }); + + migrationBuilder.CreateTable( + name: "skins", + columns: table => new + { + Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), + Description = table.Column(type: "TEXT", maxLength: 500, nullable: false), + Icon = table.Column(type: "TEXT", nullable: false), + Price = table.Column(type: "REAL", nullable: false), + ChampionForeignKey = table.Column(type: "TEXT", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_skins", x => x.Name); + table.ForeignKey( + name: "FK_skins_champions_ChampionForeignKey", + column: x => x.ChampionForeignKey, + principalTable: "champions", + principalColumn: "Name", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.InsertData( + table: "champions", + columns: new[] { "Name", "Bio", "Class", "Icon" }, + values: new object[,] + { + { "Armure", "Solide", 6, null }, + { "Dave", "Le meilleur Jazzman de France", 2, null } + }); + + migrationBuilder.InsertData( + table: "skins", + columns: new[] { "Name", "ChampionForeignKey", "Description", "Icon", "Price" }, + values: new object[,] + { + { "Armure Fullspeed", "Armure", "Deja vu", "aaa", 9.99f }, + { "Dave de glace", "Dave", "Enneigé", "aaa", 7.99f } + }); + + migrationBuilder.CreateIndex( + name: "IX_skins_ChampionForeignKey", + table: "skins", + column: "ChampionForeignKey"); + } + + /// + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropTable( + name: "skins"); + + migrationBuilder.DropTable( + name: "champions"); + } + } +} diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs b/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs index 3595433..f17b1cf 100644 --- a/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs +++ b/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs @@ -27,6 +27,9 @@ namespace Entities.Migrations .HasMaxLength(500) .HasColumnType("TEXT"); + b.Property("Class") + .HasColumnType("INTEGER"); + b.Property("Icon") .HasColumnType("TEXT"); @@ -38,14 +41,74 @@ namespace Entities.Migrations new { Name = "Dave", - Bio = "Le meilleur Jazzman de France" + Bio = "Le meilleur Jazzman de France", + Class = 2 }, new { Name = "Armure", - Bio = "Solide" + Bio = "Solide", + Class = 6 }); }); + + modelBuilder.Entity("Entities.SkinEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("ChampionForeignKey") + .IsRequired() + .HasColumnType("TEXT"); + + b.Property("Description") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("Icon") + .IsRequired() + .HasColumnType("TEXT"); + + b.Property("Price") + .HasColumnType("REAL"); + + b.HasKey("Name"); + + b.HasIndex("ChampionForeignKey"); + + b.ToTable("skins"); + + b.HasData( + new + { + Name = "Dave de glace", + ChampionForeignKey = "Dave", + Description = "Enneigé", + Icon = "aaa", + Price = 7.99f + }, + new + { + Name = "Armure Fullspeed", + ChampionForeignKey = "Armure", + Description = "Deja vu", + Icon = "aaa", + Price = 9.99f + }); + }); + + modelBuilder.Entity("Entities.SkinEntity", b => + { + b.HasOne("Entities.ChampionEntity", "Champion") + .WithMany() + .HasForeignKey("ChampionForeignKey") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Champion"); + }); #pragma warning restore 612, 618 } } diff --git a/EntityFramework_LoL/Sources/Entities/Program.cs b/EntityFramework_LoL/Sources/Entities/Program.cs index 2acf068..6e4348a 100644 --- a/EntityFramework_LoL/Sources/Entities/Program.cs +++ b/EntityFramework_LoL/Sources/Entities/Program.cs @@ -1,14 +1,16 @@ using Entities; +using Shared; -ChampionEntity dave = new() +ChampionEntity imri = new() { Name = "Imri Cartel", Bio = "Fou Furieux", + Class = ChampionClass.Assassin }; using (var context = new ChampionDbContext()) { // Crée des nounours et les insère dans la base Console.WriteLine("Creates and inserts new Champion"); - context.Add(dave); + context.Add(imri); context.SaveChanges(); } diff --git a/EntityFramework_LoL/Sources/Entities/SkinEntity.cs b/EntityFramework_LoL/Sources/Entities/SkinEntity.cs new file mode 100644 index 0000000..0baace0 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/SkinEntity.cs @@ -0,0 +1,32 @@ +using Shared; +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Entities +{ + public class SkinEntity + { + [Key] + [MaxLength(256)] + public string Name { get; set; } + [Required] + [MaxLength(500)] + public string Description { get; set; } + [Required] + public string Icon { get; set; } + [Required] + public float Price { get; set; } + + [Required] + public string ChampionForeignKey { get; set; } + + [ForeignKey("ChampionForeignKey")] + public ChampionEntity Champion { get; set; } + + } +} diff --git a/EntityFramework_LoL/Sources/Model/Champion.cs b/EntityFramework_LoL/Sources/Model/Champion.cs index fd4a5ca..9b7e96d 100644 --- a/EntityFramework_LoL/Sources/Model/Champion.cs +++ b/EntityFramework_LoL/Sources/Model/Champion.cs @@ -1,4 +1,5 @@ -using System.Collections.Immutable; +using Shared; +using System.Collections.Immutable; using System.Collections.ObjectModel; using System.Numerics; using System.Text; diff --git a/EntityFramework_LoL/Sources/Model/Model.csproj b/EntityFramework_LoL/Sources/Model/Model.csproj index 89f6363..53e6be4 100644 --- a/EntityFramework_LoL/Sources/Model/Model.csproj +++ b/EntityFramework_LoL/Sources/Model/Model.csproj @@ -9,9 +9,6 @@ - - - diff --git a/EntityFramework_LoL/Sources/Model/Rune.cs b/EntityFramework_LoL/Sources/Model/Rune.cs index 7b5047b..368582a 100644 --- a/EntityFramework_LoL/Sources/Model/Rune.cs +++ b/EntityFramework_LoL/Sources/Model/Rune.cs @@ -1,4 +1,4 @@ -using System; +using Shared; namespace Model { diff --git a/EntityFramework_LoL/Sources/Model/RunePage.cs b/EntityFramework_LoL/Sources/Model/RunePage.cs index cf56628..0dbb7ab 100644 --- a/EntityFramework_LoL/Sources/Model/RunePage.cs +++ b/EntityFramework_LoL/Sources/Model/RunePage.cs @@ -1,4 +1,4 @@ -using System; +using Shared; using System.Collections.ObjectModel; namespace Model diff --git a/EntityFramework_LoL/Sources/Model/Skill.cs b/EntityFramework_LoL/Sources/Model/Skill.cs index 0679ea6..16f947e 100644 --- a/EntityFramework_LoL/Sources/Model/Skill.cs +++ b/EntityFramework_LoL/Sources/Model/Skill.cs @@ -1,4 +1,4 @@ -using System; +using Shared; namespace Model { diff --git a/EntityFramework_LoL/Sources/Model/enums/ChampionClass.cs b/EntityFramework_LoL/Sources/Shared/enums/ChampionClass.cs similarity index 77% rename from EntityFramework_LoL/Sources/Model/enums/ChampionClass.cs rename to EntityFramework_LoL/Sources/Shared/enums/ChampionClass.cs index d169512..701b297 100644 --- a/EntityFramework_LoL/Sources/Model/enums/ChampionClass.cs +++ b/EntityFramework_LoL/Sources/Shared/enums/ChampionClass.cs @@ -1,5 +1,4 @@ -using System; -namespace Model +namespace Shared { public enum ChampionClass { diff --git a/EntityFramework_LoL/Sources/Model/enums/RuneFamily.cs b/EntityFramework_LoL/Sources/Shared/enums/RuneFamily.cs similarity index 68% rename from EntityFramework_LoL/Sources/Model/enums/RuneFamily.cs rename to EntityFramework_LoL/Sources/Shared/enums/RuneFamily.cs index 07a232c..b025487 100644 --- a/EntityFramework_LoL/Sources/Model/enums/RuneFamily.cs +++ b/EntityFramework_LoL/Sources/Shared/enums/RuneFamily.cs @@ -1,5 +1,4 @@ -using System; -namespace Model +namespace Shared { public enum RuneFamily { diff --git a/EntityFramework_LoL/Sources/Model/RunePage.Category.cs b/EntityFramework_LoL/Sources/Shared/enums/RunePage.Category.cs similarity index 60% rename from EntityFramework_LoL/Sources/Model/RunePage.Category.cs rename to EntityFramework_LoL/Sources/Shared/enums/RunePage.Category.cs index 1047c0e..2ee019d 100644 --- a/EntityFramework_LoL/Sources/Model/RunePage.Category.cs +++ b/EntityFramework_LoL/Sources/Shared/enums/RunePage.Category.cs @@ -1,8 +1,5 @@ -using System; -namespace Model +namespace Shared { - public partial class RunePage - { public enum Category { Major, @@ -12,6 +9,5 @@ namespace Model OtherMinor1, OtherMinor2 } - } } diff --git a/EntityFramework_LoL/Sources/Model/enums/SkillType.cs b/EntityFramework_LoL/Sources/Shared/enums/SkillType.cs similarity index 69% rename from EntityFramework_LoL/Sources/Model/enums/SkillType.cs rename to EntityFramework_LoL/Sources/Shared/enums/SkillType.cs index d7fc8da..3e48028 100644 --- a/EntityFramework_LoL/Sources/Model/enums/SkillType.cs +++ b/EntityFramework_LoL/Sources/Shared/enums/SkillType.cs @@ -1,5 +1,4 @@ -using System; -namespace Model +namespace Shared { public enum SkillType { diff --git a/EntityFramework_LoL/Sources/StubLib/StubData.Champions.cs b/EntityFramework_LoL/Sources/StubLib/StubData.Champions.cs index ad19275..8ed1220 100644 --- a/EntityFramework_LoL/Sources/StubLib/StubData.Champions.cs +++ b/EntityFramework_LoL/Sources/StubLib/StubData.Champions.cs @@ -1,5 +1,6 @@ using System; using Model; +using Shared; namespace StubLib { diff --git a/EntityFramework_LoL/Sources/StubLib/StubData.Runes.cs b/EntityFramework_LoL/Sources/StubLib/StubData.Runes.cs index f0e8802..32fce54 100644 --- a/EntityFramework_LoL/Sources/StubLib/StubData.Runes.cs +++ b/EntityFramework_LoL/Sources/StubLib/StubData.Runes.cs @@ -1,5 +1,6 @@ using System; using Model; +using Shared; namespace StubLib { diff --git a/EntityFramework_LoL/Sources/Tests/ConsoleTests/Program.cs b/EntityFramework_LoL/Sources/Tests/ConsoleTests/Program.cs index 93e266f..d642ce2 100644 --- a/EntityFramework_LoL/Sources/Tests/ConsoleTests/Program.cs +++ b/EntityFramework_LoL/Sources/Tests/ConsoleTests/Program.cs @@ -2,6 +2,7 @@ using System.Diagnostics; using Microsoft.Extensions.DependencyInjection; using Model; +using Shared; using StubLib; using static System.Console; From 50cbd3b162a17efe38d1e422bf9d8d50cecb5848 Mon Sep 17 00:00:00 2001 From: "arthur.valin" Date: Wed, 8 Feb 2023 17:30:59 +0100 Subject: [PATCH 5/6] Adding Skill MtoM, runes and runepages --- .vs/League-of-Legends_Project3/v17/.wsuo | Bin 14336 -> 18432 bytes .../Sources/Entities/ChampionDbContext.cs | 56 +++- .../Sources/Entities/ChampionEntity.cs | 4 + .../Sources/Entities/Entities.Champions.db | Bin 20480 -> 32768 bytes .../Entities/Entities.Champions.db-shm | Bin 32768 -> 32768 bytes .../Entities/Entities.Champions.db-wal | Bin 193672 -> 1182472 bytes ...0230204105739_myFirstMigration.Designer.cs | 118 -------- .../20230204105739_myFirstMigration.cs | 84 ------ ...0230208162909_myFirstMigration.Designer.cs | 268 ++++++++++++++++++ .../20230208162909_myFirstMigration.cs | 219 ++++++++++++++ .../ChampionDbContextModelSnapshot.cs | 150 ++++++++++ .../Sources/Entities/RuneEntity.cs | 27 ++ .../Sources/Entities/RunePageEntity.cs | 24 ++ .../Sources/Entities/SkillEntity.cs | 29 ++ 14 files changed, 773 insertions(+), 206 deletions(-) delete mode 100644 EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.Designer.cs delete mode 100644 EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.cs create mode 100644 EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.Designer.cs create mode 100644 EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.cs create mode 100644 EntityFramework_LoL/Sources/Entities/RuneEntity.cs create mode 100644 EntityFramework_LoL/Sources/Entities/RunePageEntity.cs create mode 100644 EntityFramework_LoL/Sources/Entities/SkillEntity.cs diff --git a/.vs/League-of-Legends_Project3/v17/.wsuo b/.vs/League-of-Legends_Project3/v17/.wsuo index 5e22404fe5fe2e1d66d4552f005e77589fd4dd91..e917b20bd7ac0407438812f450c49c21b2d86802 100644 GIT binary patch delta 1638 zcmb_c%}*0S6yMo?u+(k4v|5&rLQ5*C$iglyv_;g4=z%sV4IDg}D6}P-kZ4Fr2*#v0 zIdFh|{sqR1H=!5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zgcyO3BI=BvrTM>XrHBu$vn|$h#Bo);-P>@%i*ICEa1qx?c%6Vd@v6uP+>aM~Yen$X zhRlVsfOiRcraJgtSd`epE)LbE%>4*!4L zX=SsvwOOtjx>0_v@zQ*;tZy#9)T`QZBm(pR9zSeh!?Lg skins { get; set; } public DbSet champions { get; set; } + public DbSet skills { get; set; } + public DbSet runes { get; set; } + public DbSet runepages { get; set; } + + protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder) { optionsBuilder.UseSqlite($"Data Source=Entities.Champions.db"); @@ -16,22 +21,25 @@ namespace Entities protected override void OnModelCreating(ModelBuilder modelBuilder) { + modelBuilder.Entity().Property(e => e.Id).ValueGeneratedOnAdd(); + + modelBuilder.Entity().HasData(new List() { new() { Name = "Dave", Bio = "Le meilleur Jazzman de France", - Class = ChampionClass.Fighter + Class = ChampionClass.Fighter, + }, new() { - Name = "Armure", + Name = "Armure", Bio = "Solide", - Class = ChampionClass.Tank + Class = ChampionClass.Tank, } }); - modelBuilder.Entity().HasData(new List() { new SkinEntity { @@ -50,6 +58,46 @@ namespace Entities Price=9.99F }, }); + + modelBuilder.Entity().HasData(new List() { + new() + { + Name = "Boule de feu", + Description = "Fire!", + SkillType = SkillType.Basic + }, + new() + { + Name = "White Star", + Description = "Random damage", + SkillType = SkillType.Ultimate + } + }); + + modelBuilder.Entity().HasData(new List() + { + new() + { + Id = Guid.NewGuid(), + Name="Runepage_1" + } + }); + + modelBuilder.Entity().HasData(new List() { + new() + { + Name = "Bullseye", + Description = "Steady shot", + RuneFamily = RuneFamily.Precision + }, + new() + { + Name = "Alkatraz", + Description = "Lock effect", + RuneFamily = RuneFamily.Domination + } + }); + } } } diff --git a/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs b/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs index 8ed2a5c..eea4371 100644 --- a/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs +++ b/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs @@ -1,5 +1,7 @@ using Shared; using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; + namespace Entities { public class ChampionEntity @@ -13,6 +15,8 @@ namespace Entities public string? Icon { get; set; } [Required] public ChampionClass Class { get; set;} + + public virtual ICollection? Skills { get; set; } } } diff --git a/EntityFramework_LoL/Sources/Entities/Entities.Champions.db b/EntityFramework_LoL/Sources/Entities/Entities.Champions.db index 2643996e4069079cab2a9c289dd5eca80da0fc2f..301c8f4c5ac6b9533bdc98b5b32410e1b9e0753b 100644 GIT binary patch literal 32768 zcmeI)&2QUe90zc}G)`NZK0xWLGNC?lHM$~J#Yv-R2gI_(DWO?X(g3XlvP|;O8S+x> zWTFEOt;8Ae7a*i@KnVT-j!fJqj+1skoRHXY6XL{UCvlU`h8;FBiSHvNeQf{yynLQV zk^DSXcit%5Jx1T}I&G^*)56n&Bng)&6$D|9f2R3ol;(M6YIMN=ievex?3}P}KA#|e z3h}4D6Xt&*-zRR(e>L}F;v0U51OW&@00Izz00bZa0SH739LD2nUKNkd*_|f)xU_4! zAKD$)%wM(I2X?np>^jWe?`*L{|NL~mX5{JyEmaD}F4g`aT%*+r)%=?@dR}|5JZEL7=hk@fQEe>01Hip_^?iwvtYes3a;&mfJk~gVn)Qn2r*r8fbnCI?et$AZnFvmLuNf$on-{HQF))#YXJc;6qXpoSnb zH92CzdESJFAGNW&LPqYg-F=7=uV-Cox@3_U4L%7n(8CGDtVP3AVB~E z5P$##AOHafKmY;|fB*#k7Xqt_yrrg+sdO@x+|ZMmZ2F?vJ}laf+Y6riv+K$A)M{)Z zFtw4%Mg&ex2I_iLpga-C8xU2sG!~e=m`P^z@T$*>a(dJmUC(T!^`zP6DVPsC6S^=EI~5bQ zCNMP_6S^EAkH_MlD#aEz1+idVV`WC$%x<+<-=VKt*RQv&4s9}8bgWK;NzaP0r6obkIqkl~cDgOQ z$rNw@Um|w}a-ZBKcb?QPqFoSx00bZa0SG_<0uX=z1Rwwb2t*1Hc||O>9h>GYr^j0I zw7lpq6G$`i(#&8PV6gvxLm;=vjmUCv0Rj+!00bZa0SG_<0uX=z1Rwx`$1d=aq^!QM z5MT6m_`U7?{g%~WMyJF7-RI43Ez7#JeD9|(-Z_8YyS^?e7tSukmj+MwwAgR8+ylm% z1@?hOul2p?mA`)7{NcGz1`&h(|J&aC|F<7|M^FI-AOHafKmY;|fB*y_009U<00NI# z;2C+<-|P=o45S75!f@CBWL;qV{r^YY02BuS2tWV=5P$##AOHafKmY;|fWUtt5c2;2 E-$sHo>i_@% delta 138 zcmZo@U}{*vI6+#FiGhKE6^LPgX`+s?C=-KTyc9404+a+A*9?4@_}B8j=9|A+QJ|cc ztI?2|U0hzCvB_}qE#3v2r}E`9vN7^MX5fFkS+L+H|K!K=ia`EL2L6{o{vCd1pt+M@ U>Ps^*2!Qz$C&;mJf$V~F0i1awi2wiq diff --git a/EntityFramework_LoL/Sources/Entities/Entities.Champions.db-shm b/EntityFramework_LoL/Sources/Entities/Entities.Champions.db-shm index 18b64da578481efb11a35cf814fcb859e07a06f0..9cd8351f1caa059d87461e18d8ce17a5864f487c 100644 GIT binary patch literal 32768 zcmeI5cW@O|6oFxJB(0wMQr@zh0gz86xr_vW)?>L zy1?dzb$tJIKYlNMoo$_!=_oc$C1#~&@z}clu%^1cx?1A*%PhX!tir6JStB#AAL9I; z`{TJG&Yu_Rg#6&kl$WiB##X0EtX_D2@VU0|T-O|rbw(cR>+^Z0oFv+unQQePaBgvJ z&dy`QUIu+W&yYKmYKmYKmYKmYKmY zKmYKmjnuh$y=M|vUj$0+9FtmBV;#0&Kh9<*Z_`-aUtf4tC$9-acFIDX`=TcuXj`8vLjGn=cJX}*=p5xo>WWP z(4I9|i}l!$joFIbIDlg~mkHd#W4z0ERI2~81FYygCeVqlY{J&;L_coGNvD9`Bx{B_pst-Pn|E*p-7gk#XF}T|CSC{7JR?J{ekN=RJYWbf*VB>CeHO z#Q99(Zl31@JIJ%Cx=*2*Wa0(YNnR|GFMMP0E^?fp^%1#M^ZP}SY9Kxww z$TdvkUS4J~MNxCT0V&x*$;_QVZ~Cw|hjJ{ZGoEXi&MaQxLmEUa)c?6-Rc0y(Y{wo9 zo&%;QO(<3(QOO+MyJTC3|*v2zlcoWO%T#an#BSF};rC&#G@sUq+xU-Kis y@fQVAaa10))jN=?{gc=v1U}<;+NtA{AXIK@34G2^R7BywZfl5u2#7#t0)GRof361r delta 201 zcmZo@U}|V!s+V}A%K!qbK+MR%ARq!|Ct3G*WxNb;Fz~nPbrr}l_Sk-6#i5G(R-~#2 znGFIUbN?d&upk2i69d!4#_-K7tiNnG3$W_2O#bJ@v6+eW8xu1-1OH}5*56Fb91H?r c#^fK~JV2>WOq@(W*K#rNG6-${&%$U307im1A^-pY diff --git a/EntityFramework_LoL/Sources/Entities/Entities.Champions.db-wal b/EntityFramework_LoL/Sources/Entities/Entities.Champions.db-wal index c9dd03312ea6cff13b2470c6ae0af47294a4cf80..c02c794b78df6f8d8b92ee5a382d78297cb471e1 100644 GIT binary patch literal 1182472 zcmeF)3t$^Zoj>s1l`UDeS5g}1ND&)pyV?kxW-*{NZ*n6a4T-0E0g&`HaB6qkuw(G zG|e=He$GH*Mz&{)Se(d2XC#+R6yt?!lw6)S*b9Y>Sdz_9VphFKZj-afB6$Bsv0SG_<0uX=z1Rwwb2tZ)T2%P#jf^Sv# z^X^?D5Zj>NYLz;NmSbas~kiKmY;|fB*y_009U<00Izzz-bUr=N#1f z1=epGee+eLe{nz!JV@pvAWLQJfYWd}oB{$6fB*y_009U<00Izz00bZafwL`O8Fz41 zcK;KR7JiPngK9ql$v<7w*aUQ4*>^CXxP#S9N1UN?2f2pBYTUtwyAXGfIAVbS1Rwwb z2tWV=5P$##AaEuHXxu^a_}o&8J4o`|jktqnHtwKd96|B;@xq_BtoT005uC}lBF+r~ z2tWV=5P$##AOHafKmY;|STq8LaRfKqU;Jq2;lFSoY`>% zG)90vPhm2D`Rdnx=btX5;|Og09Sr{j{~%dmfdB*`009U<00Izz00bZa0SG|gl@MsN z*@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Wv2b9TZGNUvQ5FbU+ zt{1pY_&+zUdF{XLD_k#d*1^BcpIymlXd46|009U<00Izz00bZa0SG`~MGN>{4TiA- zC+})B4GxgDSJC!s;{u!o{N~M(K=!vIfS>9g%?hD8EZ#+j|-^96FuBh?U z74AYPMrqc-grbZ@l-p(T@FXq0;k~mvo>_aRexE`*1fY)#Y<&51{}w1akttj+aK^#^ zia)c&c~CtFKmY;|fB*y_009U<00Izz00c?|R=b)w(@27|#?|7TJzhXo^V3ze>jkbq zwkOzG|KTsP!GcvK8^r<$KmY;|fB*y_009U<00Izz00dT+08g8vjSF1$#2wFlX5(w$ zU}1z97g$+G8m)l<1Rwwb2tWV=5P$##AOHaflnSul{{0cB1vmn?GB~9em5dpX1*mFRvvZHHK$8_kiXS(B<@l z-s@2NpsUhl^pXR1uLJUo2LvDh0SG_<0uX=z1Rwwb2tWV=7h9mhRm-9XonBX+nm|aZ zM1SAc#|2*d+UsRsy5^m~!1V$b`(R=J5P$##AOHafKmY;|fB*y_0D%ugfc?#1yI$bO pWup&w?)%!$FfQ -using Entities; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; - -#nullable disable - -namespace Entities.Migrations -{ - [DbContext(typeof(ChampionDbContext))] - [Migration("20230204105739_myFirstMigration")] - partial class myFirstMigration - { - /// - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder.HasAnnotation("ProductVersion", "7.0.2"); - - modelBuilder.Entity("Entities.ChampionEntity", b => - { - b.Property("Name") - .HasMaxLength(256) - .HasColumnType("TEXT"); - - b.Property("Bio") - .IsRequired() - .HasMaxLength(500) - .HasColumnType("TEXT"); - - b.Property("Class") - .HasColumnType("INTEGER"); - - b.Property("Icon") - .HasColumnType("TEXT"); - - b.HasKey("Name"); - - b.ToTable("champions"); - - b.HasData( - new - { - Name = "Dave", - Bio = "Le meilleur Jazzman de France", - Class = 2 - }, - new - { - Name = "Armure", - Bio = "Solide", - Class = 6 - }); - }); - - modelBuilder.Entity("Entities.SkinEntity", b => - { - b.Property("Name") - .HasMaxLength(256) - .HasColumnType("TEXT"); - - b.Property("ChampionForeignKey") - .IsRequired() - .HasColumnType("TEXT"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(500) - .HasColumnType("TEXT"); - - b.Property("Icon") - .IsRequired() - .HasColumnType("TEXT"); - - b.Property("Price") - .HasColumnType("REAL"); - - b.HasKey("Name"); - - b.HasIndex("ChampionForeignKey"); - - b.ToTable("skins"); - - b.HasData( - new - { - Name = "Dave de glace", - ChampionForeignKey = "Dave", - Description = "Enneigé", - Icon = "aaa", - Price = 7.99f - }, - new - { - Name = "Armure Fullspeed", - ChampionForeignKey = "Armure", - Description = "Deja vu", - Icon = "aaa", - Price = 9.99f - }); - }); - - modelBuilder.Entity("Entities.SkinEntity", b => - { - b.HasOne("Entities.ChampionEntity", "Champion") - .WithMany() - .HasForeignKey("ChampionForeignKey") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.Navigation("Champion"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.cs b/EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.cs deleted file mode 100644 index a628a29..0000000 --- a/EntityFramework_LoL/Sources/Entities/Migrations/20230204105739_myFirstMigration.cs +++ /dev/null @@ -1,84 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -#pragma warning disable CA1814 // Prefer jagged arrays over multidimensional - -namespace Entities.Migrations -{ - /// - public partial class myFirstMigration : Migration - { - /// - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.CreateTable( - name: "champions", - columns: table => new - { - Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), - Bio = table.Column(type: "TEXT", maxLength: 500, nullable: false), - Icon = table.Column(type: "TEXT", nullable: true), - Class = table.Column(type: "INTEGER", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_champions", x => x.Name); - }); - - migrationBuilder.CreateTable( - name: "skins", - columns: table => new - { - Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), - Description = table.Column(type: "TEXT", maxLength: 500, nullable: false), - Icon = table.Column(type: "TEXT", nullable: false), - Price = table.Column(type: "REAL", nullable: false), - ChampionForeignKey = table.Column(type: "TEXT", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_skins", x => x.Name); - table.ForeignKey( - name: "FK_skins_champions_ChampionForeignKey", - column: x => x.ChampionForeignKey, - principalTable: "champions", - principalColumn: "Name", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.InsertData( - table: "champions", - columns: new[] { "Name", "Bio", "Class", "Icon" }, - values: new object[,] - { - { "Armure", "Solide", 6, null }, - { "Dave", "Le meilleur Jazzman de France", 2, null } - }); - - migrationBuilder.InsertData( - table: "skins", - columns: new[] { "Name", "ChampionForeignKey", "Description", "Icon", "Price" }, - values: new object[,] - { - { "Armure Fullspeed", "Armure", "Deja vu", "aaa", 9.99f }, - { "Dave de glace", "Dave", "Enneigé", "aaa", 7.99f } - }); - - migrationBuilder.CreateIndex( - name: "IX_skins_ChampionForeignKey", - table: "skins", - column: "ChampionForeignKey"); - } - - /// - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropTable( - name: "skins"); - - migrationBuilder.DropTable( - name: "champions"); - } - } -} diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.Designer.cs b/EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.Designer.cs new file mode 100644 index 0000000..130ec85 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.Designer.cs @@ -0,0 +1,268 @@ +// +using System; +using Entities; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; + +#nullable disable + +namespace Entities.Migrations +{ + [DbContext(typeof(ChampionDbContext))] + [Migration("20230208162909_myFirstMigration")] + partial class myFirstMigration + { + /// + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder.HasAnnotation("ProductVersion", "7.0.2"); + + modelBuilder.Entity("ChampionEntitySkillEntity", b => + { + b.Property("ChampionsName") + .HasColumnType("TEXT"); + + b.Property("SkillsName") + .HasColumnType("TEXT"); + + b.HasKey("ChampionsName", "SkillsName"); + + b.HasIndex("SkillsName"); + + b.ToTable("ChampionEntitySkillEntity"); + }); + + modelBuilder.Entity("Entities.ChampionEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("Bio") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("Class") + .HasColumnType("INTEGER"); + + b.Property("Icon") + .HasColumnType("TEXT"); + + b.HasKey("Name"); + + b.ToTable("champions"); + + b.HasData( + new + { + Name = "Dave", + Bio = "Le meilleur Jazzman de France", + Class = 2 + }, + new + { + Name = "Armure", + Bio = "Solide", + Class = 6 + }); + }); + + modelBuilder.Entity("Entities.RuneEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("Description") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("RuneFamily") + .HasColumnType("INTEGER"); + + b.HasKey("Name"); + + b.ToTable("runes"); + + b.HasData( + new + { + Name = "Bullseye", + Description = "Steady shot", + RuneFamily = 1 + }, + new + { + Name = "Alkatraz", + Description = "Lock effect", + RuneFamily = 2 + }); + }); + + modelBuilder.Entity("Entities.RunePageEntity", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("TEXT"); + + b.Property("Name") + .IsRequired() + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.HasKey("Id"); + + b.ToTable("runepages"); + + b.HasData( + new + { + Id = new Guid("78729bae-c931-4a75-9662-6754ed8e2ce3"), + Name = "Runepage_1" + }); + }); + + modelBuilder.Entity("Entities.SkillEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("Description") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("SkillType") + .HasColumnType("INTEGER"); + + b.HasKey("Name"); + + b.ToTable("skills"); + + b.HasData( + new + { + Name = "Boule de feu", + Description = "Fire!", + SkillType = 1 + }, + new + { + Name = "White Star", + Description = "Random damage", + SkillType = 3 + }); + }); + + modelBuilder.Entity("Entities.SkinEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("ChampionForeignKey") + .IsRequired() + .HasColumnType("TEXT"); + + b.Property("Description") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("Icon") + .IsRequired() + .HasColumnType("TEXT"); + + b.Property("Price") + .HasColumnType("REAL"); + + b.HasKey("Name"); + + b.HasIndex("ChampionForeignKey"); + + b.ToTable("skins"); + + b.HasData( + new + { + Name = "Dave de glace", + ChampionForeignKey = "Dave", + Description = "Enneigé", + Icon = "aaa", + Price = 7.99f + }, + new + { + Name = "Armure Fullspeed", + ChampionForeignKey = "Armure", + Description = "Deja vu", + Icon = "aaa", + Price = 9.99f + }); + }); + + modelBuilder.Entity("RuneEntityRunePageEntity", b => + { + b.Property("runepagesId") + .HasColumnType("TEXT"); + + b.Property("runesName") + .HasColumnType("TEXT"); + + b.HasKey("runepagesId", "runesName"); + + b.HasIndex("runesName"); + + b.ToTable("RuneEntityRunePageEntity"); + }); + + modelBuilder.Entity("ChampionEntitySkillEntity", b => + { + b.HasOne("Entities.ChampionEntity", null) + .WithMany() + .HasForeignKey("ChampionsName") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Entities.SkillEntity", null) + .WithMany() + .HasForeignKey("SkillsName") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + + modelBuilder.Entity("Entities.SkinEntity", b => + { + b.HasOne("Entities.ChampionEntity", "Champion") + .WithMany() + .HasForeignKey("ChampionForeignKey") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Champion"); + }); + + modelBuilder.Entity("RuneEntityRunePageEntity", b => + { + b.HasOne("Entities.RunePageEntity", null) + .WithMany() + .HasForeignKey("runepagesId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Entities.RuneEntity", null) + .WithMany() + .HasForeignKey("runesName") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.cs b/EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.cs new file mode 100644 index 0000000..62248a1 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.cs @@ -0,0 +1,219 @@ +using System; +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +#pragma warning disable CA1814 // Prefer jagged arrays over multidimensional + +namespace Entities.Migrations +{ + /// + public partial class myFirstMigration : Migration + { + /// + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.CreateTable( + name: "champions", + columns: table => new + { + Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), + Bio = table.Column(type: "TEXT", maxLength: 500, nullable: false), + Icon = table.Column(type: "TEXT", nullable: true), + Class = table.Column(type: "INTEGER", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_champions", x => x.Name); + }); + + migrationBuilder.CreateTable( + name: "runepages", + columns: table => new + { + Id = table.Column(type: "TEXT", nullable: false), + Name = table.Column(type: "TEXT", maxLength: 256, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_runepages", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "runes", + columns: table => new + { + Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), + Description = table.Column(type: "TEXT", maxLength: 500, nullable: false), + RuneFamily = table.Column(type: "INTEGER", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_runes", x => x.Name); + }); + + migrationBuilder.CreateTable( + name: "skills", + columns: table => new + { + Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), + Description = table.Column(type: "TEXT", maxLength: 500, nullable: false), + SkillType = table.Column(type: "INTEGER", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_skills", x => x.Name); + }); + + migrationBuilder.CreateTable( + name: "skins", + columns: table => new + { + Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), + Description = table.Column(type: "TEXT", maxLength: 500, nullable: false), + Icon = table.Column(type: "TEXT", nullable: false), + Price = table.Column(type: "REAL", nullable: false), + ChampionForeignKey = table.Column(type: "TEXT", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_skins", x => x.Name); + table.ForeignKey( + name: "FK_skins_champions_ChampionForeignKey", + column: x => x.ChampionForeignKey, + principalTable: "champions", + principalColumn: "Name", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "RuneEntityRunePageEntity", + columns: table => new + { + runepagesId = table.Column(type: "TEXT", nullable: false), + runesName = table.Column(type: "TEXT", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_RuneEntityRunePageEntity", x => new { x.runepagesId, x.runesName }); + table.ForeignKey( + name: "FK_RuneEntityRunePageEntity_runepages_runepagesId", + column: x => x.runepagesId, + principalTable: "runepages", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + table.ForeignKey( + name: "FK_RuneEntityRunePageEntity_runes_runesName", + column: x => x.runesName, + principalTable: "runes", + principalColumn: "Name", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "ChampionEntitySkillEntity", + columns: table => new + { + ChampionsName = table.Column(type: "TEXT", nullable: false), + SkillsName = table.Column(type: "TEXT", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_ChampionEntitySkillEntity", x => new { x.ChampionsName, x.SkillsName }); + table.ForeignKey( + name: "FK_ChampionEntitySkillEntity_champions_ChampionsName", + column: x => x.ChampionsName, + principalTable: "champions", + principalColumn: "Name", + onDelete: ReferentialAction.Cascade); + table.ForeignKey( + name: "FK_ChampionEntitySkillEntity_skills_SkillsName", + column: x => x.SkillsName, + principalTable: "skills", + principalColumn: "Name", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.InsertData( + table: "champions", + columns: new[] { "Name", "Bio", "Class", "Icon" }, + values: new object[,] + { + { "Armure", "Solide", 6, null }, + { "Dave", "Le meilleur Jazzman de France", 2, null } + }); + + migrationBuilder.InsertData( + table: "runepages", + columns: new[] { "Id", "Name" }, + values: new object[] { new Guid("78729bae-c931-4a75-9662-6754ed8e2ce3"), "Runepage_1" }); + + migrationBuilder.InsertData( + table: "runes", + columns: new[] { "Name", "Description", "RuneFamily" }, + values: new object[,] + { + { "Alkatraz", "Lock effect", 2 }, + { "Bullseye", "Steady shot", 1 } + }); + + migrationBuilder.InsertData( + table: "skills", + columns: new[] { "Name", "Description", "SkillType" }, + values: new object[,] + { + { "Boule de feu", "Fire!", 1 }, + { "White Star", "Random damage", 3 } + }); + + migrationBuilder.InsertData( + table: "skins", + columns: new[] { "Name", "ChampionForeignKey", "Description", "Icon", "Price" }, + values: new object[,] + { + { "Armure Fullspeed", "Armure", "Deja vu", "aaa", 9.99f }, + { "Dave de glace", "Dave", "Enneigé", "aaa", 7.99f } + }); + + migrationBuilder.CreateIndex( + name: "IX_ChampionEntitySkillEntity_SkillsName", + table: "ChampionEntitySkillEntity", + column: "SkillsName"); + + migrationBuilder.CreateIndex( + name: "IX_RuneEntityRunePageEntity_runesName", + table: "RuneEntityRunePageEntity", + column: "runesName"); + + migrationBuilder.CreateIndex( + name: "IX_skins_ChampionForeignKey", + table: "skins", + column: "ChampionForeignKey"); + } + + /// + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropTable( + name: "ChampionEntitySkillEntity"); + + migrationBuilder.DropTable( + name: "RuneEntityRunePageEntity"); + + migrationBuilder.DropTable( + name: "skins"); + + migrationBuilder.DropTable( + name: "skills"); + + migrationBuilder.DropTable( + name: "runepages"); + + migrationBuilder.DropTable( + name: "runes"); + + migrationBuilder.DropTable( + name: "champions"); + } + } +} diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs b/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs index f17b1cf..7679554 100644 --- a/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs +++ b/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs @@ -1,4 +1,5 @@ // +using System; using Entities; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Infrastructure; @@ -16,6 +17,21 @@ namespace Entities.Migrations #pragma warning disable 612, 618 modelBuilder.HasAnnotation("ProductVersion", "7.0.2"); + modelBuilder.Entity("ChampionEntitySkillEntity", b => + { + b.Property("ChampionsName") + .HasColumnType("TEXT"); + + b.Property("SkillsName") + .HasColumnType("TEXT"); + + b.HasKey("ChampionsName", "SkillsName"); + + b.HasIndex("SkillsName"); + + b.ToTable("ChampionEntitySkillEntity"); + }); + modelBuilder.Entity("Entities.ChampionEntity", b => { b.Property("Name") @@ -52,6 +68,95 @@ namespace Entities.Migrations }); }); + modelBuilder.Entity("Entities.RuneEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("Description") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("RuneFamily") + .HasColumnType("INTEGER"); + + b.HasKey("Name"); + + b.ToTable("runes"); + + b.HasData( + new + { + Name = "Bullseye", + Description = "Steady shot", + RuneFamily = 1 + }, + new + { + Name = "Alkatraz", + Description = "Lock effect", + RuneFamily = 2 + }); + }); + + modelBuilder.Entity("Entities.RunePageEntity", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("TEXT"); + + b.Property("Name") + .IsRequired() + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.HasKey("Id"); + + b.ToTable("runepages"); + + b.HasData( + new + { + Id = new Guid("78729bae-c931-4a75-9662-6754ed8e2ce3"), + Name = "Runepage_1" + }); + }); + + modelBuilder.Entity("Entities.SkillEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("Description") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("SkillType") + .HasColumnType("INTEGER"); + + b.HasKey("Name"); + + b.ToTable("skills"); + + b.HasData( + new + { + Name = "Boule de feu", + Description = "Fire!", + SkillType = 1 + }, + new + { + Name = "White Star", + Description = "Random damage", + SkillType = 3 + }); + }); + modelBuilder.Entity("Entities.SkinEntity", b => { b.Property("Name") @@ -99,6 +204,36 @@ namespace Entities.Migrations }); }); + modelBuilder.Entity("RuneEntityRunePageEntity", b => + { + b.Property("runepagesId") + .HasColumnType("TEXT"); + + b.Property("runesName") + .HasColumnType("TEXT"); + + b.HasKey("runepagesId", "runesName"); + + b.HasIndex("runesName"); + + b.ToTable("RuneEntityRunePageEntity"); + }); + + modelBuilder.Entity("ChampionEntitySkillEntity", b => + { + b.HasOne("Entities.ChampionEntity", null) + .WithMany() + .HasForeignKey("ChampionsName") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Entities.SkillEntity", null) + .WithMany() + .HasForeignKey("SkillsName") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + modelBuilder.Entity("Entities.SkinEntity", b => { b.HasOne("Entities.ChampionEntity", "Champion") @@ -109,6 +244,21 @@ namespace Entities.Migrations b.Navigation("Champion"); }); + + modelBuilder.Entity("RuneEntityRunePageEntity", b => + { + b.HasOne("Entities.RunePageEntity", null) + .WithMany() + .HasForeignKey("runepagesId") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Entities.RuneEntity", null) + .WithMany() + .HasForeignKey("runesName") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); #pragma warning restore 612, 618 } } diff --git a/EntityFramework_LoL/Sources/Entities/RuneEntity.cs b/EntityFramework_LoL/Sources/Entities/RuneEntity.cs new file mode 100644 index 0000000..a89d1a4 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/RuneEntity.cs @@ -0,0 +1,27 @@ +using Shared; +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Entities +{ + public class RuneEntity + { + [Key] + [MaxLength(256)] + public string Name { get; set; } + + [Required] + [MaxLength(500)] + public string Description { get; set; } + + [Required] + public RuneFamily RuneFamily { get; set; } + public ICollection runepages { get; set; } + + + } +} diff --git a/EntityFramework_LoL/Sources/Entities/RunePageEntity.cs b/EntityFramework_LoL/Sources/Entities/RunePageEntity.cs new file mode 100644 index 0000000..ce2ae88 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/RunePageEntity.cs @@ -0,0 +1,24 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Entities +{ + public class RunePageEntity + { + + [Key] + public Guid Id { get; set; } + + [MaxLength(256)] + public string Name { get; set; } + + public ICollection runes { get; set; } + + + } +} diff --git a/EntityFramework_LoL/Sources/Entities/SkillEntity.cs b/EntityFramework_LoL/Sources/Entities/SkillEntity.cs new file mode 100644 index 0000000..51a4ffd --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/SkillEntity.cs @@ -0,0 +1,29 @@ +using Shared; +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Entities +{ + public class SkillEntity + { + [Key] + [MaxLength(256)] + public string Name { get; set; } + + [Required] + [MaxLength(500)] + public string Description { get; set; } + + [Required] + public SkillType SkillType { get; set; } + + public virtual ICollection? Champions { get; set; } + + + } +} From f80eb447361ed1841ec0729b212e86f255b22fc1 Mon Sep 17 00:00:00 2001 From: "arthur.valin" Date: Thu, 9 Feb 2023 14:39:53 +0100 Subject: [PATCH 6/6] Customising RunePageRune Join and adding Large Image --- .vs/League-of-Legends_Project3/v17/.wsuo | Bin 18432 -> 18944 bytes .../Sources/Entities/ChampionDbContext.cs | 18 ++ .../Sources/Entities/ChampionEntity.cs | 8 +- .../Sources/Entities/Entities.Champions.db | Bin 32768 -> 81920 bytes .../Entities/Entities.Champions.db-shm | Bin 32768 -> 32768 bytes .../Entities/Entities.Champions.db-wal | Bin 1182472 -> 3205392 bytes .../Sources/Entities/LargeImageEntity.cs | 19 ++ ...230209133904_myFirstMigration.Designer.cs} | 112 +++++++++--- ....cs => 20230209133904_myFirstMigration.cs} | 164 ++++++++++++------ .../ChampionDbContextModelSnapshot.cs | 110 +++++++++--- .../Sources/Entities/RuneEntity.cs | 7 +- .../Sources/Entities/RunePageRuneEntity.cs | 14 ++ .../Sources/Entities/SkinEntity.cs | 5 + ...0230209124258_myFirstMigration.Designer.cs | 44 +++++ .../20230209124258_myFirstMigration.cs | 22 +++ .../Sources/StubLib/StubData.RunePages.cs | 13 +- 16 files changed, 426 insertions(+), 110 deletions(-) create mode 100644 EntityFramework_LoL/Sources/Entities/LargeImageEntity.cs rename EntityFramework_LoL/Sources/Entities/Migrations/{20230208162909_myFirstMigration.Designer.cs => 20230209133904_myFirstMigration.Designer.cs} (78%) rename EntityFramework_LoL/Sources/Entities/Migrations/{20230208162909_myFirstMigration.cs => 20230209133904_myFirstMigration.cs} (70%) create mode 100644 EntityFramework_LoL/Sources/Entities/RunePageRuneEntity.cs create mode 100644 EntityFramework_LoL/Sources/EntityFramework/Migrations/20230209124258_myFirstMigration.Designer.cs create mode 100644 EntityFramework_LoL/Sources/EntityFramework/Migrations/20230209124258_myFirstMigration.cs diff --git a/.vs/League-of-Legends_Project3/v17/.wsuo b/.vs/League-of-Legends_Project3/v17/.wsuo index e917b20bd7ac0407438812f450c49c21b2d86802..80c36fce6bc5f9b6f5a1fd8186a6fd6e3ad06882 100644 GIT binary patch delta 956 zcmbVKO-mb56rDSr>O|j*GmU1_B#kv@VGAQoCdP;XTNsL^g`}WswKZ9}jNmfRO&3{| zdH#UnzR>3Vfq+8AZUnpOj}W?;g;~`0-h3JxDD=YN@y>hq-g7@{AE0&!pZCx~DN(&s2QEO1+4qpXMmmURp!-F~a{@7rFc9=k#>8vQGVdc3 zMZ^$s#5}SwQPNUhwoBltdx6^4&AdtcLe8DMOG$A^n*mh+{P^s#d*`SO>k=){cY%N?3aD87`x;A0YZ7sz!;0kf5&iN#7`TqM7wZ zd_**PF#8Hv0$t{Ax;1l}xLW+ifg0CqA}Uybh-{f>z}p#Ux`RxixGh}PU!(OlEzX>uK;k^BjbunX*#3|v90?&XiU66q!yBzt_$ zXak8L>$Gi6gK5!vboRG{^z#h7hbJR@Ag>m6@G__Ra6Ost|57fDu)~42ZFofCQd`{6 zTKP!cu1{81H^)+McXPXrxhbDzKyH F>K`E3PSyYb delta 1178 zcmbtT&ubG=5YCI6bW`8PO|to&*iDF`YQRQQD-|S4&_W8Upx~hgJ$S45YlR+DFXoU# z-05E+Uc71c<|&eb6+sJnDR}fB5EjWEY@OM3!`4W7|EvHj;ilx1(UaQsIvy*$$%zy7<%S1{ z3jgobhfo+K`D5+Lsh0V|cV;bA6$|o53s{xwqb<<92OeBHF{{CrHE8XrX3;P}B zN_vs;G=^tAzZkOu3^R+IQm7s~v}%~@;Vm3rv*hjP^ton6ihRoH-*gdJgXM7{wK_tqkrH zt<7&jn8OnyGcp5`c%(~{t|WztQZUion$iAMzQBS~8O;LhSd#}ZCGGu~l&)w_0!z^( z=e_M8R=jPfePdRH4fULS_x2oqCQCxj`4Bo~AHKGl6sp;&XXWk`Kuigln?=Q{;e*qy|nuP!W diff --git a/EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs b/EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs index b2c8f8f..e28b10f 100644 --- a/EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs +++ b/EntityFramework_LoL/Sources/Entities/ChampionDbContext.cs @@ -1,5 +1,6 @@ using Microsoft.EntityFrameworkCore; using Shared; +using System.Reflection.Metadata; using System.Security.Claims; using System.Xml.Linq; @@ -12,6 +13,7 @@ namespace Entities public DbSet skills { get; set; } public DbSet runes { get; set; } public DbSet runepages { get; set; } + public DbSet largeimages { get; set; } protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder) @@ -21,8 +23,24 @@ namespace Entities protected override void OnModelCreating(ModelBuilder modelBuilder) { + + modelBuilder.Entity().Property(e => e.Id).ValueGeneratedOnAdd(); + modelBuilder.Entity().Property(e => e.Id).ValueGeneratedOnAdd(); + modelBuilder.Entity() + .HasMany(x => x.runes) + .WithMany(x => x.runepages) + .UsingEntity(); + + modelBuilder.Entity().HasData(new List() + { + new() + { + Id = Guid.NewGuid(), + Base64 = "aaa" + } + }); modelBuilder.Entity().HasData(new List() { new() diff --git a/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs b/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs index eea4371..5e3101a 100644 --- a/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs +++ b/EntityFramework_LoL/Sources/Entities/ChampionEntity.cs @@ -15,8 +15,14 @@ namespace Entities public string? Icon { get; set; } [Required] public ChampionClass Class { get; set;} - public virtual ICollection? Skills { get; set; } + public Guid? ImageId { get; set; } + + [ForeignKey("ImageId")] + public LargeImageEntity? Image { get; set; } + + + } } diff --git a/EntityFramework_LoL/Sources/Entities/Entities.Champions.db b/EntityFramework_LoL/Sources/Entities/Entities.Champions.db index 301c8f4c5ac6b9533bdc98b5b32410e1b9e0753b..5847519f33f10f07991fe63c42421d6b8cbacc6f 100644 GIT binary patch literal 81920 zcmeI*&2QW09S3l}$dYBrViLz?+%5>CAaLB(fhbv4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R76i^Lm(sLkhi&6ot(_{A9bAM@|xpU9uVZ_h8bS!+CxIer9Dx&)lL+1?R+~lGGgL$#4C| NH?wT`BfrQ&004VjK9K+b diff --git a/EntityFramework_LoL/Sources/Entities/Entities.Champions.db-shm b/EntityFramework_LoL/Sources/Entities/Entities.Champions.db-shm index 9cd8351f1caa059d87461e18d8ce17a5864f487c..be1302a557fa43b70c65f795a052420bbca6facd 100644 GIT binary patch literal 32768 zcmeI51&~!o7KZ=-$K73nyGwBQ;1Jy1NpN=!?gUG4NC@sExVyUtcX!CWyW6!dQxo>R z4UkEtyQ-_+>3h2S{NFkKYNl##PxMQv;kF`9ClEelARw0W`TXmog=b}NRV`iV>_ZEM zZ=UhSlnAeKbUTqSx{v?rSH}<~gp3gi# z`?}8miX*5KQ!u9oceu|_=j|QD5r;ZdKjmh^<6*n%#3@^b^XkK z?mF&#cg(+ezQz#NStp#wdhY)2n2F8Z*Tn4UYZw_{qtDp>&G|F28D=I{Qv-&ZXKaR@ z@pW_Q#%FB*=KR00g?HAC;B=RliNPK7v6Y@^B8 zpHh?I=#3`V*RLis-)J(n(PZq8rO7=vrjFe22(zDGJ?{6Qd1mrqY;R-tT*KDb@3|W` zrtYISyrVijn$z7Jd47MJF~2!-^WiziF)0(wpjv}fF)oFSOS)SC143y z0+xU!Up%vPrGrFS>MqwPL;Csx%e5}QKY{M?>!yz2UE!@LXyuv#K zVlakgd?sQ_reh|4&YaB0imbxgY``XL!LQh!gE@?2`7Nh%I%o3-uIFa%;(i|Hah~P{ zKIAjLr4&>l6;272RB4n^S(QV1R8ZAaTaDFP?bJ!#)LY{Aw5o;XkHTRV_7AE45Wndjj5@^d<0-mH&{gh+yvNRQkohFWNi{uqx1*nm^Gk8n)P zf~?9;9L}G(g_rr95tU3uR7d?ZMeB4#kL*eDlKsbW3t_9@OSE$CNek)RtrpR_Lnj(y zBOVeVDN-Q=vLX-4qc*<608GG7*of13fbdMhLafHl9KnU$%3t|{k(69TRagBrRX^*f z9^3l&lK#hWb8i^5%^L!#krAIGFN&iyDxfmzpg9I&Di&fp&fqm7Fg**iA-ixA7x4hE z@Es#7lZxpp4bVLOq6>OrtKA#a)+fLbNP|qshI}Z4y6AvGn1)5zfwOpnh|ItuY{agd z%*8y&tAwH`vx@6$4b*(C*F`Y1&6?@?RN07swzDxyBR;2X@q670cwkdc{% z#n_D9`5l+?D6ccHqA8ocPzMdxPui#}dT#4Jz~#~g*>a1_HSetZRFYF2M6}R;dPy`C$3sglze2pF$if=Io z%Wwb}5rk2hoh8_cJvo!hd6G97TrreOrPM`3v_zYALoaRp2dHe?V0p%+GA66Rth*5Ow?Lky;3 zDb`^hj^irs<{ds_Y^7CMHPLX*)Ha>g8(ZtX;kMoZia=AeLvM`4SWL!un2C8WUS(^x*1yKlvReYsVepOUWHBd9PQAc%E zPmR{M`d+j3gBEJ3R%(|H>V(eflCJ8e?uzy=vV2XM_5WZ5Zr~;2G9gni4Kp$;b1*N< zvliQNAct}cCvXbC=Pb_W&)muL{7gxdTIrQV*_B%b^rf0>j3#Nf4oS9>KUiMuLZ5=b zO*}y;#$#GmV0{kaME=5kOrQ*^q!t>hIohLh3S{g0QzXOg@remkR!fc3bgj}}ozy)A Kwsrmo8TbwISj6!F delta 346 zcmZo@U}|V!s+V}A%K!q(K+MR%ARrGUM1brW=`8o3Y>zZG@VDx9705A`db)+Jbg9!K zQq_aZ1_6+{|B(Phl!1*wAHq&(ffbCz(*jqZ}yXLB0r3*DI#U_lkIcj89CH@01Dw8E=@_UNZb* XkYfb0e=u>pV))9y%_tAzDX;(luDF8M diff --git a/EntityFramework_LoL/Sources/Entities/Entities.Champions.db-wal b/EntityFramework_LoL/Sources/Entities/Entities.Champions.db-wal index c02c794b78df6f8d8b92ee5a382d78297cb471e1..d2719b5abd4b3fd502dc6237057f86c2a8354294 100644 GIT binary patch delta 48617 zcmeHQ2V4`$_fMgOB%6c|0!k4DHA3j9s8m7e>e)^a5d{TBzzQfTc2p2`?P9N>5jCE@ zcNDQJc5K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!k*GdSVq0 z1HVioVcG8IE=UUScq$Vu1S9NnHqIR~q`mv63xHp zL-UB4IbpAzE(8E^q&1@rA6SDH1c;&Fobu7C&0DYBMdQNX+3i$wZ&%o+NKQL@f@qMA6IyGq8B7+N&49x|&?sm3S9iYC zOnUM>CVO6?t3?^*slyEW0}hF&Hq1T@X%GT|;a9FnjAAqC=t9@!U;qHv&SJCTTx*hEKzKLO}caIPSzGj-l&rBMO@pMdUS zsaEe0fb+ABB@#I@j0EV59vmxg`K6Jr4xiQJ*F?I`EHHirqdhK3!$Qr3W7MekE8)Sv z2=x+EZ?hpL%bSioF5KT1QgHt>pD&?->N8ll(LVEk|=L8$oiRC zg(_w8LG?WB#ula)<`$L~))uxF_7;v7&K9l~?iQXF-WI+V{uY52!7V}@+yHwb B4nqI{ diff --git a/EntityFramework_LoL/Sources/Entities/LargeImageEntity.cs b/EntityFramework_LoL/Sources/Entities/LargeImageEntity.cs new file mode 100644 index 0000000..3448ac9 --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/LargeImageEntity.cs @@ -0,0 +1,19 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Entities +{ + public class LargeImageEntity + { + + [Key] + public Guid Id { get; set; } + [Required] + public string Base64 { get; set; } + + } +} diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.Designer.cs b/EntityFramework_LoL/Sources/Entities/Migrations/20230209133904_myFirstMigration.Designer.cs similarity index 78% rename from EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.Designer.cs rename to EntityFramework_LoL/Sources/Entities/Migrations/20230209133904_myFirstMigration.Designer.cs index 130ec85..81f4297 100644 --- a/EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.Designer.cs +++ b/EntityFramework_LoL/Sources/Entities/Migrations/20230209133904_myFirstMigration.Designer.cs @@ -11,7 +11,7 @@ using Microsoft.EntityFrameworkCore.Storage.ValueConversion; namespace Entities.Migrations { [DbContext(typeof(ChampionDbContext))] - [Migration("20230208162909_myFirstMigration")] + [Migration("20230209133904_myFirstMigration")] partial class myFirstMigration { /// @@ -52,8 +52,13 @@ namespace Entities.Migrations b.Property("Icon") .HasColumnType("TEXT"); + b.Property("ImageId") + .HasColumnType("TEXT"); + b.HasKey("Name"); + b.HasIndex("ImageId"); + b.ToTable("champions"); b.HasData( @@ -71,6 +76,28 @@ namespace Entities.Migrations }); }); + modelBuilder.Entity("Entities.LargeImageEntity", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("TEXT"); + + b.Property("Base64") + .IsRequired() + .HasColumnType("TEXT"); + + b.HasKey("Id"); + + b.ToTable("largeimages"); + + b.HasData( + new + { + Id = new Guid("70d7aace-13a9-40e1-bd94-99790805f6d0"), + Base64 = "aaa" + }); + }); + modelBuilder.Entity("Entities.RuneEntity", b => { b.Property("Name") @@ -82,11 +109,16 @@ namespace Entities.Migrations .HasMaxLength(500) .HasColumnType("TEXT"); + b.Property("ImageId") + .HasColumnType("TEXT"); + b.Property("RuneFamily") .HasColumnType("INTEGER"); b.HasKey("Name"); + b.HasIndex("ImageId"); + b.ToTable("runes"); b.HasData( @@ -122,11 +154,29 @@ namespace Entities.Migrations b.HasData( new { - Id = new Guid("78729bae-c931-4a75-9662-6754ed8e2ce3"), + Id = new Guid("a5a4f69b-5cbb-48c1-beb4-896bc9171714"), Name = "Runepage_1" }); }); + modelBuilder.Entity("Entities.RunePageRuneEntity", b => + { + b.Property("runepagesId") + .HasColumnType("TEXT"); + + b.Property("runesName") + .HasColumnType("TEXT"); + + b.Property("Category") + .HasColumnType("INTEGER"); + + b.HasKey("runepagesId", "runesName"); + + b.HasIndex("runesName"); + + b.ToTable("RunePageRuneEntity"); + }); + modelBuilder.Entity("Entities.SkillEntity", b => { b.Property("Name") @@ -179,6 +229,9 @@ namespace Entities.Migrations .IsRequired() .HasColumnType("TEXT"); + b.Property("ImageId") + .HasColumnType("TEXT"); + b.Property("Price") .HasColumnType("REAL"); @@ -186,6 +239,8 @@ namespace Entities.Migrations b.HasIndex("ChampionForeignKey"); + b.HasIndex("ImageId"); + b.ToTable("skins"); b.HasData( @@ -207,21 +262,6 @@ namespace Entities.Migrations }); }); - modelBuilder.Entity("RuneEntityRunePageEntity", b => - { - b.Property("runepagesId") - .HasColumnType("TEXT"); - - b.Property("runesName") - .HasColumnType("TEXT"); - - b.HasKey("runepagesId", "runesName"); - - b.HasIndex("runesName"); - - b.ToTable("RuneEntityRunePageEntity"); - }); - modelBuilder.Entity("ChampionEntitySkillEntity", b => { b.HasOne("Entities.ChampionEntity", null) @@ -237,18 +277,25 @@ namespace Entities.Migrations .IsRequired(); }); - modelBuilder.Entity("Entities.SkinEntity", b => + modelBuilder.Entity("Entities.ChampionEntity", b => { - b.HasOne("Entities.ChampionEntity", "Champion") + b.HasOne("Entities.LargeImageEntity", "Image") .WithMany() - .HasForeignKey("ChampionForeignKey") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); + .HasForeignKey("ImageId"); - b.Navigation("Champion"); + b.Navigation("Image"); }); - modelBuilder.Entity("RuneEntityRunePageEntity", b => + modelBuilder.Entity("Entities.RuneEntity", b => + { + b.HasOne("Entities.LargeImageEntity", "Image") + .WithMany() + .HasForeignKey("ImageId"); + + b.Navigation("Image"); + }); + + modelBuilder.Entity("Entities.RunePageRuneEntity", b => { b.HasOne("Entities.RunePageEntity", null) .WithMany() @@ -262,6 +309,23 @@ namespace Entities.Migrations .OnDelete(DeleteBehavior.Cascade) .IsRequired(); }); + + modelBuilder.Entity("Entities.SkinEntity", b => + { + b.HasOne("Entities.ChampionEntity", "Champion") + .WithMany() + .HasForeignKey("ChampionForeignKey") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Entities.LargeImageEntity", "Image") + .WithMany() + .HasForeignKey("ImageId"); + + b.Navigation("Champion"); + + b.Navigation("Image"); + }); #pragma warning restore 612, 618 } } diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.cs b/EntityFramework_LoL/Sources/Entities/Migrations/20230209133904_myFirstMigration.cs similarity index 70% rename from EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.cs rename to EntityFramework_LoL/Sources/Entities/Migrations/20230209133904_myFirstMigration.cs index 62248a1..eb3748a 100644 --- a/EntityFramework_LoL/Sources/Entities/Migrations/20230208162909_myFirstMigration.cs +++ b/EntityFramework_LoL/Sources/Entities/Migrations/20230209133904_myFirstMigration.cs @@ -14,17 +14,15 @@ namespace Entities.Migrations protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.CreateTable( - name: "champions", + name: "largeimages", columns: table => new { - Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), - Bio = table.Column(type: "TEXT", maxLength: 500, nullable: false), - Icon = table.Column(type: "TEXT", nullable: true), - Class = table.Column(type: "INTEGER", nullable: false) + Id = table.Column(type: "TEXT", nullable: false), + Base64 = table.Column(type: "TEXT", nullable: false) }, constraints: table => { - table.PrimaryKey("PK_champions", x => x.Name); + table.PrimaryKey("PK_largeimages", x => x.Id); }); migrationBuilder.CreateTable( @@ -40,29 +38,79 @@ namespace Entities.Migrations }); migrationBuilder.CreateTable( - name: "runes", + name: "skills", columns: table => new { Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), Description = table.Column(type: "TEXT", maxLength: 500, nullable: false), - RuneFamily = table.Column(type: "INTEGER", nullable: false) + SkillType = table.Column(type: "INTEGER", nullable: false) }, constraints: table => { - table.PrimaryKey("PK_runes", x => x.Name); + table.PrimaryKey("PK_skills", x => x.Name); }); migrationBuilder.CreateTable( - name: "skills", + name: "champions", + columns: table => new + { + Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), + Bio = table.Column(type: "TEXT", maxLength: 500, nullable: false), + Icon = table.Column(type: "TEXT", nullable: true), + Class = table.Column(type: "INTEGER", nullable: false), + ImageId = table.Column(type: "TEXT", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_champions", x => x.Name); + table.ForeignKey( + name: "FK_champions_largeimages_ImageId", + column: x => x.ImageId, + principalTable: "largeimages", + principalColumn: "Id"); + }); + + migrationBuilder.CreateTable( + name: "runes", columns: table => new { Name = table.Column(type: "TEXT", maxLength: 256, nullable: false), Description = table.Column(type: "TEXT", maxLength: 500, nullable: false), - SkillType = table.Column(type: "INTEGER", nullable: false) + RuneFamily = table.Column(type: "INTEGER", nullable: false), + ImageId = table.Column(type: "TEXT", nullable: true) }, constraints: table => { - table.PrimaryKey("PK_skills", x => x.Name); + table.PrimaryKey("PK_runes", x => x.Name); + table.ForeignKey( + name: "FK_runes_largeimages_ImageId", + column: x => x.ImageId, + principalTable: "largeimages", + principalColumn: "Id"); + }); + + migrationBuilder.CreateTable( + name: "ChampionEntitySkillEntity", + columns: table => new + { + ChampionsName = table.Column(type: "TEXT", nullable: false), + SkillsName = table.Column(type: "TEXT", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_ChampionEntitySkillEntity", x => new { x.ChampionsName, x.SkillsName }); + table.ForeignKey( + name: "FK_ChampionEntitySkillEntity_champions_ChampionsName", + column: x => x.ChampionsName, + principalTable: "champions", + principalColumn: "Name", + onDelete: ReferentialAction.Cascade); + table.ForeignKey( + name: "FK_ChampionEntitySkillEntity_skills_SkillsName", + column: x => x.SkillsName, + principalTable: "skills", + principalColumn: "Name", + onDelete: ReferentialAction.Cascade); }); migrationBuilder.CreateTable( @@ -73,7 +121,8 @@ namespace Entities.Migrations Description = table.Column(type: "TEXT", maxLength: 500, nullable: false), Icon = table.Column(type: "TEXT", nullable: false), Price = table.Column(type: "REAL", nullable: false), - ChampionForeignKey = table.Column(type: "TEXT", nullable: false) + ChampionForeignKey = table.Column(type: "TEXT", nullable: false), + ImageId = table.Column(type: "TEXT", nullable: true) }, constraints: table => { @@ -84,77 +133,64 @@ namespace Entities.Migrations principalTable: "champions", principalColumn: "Name", onDelete: ReferentialAction.Cascade); + table.ForeignKey( + name: "FK_skins_largeimages_ImageId", + column: x => x.ImageId, + principalTable: "largeimages", + principalColumn: "Id"); }); migrationBuilder.CreateTable( - name: "RuneEntityRunePageEntity", + name: "RunePageRuneEntity", columns: table => new { runepagesId = table.Column(type: "TEXT", nullable: false), - runesName = table.Column(type: "TEXT", nullable: false) + runesName = table.Column(type: "TEXT", nullable: false), + Category = table.Column(type: "INTEGER", nullable: false) }, constraints: table => { - table.PrimaryKey("PK_RuneEntityRunePageEntity", x => new { x.runepagesId, x.runesName }); + table.PrimaryKey("PK_RunePageRuneEntity", x => new { x.runepagesId, x.runesName }); table.ForeignKey( - name: "FK_RuneEntityRunePageEntity_runepages_runepagesId", + name: "FK_RunePageRuneEntity_runepages_runepagesId", column: x => x.runepagesId, principalTable: "runepages", principalColumn: "Id", onDelete: ReferentialAction.Cascade); table.ForeignKey( - name: "FK_RuneEntityRunePageEntity_runes_runesName", + name: "FK_RunePageRuneEntity_runes_runesName", column: x => x.runesName, principalTable: "runes", principalColumn: "Name", onDelete: ReferentialAction.Cascade); }); - migrationBuilder.CreateTable( - name: "ChampionEntitySkillEntity", - columns: table => new - { - ChampionsName = table.Column(type: "TEXT", nullable: false), - SkillsName = table.Column(type: "TEXT", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_ChampionEntitySkillEntity", x => new { x.ChampionsName, x.SkillsName }); - table.ForeignKey( - name: "FK_ChampionEntitySkillEntity_champions_ChampionsName", - column: x => x.ChampionsName, - principalTable: "champions", - principalColumn: "Name", - onDelete: ReferentialAction.Cascade); - table.ForeignKey( - name: "FK_ChampionEntitySkillEntity_skills_SkillsName", - column: x => x.SkillsName, - principalTable: "skills", - principalColumn: "Name", - onDelete: ReferentialAction.Cascade); - }); - migrationBuilder.InsertData( table: "champions", - columns: new[] { "Name", "Bio", "Class", "Icon" }, + columns: new[] { "Name", "Bio", "Class", "Icon", "ImageId" }, values: new object[,] { - { "Armure", "Solide", 6, null }, - { "Dave", "Le meilleur Jazzman de France", 2, null } + { "Armure", "Solide", 6, null, null }, + { "Dave", "Le meilleur Jazzman de France", 2, null, null } }); + migrationBuilder.InsertData( + table: "largeimages", + columns: new[] { "Id", "Base64" }, + values: new object[] { new Guid("70d7aace-13a9-40e1-bd94-99790805f6d0"), "aaa" }); + migrationBuilder.InsertData( table: "runepages", columns: new[] { "Id", "Name" }, - values: new object[] { new Guid("78729bae-c931-4a75-9662-6754ed8e2ce3"), "Runepage_1" }); + values: new object[] { new Guid("a5a4f69b-5cbb-48c1-beb4-896bc9171714"), "Runepage_1" }); migrationBuilder.InsertData( table: "runes", - columns: new[] { "Name", "Description", "RuneFamily" }, + columns: new[] { "Name", "Description", "ImageId", "RuneFamily" }, values: new object[,] { - { "Alkatraz", "Lock effect", 2 }, - { "Bullseye", "Steady shot", 1 } + { "Alkatraz", "Lock effect", null, 2 }, + { "Bullseye", "Steady shot", null, 1 } }); migrationBuilder.InsertData( @@ -168,11 +204,11 @@ namespace Entities.Migrations migrationBuilder.InsertData( table: "skins", - columns: new[] { "Name", "ChampionForeignKey", "Description", "Icon", "Price" }, + columns: new[] { "Name", "ChampionForeignKey", "Description", "Icon", "ImageId", "Price" }, values: new object[,] { - { "Armure Fullspeed", "Armure", "Deja vu", "aaa", 9.99f }, - { "Dave de glace", "Dave", "Enneigé", "aaa", 7.99f } + { "Armure Fullspeed", "Armure", "Deja vu", "aaa", null, 9.99f }, + { "Dave de glace", "Dave", "Enneigé", "aaa", null, 7.99f } }); migrationBuilder.CreateIndex( @@ -181,14 +217,29 @@ namespace Entities.Migrations column: "SkillsName"); migrationBuilder.CreateIndex( - name: "IX_RuneEntityRunePageEntity_runesName", - table: "RuneEntityRunePageEntity", + name: "IX_champions_ImageId", + table: "champions", + column: "ImageId"); + + migrationBuilder.CreateIndex( + name: "IX_RunePageRuneEntity_runesName", + table: "RunePageRuneEntity", column: "runesName"); + migrationBuilder.CreateIndex( + name: "IX_runes_ImageId", + table: "runes", + column: "ImageId"); + migrationBuilder.CreateIndex( name: "IX_skins_ChampionForeignKey", table: "skins", column: "ChampionForeignKey"); + + migrationBuilder.CreateIndex( + name: "IX_skins_ImageId", + table: "skins", + column: "ImageId"); } /// @@ -198,7 +249,7 @@ namespace Entities.Migrations name: "ChampionEntitySkillEntity"); migrationBuilder.DropTable( - name: "RuneEntityRunePageEntity"); + name: "RunePageRuneEntity"); migrationBuilder.DropTable( name: "skins"); @@ -214,6 +265,9 @@ namespace Entities.Migrations migrationBuilder.DropTable( name: "champions"); + + migrationBuilder.DropTable( + name: "largeimages"); } } } diff --git a/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs b/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs index 7679554..aef1440 100644 --- a/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs +++ b/EntityFramework_LoL/Sources/Entities/Migrations/ChampionDbContextModelSnapshot.cs @@ -49,8 +49,13 @@ namespace Entities.Migrations b.Property("Icon") .HasColumnType("TEXT"); + b.Property("ImageId") + .HasColumnType("TEXT"); + b.HasKey("Name"); + b.HasIndex("ImageId"); + b.ToTable("champions"); b.HasData( @@ -68,6 +73,28 @@ namespace Entities.Migrations }); }); + modelBuilder.Entity("Entities.LargeImageEntity", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("TEXT"); + + b.Property("Base64") + .IsRequired() + .HasColumnType("TEXT"); + + b.HasKey("Id"); + + b.ToTable("largeimages"); + + b.HasData( + new + { + Id = new Guid("70d7aace-13a9-40e1-bd94-99790805f6d0"), + Base64 = "aaa" + }); + }); + modelBuilder.Entity("Entities.RuneEntity", b => { b.Property("Name") @@ -79,11 +106,16 @@ namespace Entities.Migrations .HasMaxLength(500) .HasColumnType("TEXT"); + b.Property("ImageId") + .HasColumnType("TEXT"); + b.Property("RuneFamily") .HasColumnType("INTEGER"); b.HasKey("Name"); + b.HasIndex("ImageId"); + b.ToTable("runes"); b.HasData( @@ -119,11 +151,29 @@ namespace Entities.Migrations b.HasData( new { - Id = new Guid("78729bae-c931-4a75-9662-6754ed8e2ce3"), + Id = new Guid("a5a4f69b-5cbb-48c1-beb4-896bc9171714"), Name = "Runepage_1" }); }); + modelBuilder.Entity("Entities.RunePageRuneEntity", b => + { + b.Property("runepagesId") + .HasColumnType("TEXT"); + + b.Property("runesName") + .HasColumnType("TEXT"); + + b.Property("Category") + .HasColumnType("INTEGER"); + + b.HasKey("runepagesId", "runesName"); + + b.HasIndex("runesName"); + + b.ToTable("RunePageRuneEntity"); + }); + modelBuilder.Entity("Entities.SkillEntity", b => { b.Property("Name") @@ -176,6 +226,9 @@ namespace Entities.Migrations .IsRequired() .HasColumnType("TEXT"); + b.Property("ImageId") + .HasColumnType("TEXT"); + b.Property("Price") .HasColumnType("REAL"); @@ -183,6 +236,8 @@ namespace Entities.Migrations b.HasIndex("ChampionForeignKey"); + b.HasIndex("ImageId"); + b.ToTable("skins"); b.HasData( @@ -204,21 +259,6 @@ namespace Entities.Migrations }); }); - modelBuilder.Entity("RuneEntityRunePageEntity", b => - { - b.Property("runepagesId") - .HasColumnType("TEXT"); - - b.Property("runesName") - .HasColumnType("TEXT"); - - b.HasKey("runepagesId", "runesName"); - - b.HasIndex("runesName"); - - b.ToTable("RuneEntityRunePageEntity"); - }); - modelBuilder.Entity("ChampionEntitySkillEntity", b => { b.HasOne("Entities.ChampionEntity", null) @@ -234,18 +274,25 @@ namespace Entities.Migrations .IsRequired(); }); - modelBuilder.Entity("Entities.SkinEntity", b => + modelBuilder.Entity("Entities.ChampionEntity", b => { - b.HasOne("Entities.ChampionEntity", "Champion") + b.HasOne("Entities.LargeImageEntity", "Image") .WithMany() - .HasForeignKey("ChampionForeignKey") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); + .HasForeignKey("ImageId"); - b.Navigation("Champion"); + b.Navigation("Image"); }); - modelBuilder.Entity("RuneEntityRunePageEntity", b => + modelBuilder.Entity("Entities.RuneEntity", b => + { + b.HasOne("Entities.LargeImageEntity", "Image") + .WithMany() + .HasForeignKey("ImageId"); + + b.Navigation("Image"); + }); + + modelBuilder.Entity("Entities.RunePageRuneEntity", b => { b.HasOne("Entities.RunePageEntity", null) .WithMany() @@ -259,6 +306,23 @@ namespace Entities.Migrations .OnDelete(DeleteBehavior.Cascade) .IsRequired(); }); + + modelBuilder.Entity("Entities.SkinEntity", b => + { + b.HasOne("Entities.ChampionEntity", "Champion") + .WithMany() + .HasForeignKey("ChampionForeignKey") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("Entities.LargeImageEntity", "Image") + .WithMany() + .HasForeignKey("ImageId"); + + b.Navigation("Champion"); + + b.Navigation("Image"); + }); #pragma warning restore 612, 618 } } diff --git a/EntityFramework_LoL/Sources/Entities/RuneEntity.cs b/EntityFramework_LoL/Sources/Entities/RuneEntity.cs index a89d1a4..9b1d077 100644 --- a/EntityFramework_LoL/Sources/Entities/RuneEntity.cs +++ b/EntityFramework_LoL/Sources/Entities/RuneEntity.cs @@ -2,6 +2,7 @@ using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; using System.Linq; using System.Text; using System.Threading.Tasks; @@ -20,8 +21,12 @@ namespace Entities [Required] public RuneFamily RuneFamily { get; set; } - public ICollection runepages { get; set; } + public ICollection? runepages { get; set; } + public Guid? ImageId { get; set; } + + [ForeignKey("ImageId")] + public LargeImageEntity? Image { get; set; } } } diff --git a/EntityFramework_LoL/Sources/Entities/RunePageRuneEntity.cs b/EntityFramework_LoL/Sources/Entities/RunePageRuneEntity.cs new file mode 100644 index 0000000..a1ad83f --- /dev/null +++ b/EntityFramework_LoL/Sources/Entities/RunePageRuneEntity.cs @@ -0,0 +1,14 @@ +using Shared; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Entities +{ + public class RunePageRuneEntity + { + public Category Category { get; set; } + } +} diff --git a/EntityFramework_LoL/Sources/Entities/SkinEntity.cs b/EntityFramework_LoL/Sources/Entities/SkinEntity.cs index 0baace0..927dca3 100644 --- a/EntityFramework_LoL/Sources/Entities/SkinEntity.cs +++ b/EntityFramework_LoL/Sources/Entities/SkinEntity.cs @@ -28,5 +28,10 @@ namespace Entities [ForeignKey("ChampionForeignKey")] public ChampionEntity Champion { get; set; } + public Guid? ImageId { get; set; } + + [ForeignKey("ImageId")] + public LargeImageEntity? Image { get; set; } + } } diff --git a/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230209124258_myFirstMigration.Designer.cs b/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230209124258_myFirstMigration.Designer.cs new file mode 100644 index 0000000..b64a1d8 --- /dev/null +++ b/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230209124258_myFirstMigration.Designer.cs @@ -0,0 +1,44 @@ +// +using EntityFramework.DbContexts; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; + +#nullable disable + +namespace EntityFramework.Migrations +{ + [DbContext(typeof(ChampionDbContext))] + [Migration("20230209124258_myFirstMigration")] + partial class myFirstMigration + { + /// + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder.HasAnnotation("ProductVersion", "7.0.2"); + + modelBuilder.Entity("EntityFramework.Entities.ChampionEntity", b => + { + b.Property("Name") + .HasMaxLength(256) + .HasColumnType("TEXT"); + + b.Property("Bio") + .IsRequired() + .HasMaxLength(500) + .HasColumnType("TEXT"); + + b.Property("Icon") + .IsRequired() + .HasColumnType("TEXT"); + + b.HasKey("Name"); + + b.ToTable("champions"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230209124258_myFirstMigration.cs b/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230209124258_myFirstMigration.cs new file mode 100644 index 0000000..9f3f929 --- /dev/null +++ b/EntityFramework_LoL/Sources/EntityFramework/Migrations/20230209124258_myFirstMigration.cs @@ -0,0 +1,22 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace EntityFramework.Migrations +{ + /// + public partial class myFirstMigration : Migration + { + /// + protected override void Up(MigrationBuilder migrationBuilder) + { + + } + + /// + protected override void Down(MigrationBuilder migrationBuilder) + { + + } + } +} diff --git a/EntityFramework_LoL/Sources/StubLib/StubData.RunePages.cs b/EntityFramework_LoL/Sources/StubLib/StubData.RunePages.cs index a08a947..169a102 100644 --- a/EntityFramework_LoL/Sources/StubLib/StubData.RunePages.cs +++ b/EntityFramework_LoL/Sources/StubLib/StubData.RunePages.cs @@ -1,5 +1,6 @@ using System; using Model; +using Shared; namespace StubLib { @@ -10,12 +11,12 @@ namespace StubLib private void InitRunePages() { var runePage1 = new RunePage("rune page 1"); - runePage1[RunePage.Category.Major] = runes[0]; - runePage1[RunePage.Category.Minor1] = runes[1]; - runePage1[RunePage.Category.Minor2] = runes[2]; - runePage1[RunePage.Category.Minor3] = runes[3]; - runePage1[RunePage.Category.OtherMinor1] = runes[4]; - runePage1[RunePage.Category.OtherMinor2] = runes[5]; + runePage1[Category.Major] = runes[0]; + runePage1[Category.Minor1] = runes[1]; + runePage1[Category.Minor2] = runes[2]; + runePage1[Category.Minor3] = runes[3]; + runePage1[Category.OtherMinor1] = runes[4]; + runePage1[Category.OtherMinor2] = runes[5]; runePages.Add(runePage1); }