From 957b6e4ce188ff689205c80966e42892aee2af56 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tommy=20=C3=96man?= Date: Wed, 13 Nov 2019 22:28:56 +0100 Subject: [PATCH] Add project files. --- Queries.sln | 22 ++ Queries/App.config | 12 ++ Queries/Author.cs | 18 ++ Queries/Course.cs | 30 +++ Queries/Cover.cs | 8 + .../CourseConfiguration.cs | 35 ++++ ...1510010029257_InitialMigration.Designer.cs | 29 +++ .../201510010029257_InitialMigration.cs | 85 ++++++++ .../201510010029257_InitialMigration.resx | 126 ++++++++++++ Queries/Migrations/Configuration.cs | 194 ++++++++++++++++++ Queries/PlutoContext.cs | 22 ++ Queries/Program.cs | 10 + Queries/Properties/AssemblyInfo.cs | 36 ++++ Queries/Queries.csproj | 82 ++++++++ Queries/Tag.cs | 18 ++ Queries/packages.config | 4 + 16 files changed, 731 insertions(+) create mode 100644 Queries.sln create mode 100644 Queries/App.config create mode 100644 Queries/Author.cs create mode 100644 Queries/Course.cs create mode 100644 Queries/Cover.cs create mode 100644 Queries/EntityConfigurations/CourseConfiguration.cs create mode 100644 Queries/Migrations/201510010029257_InitialMigration.Designer.cs create mode 100644 Queries/Migrations/201510010029257_InitialMigration.cs create mode 100644 Queries/Migrations/201510010029257_InitialMigration.resx create mode 100644 Queries/Migrations/Configuration.cs create mode 100644 Queries/PlutoContext.cs create mode 100644 Queries/Program.cs create mode 100644 Queries/Properties/AssemblyInfo.cs create mode 100644 Queries/Queries.csproj create mode 100644 Queries/Tag.cs create mode 100644 Queries/packages.config diff --git a/Queries.sln b/Queries.sln new file mode 100644 index 0000000..651cb68 --- /dev/null +++ b/Queries.sln @@ -0,0 +1,22 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 2013 +VisualStudioVersion = 12.0.31101.0 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Queries", "Queries\Queries.csproj", "{D1776DED-C59A-4F8A-8C31-96EAE15BDF5A}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {D1776DED-C59A-4F8A-8C31-96EAE15BDF5A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {D1776DED-C59A-4F8A-8C31-96EAE15BDF5A}.Debug|Any CPU.Build.0 = Debug|Any CPU + {D1776DED-C59A-4F8A-8C31-96EAE15BDF5A}.Release|Any CPU.ActiveCfg = Release|Any CPU + {D1776DED-C59A-4F8A-8C31-96EAE15BDF5A}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/Queries/App.config b/Queries/App.config new file mode 100644 index 0000000..497eb68 --- /dev/null +++ b/Queries/App.config @@ -0,0 +1,12 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/Queries/Author.cs b/Queries/Author.cs new file mode 100644 index 0000000..6703146 --- /dev/null +++ b/Queries/Author.cs @@ -0,0 +1,18 @@ +using System.Collections.Generic; + +namespace Queries +{ + public class Author + { + public Author() + { + Courses = new HashSet(); + } + + public int Id { get; set; } + + public string Name { get; set; } + + public virtual ICollection Courses { get; set; } + } +} diff --git a/Queries/Course.cs b/Queries/Course.cs new file mode 100644 index 0000000..1ff746e --- /dev/null +++ b/Queries/Course.cs @@ -0,0 +1,30 @@ +using System.Collections.Generic; + +namespace Queries +{ + public class Course + { + public Course() + { + Tags = new HashSet(); + } + + public int Id { get; set; } + + public string Name { get; set; } + + public string Description { get; set; } + + public int Level { get; set; } + + public float FullPrice { get; set; } + + public virtual Author Author { get; set; } + + public int AuthorId { get; set; } + + public virtual ICollection Tags { get; set; } + + public Cover Cover { get; set; } + } +} diff --git a/Queries/Cover.cs b/Queries/Cover.cs new file mode 100644 index 0000000..65a13d5 --- /dev/null +++ b/Queries/Cover.cs @@ -0,0 +1,8 @@ +namespace Queries +{ + public class Cover + { + public int Id { get; set; } + public Course Course { get; set; } + } +} diff --git a/Queries/EntityConfigurations/CourseConfiguration.cs b/Queries/EntityConfigurations/CourseConfiguration.cs new file mode 100644 index 0000000..610c0e1 --- /dev/null +++ b/Queries/EntityConfigurations/CourseConfiguration.cs @@ -0,0 +1,35 @@ +using System.Data.Entity.ModelConfiguration; + +namespace Queries.EntityConfigurations +{ + public class CourseConfiguration : EntityTypeConfiguration + { + public CourseConfiguration() + { + Property(c => c.Description) + .IsRequired() + .HasMaxLength(2000); + + Property(c => c.Name) + .IsRequired() + .HasMaxLength(255); + + HasRequired(c => c.Author) + .WithMany(a => a.Courses) + .HasForeignKey(c => c.AuthorId) + .WillCascadeOnDelete(false); + + HasRequired(c => c.Cover) + .WithRequiredPrincipal(c => c.Course); + + HasMany(c => c.Tags) + .WithMany(t => t.Courses) + .Map(m => + { + m.ToTable("CourseTags"); + m.MapLeftKey("CourseId"); + m.MapRightKey("TagId"); + }); + } + } +} diff --git a/Queries/Migrations/201510010029257_InitialMigration.Designer.cs b/Queries/Migrations/201510010029257_InitialMigration.Designer.cs new file mode 100644 index 0000000..7e8ba1e --- /dev/null +++ b/Queries/Migrations/201510010029257_InitialMigration.Designer.cs @@ -0,0 +1,29 @@ +// +namespace Queries.Migrations +{ + using System.CodeDom.Compiler; + using System.Data.Entity.Migrations; + using System.Data.Entity.Migrations.Infrastructure; + using System.Resources; + + [GeneratedCode("EntityFramework.Migrations", "6.1.3-40302")] + public sealed partial class InitialMigration : IMigrationMetadata + { + private readonly ResourceManager Resources = new ResourceManager(typeof(InitialMigration)); + + string IMigrationMetadata.Id + { + get { return "201510010029257_InitialMigration"; } + } + + string IMigrationMetadata.Source + { + get { return null; } + } + + string IMigrationMetadata.Target + { + get { return Resources.GetString("Target"); } + } + } +} diff --git a/Queries/Migrations/201510010029257_InitialMigration.cs b/Queries/Migrations/201510010029257_InitialMigration.cs new file mode 100644 index 0000000..da5da4b --- /dev/null +++ b/Queries/Migrations/201510010029257_InitialMigration.cs @@ -0,0 +1,85 @@ +namespace Queries.Migrations +{ + using System; + using System.Data.Entity.Migrations; + + public partial class InitialMigration : DbMigration + { + public override void Up() + { + CreateTable( + "dbo.Authors", + c => new + { + Id = c.Int(nullable: false, identity: true), + Name = c.String(), + }) + .PrimaryKey(t => t.Id); + + CreateTable( + "dbo.Courses", + c => new + { + Id = c.Int(nullable: false, identity: true), + Name = c.String(nullable: false, maxLength: 255), + Description = c.String(nullable: false, maxLength: 2000), + Level = c.Int(nullable: false), + FullPrice = c.Single(nullable: false), + AuthorId = c.Int(nullable: false), + }) + .PrimaryKey(t => t.Id) + .ForeignKey("dbo.Authors", t => t.AuthorId) + .Index(t => t.AuthorId); + + CreateTable( + "dbo.Covers", + c => new + { + Id = c.Int(nullable: false), + }) + .PrimaryKey(t => t.Id) + .ForeignKey("dbo.Courses", t => t.Id) + .Index(t => t.Id); + + CreateTable( + "dbo.Tags", + c => new + { + Id = c.Int(nullable: false, identity: true), + Name = c.String(), + }) + .PrimaryKey(t => t.Id); + + CreateTable( + "dbo.CourseTags", + c => new + { + CourseId = c.Int(nullable: false), + TagId = c.Int(nullable: false), + }) + .PrimaryKey(t => new { t.CourseId, t.TagId }) + .ForeignKey("dbo.Courses", t => t.CourseId, cascadeDelete: true) + .ForeignKey("dbo.Tags", t => t.TagId, cascadeDelete: true) + .Index(t => t.CourseId) + .Index(t => t.TagId); + + } + + public override void Down() + { + DropForeignKey("dbo.CourseTags", "TagId", "dbo.Tags"); + DropForeignKey("dbo.CourseTags", "CourseId", "dbo.Courses"); + DropForeignKey("dbo.Covers", "Id", "dbo.Courses"); + DropForeignKey("dbo.Courses", "AuthorId", "dbo.Authors"); + DropIndex("dbo.CourseTags", new[] { "TagId" }); + DropIndex("dbo.CourseTags", new[] { "CourseId" }); + DropIndex("dbo.Covers", new[] { "Id" }); + DropIndex("dbo.Courses", new[] { "AuthorId" }); + DropTable("dbo.CourseTags"); + DropTable("dbo.Tags"); + DropTable("dbo.Covers"); + DropTable("dbo.Courses"); + DropTable("dbo.Authors"); + } + } +} diff --git a/Queries/Migrations/201510010029257_InitialMigration.resx b/Queries/Migrations/201510010029257_InitialMigration.resx new file mode 100644 index 0000000..2946a91 --- /dev/null +++ b/Queries/Migrations/201510010029257_InitialMigration.resx @@ -0,0 +1,126 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + 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 + + + dbo + + \ No newline at end of file diff --git a/Queries/Migrations/Configuration.cs b/Queries/Migrations/Configuration.cs new file mode 100644 index 0000000..5a3d4cf --- /dev/null +++ b/Queries/Migrations/Configuration.cs @@ -0,0 +1,194 @@ +using System.Collections.Generic; +using System.Collections.ObjectModel; + +namespace Queries.Migrations +{ + using System.Data.Entity.Migrations; + + internal sealed class Configuration : DbMigrationsConfiguration + { + public Configuration() + { + AutomaticMigrationsEnabled = false; + } + + protected override void Seed(PlutoContext context) + { + #region Add Tags + var tags = new Dictionary + { + {"c#", new Tag {Id = 1, Name = "c#"}}, + {"angularjs", new Tag {Id = 2, Name = "angularjs"}}, + {"javascript", new Tag {Id = 3, Name = "javascript"}}, + {"nodejs", new Tag {Id = 4, Name = "nodejs"}}, + {"oop", new Tag {Id = 5, Name = "oop"}}, + {"linq", new Tag {Id = 6, Name = "linq"}}, + }; + + foreach (var tag in tags.Values) + context.Tags.AddOrUpdate(t => t.Id, tag); + #endregion + + #region Add Authors + var authors = new List + { + new Author + { + Id = 1, + Name = "Mosh Hamedani" + }, + new Author + { + Id = 2, + Name = "Anthony Alicea" + }, + new Author + { + Id = 3, + Name = "Eric Wise" + }, + new Author + { + Id = 4, + Name = "Tom Owsiak" + }, + new Author + { + Id = 5, + Name = "John Smith" + } + }; + + foreach (var author in authors) + context.Authors.AddOrUpdate(a => a.Id, author); + #endregion + + #region Add Courses + var courses = new List + { + new Course + { + Id = 1, + Name = "C# Basics", + AuthorId = 1, + FullPrice = 49, + Description = "Description for C# Basics", + Level = 1, + Tags = new Collection() + { + tags["c#"] + } + }, + new Course + { + Id = 2, + Name = "C# Intermediate", + AuthorId = 1, + FullPrice = 49, + Description = "Description for C# Intermediate", + Level = 2, + Tags = new Collection() + { + tags["c#"], + tags["oop"] + } + }, + new Course + { + Id = 3, + Name = "C# Advanced", + AuthorId = 1, + FullPrice = 69, + Description = "Description for C# Advanced", + Level = 3, + Tags = new Collection() + { + tags["c#"] + } + }, + new Course + { + Id = 4, + Name = "Javascript: Understanding the Weird Parts", + AuthorId = 2, + FullPrice = 149, + Description = "Description for Javascript", + Level = 2, + Tags = new Collection() + { + tags["javascript"] + } + }, + new Course + { + Id = 5, + Name = "Learn and Understand AngularJS", + AuthorId = 2, + FullPrice = 99, + Description = "Description for AngularJS", + Level = 2, + Tags = new Collection() + { + tags["angularjs"] + } + }, + new Course + { + Id = 6, + Name = "Learn and Understand NodeJS", + AuthorId = 2, + FullPrice = 149, + Description = "Description for NodeJS", + Level = 2, + Tags = new Collection() + { + tags["nodejs"] + } + }, + new Course + { + Id = 7, + Name = "Programming for Complete Beginners", + AuthorId = 3, + FullPrice = 45, + Description = "Description for Programming for Beginners", + Level = 1, + Tags = new Collection() + { + tags["c#"] + } + }, + new Course + { + Id = 8, + Name = "A 16 Hour C# Course with Visual Studio 2013", + AuthorId = 4, + FullPrice = 150, + Description = "Description 16 Hour Course", + Level = 1, + Tags = new Collection() + { + tags["c#"] + } + }, + new Course + { + Id = 9, + Name = "Learn JavaScript Through Visual Studio 2013", + AuthorId = 4, + FullPrice = 20, + Description = "Description Learn Javascript", + Level = 1, + Tags = new Collection() + { + tags["javascript"] + } + } + }; + + foreach (var course in courses) + context.Courses.AddOrUpdate(c => c.Id, course); + #endregion + } + } +} diff --git a/Queries/PlutoContext.cs b/Queries/PlutoContext.cs new file mode 100644 index 0000000..b73e0be --- /dev/null +++ b/Queries/PlutoContext.cs @@ -0,0 +1,22 @@ +using System.Data.Entity; +using Queries.EntityConfigurations; + +namespace Queries +{ + public class PlutoContext : DbContext + { + public PlutoContext() + : base("name=PlutoContext") + { + } + + public virtual DbSet Authors { get; set; } + public virtual DbSet Courses { get; set; } + public virtual DbSet Tags { get; set; } + + protected override void OnModelCreating(DbModelBuilder modelBuilder) + { + modelBuilder.Configurations.Add(new CourseConfiguration()); + } + } +} diff --git a/Queries/Program.cs b/Queries/Program.cs new file mode 100644 index 0000000..33a0d4f --- /dev/null +++ b/Queries/Program.cs @@ -0,0 +1,10 @@ + +namespace Queries +{ + class Program + { + static void Main(string[] args) + { + } + } +} diff --git a/Queries/Properties/AssemblyInfo.cs b/Queries/Properties/AssemblyInfo.cs new file mode 100644 index 0000000..23f6014 --- /dev/null +++ b/Queries/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("Queries")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("Queries")] +[assembly: AssemblyCopyright("Copyright © 2015")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("0485f195-b128-4fd3-84d9-01e25288bf61")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/Queries/Queries.csproj b/Queries/Queries.csproj new file mode 100644 index 0000000..9bb846e --- /dev/null +++ b/Queries/Queries.csproj @@ -0,0 +1,82 @@ + + + + + Debug + AnyCPU + {D1776DED-C59A-4F8A-8C31-96EAE15BDF5A} + Exe + Properties + Queries + Queries + v4.5 + 512 + + + AnyCPU + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + AnyCPU + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + ..\packages\EntityFramework.6.1.3\lib\net45\EntityFramework.dll + + + ..\packages\EntityFramework.6.1.3\lib\net45\EntityFramework.SqlServer.dll + + + + + + + + + + + + + + + + + + 201510010029257_InitialMigration.cs + + + + + + + + + + + + + + 201510010029257_InitialMigration.cs + + + + + \ No newline at end of file diff --git a/Queries/Tag.cs b/Queries/Tag.cs new file mode 100644 index 0000000..06ef25b --- /dev/null +++ b/Queries/Tag.cs @@ -0,0 +1,18 @@ +using System.Collections.Generic; + +namespace Queries +{ + public class Tag + { + public Tag() + { + Courses = new HashSet(); + } + + public int Id { get; set; } + + public string Name { get; set; } + + public virtual ICollection Courses { get; set; } + } +} diff --git a/Queries/packages.config b/Queries/packages.config new file mode 100644 index 0000000..9e8db31 --- /dev/null +++ b/Queries/packages.config @@ -0,0 +1,4 @@ + + + + \ No newline at end of file