diff --git a/JavaScriptServices.sln b/JavaScriptServices.sln index a560cb2..e401470 100644 --- a/JavaScriptServices.sln +++ b/JavaScriptServices.sln @@ -1,7 +1,7 @@  Microsoft Visual Studio Solution File, Format Version 12.00 # Visual Studio 15 -VisualStudioVersion = 15.0.26228.4 +VisualStudioVersion = 15.0.26430.4 MinimumVisualStudioVersion = 10.0.40219.1 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{27304DDE-AFB2-4F8B-B765-E3E2F11E886C}" EndProject @@ -11,10 +11,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.NodeSe EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.SpaServices", "src\Microsoft.AspNetCore.SpaServices\Microsoft.AspNetCore.SpaServices.csproj", "{66B071A8-EFC8-4A06-BEF6-06B99AE27EEC}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.AngularServices", "src\Microsoft.AspNetCore.AngularServices\Microsoft.AspNetCore.AngularServices.csproj", "{58AAABB6-9D21-42F6-BC97-3DD282B55FD6}" -EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AspNetCore.ReactServices", "src\Microsoft.AspNetCore.ReactServices\Microsoft.AspNetCore.ReactServices.csproj", "{F1081B9A-8D67-4A5E-80C6-615F9A975D4F}" -EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "misc", "misc", "{99EAF1FE-22C8-4526-BE78-74B24125D37F}" ProjectSection(SolutionItems) = preProject .gitignore = .gitignore @@ -32,16 +28,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Webpack", "samples\misc\Web EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NodeServicesExamples", "samples\misc\NodeServicesExamples\NodeServicesExamples.csproj", "{93EFCC5F-C6EE-4623-894F-A42B22C0B6FE}" EndProject -Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "angular", "angular", "{B54435EB-D5E8-4CEC-A02E-DDCB0C750E34}" -EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "MusicStore", "samples\angular\MusicStore\MusicStore.csproj", "{63FC66E7-559B-4426-93E1-2D951EFC8293}" -EndProject -Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "react", "react", "{BD77E73E-13BC-4550-99DA-51869BD8DFC4}" -EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ReactGrid", "samples\react\ReactGrid\ReactGrid.csproj", "{3B023106-88DB-4C3A-B01F-C1AECB02D80B}" -EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "MusicStore", "samples\react\MusicStore\MusicStore.csproj", "{6E898586-79CA-4AA8-946E-943B3682F376}" -EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "templates", "templates", "{1598B415-73F1-4B37-B3B4-0A10677ABB2D}" EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "KnockoutSpa", "templates\KnockoutSpa\KnockoutSpa.csproj", "{F60248B1-940E-43FB-BEA0-589362AA6320}" @@ -54,8 +40,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ReactSpa", "templates\React EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ReactReduxSpa", "templates\ReactReduxSpa\ReactReduxSpa.csproj", "{9D4D15A1-A25B-44EC-AB63-F1CE9986712E}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "WebApplicationBasic", "templates\WebApplicationBasic\WebApplicationBasic.csproj", "{86911E07-C733-4C18-B49F-9A007A651246}" -EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "build", "build", "{E415FE14-13B0-469F-836D-95059E6BAA6E}" ProjectSection(SolutionItems) = preProject src\build\common.props = src\build\common.props @@ -82,14 +66,6 @@ Global {66B071A8-EFC8-4A06-BEF6-06B99AE27EEC}.Debug|Any CPU.Build.0 = Debug|Any CPU {66B071A8-EFC8-4A06-BEF6-06B99AE27EEC}.Release|Any CPU.ActiveCfg = Release|Any CPU {66B071A8-EFC8-4A06-BEF6-06B99AE27EEC}.Release|Any CPU.Build.0 = Release|Any CPU - {58AAABB6-9D21-42F6-BC97-3DD282B55FD6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {58AAABB6-9D21-42F6-BC97-3DD282B55FD6}.Debug|Any CPU.Build.0 = Debug|Any CPU - {58AAABB6-9D21-42F6-BC97-3DD282B55FD6}.Release|Any CPU.ActiveCfg = Release|Any CPU - {58AAABB6-9D21-42F6-BC97-3DD282B55FD6}.Release|Any CPU.Build.0 = Release|Any CPU - {F1081B9A-8D67-4A5E-80C6-615F9A975D4F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {F1081B9A-8D67-4A5E-80C6-615F9A975D4F}.Debug|Any CPU.Build.0 = Debug|Any CPU - {F1081B9A-8D67-4A5E-80C6-615F9A975D4F}.Release|Any CPU.ActiveCfg = Release|Any CPU - {F1081B9A-8D67-4A5E-80C6-615F9A975D4F}.Release|Any CPU.Build.0 = Release|Any CPU {1931B19A-EC42-4D56-B2D0-FB06D17244DA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {1931B19A-EC42-4D56-B2D0-FB06D17244DA}.Debug|Any CPU.Build.0 = Debug|Any CPU {1931B19A-EC42-4D56-B2D0-FB06D17244DA}.Release|Any CPU.ActiveCfg = Release|Any CPU @@ -102,18 +78,6 @@ Global {93EFCC5F-C6EE-4623-894F-A42B22C0B6FE}.Debug|Any CPU.Build.0 = Debug|Any CPU {93EFCC5F-C6EE-4623-894F-A42B22C0B6FE}.Release|Any CPU.ActiveCfg = Release|Any CPU {93EFCC5F-C6EE-4623-894F-A42B22C0B6FE}.Release|Any CPU.Build.0 = Release|Any CPU - {63FC66E7-559B-4426-93E1-2D951EFC8293}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {63FC66E7-559B-4426-93E1-2D951EFC8293}.Debug|Any CPU.Build.0 = Debug|Any CPU - {63FC66E7-559B-4426-93E1-2D951EFC8293}.Release|Any CPU.ActiveCfg = Release|Any CPU - {63FC66E7-559B-4426-93E1-2D951EFC8293}.Release|Any CPU.Build.0 = Release|Any CPU - {3B023106-88DB-4C3A-B01F-C1AECB02D80B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {3B023106-88DB-4C3A-B01F-C1AECB02D80B}.Debug|Any CPU.Build.0 = Debug|Any CPU - {3B023106-88DB-4C3A-B01F-C1AECB02D80B}.Release|Any CPU.ActiveCfg = Release|Any CPU - {3B023106-88DB-4C3A-B01F-C1AECB02D80B}.Release|Any CPU.Build.0 = Release|Any CPU - {6E898586-79CA-4AA8-946E-943B3682F376}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {6E898586-79CA-4AA8-946E-943B3682F376}.Debug|Any CPU.Build.0 = Debug|Any CPU - {6E898586-79CA-4AA8-946E-943B3682F376}.Release|Any CPU.ActiveCfg = Release|Any CPU - {6E898586-79CA-4AA8-946E-943B3682F376}.Release|Any CPU.Build.0 = Release|Any CPU {F60248B1-940E-43FB-BEA0-589362AA6320}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {F60248B1-940E-43FB-BEA0-589362AA6320}.Debug|Any CPU.Build.0 = Debug|Any CPU {F60248B1-940E-43FB-BEA0-589362AA6320}.Release|Any CPU.ActiveCfg = Release|Any CPU @@ -134,10 +98,6 @@ Global {9D4D15A1-A25B-44EC-AB63-F1CE9986712E}.Debug|Any CPU.Build.0 = Debug|Any CPU {9D4D15A1-A25B-44EC-AB63-F1CE9986712E}.Release|Any CPU.ActiveCfg = Release|Any CPU {9D4D15A1-A25B-44EC-AB63-F1CE9986712E}.Release|Any CPU.Build.0 = Release|Any CPU - {86911E07-C733-4C18-B49F-9A007A651246}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {86911E07-C733-4C18-B49F-9A007A651246}.Debug|Any CPU.Build.0 = Debug|Any CPU - {86911E07-C733-4C18-B49F-9A007A651246}.Release|Any CPU.ActiveCfg = Release|Any CPU - {86911E07-C733-4C18-B49F-9A007A651246}.Release|Any CPU.Build.0 = Release|Any CPU {49D7665A-20EC-43FC-B8E8-EA0204F2D8C3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {49D7665A-20EC-43FC-B8E8-EA0204F2D8C3}.Debug|Any CPU.Build.0 = Debug|Any CPU {49D7665A-20EC-43FC-B8E8-EA0204F2D8C3}.Release|Any CPU.ActiveCfg = Release|Any CPU @@ -150,24 +110,15 @@ Global {66B77203-1469-41DF-92F2-2BE6900BD36F} = {27304DDE-AFB2-4F8B-B765-E3E2F11E886C} {F46DEF99-6FAA-4406-B5D8-6FF34EF669E3} = {27304DDE-AFB2-4F8B-B765-E3E2F11E886C} {66B071A8-EFC8-4A06-BEF6-06B99AE27EEC} = {27304DDE-AFB2-4F8B-B765-E3E2F11E886C} - {58AAABB6-9D21-42F6-BC97-3DD282B55FD6} = {27304DDE-AFB2-4F8B-B765-E3E2F11E886C} - {F1081B9A-8D67-4A5E-80C6-615F9A975D4F} = {27304DDE-AFB2-4F8B-B765-E3E2F11E886C} {E6A161EA-646C-4033-9090-95BE809AB8D9} = {23836492-E7F4-4376-85BF-A635C304AC46} {1931B19A-EC42-4D56-B2D0-FB06D17244DA} = {E6A161EA-646C-4033-9090-95BE809AB8D9} {DE479DC3-1461-4EAD-A188-4AF7AA4AE344} = {E6A161EA-646C-4033-9090-95BE809AB8D9} {93EFCC5F-C6EE-4623-894F-A42B22C0B6FE} = {E6A161EA-646C-4033-9090-95BE809AB8D9} - {B54435EB-D5E8-4CEC-A02E-DDCB0C750E34} = {23836492-E7F4-4376-85BF-A635C304AC46} - {63FC66E7-559B-4426-93E1-2D951EFC8293} = {B54435EB-D5E8-4CEC-A02E-DDCB0C750E34} - {BD77E73E-13BC-4550-99DA-51869BD8DFC4} = {23836492-E7F4-4376-85BF-A635C304AC46} - {3B023106-88DB-4C3A-B01F-C1AECB02D80B} = {BD77E73E-13BC-4550-99DA-51869BD8DFC4} - {6E898586-79CA-4AA8-946E-943B3682F376} = {BD77E73E-13BC-4550-99DA-51869BD8DFC4} {F60248B1-940E-43FB-BEA0-589362AA6320} = {1598B415-73F1-4B37-B3B4-0A10677ABB2D} {4D4B84C9-13F7-40CA-B05A-DC98FD6019AC} = {1598B415-73F1-4B37-B3B4-0A10677ABB2D} {4D57B6E1-7141-48ED-959E-872BDD4A2F72} = {1598B415-73F1-4B37-B3B4-0A10677ABB2D} {868A630E-C61B-4807-B7A8-7EB53BE1C28A} = {1598B415-73F1-4B37-B3B4-0A10677ABB2D} {9D4D15A1-A25B-44EC-AB63-F1CE9986712E} = {1598B415-73F1-4B37-B3B4-0A10677ABB2D} - {86911E07-C733-4C18-B49F-9A007A651246} = {1598B415-73F1-4B37-B3B4-0A10677ABB2D} - {E415FE14-13B0-469F-836D-95059E6BAA6E} = {27304DDE-AFB2-4F8B-B765-E3E2F11E886C} {49D7665A-20EC-43FC-B8E8-EA0204F2D8C3} = {1598B415-73F1-4B37-B3B4-0A10677ABB2D} EndGlobalSection EndGlobal diff --git a/samples/angular/MusicStore/.gitignore b/samples/angular/MusicStore/.gitignore deleted file mode 100644 index a31c74a..0000000 --- a/samples/angular/MusicStore/.gitignore +++ /dev/null @@ -1,9 +0,0 @@ -/node_modules/ -/wwwroot/lib/ -/wwwroot/ng-app/**/*.js -/music-db.sqlite -/Properties/launchSettings.json - -# Obviously you don't really want your DB to go in wwwroot, but due to https://github.com/aspnet/Microsoft.Data.Sqlite/issues/188 -# it currently does when run from IIS Express. Will resolve this once RC2 is out, which is supposed to eliminate the inconsistency. -/wwwroot/music-db.sqlite diff --git a/samples/angular/MusicStore/Apis/AlbumsApiController.cs b/samples/angular/MusicStore/Apis/AlbumsApiController.cs deleted file mode 100644 index 3b98a1e..0000000 --- a/samples/angular/MusicStore/Apis/AlbumsApiController.cs +++ /dev/null @@ -1,216 +0,0 @@ -using System.ComponentModel.DataAnnotations; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Authorization; -using Microsoft.AspNetCore.Mvc; -using Microsoft.EntityFrameworkCore; -using AutoMapper; -using MusicStore.Models; -using MusicStore.Infrastructure; - -namespace MusicStore.Apis -{ - [Route("api/albums")] - public class AlbumsApiController : Controller - { - private readonly MusicStoreContext _storeContext; - - public AlbumsApiController(MusicStoreContext storeContext) - { - _storeContext = storeContext; - } - - [HttpGet] - [NoCache] - public async Task Paged(int page = 1, int pageSize = 50, string sortBy = null) - { - await _storeContext.Genres.LoadAsync(); - await _storeContext.Artists.LoadAsync(); - - var albums = await _storeContext.Albums - .Include(a => a.Genre) - .Include(a => a.Artist) - .ToPagedListAsync(page, pageSize, sortBy, - a => a.Title, // sortExpression - SortDirection.Ascending, // defaultSortDirection - a => Mapper.Map(a, new AlbumResultDto())); // selector - - return Json(albums); - } - - [HttpGet("all")] - [NoCache] - public async Task All() - { - var albums = await _storeContext.Albums - .Include(a => a.Genre) - .Include(a => a.Artist) - .OrderBy(a => a.Title) - .ToListAsync(); - - return Json(albums.Select(a => Mapper.Map(a, new AlbumResultDto()))); - } - - [HttpGet("mostPopular")] - [NoCache] - public async Task MostPopular(int count = 6) - { - count = count > 0 && count < 20 ? count : 6; - var albums = await _storeContext.Albums - .OrderByDescending(a => a.OrderDetails.Count()) - .Take(count) - .ToListAsync(); - - // TODO: Move the .Select() to end of albums query when EF supports it - return Json(albums.Select(a => Mapper.Map(a, new AlbumResultDto()))); - } - - [HttpGet("{albumId:int}")] - [NoCache] - public async Task Details(int albumId) - { - await _storeContext.Genres.LoadAsync(); - await _storeContext.Artists.LoadAsync(); - - var album = await _storeContext.Albums - .Include(a => a.Artist) - .Include(a => a.Genre) - .Where(a => a.AlbumId == albumId) - .SingleOrDefaultAsync(); - - var albumResult = Mapper.Map(album, new AlbumResultDto()); - - // TODO: Add null checking and return 404 in that case - - return Json(albumResult); - } - - [HttpPost] - [Authorize("app-ManageStore")] - public async Task CreateAlbum([FromBody]AlbumChangeDto album) - { - if (!ModelState.IsValid) - { - // Return the model errors - return BadRequest(ModelState); - } - - // Save the changes to the DB - var dbAlbum = new Album(); - _storeContext.Albums.Add(Mapper.Map(album, dbAlbum)); - await _storeContext.SaveChangesAsync(); - - // TODO: Handle missing record, key violations, concurrency issues, etc. - - return new ObjectResult(new { - Data = dbAlbum.AlbumId, - Message = "Album created successfully." - }); - } - - [HttpPut("{albumId:int}/update")] - public async Task UpdateAlbum(int albumId, [FromBody] AlbumChangeDto album) - { - if (!ModelState.IsValid) - { - // Return the model errors - return BadRequest(ModelState); - } - - var dbAlbum = await _storeContext.Albums.SingleOrDefaultAsync(a => a.AlbumId == albumId); - - if (dbAlbum == null) - { - return new ObjectResult(new { - Message = string.Format("The album with ID {0} was not found.", albumId) - }) { StatusCode = 404 }; - } - - // Save the changes to the DB - Mapper.Map(album, dbAlbum); - await _storeContext.SaveChangesAsync(); - - // TODO: Handle missing record, key violations, concurrency issues, etc. - - return new ObjectResult (new { - Message = "Album updated successfully." - }); - } - - [HttpDelete("{albumId:int}")] - [Authorize("app-ManageStore")] - public async Task DeleteAlbum(int albumId) - { - var album = await _storeContext.Albums.SingleOrDefaultAsync(a => a.AlbumId == albumId); - - if (album != null) - { - _storeContext.Albums.Remove(album); - - // Save the changes to the DB - await _storeContext.SaveChangesAsync(); - - // TODO: Handle missing record, key violations, concurrency issues, etc. - } - - return new ObjectResult (new { - Message = "Album deleted successfully." - }); - } - } - - [ModelMetadataType(typeof(Album))] - public class AlbumChangeDto : IValidatableObject - { - public int GenreId { get; set; } - - public int ArtistId { get; set; } - - public string Title { get; set; } - - public decimal Price { get; set; } - - public string AlbumArtUrl { get; set; } - - public IEnumerable Validate(ValidationContext validationContext) - { - // An example of object-level (i.e., multi-property) validation - if (this.GenreId == 13 /* Indie */) { - switch (SentimentAnalysis.GetSentiment(Title)) { - case SentimentAnalysis.SentimentResult.Positive: - yield return new ValidationResult("Sounds too positive. Indie music requires more ambiguity."); - break; - case SentimentAnalysis.SentimentResult.Negative: - yield return new ValidationResult("Sounds too negative. Indie music requires more ambiguity."); - break; - } - } - } - } - - public class AlbumResultDto : AlbumChangeDto - { - public AlbumResultDto() - { - Artist = new ArtistResultDto(); - Genre = new GenreResultDto(); - } - - public int AlbumId { get; set; } - - public ArtistResultDto Artist { get; private set; } - - public GenreResultDto Genre { get; private set; } - } - - public class ArtistResultDto - { - public string Name { get; set; } - } - - public class GenreResultDto - { - public string Name { get; set; } - } -} diff --git a/samples/angular/MusicStore/Apis/ArtistsApiController.cs b/samples/angular/MusicStore/Apis/ArtistsApiController.cs deleted file mode 100644 index f3568ae..0000000 --- a/samples/angular/MusicStore/Apis/ArtistsApiController.cs +++ /dev/null @@ -1,30 +0,0 @@ -using System; -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Mvc; -using Microsoft.EntityFrameworkCore; -using MusicStore.Models; - -namespace MusicStore.Apis -{ - [Route("api/artists")] - public class ArtistsApiController : Controller - { - private readonly MusicStoreContext _storeContext; - - public ArtistsApiController(MusicStoreContext storeContext) - { - _storeContext = storeContext; - } - - [HttpGet("lookup")] - public async Task Lookup() - { - var artists = await _storeContext.Artists - .OrderBy(a => a.Name) - .ToListAsync(); - - return Json(artists); - } - } -} diff --git a/samples/angular/MusicStore/Apis/GenresApiController.cs b/samples/angular/MusicStore/Apis/GenresApiController.cs deleted file mode 100644 index 338ca2f..0000000 --- a/samples/angular/MusicStore/Apis/GenresApiController.cs +++ /dev/null @@ -1,70 +0,0 @@ -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Mvc; -using Microsoft.EntityFrameworkCore; -using MusicStore.Models; -using MusicStore.Infrastructure; - -namespace MusicStore.Apis -{ - [Route("api/genres")] - public class GenresApiController : Controller - { - private readonly MusicStoreContext _storeContext; - - public GenresApiController(MusicStoreContext storeContext) - { - _storeContext = storeContext; - } - - [HttpGet] - public async Task GenreList() - { - var genres = await _storeContext.Genres - //.Include(g => g.Albums) - .OrderBy(g => g.Name) - .ToListAsync(); - - return Json(genres); - } - - [HttpGet("genre-lookup")] - public async Task Lookup() - { - var genres = await _storeContext.Genres - .Select(g => new { g.GenreId, g.Name }) - .ToListAsync(); - - return Json(genres); - } - - [HttpGet("menu")] - public async Task GenreMenuList(int count = 9) - { - count = count > 0 && count < 20 ? count : 9; - - var genres = await _storeContext.Genres - .OrderByDescending(g => - g.Albums.Sum(a => - a.OrderDetails.Sum(od => od.Quantity))) - .Take(count) - .ToListAsync(); - - return Json(genres); - } - - [HttpGet("{genreId:int}/albums")] - [NoCache] - public async Task GenreAlbums(int genreId) - { - var albums = await _storeContext.Albums - .Where(a => a.GenreId == genreId) - //.Include(a => a.Genre) - //.Include(a => a.Artist) - //.OrderBy(a => a.Genre.Name) - .ToListAsync(); - - return Json(albums); - } - } -} diff --git a/samples/angular/MusicStore/Apis/Models/AccountViewModels.cs b/samples/angular/MusicStore/Apis/Models/AccountViewModels.cs deleted file mode 100644 index 831978a..0000000 --- a/samples/angular/MusicStore/Apis/Models/AccountViewModels.cs +++ /dev/null @@ -1,63 +0,0 @@ -using System.ComponentModel.DataAnnotations; - -namespace MusicStore.Models -{ - public class ExternalLoginConfirmationViewModel - { - [Required] - [Display(Name = "User name")] - public string UserName { get; set; } - } - - public class ManageUserViewModel - { - [Required] - [DataType(DataType.Password)] - [Display(Name = "Current password")] - public string OldPassword { get; set; } - - [Required] - [StringLength(100, ErrorMessage = "The {0} must be at least {2} characters long.", MinimumLength = 6)] - [DataType(DataType.Password)] - [Display(Name = "New password")] - public string NewPassword { get; set; } - - [DataType(DataType.Password)] - [Display(Name = "Confirm new password")] - [Compare("NewPassword", ErrorMessage = "The new password and confirmation password do not match.")] - public string ConfirmPassword { get; set; } - } - - public class LoginViewModel - { - [Required] - [Display(Name = "User name")] - public string UserName { get; set; } - - [Required] - [DataType(DataType.Password)] - [Display(Name = "Password")] - public string Password { get; set; } - - [Display(Name = "Remember me?")] - public bool RememberMe { get; set; } - } - - public class RegisterViewModel - { - [Required] - [Display(Name = "User name")] - public string UserName { get; set; } - - [Required] - [StringLength(100, ErrorMessage = "The {0} must be at least {2} characters long.", MinimumLength = 6)] - [DataType(DataType.Password)] - [Display(Name = "Password")] - public string Password { get; set; } - - [DataType(DataType.Password)] - [Display(Name = "Confirm password")] - [Compare("Password", ErrorMessage = "The password and confirmation password do not match.")] - public string ConfirmPassword { get; set; } - } -} diff --git a/samples/angular/MusicStore/Apis/Models/Album.cs b/samples/angular/MusicStore/Apis/Models/Album.cs deleted file mode 100644 index b4495f3..0000000 --- a/samples/angular/MusicStore/Apis/Models/Album.cs +++ /dev/null @@ -1,40 +0,0 @@ -using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; - -namespace MusicStore.Models -{ - public class Album - { - public Album() - { - // TODO: Temporary hack to populate the orderdetails until EF does this automatically. - OrderDetails = new List(); - } - - [ScaffoldColumn(false)] - public int AlbumId { get; set; } - - public int GenreId { get; set; } - - public int ArtistId { get; set; } - - [Required] - [StringLength(160, MinimumLength = 2)] - public string Title { get; set; } - - [Required] - [RangeAttribute(typeof(decimal), "0.01", "100")] // Long-form constructor to work around https://github.com/dotnet/coreclr/issues/2172 - [DataType(DataType.Currency)] - public decimal Price { get; set; } - - [Display(Name = "Album Art URL")] - [StringLength(1024)] - public string AlbumArtUrl { get; set; } - - public virtual Genre Genre { get; set; } - - public virtual Artist Artist { get; set; } - - public virtual ICollection OrderDetails { get; set; } - } -} diff --git a/samples/angular/MusicStore/Apis/Models/Artist.cs b/samples/angular/MusicStore/Apis/Models/Artist.cs deleted file mode 100644 index b364a89..0000000 --- a/samples/angular/MusicStore/Apis/Models/Artist.cs +++ /dev/null @@ -1,12 +0,0 @@ -using System.ComponentModel.DataAnnotations; - -namespace MusicStore.Models -{ - public class Artist - { - public int ArtistId { get; set; } - - [Required] - public string Name { get; set; } - } -} diff --git a/samples/angular/MusicStore/Apis/Models/CartItem.cs b/samples/angular/MusicStore/Apis/Models/CartItem.cs deleted file mode 100644 index 7209462..0000000 --- a/samples/angular/MusicStore/Apis/Models/CartItem.cs +++ /dev/null @@ -1,21 +0,0 @@ -using System; -using System.ComponentModel.DataAnnotations; - -namespace MusicStore.Models -{ - public class CartItem - { - [Key] - public int CartItemId { get; set; } - - [Required] - public string CartId { get; set; } - public int AlbumId { get; set; } - public int Count { get; set; } - - [DataType(DataType.DateTime)] - public DateTime DateCreated { get; set; } - - public virtual Album Album { get; set; } - } -} diff --git a/samples/angular/MusicStore/Apis/Models/Genre.cs b/samples/angular/MusicStore/Apis/Models/Genre.cs deleted file mode 100644 index eed5616..0000000 --- a/samples/angular/MusicStore/Apis/Models/Genre.cs +++ /dev/null @@ -1,24 +0,0 @@ -using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; -using Newtonsoft.Json; - -namespace MusicStore.Models -{ - public class Genre - { - public Genre() - { - Albums = new List(); - } - - public int GenreId { get; set; } - - [Required] - public string Name { get; set; } - - public string Description { get; set; } - - [JsonIgnore] - public virtual ICollection Albums { get; set; } - } -} diff --git a/samples/angular/MusicStore/Apis/Models/MusicStoreContext.cs b/samples/angular/MusicStore/Apis/Models/MusicStoreContext.cs deleted file mode 100644 index aee7aed..0000000 --- a/samples/angular/MusicStore/Apis/Models/MusicStoreContext.cs +++ /dev/null @@ -1,34 +0,0 @@ -using Microsoft.AspNetCore.Identity.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore; - -namespace MusicStore.Models -{ - public class ApplicationUser : IdentityUser { } - - public class MusicStoreContext : IdentityDbContext - { - public MusicStoreContext(DbContextOptions options) : base(options) - { - } - - public DbSet Albums { get; set; } - public DbSet Artists { get; set; } - public DbSet Orders { get; set; } - public DbSet Genres { get; set; } - public DbSet CartItems { get; set; } - public DbSet OrderDetails { get; set; } - - protected override void OnModelCreating(ModelBuilder builder) - { - // Configure pluralization - builder.Entity().ToTable("Albums"); - builder.Entity().ToTable("Artists"); - builder.Entity().ToTable("Orders"); - builder.Entity().ToTable("Genres"); - builder.Entity().ToTable("CartItems"); - builder.Entity().ToTable("OrderDetails"); - - base.OnModelCreating(builder); - } - } -} diff --git a/samples/angular/MusicStore/Apis/Models/Order.cs b/samples/angular/MusicStore/Apis/Models/Order.cs deleted file mode 100644 index 110a77d..0000000 --- a/samples/angular/MusicStore/Apis/Models/Order.cs +++ /dev/null @@ -1,73 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; - -namespace MusicStore.Models -{ - //[Bind(Include = "FirstName,LastName,Address,City,State,PostalCode,Country,Phone,Email")] - public class Order - { - public Order() - { - OrderDetails = new List(); - } - - [ScaffoldColumn(false)] - public int OrderId { get; set; } - - [ScaffoldColumn(false)] - public DateTime OrderDate { get; set; } - - [Required] - [ScaffoldColumn(false)] - public string Username { get; set; } - - [Required] - [Display(Name = "First Name")] - [StringLength(160)] - public string FirstName { get; set; } - - [Required] - [Display(Name = "Last Name")] - [StringLength(160)] - public string LastName { get; set; } - - [Required] - [StringLength(70, MinimumLength = 3)] - public string Address { get; set; } - - [Required] - [StringLength(40)] - public string City { get; set; } - - [Required] - [StringLength(40)] - public string State { get; set; } - - [Required] - [Display(Name = "Postal Code")] - [StringLength(10, MinimumLength = 5)] - public string PostalCode { get; set; } - - [Required] - [StringLength(40)] - public string Country { get; set; } - - [Required] - [StringLength(24)] - [DataType(DataType.PhoneNumber)] - public string Phone { get; set; } - - [Required] - [Display(Name = "Email Address")] - [RegularExpression(@"[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,4}", - ErrorMessage = "Email is not valid.")] - [DataType(DataType.EmailAddress)] - public string Email { get; set; } - - [ScaffoldColumn(false)] - public decimal Total { get; set; } - - public ICollection OrderDetails { get; set; } - } -} diff --git a/samples/angular/MusicStore/Apis/Models/OrderDetail.cs b/samples/angular/MusicStore/Apis/Models/OrderDetail.cs deleted file mode 100644 index cb1e693..0000000 --- a/samples/angular/MusicStore/Apis/Models/OrderDetail.cs +++ /dev/null @@ -1,14 +0,0 @@ -namespace MusicStore.Models -{ - public class OrderDetail - { - public int OrderDetailId { get; set; } - public int OrderId { get; set; } - public int AlbumId { get; set; } - public int Quantity { get; set; } - public decimal UnitPrice { get; set; } - - public virtual Album Album { get; set; } - public virtual Order Order { get; set; } - } -} diff --git a/samples/angular/MusicStore/Apis/Models/SampleData.cs b/samples/angular/MusicStore/Apis/Models/SampleData.cs deleted file mode 100644 index b1d98a7..0000000 --- a/samples/angular/MusicStore/Apis/Models/SampleData.cs +++ /dev/null @@ -1,915 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Security.Claims; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Identity; -using Microsoft.AspNetCore.Identity.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore; -using Microsoft.Extensions.DependencyInjection; -using Microsoft.Extensions.Options; - -namespace MusicStore.Models -{ - public static class SampleData - { - const string imgUrl = "/images/placeholder.png"; - - public static async Task InitializeMusicStoreDatabaseAsync(IServiceProvider serviceProvider) - { - using (var db = serviceProvider.GetService()) - { - if (await db.Database.EnsureCreatedAsync()) - { - await InsertTestData(serviceProvider); - } - } - } - - private static async Task InsertTestData(IServiceProvider serviceProvider) - { - var albums = GetAlbums(imgUrl, Genres, Artists); - await AddOrUpdateAsync(serviceProvider, g => g.GenreId, Genres.Select(genre => genre.Value)); - await AddOrUpdateAsync(serviceProvider, a => a.ArtistId, Artists.Select(artist => artist.Value)); - await AddOrUpdateAsync(serviceProvider, a => a.AlbumId, albums); - } - - // TODO [EF] This may be replaced by a first class mechanism in EF - private static async Task AddOrUpdateAsync( - IServiceProvider serviceProvider, - Func propertyToMatch, IEnumerable entities) - where TEntity : class - { - // Query in a separate context so that we can attach existing entities as modified - List existingData; - - using (var scope = serviceProvider.GetRequiredService().CreateScope()) - using (var db = scope.ServiceProvider.GetService()) - { - existingData = db.Set().ToList(); - } - - using (var scope = serviceProvider.GetRequiredService().CreateScope()) - using (var db = scope.ServiceProvider.GetService()) - { - foreach (var item in entities) - { - db.Entry(item).State = existingData.Any(g => propertyToMatch(g).Equals(propertyToMatch(item))) - ? EntityState.Modified - : EntityState.Added; - } - - await db.SaveChangesAsync(); - } - } - - private static Album[] GetAlbums(string imgUrl, Dictionary genres, Dictionary artists) - { - var albums = new Album[] - { - new Album { Title = "The Best Of The Men At Work", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Men At Work"], AlbumArtUrl = imgUrl }, - new Album { Title = "...And Justice For All", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "עד גבול האור", Genre = genres["World"], Price = 8.99M, Artist = artists["אריק אינשטיין"], AlbumArtUrl = imgUrl }, - new Album { Title = "Black Light Syndrome", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Terry Bozzio, Tony Levin & Steve Stevens"], AlbumArtUrl = imgUrl }, - new Album { Title = "10,000 Days", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Tool"], AlbumArtUrl = imgUrl }, - new Album { Title = "11i", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Supreme Beings of Leisure"], AlbumArtUrl = imgUrl }, - new Album { Title = "1960", Genre = genres["Indie"], Price = 8.99M, Artist = artists["Soul-Junk"], AlbumArtUrl = imgUrl }, - new Album { Title = "4x4=12 ", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["deadmau5"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Copland Celebration, Vol. I", Genre = genres["Classical"], Price = 8.99M, Artist = artists["London Symphony Orchestra"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Lively Mind", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Paul Oakenfold"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Matter of Life and Death", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Real Dead One", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Real Live One", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Rush of Blood to the Head", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Coldplay"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Soprano Inspired", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Britten Sinfonia, Ivor Bolton & Lesley Garrett"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Winter Symphony", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Abbey Road", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Beatles"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ace Of Spades", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Motörhead"], AlbumArtUrl = imgUrl }, - new Album { Title = "Achtung Baby", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Acústico MTV", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Os Paralamas Do Sucesso"], AlbumArtUrl = imgUrl }, - new Album { Title = "Adams, John: The Chairman Dances", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Edo de Waart & San Francisco Symphony"], AlbumArtUrl = imgUrl }, - new Album { Title = "Adrenaline", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deftones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ænima", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Tool"], AlbumArtUrl = imgUrl }, - new Album { Title = "Afrociberdelia", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Chico Science & Nação Zumbi"], AlbumArtUrl = imgUrl }, - new Album { Title = "After the Goldrush", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Neil Young"], AlbumArtUrl = imgUrl }, - new Album { Title = "Airdrawn Dagger", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Sasha"], AlbumArtUrl = imgUrl }, - new Album { Title = "Album Title Goes Here", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["deadmau5"], AlbumArtUrl = imgUrl }, - new Album { Title = "Alcohol Fueled Brewtality Live! [Disc 1]", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Black Label Society"], AlbumArtUrl = imgUrl }, - new Album { Title = "Alcohol Fueled Brewtality Live! [Disc 2]", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Black Label Society"], AlbumArtUrl = imgUrl }, - new Album { Title = "Alive 2007", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Daft Punk"], AlbumArtUrl = imgUrl }, - new Album { Title = "All I Ask of You", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Amen (So Be It)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Paddy Casey"], AlbumArtUrl = imgUrl }, - new Album { Title = "Animal Vehicle", Genre = genres["Pop"], Price = 8.99M, Artist = artists["The Axis of Awesome"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ao Vivo [IMPORT]", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Zeca Pagodinho"], AlbumArtUrl = imgUrl }, - new Album { Title = "Apocalyptic Love", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Slash"], AlbumArtUrl = imgUrl }, - new Album { Title = "Appetite for Destruction", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Guns N' Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "Are You Experienced?", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Jimi Hendrix"], AlbumArtUrl = imgUrl }, - new Album { Title = "Arquivo II", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Os Paralamas Do Sucesso"], AlbumArtUrl = imgUrl }, - new Album { Title = "Arquivo Os Paralamas Do Sucesso", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Os Paralamas Do Sucesso"], AlbumArtUrl = imgUrl }, - new Album { Title = "A-Sides", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Soundgarden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Audioslave", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Audioslave"], AlbumArtUrl = imgUrl }, - new Album { Title = "Automatic for the People", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["R.E.M."], AlbumArtUrl = imgUrl }, - new Album { Title = "Axé Bahia 2001", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Various Artists"], AlbumArtUrl = imgUrl }, - new Album { Title = "Babel", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Mumford & Sons"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bach: Goldberg Variations", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Wilhelm Kempff"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bach: The Brandenburg Concertos", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Orchestra of The Age of Enlightenment"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bach: The Cello Suites", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Yo-Yo Ma"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bach: Toccata & Fugue in D Minor", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Ton Koopman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bad Motorfinger", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Soundgarden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Balls to the Wall", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Accept"], AlbumArtUrl = imgUrl }, - new Album { Title = "Banadeek Ta'ala", Genre = genres["World"], Price = 8.99M, Artist = artists["Amr Diab"], AlbumArtUrl = imgUrl }, - new Album { Title = "Barbie Girl", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Aqua"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bark at the Moon (Remastered)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bartok: Violin & Viola Concertos", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Yehudi Menuhin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Barulhinho Bom", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Marisa Monte"], AlbumArtUrl = imgUrl }, - new Album { Title = "BBC Sessions [Disc 1] [Live]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "BBC Sessions [Disc 2] [Live]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Be Here Now", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Oasis"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bedrock 11 Compiled & Mixed", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["John Digweed"], AlbumArtUrl = imgUrl }, - new Album { Title = "Berlioz: Symphonie Fantastique", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Michael Tilson Thomas"], AlbumArtUrl = imgUrl }, - new Album { Title = "Beyond Good And Evil", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Cult"], AlbumArtUrl = imgUrl }, - new Album { Title = "Big Bad Wolf ", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Armand Van Helden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Big Ones", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Aerosmith"], AlbumArtUrl = imgUrl }, - new Album { Title = "Black Album", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Black Sabbath Vol. 4 (Remaster)", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Black Sabbath"], AlbumArtUrl = imgUrl }, - new Album { Title = "Black Sabbath", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Black Sabbath"], AlbumArtUrl = imgUrl }, - new Album { Title = "Black", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Blackwater Park", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Opeth"], AlbumArtUrl = imgUrl }, - new Album { Title = "Blizzard of Ozz", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Blood", Genre = genres["Rock"], Price = 8.99M, Artist = artists["In This Moment"], AlbumArtUrl = imgUrl }, - new Album { Title = "Blue Moods", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Incognito"], AlbumArtUrl = imgUrl }, - new Album { Title = "Blue", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Weezer"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bongo Fury", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Frank Zappa & Captain Beefheart"], AlbumArtUrl = imgUrl }, - new Album { Title = "Boys & Girls", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Alabama Shakes"], AlbumArtUrl = imgUrl }, - new Album { Title = "Brave New World", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "B-Sides 1980-1990", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bunkka", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Paul Oakenfold"], AlbumArtUrl = imgUrl }, - new Album { Title = "By The Way", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Red Hot Chili Peppers"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cake: B-Sides and Rarities", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Cake"], AlbumArtUrl = imgUrl }, - new Album { Title = "Californication", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Red Hot Chili Peppers"], AlbumArtUrl = imgUrl }, - new Album { Title = "Carmina Burana", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Boston Symphony Orchestra & Seiji Ozawa"], AlbumArtUrl = imgUrl }, - new Album { Title = "Carried to Dust (Bonus Track Version)", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Calexico"], AlbumArtUrl = imgUrl }, - new Album { Title = "Carry On", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Chris Cornell"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cássia Eller - Sem Limite [Disc 1]", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Cássia Eller"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chemical Wedding", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Bruce Dickinson"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chill: Brazil (Disc 1)", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Marcos Valle"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chill: Brazil (Disc 2)", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Antônio Carlos Jobim"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chocolate Starfish And The Hot Dog Flavored Water", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Limp Bizkit"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chronicle, Vol. 1", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Creedence Clearwater Revival"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chronicle, Vol. 2", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Creedence Clearwater Revival"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ciao, Baby", Genre = genres["Rock"], Price = 8.99M, Artist = artists["TheStart"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cidade Negra - Hits", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Cidade Negra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Classic Munkle: Turbo Edition", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Munkle"], AlbumArtUrl = imgUrl }, - new Album { Title = "Classics: The Best of Sarah Brightman", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Coda", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Come Away With Me", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Norah Jones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Come Taste The Band", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Comfort Eagle", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Cake"], AlbumArtUrl = imgUrl }, - new Album { Title = "Common Reaction", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Uh Huh Her "], AlbumArtUrl = imgUrl }, - new Album { Title = "Compositores", Genre = genres["Rock"], Price = 8.99M, Artist = artists["O Terço"], AlbumArtUrl = imgUrl }, - new Album { Title = "Contraband", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Velvet Revolver"], AlbumArtUrl = imgUrl }, - new Album { Title = "Core", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Stone Temple Pilots"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cornerstone", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Styx"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cosmicolor", Genre = genres["Rap"], Price = 8.99M, Artist = artists["M-Flo"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cross", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Justice"], AlbumArtUrl = imgUrl }, - new Album { Title = "Culture of Fear", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Thievery Corporation"], AlbumArtUrl = imgUrl }, - new Album { Title = "Da Lama Ao Caos", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Chico Science & Nação Zumbi"], AlbumArtUrl = imgUrl }, - new Album { Title = "Dakshina", Genre = genres["World"], Price = 8.99M, Artist = artists["Deva Premal"], AlbumArtUrl = imgUrl }, - new Album { Title = "Dark Side of the Moon", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pink Floyd"], AlbumArtUrl = imgUrl }, - new Album { Title = "Death Magnetic", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Deep End of Down", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Above the Fold"], AlbumArtUrl = imgUrl }, - new Album { Title = "Deep Purple In Rock", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Deixa Entrar", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Falamansa"], AlbumArtUrl = imgUrl }, - new Album { Title = "Deja Vu", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Crosby, Stills, Nash, and Young"], AlbumArtUrl = imgUrl }, - new Album { Title = "Di Korpu Ku Alma", Genre = genres["World"], Price = 8.99M, Artist = artists["Lura"], AlbumArtUrl = imgUrl }, - new Album { Title = "Diary of a Madman (Remastered)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Diary of a Madman", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Dirt", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Alice in Chains"], AlbumArtUrl = imgUrl }, - new Album { Title = "Diver Down", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Van Halen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Djavan Ao Vivo - Vol. 02", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Djavan"], AlbumArtUrl = imgUrl }, - new Album { Title = "Djavan Ao Vivo - Vol. 1", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Djavan"], AlbumArtUrl = imgUrl }, - new Album { Title = "Drum'n'bass for Papa", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Plug"], AlbumArtUrl = imgUrl }, - new Album { Title = "Duluth", Genre = genres["Country"], Price = 8.99M, Artist = artists["Trampled By Turtles"], AlbumArtUrl = imgUrl }, - new Album { Title = "Dummy", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Portishead"], AlbumArtUrl = imgUrl }, - new Album { Title = "Duos II", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Luciana Souza/Romero Lubambo"], AlbumArtUrl = imgUrl }, - new Album { Title = "Earl Scruggs and Friends", Genre = genres["Country"], Price = 8.99M, Artist = artists["Earl Scruggs"], AlbumArtUrl = imgUrl }, - new Album { Title = "Eden", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "El Camino", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Black Keys"], AlbumArtUrl = imgUrl }, - new Album { Title = "Elegant Gypsy", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Al di Meola"], AlbumArtUrl = imgUrl }, - new Album { Title = "Elements Of Life", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Tiësto"], AlbumArtUrl = imgUrl }, - new Album { Title = "Elis Regina-Minha História", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Elis Regina"], AlbumArtUrl = imgUrl }, - new Album { Title = "Emergency On Planet Earth", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Jamiroquai"], AlbumArtUrl = imgUrl }, - new Album { Title = "Emotion", Genre = genres["World"], Price = 8.99M, Artist = artists["Papa Wemba"], AlbumArtUrl = imgUrl }, - new Album { Title = "English Renaissance", Genre = genres["Classical"], Price = 8.99M, Artist = artists["The King's Singers"], AlbumArtUrl = imgUrl }, - new Album { Title = "Every Kind of Light", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Posies"], AlbumArtUrl = imgUrl }, - new Album { Title = "Faceless", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Godsmack"], AlbumArtUrl = imgUrl }, - new Album { Title = "Facelift", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Alice in Chains"], AlbumArtUrl = imgUrl }, - new Album { Title = "Fair Warning", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Van Halen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Fear of a Black Planet", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Public Enemy"], AlbumArtUrl = imgUrl }, - new Album { Title = "Fear Of The Dark", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Feels Like Home", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Norah Jones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Fireball", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Fly", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "For Those About To Rock We Salute You", Genre = genres["Rock"], Price = 8.99M, Artist = artists["AC/DC"], AlbumArtUrl = imgUrl }, - new Album { Title = "Four", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Blues Traveler"], AlbumArtUrl = imgUrl }, - new Album { Title = "Frank", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Amy Winehouse"], AlbumArtUrl = imgUrl }, - new Album { Title = "Further Down the Spiral", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Nine Inch Nails"], AlbumArtUrl = imgUrl }, - new Album { Title = "Garage Inc. (Disc 1)", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Garage Inc. (Disc 2)", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Garbage", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Garbage"], AlbumArtUrl = imgUrl }, - new Album { Title = "Good News For People Who Love Bad News", Genre = genres["Indie"], Price = 8.99M, Artist = artists["Modest Mouse"], AlbumArtUrl = imgUrl }, - new Album { Title = "Gordon", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Barenaked Ladies"], AlbumArtUrl = imgUrl }, - new Album { Title = "Górecki: Symphony No. 3", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Adrian Leaper & Doreen de Feis"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Hits I", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Queen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Hits II", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Queen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Hits", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Duck Sauce"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Hits", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Lenny Kravitz"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Hits", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Lenny Kravitz"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Kiss", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Kiss"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greetings from Michigan", Genre = genres["Indie"], Price = 8.99M, Artist = artists["Sufjan Stevens"], AlbumArtUrl = imgUrl }, - new Album { Title = "Group Therapy", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Above & Beyond"], AlbumArtUrl = imgUrl }, - new Album { Title = "Handel: The Messiah (Highlights)", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Scholars Baroque Ensemble"], AlbumArtUrl = imgUrl }, - new Album { Title = "Haydn: Symphonies 99 - 104", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Royal Philharmonic Orchestra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Heart of the Night", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Spyro Gyra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Heart On", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Eagles of Death Metal"], AlbumArtUrl = imgUrl }, - new Album { Title = "Holy Diver", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Dio"], AlbumArtUrl = imgUrl }, - new Album { Title = "Homework", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Daft Punk"], AlbumArtUrl = imgUrl }, - new Album { Title = "Hot Rocks, 1964-1971 (Disc 1)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Rolling Stones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Houses Of The Holy", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "How To Dismantle An Atomic Bomb", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Human", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Projected"], AlbumArtUrl = imgUrl }, - new Album { Title = "Hunky Dory", Genre = genres["Rock"], Price = 8.99M, Artist = artists["David Bowie"], AlbumArtUrl = imgUrl }, - new Album { Title = "Hymns", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Projected"], AlbumArtUrl = imgUrl }, - new Album { Title = "Hysteria", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Def Leppard"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Absentia", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Porcupine Tree"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Between", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Paul Van Dyk"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Rainbows", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Radiohead"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Step", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Stevie Ray Vaughan & Double Trouble"], AlbumArtUrl = imgUrl }, - new Album { Title = "In the court of the Crimson King", Genre = genres["Rock"], Price = 8.99M, Artist = artists["King Crimson"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Through The Out Door", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Your Honor [Disc 1]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Foo Fighters"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Your Honor [Disc 2]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Foo Fighters"], AlbumArtUrl = imgUrl }, - new Album { Title = "Indestructible", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Rancid"], AlbumArtUrl = imgUrl }, - new Album { Title = "Infinity", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Journey"], AlbumArtUrl = imgUrl }, - new Album { Title = "Into The Light", Genre = genres["Rock"], Price = 8.99M, Artist = artists["David Coverdale"], AlbumArtUrl = imgUrl }, - new Album { Title = "Introspective", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Pet Shop Boys"], AlbumArtUrl = imgUrl }, - new Album { Title = "Iron Maiden", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "ISAM", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Amon Tobin"], AlbumArtUrl = imgUrl }, - new Album { Title = "IV", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Jagged Little Pill", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Alanis Morissette"], AlbumArtUrl = imgUrl }, - new Album { Title = "Jagged Little Pill", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Alanis Morissette"], AlbumArtUrl = imgUrl }, - new Album { Title = "Jorge Ben Jor 25 Anos", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Jorge Ben"], AlbumArtUrl = imgUrl }, - new Album { Title = "Jota Quest-1995", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Jota Quest"], AlbumArtUrl = imgUrl }, - new Album { Title = "Kick", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["INXS"], AlbumArtUrl = imgUrl }, - new Album { Title = "Kill 'Em All", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Kind of Blue", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Miles Davis"], AlbumArtUrl = imgUrl }, - new Album { Title = "King For A Day Fool For A Lifetime", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Faith No More"], AlbumArtUrl = imgUrl }, - new Album { Title = "Kiss", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Carly Rae Jepsen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Last Call", Genre = genres["Country"], Price = 8.99M, Artist = artists["Cayouche"], AlbumArtUrl = imgUrl }, - new Album { Title = "Le Freak", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Chic"], AlbumArtUrl = imgUrl }, - new Album { Title = "Le Tigre", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Le Tigre"], AlbumArtUrl = imgUrl }, - new Album { Title = "Led Zeppelin I", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Led Zeppelin II", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Led Zeppelin III", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Let There Be Rock", Genre = genres["Rock"], Price = 8.99M, Artist = artists["AC/DC"], AlbumArtUrl = imgUrl }, - new Album { Title = "Little Earthquakes", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Tori Amos"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live [Disc 1]", Genre = genres["Blues"], Price = 8.99M, Artist = artists["The Black Crowes"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live [Disc 2]", Genre = genres["Blues"], Price = 8.99M, Artist = artists["The Black Crowes"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live After Death", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live At Donington 1992 (Disc 1)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live At Donington 1992 (Disc 2)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live on Earth", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["The Cat Empire"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live On Two Legs [Live]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pearl Jam"], AlbumArtUrl = imgUrl }, - new Album { Title = "Living After Midnight", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Judas Priest"], AlbumArtUrl = imgUrl }, - new Album { Title = "Living", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Paddy Casey"], AlbumArtUrl = imgUrl }, - new Album { Title = "Load", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Love Changes Everything", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "MacArthur Park Suite", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Donna Summer"], AlbumArtUrl = imgUrl }, - new Album { Title = "Machine Head", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Magical Mystery Tour", Genre = genres["Pop"], Price = 8.99M, Artist = artists["The Beatles"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mais Do Mesmo", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Legião Urbana"], AlbumArtUrl = imgUrl }, - new Album { Title = "Maquinarama", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Skank"], AlbumArtUrl = imgUrl }, - new Album { Title = "Marasim", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Jagjit Singh"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mascagni: Cavalleria Rusticana", Genre = genres["Classical"], Price = 8.99M, Artist = artists["James Levine"], AlbumArtUrl = imgUrl }, - new Album { Title = "Master of Puppets", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mechanics & Mathematics", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Venus Hum"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mental Jewelry", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Live"], AlbumArtUrl = imgUrl }, - new Album { Title = "Metallics", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "meteora", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Linkin Park"], AlbumArtUrl = imgUrl }, - new Album { Title = "Meus Momentos", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Gonzaguinha"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mezmerize", Genre = genres["Metal"], Price = 8.99M, Artist = artists["System Of A Down"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mezzanine", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Massive Attack"], AlbumArtUrl = imgUrl }, - new Album { Title = "Miles Ahead", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Miles Davis"], AlbumArtUrl = imgUrl }, - new Album { Title = "Milton Nascimento Ao Vivo", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Milton Nascimento"], AlbumArtUrl = imgUrl }, - new Album { Title = "Minas", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Milton Nascimento"], AlbumArtUrl = imgUrl }, - new Album { Title = "Minha Historia", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Chico Buarque"], AlbumArtUrl = imgUrl }, - new Album { Title = "Misplaced Childhood", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Marillion"], AlbumArtUrl = imgUrl }, - new Album { Title = "MK III The Final Concerts [Disc 1]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Morning Dance", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Spyro Gyra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Motley Crue Greatest Hits", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Mötley Crüe"], AlbumArtUrl = imgUrl }, - new Album { Title = "Moving Pictures", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Rush"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mozart: Chamber Music", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Nash Ensemble"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mozart: Symphonies Nos. 40 & 41", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Berliner Philharmoniker"], AlbumArtUrl = imgUrl }, - new Album { Title = "Murder Ballads", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Nick Cave and the Bad Seeds"], AlbumArtUrl = imgUrl }, - new Album { Title = "Music For The Jilted Generation", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["The Prodigy"], AlbumArtUrl = imgUrl }, - new Album { Title = "My Generation - The Very Best Of The Who", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Who"], AlbumArtUrl = imgUrl }, - new Album { Title = "My Name is Skrillex", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Skrillex"], AlbumArtUrl = imgUrl }, - new Album { Title = "Na Pista", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Cláudio Zoli"], AlbumArtUrl = imgUrl }, - new Album { Title = "Nevermind", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Nirvana"], AlbumArtUrl = imgUrl }, - new Album { Title = "New Adventures In Hi-Fi", Genre = genres["Rock"], Price = 8.99M, Artist = artists["R.E.M."], AlbumArtUrl = imgUrl }, - new Album { Title = "New Divide", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Linkin Park"], AlbumArtUrl = imgUrl }, - new Album { Title = "New York Dolls", Genre = genres["Punk"], Price = 8.99M, Artist = artists["New York Dolls"], AlbumArtUrl = imgUrl }, - new Album { Title = "News Of The World", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Queen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Nielsen: The Six Symphonies", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Göteborgs Symfoniker & Neeme Järvi"], AlbumArtUrl = imgUrl }, - new Album { Title = "Night At The Opera", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Queen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Night Castle", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Trans-Siberian Orchestra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Nkolo", Genre = genres["World"], Price = 8.99M, Artist = artists["Lokua Kanza"], AlbumArtUrl = imgUrl }, - new Album { Title = "No More Tears (Remastered)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "No Prayer For The Dying", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "No Security", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Rolling Stones"], AlbumArtUrl = imgUrl }, - new Album { Title = "O Brother, Where Art Thou?", Genre = genres["Country"], Price = 8.99M, Artist = artists["Alison Krauss"], AlbumArtUrl = imgUrl }, - new Album { Title = "O Samba Poconé", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Skank"], AlbumArtUrl = imgUrl }, - new Album { Title = "O(+>", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Prince"], AlbumArtUrl = imgUrl }, - new Album { Title = "Oceania", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Smashing Pumpkins"], AlbumArtUrl = imgUrl }, - new Album { Title = "Off the Deep End", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Weird Al"], AlbumArtUrl = imgUrl }, - new Album { Title = "OK Computer", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Radiohead"], AlbumArtUrl = imgUrl }, - new Album { Title = "Olodum", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Olodum"], AlbumArtUrl = imgUrl }, - new Album { Title = "One Love", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["David Guetta"], AlbumArtUrl = imgUrl }, - new Album { Title = "Operation: Mindcrime", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Queensrÿche"], AlbumArtUrl = imgUrl }, - new Album { Title = "Opiate", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Tool"], AlbumArtUrl = imgUrl }, - new Album { Title = "Outbreak", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Dennis Chambers"], AlbumArtUrl = imgUrl }, - new Album { Title = "Pachelbel: Canon & Gigue", Genre = genres["Classical"], Price = 8.99M, Artist = artists["English Concert & Trevor Pinnock"], AlbumArtUrl = imgUrl }, - new Album { Title = "Paid in Full", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Eric B. and Rakim"], AlbumArtUrl = imgUrl }, - new Album { Title = "Para Siempre", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Vicente Fernandez"], AlbumArtUrl = imgUrl }, - new Album { Title = "Pause", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Four Tet"], AlbumArtUrl = imgUrl }, - new Album { Title = "Peace Sells... but Who's Buying", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Megadeth"], AlbumArtUrl = imgUrl }, - new Album { Title = "Physical Graffiti [Disc 1]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Physical Graffiti [Disc 2]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Physical Graffiti", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Piece Of Mind", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Pinkerton", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Weezer"], AlbumArtUrl = imgUrl }, - new Album { Title = "Plays Metallica By Four Cellos", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Apocalyptica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Pop", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Powerslave", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Prenda Minha", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Caetano Veloso"], AlbumArtUrl = imgUrl }, - new Album { Title = "Presence", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Pretty Hate Machine", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Nine Inch Nails"], AlbumArtUrl = imgUrl }, - new Album { Title = "Prisoner", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Jezabels"], AlbumArtUrl = imgUrl }, - new Album { Title = "Privateering", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Mark Knopfler"], AlbumArtUrl = imgUrl }, - new Album { Title = "Prokofiev: Romeo & Juliet", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Michael Tilson Thomas"], AlbumArtUrl = imgUrl }, - new Album { Title = "Prokofiev: Symphony No.1", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sergei Prokofiev & Yuri Temirkanov"], AlbumArtUrl = imgUrl }, - new Album { Title = "PSY's Best 6th Part 1", Genre = genres["Pop"], Price = 8.99M, Artist = artists["PSY"], AlbumArtUrl = imgUrl }, - new Album { Title = "Purcell: The Fairy Queen", Genre = genres["Classical"], Price = 8.99M, Artist = artists["London Classical Players"], AlbumArtUrl = imgUrl }, - new Album { Title = "Purpendicular", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Purple", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Stone Temple Pilots"], AlbumArtUrl = imgUrl }, - new Album { Title = "Quanta Gente Veio Ver (Live)", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Gilberto Gil"], AlbumArtUrl = imgUrl }, - new Album { Title = "Quanta Gente Veio ver--Bônus De Carnaval", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Gilberto Gil"], AlbumArtUrl = imgUrl }, - new Album { Title = "Quiet Songs", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Aisha Duo"], AlbumArtUrl = imgUrl }, - new Album { Title = "Raices", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Los Tigres del Norte"], AlbumArtUrl = imgUrl }, - new Album { Title = "Raising Hell", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Run DMC"], AlbumArtUrl = imgUrl }, - new Album { Title = "Raoul and the Kings of Spain ", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Tears For Fears"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rattle And Hum", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Raul Seixas", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Raul Seixas"], AlbumArtUrl = imgUrl }, - new Album { Title = "Recovery [Explicit]", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Eminem"], AlbumArtUrl = imgUrl }, - new Album { Title = "Reign In Blood", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Slayer"], AlbumArtUrl = imgUrl }, - new Album { Title = "Relayed", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Yes"], AlbumArtUrl = imgUrl }, - new Album { Title = "ReLoad", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Respighi:Pines of Rome", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Eugene Ormandy"], AlbumArtUrl = imgUrl }, - new Album { Title = "Restless and Wild", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Accept"], AlbumArtUrl = imgUrl }, - new Album { Title = "Retrospective I (1974-1980)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Rush"], AlbumArtUrl = imgUrl }, - new Album { Title = "Revelations", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Audioslave"], AlbumArtUrl = imgUrl }, - new Album { Title = "Revolver", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Beatles"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ride the Lighting ", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ride The Lightning", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ring My Bell", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Anita Ward"], AlbumArtUrl = imgUrl }, - new Album { Title = "Riot Act", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pearl Jam"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rise of the Phoenix", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Before the Dawn"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rock In Rio [CD1]", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rock In Rio [CD2]", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rock In Rio [CD2]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Roda De Funk", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Funk Como Le Gusta"], AlbumArtUrl = imgUrl }, - new Album { Title = "Room for Squares", Genre = genres["Pop"], Price = 8.99M, Artist = artists["John Mayer"], AlbumArtUrl = imgUrl }, - new Album { Title = "Root Down", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Jimmy Smith"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rounds", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Four Tet"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rubber Factory", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Black Keys"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rust in Peace", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Megadeth"], AlbumArtUrl = imgUrl }, - new Album { Title = "Sambas De Enredo 2001", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Various Artists"], AlbumArtUrl = imgUrl }, - new Album { Title = "Santana - As Years Go By", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Santana"], AlbumArtUrl = imgUrl }, - new Album { Title = "Santana Live", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Santana"], AlbumArtUrl = imgUrl }, - new Album { Title = "Saturday Night Fever", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Bee Gees"], AlbumArtUrl = imgUrl }, - new Album { Title = "Scary Monsters and Nice Sprites", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Skrillex"], AlbumArtUrl = imgUrl }, - new Album { Title = "Scheherazade", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Chicago Symphony Orchestra & Fritz Reiner"], AlbumArtUrl = imgUrl }, - new Album { Title = "SCRIABIN: Vers la flamme", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Christopher O'Riley"], AlbumArtUrl = imgUrl }, - new Album { Title = "Second Coming", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Stone Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "Serie Sem Limite (Disc 1)", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Tim Maia"], AlbumArtUrl = imgUrl }, - new Album { Title = "Serie Sem Limite (Disc 2)", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Tim Maia"], AlbumArtUrl = imgUrl }, - new Album { Title = "Serious About Men", Genre = genres["Rap"], Price = 8.99M, Artist = artists["The Rubberbandits"], AlbumArtUrl = imgUrl }, - new Album { Title = "Seventh Son of a Seventh Son", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Short Bus", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Filter"], AlbumArtUrl = imgUrl }, - new Album { Title = "Sibelius: Finlandia", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Berliner Philharmoniker"], AlbumArtUrl = imgUrl }, - new Album { Title = "Singles Collection", Genre = genres["Rock"], Price = 8.99M, Artist = artists["David Bowie"], AlbumArtUrl = imgUrl }, - new Album { Title = "Six Degrees of Inner Turbulence", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Dream Theater"], AlbumArtUrl = imgUrl }, - new Album { Title = "Slave To The Empire", Genre = genres["Metal"], Price = 8.99M, Artist = artists["T&N"], AlbumArtUrl = imgUrl }, - new Album { Title = "Slaves And Masters", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Slouching Towards Bethlehem", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Robert James"], AlbumArtUrl = imgUrl }, - new Album { Title = "Smash", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Offspring"], AlbumArtUrl = imgUrl }, - new Album { Title = "Something Special", Genre = genres["Country"], Price = 8.99M, Artist = artists["Dolly Parton"], AlbumArtUrl = imgUrl }, - new Album { Title = "Somewhere in Time", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Song(s) You Know By Heart", Genre = genres["Country"], Price = 8.99M, Artist = artists["Jimmy Buffett"], AlbumArtUrl = imgUrl }, - new Album { Title = "Sound of Music", Genre = genres["Punk"], Price = 8.99M, Artist = artists["Adicts"], AlbumArtUrl = imgUrl }, - new Album { Title = "South American Getaway", Genre = genres["Classical"], Price = 8.99M, Artist = artists["The 12 Cellists of The Berlin Philharmonic"], AlbumArtUrl = imgUrl }, - new Album { Title = "Sozinho Remix Ao Vivo", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Caetano Veloso"], AlbumArtUrl = imgUrl }, - new Album { Title = "Speak of the Devil", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Spiritual State", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Nujabes"], AlbumArtUrl = imgUrl }, - new Album { Title = "St. Anger", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Still Life", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Opeth"], AlbumArtUrl = imgUrl }, - new Album { Title = "Stop Making Sense", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Talking Heads"], AlbumArtUrl = imgUrl }, - new Album { Title = "Stormbringer", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Stranger than Fiction", Genre = genres["Punk"], Price = 8.99M, Artist = artists["Bad Religion"], AlbumArtUrl = imgUrl }, - new Album { Title = "Strauss: Waltzes", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Eugene Ormandy"], AlbumArtUrl = imgUrl }, - new Album { Title = "Supermodified", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Amon Tobin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Supernatural", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Santana"], AlbumArtUrl = imgUrl }, - new Album { Title = "Surfing with the Alien (Remastered)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Joe Satriani"], AlbumArtUrl = imgUrl }, - new Album { Title = "Switched-On Bach", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Wendy Carlos"], AlbumArtUrl = imgUrl }, - new Album { Title = "Symphony", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Szymanowski: Piano Works, Vol. 1", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Martin Roscoe"], AlbumArtUrl = imgUrl }, - new Album { Title = "Tchaikovsky: The Nutcracker", Genre = genres["Classical"], Price = 8.99M, Artist = artists["London Symphony Orchestra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ted Nugent", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ted Nugent"], AlbumArtUrl = imgUrl }, - new Album { Title = "Teflon Don", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Rick Ross"], AlbumArtUrl = imgUrl }, - new Album { Title = "Tell Another Joke at the Ol' Choppin' Block", Genre = genres["Indie"], Price = 8.99M, Artist = artists["Danielson Famile"], AlbumArtUrl = imgUrl }, - new Album { Title = "Temple of the Dog", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Temple of the Dog"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ten", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pearl Jam"], AlbumArtUrl = imgUrl }, - new Album { Title = "Texas Flood", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Stevie Ray Vaughan"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Battle Rages On", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Beast Live", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Paul D'Ianno"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best Of 1980-1990", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best of 1990–2000", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best of Beethoven", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Nicolaus Esterhazy Sinfonia"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best Of Billy Cobham", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Billy Cobham"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best of Ed Motta", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Ed Motta"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best Of Van Halen, Vol. I", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Van Halen"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Bridge", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Melanie Fiona"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Cage", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Tygers of Pan Tang"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Chicago Transit Authority", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Chicago "], AlbumArtUrl = imgUrl }, - new Album { Title = "The Chronic", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Dr. Dre"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Colour And The Shape", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Foo Fighters"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Crane Wife", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["The Decemberists"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Cream Of Clapton", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Eric Clapton"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Cure", Genre = genres["Pop"], Price = 8.99M, Artist = artists["The Cure"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Dark Side Of The Moon", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pink Floyd"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Divine Conspiracy", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Epica"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Doors", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Doors"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Dream of the Blue Turtles", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Sting"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Essential Miles Davis [Disc 1]", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Miles Davis"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Essential Miles Davis [Disc 2]", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Miles Davis"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Final Concerts (Disc 2)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Final Frontier", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Head and the Heart", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Head and the Heart"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Joshua Tree", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Last Night of the Proms", Genre = genres["Classical"], Price = 8.99M, Artist = artists["BBC Concert Orchestra"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Lumineers", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Lumineers"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Number of The Beast", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Number of The Beast", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Police Greatest Hits", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Police"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Song Remains The Same (Disc 1)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Song Remains The Same (Disc 2)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Southern Harmony and Musical Companion", Genre = genres["Blues"], Price = 8.99M, Artist = artists["The Black Crowes"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Spade", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Butch Walker & The Black Widows"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Stone Roses", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Stone Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Suburbs", Genre = genres["Indie"], Price = 8.99M, Artist = artists["Arcade Fire"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Three Tenors Disc1/Disc2", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Carreras, Pavarotti, Domingo"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Trees They Grow So High", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Wall", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pink Floyd"], AlbumArtUrl = imgUrl }, - new Album { Title = "The X Factor", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Them Crooked Vultures", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Them Crooked Vultures"], AlbumArtUrl = imgUrl }, - new Album { Title = "This Is Happening", Genre = genres["Rock"], Price = 8.99M, Artist = artists["LCD Soundsystem"], AlbumArtUrl = imgUrl }, - new Album { Title = "Thunder, Lightning, Strike", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Go! Team"], AlbumArtUrl = imgUrl }, - new Album { Title = "Time to Say Goodbye", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Time, Love & Tenderness", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Michael Bolton"], AlbumArtUrl = imgUrl }, - new Album { Title = "Tomorrow Starts Today", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Mobile"], AlbumArtUrl = imgUrl }, - new Album { Title = "Tribute", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Tuesday Night Music Club", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Sheryl Crow"], AlbumArtUrl = imgUrl }, - new Album { Title = "Umoja", Genre = genres["Rock"], Price = 8.99M, Artist = artists["BLØF"], AlbumArtUrl = imgUrl }, - new Album { Title = "Under the Pink", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Tori Amos"], AlbumArtUrl = imgUrl }, - new Album { Title = "Undertow", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Tool"], AlbumArtUrl = imgUrl }, - new Album { Title = "Un-Led-Ed", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Dread Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Unplugged [Live]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Kiss"], AlbumArtUrl = imgUrl }, - new Album { Title = "Unplugged", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Eric Clapton"], AlbumArtUrl = imgUrl }, - new Album { Title = "Unplugged", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Eric Clapton"], AlbumArtUrl = imgUrl }, - new Album { Title = "Untrue", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Burial"], AlbumArtUrl = imgUrl }, - new Album { Title = "Use Your Illusion I", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Guns N' Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "Use Your Illusion II", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Guns N' Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "Use Your Illusion II", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Guns N' Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "Van Halen III", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Van Halen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Van Halen", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Van Halen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Version 2.0", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Garbage"], AlbumArtUrl = imgUrl }, - new Album { Title = "Vinicius De Moraes", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Vinícius De Moraes"], AlbumArtUrl = imgUrl }, - new Album { Title = "Virtual XI", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Voodoo Lounge", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Rolling Stones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Vozes do MPB", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Various Artists"], AlbumArtUrl = imgUrl }, - new Album { Title = "Vs.", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pearl Jam"], AlbumArtUrl = imgUrl }, - new Album { Title = "Wagner: Favourite Overtures", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sir Georg Solti & Wiener Philharmoniker"], AlbumArtUrl = imgUrl }, - new Album { Title = "Walking Into Clarksdale", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Page & Plant"], AlbumArtUrl = imgUrl }, - new Album { Title = "Wapi Yo", Genre = genres["World"], Price = 8.99M, Artist = artists["Lokua Kanza"], AlbumArtUrl = imgUrl }, - new Album { Title = "War", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Warner 25 Anos", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Antônio Carlos Jobim"], AlbumArtUrl = imgUrl }, - new Album { Title = "Wasteland R&Btheque", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Raunchy"], AlbumArtUrl = imgUrl }, - new Album { Title = "Watermark", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Enya"], AlbumArtUrl = imgUrl }, - new Album { Title = "We Were Exploding Anyway", Genre = genres["Rock"], Price = 8.99M, Artist = artists["65daysofstatic"], AlbumArtUrl = imgUrl }, - new Album { Title = "Weill: The Seven Deadly Sins", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Orchestre de l'Opéra de Lyon"], AlbumArtUrl = imgUrl }, - new Album { Title = "White Pony", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deftones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Who's Next", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Who"], AlbumArtUrl = imgUrl }, - new Album { Title = "Wish You Were Here", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pink Floyd"], AlbumArtUrl = imgUrl }, - new Album { Title = "With Oden on Our Side", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Amon Amarth"], AlbumArtUrl = imgUrl }, - new Album { Title = "Worlds", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Aaron Goldberg"], AlbumArtUrl = imgUrl }, - new Album { Title = "Worship Music", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Anthrax"], AlbumArtUrl = imgUrl }, - new Album { Title = "X&Y", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Coldplay"], AlbumArtUrl = imgUrl }, - new Album { Title = "Xinti", Genre = genres["World"], Price = 8.99M, Artist = artists["Sara Tavares"], AlbumArtUrl = imgUrl }, - new Album { Title = "Yano", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Yano"], AlbumArtUrl = imgUrl }, - new Album { Title = "Yesterday Once More Disc 1/Disc 2", Genre = genres["Pop"], Price = 8.99M, Artist = artists["The Carpenters"], AlbumArtUrl = imgUrl }, - new Album { Title = "Zooropa", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Zoso", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - }; - - foreach (var album in albums) - { - album.ArtistId = album.Artist.ArtistId; - album.GenreId = album.Genre.GenreId; - } - - return albums; - } - - private static Dictionary artists; - public static Dictionary Artists - { - get - { - if (artists == null) - { - var artistsList = new Artist[] - { - new Artist { Name = "65daysofstatic" }, - new Artist { Name = "Aaron Goldberg" }, - new Artist { Name = "Above & Beyond" }, - new Artist { Name = "Above the Fold" }, - new Artist { Name = "AC/DC" }, - new Artist { Name = "Accept" }, - new Artist { Name = "Adicts" }, - new Artist { Name = "Adrian Leaper & Doreen de Feis" }, - new Artist { Name = "Aerosmith" }, - new Artist { Name = "Aisha Duo" }, - new Artist { Name = "Al di Meola" }, - new Artist { Name = "Alabama Shakes" }, - new Artist { Name = "Alanis Morissette" }, - new Artist { Name = "Alberto Turco & Nova Schola Gregoriana" }, - new Artist { Name = "Alice in Chains" }, - new Artist { Name = "Alison Krauss" }, - new Artist { Name = "Amon Amarth" }, - new Artist { Name = "Amon Tobin" }, - new Artist { Name = "Amr Diab" }, - new Artist { Name = "Amy Winehouse" }, - new Artist { Name = "Anita Ward" }, - new Artist { Name = "Anthrax" }, - new Artist { Name = "Antônio Carlos Jobim" }, - new Artist { Name = "Apocalyptica" }, - new Artist { Name = "Aqua" }, - new Artist { Name = "Armand Van Helden" }, - new Artist { Name = "Arcade Fire" }, - new Artist { Name = "Audioslave" }, - new Artist { Name = "Bad Religion" }, - new Artist { Name = "Barenaked Ladies" }, - new Artist { Name = "BBC Concert Orchestra" }, - new Artist { Name = "Bee Gees" }, - new Artist { Name = "Before the Dawn" }, - new Artist { Name = "Berliner Philharmoniker" }, - new Artist { Name = "Billy Cobham" }, - new Artist { Name = "Black Label Society" }, - new Artist { Name = "Black Sabbath" }, - new Artist { Name = "BLØF" }, - new Artist { Name = "Blues Traveler" }, - new Artist { Name = "Boston Symphony Orchestra & Seiji Ozawa" }, - new Artist { Name = "Britten Sinfonia, Ivor Bolton & Lesley Garrett" }, - new Artist { Name = "Bruce Dickinson" }, - new Artist { Name = "Buddy Guy" }, - new Artist { Name = "Burial" }, - new Artist { Name = "Butch Walker & The Black Widows" }, - new Artist { Name = "Caetano Veloso" }, - new Artist { Name = "Cake" }, - new Artist { Name = "Calexico" }, - new Artist { Name = "Carly Rae Jepsen" }, - new Artist { Name = "Carreras, Pavarotti, Domingo" }, - new Artist { Name = "Cássia Eller" }, - new Artist { Name = "Cayouche" }, - new Artist { Name = "Chic" }, - new Artist { Name = "Chicago " }, - new Artist { Name = "Chicago Symphony Orchestra & Fritz Reiner" }, - new Artist { Name = "Chico Buarque" }, - new Artist { Name = "Chico Science & Nação Zumbi" }, - new Artist { Name = "Choir Of Westminster Abbey & Simon Preston" }, - new Artist { Name = "Chris Cornell" }, - new Artist { Name = "Christopher O'Riley" }, - new Artist { Name = "Cidade Negra" }, - new Artist { Name = "Cláudio Zoli" }, - new Artist { Name = "Coldplay" }, - new Artist { Name = "Creedence Clearwater Revival" }, - new Artist { Name = "Crosby, Stills, Nash, and Young" }, - new Artist { Name = "Daft Punk" }, - new Artist { Name = "Danielson Famile" }, - new Artist { Name = "David Bowie" }, - new Artist { Name = "David Coverdale" }, - new Artist { Name = "David Guetta" }, - new Artist { Name = "deadmau5" }, - new Artist { Name = "Deep Purple" }, - new Artist { Name = "Def Leppard" }, - new Artist { Name = "Deftones" }, - new Artist { Name = "Dennis Chambers" }, - new Artist { Name = "Deva Premal" }, - new Artist { Name = "Dio" }, - new Artist { Name = "Djavan" }, - new Artist { Name = "Dolly Parton" }, - new Artist { Name = "Donna Summer" }, - new Artist { Name = "Dr. Dre" }, - new Artist { Name = "Dread Zeppelin" }, - new Artist { Name = "Dream Theater" }, - new Artist { Name = "Duck Sauce" }, - new Artist { Name = "Earl Scruggs" }, - new Artist { Name = "Ed Motta" }, - new Artist { Name = "Edo de Waart & San Francisco Symphony" }, - new Artist { Name = "Elis Regina" }, - new Artist { Name = "Eminem" }, - new Artist { Name = "English Concert & Trevor Pinnock" }, - new Artist { Name = "Enya" }, - new Artist { Name = "Epica" }, - new Artist { Name = "Eric B. and Rakim" }, - new Artist { Name = "Eric Clapton" }, - new Artist { Name = "Eugene Ormandy" }, - new Artist { Name = "Faith No More" }, - new Artist { Name = "Falamansa" }, - new Artist { Name = "Filter" }, - new Artist { Name = "Foo Fighters" }, - new Artist { Name = "Four Tet" }, - new Artist { Name = "Frank Zappa & Captain Beefheart" }, - new Artist { Name = "Fretwork" }, - new Artist { Name = "Funk Como Le Gusta" }, - new Artist { Name = "Garbage" }, - new Artist { Name = "Gerald Moore" }, - new Artist { Name = "Gilberto Gil" }, - new Artist { Name = "Godsmack" }, - new Artist { Name = "Gonzaguinha" }, - new Artist { Name = "Göteborgs Symfoniker & Neeme Järvi" }, - new Artist { Name = "Guns N' Roses" }, - new Artist { Name = "Gustav Mahler" }, - new Artist { Name = "In This Moment" }, - new Artist { Name = "Incognito" }, - new Artist { Name = "INXS" }, - new Artist { Name = "Iron Maiden" }, - new Artist { Name = "Jagjit Singh" }, - new Artist { Name = "James Levine" }, - new Artist { Name = "Jamiroquai" }, - new Artist { Name = "Jimi Hendrix" }, - new Artist { Name = "Jimmy Buffett" }, - new Artist { Name = "Jimmy Smith" }, - new Artist { Name = "Joe Satriani" }, - new Artist { Name = "John Digweed" }, - new Artist { Name = "John Mayer" }, - new Artist { Name = "Jorge Ben" }, - new Artist { Name = "Jota Quest" }, - new Artist { Name = "Journey" }, - new Artist { Name = "Judas Priest" }, - new Artist { Name = "Julian Bream" }, - new Artist { Name = "Justice" }, - new Artist { Name = "Orchestre de l'Opéra de Lyon" }, - new Artist { Name = "King Crimson" }, - new Artist { Name = "Kiss" }, - new Artist { Name = "LCD Soundsystem" }, - new Artist { Name = "Le Tigre" }, - new Artist { Name = "Led Zeppelin" }, - new Artist { Name = "Legião Urbana" }, - new Artist { Name = "Lenny Kravitz" }, - new Artist { Name = "Les Arts Florissants & William Christie" }, - new Artist { Name = "Limp Bizkit" }, - new Artist { Name = "Linkin Park" }, - new Artist { Name = "Live" }, - new Artist { Name = "Lokua Kanza" }, - new Artist { Name = "London Symphony Orchestra" }, - new Artist { Name = "Los Tigres del Norte" }, - new Artist { Name = "Luciana Souza/Romero Lubambo" }, - new Artist { Name = "Lulu Santos" }, - new Artist { Name = "Lura" }, - new Artist { Name = "Marcos Valle" }, - new Artist { Name = "Marillion" }, - new Artist { Name = "Marisa Monte" }, - new Artist { Name = "Mark Knopfler" }, - new Artist { Name = "Martin Roscoe" }, - new Artist { Name = "Massive Attack" }, - new Artist { Name = "Maurizio Pollini" }, - new Artist { Name = "Megadeth" }, - new Artist { Name = "Mela Tenenbaum, Pro Musica Prague & Richard Kapp" }, - new Artist { Name = "Melanie Fiona" }, - new Artist { Name = "Men At Work" }, - new Artist { Name = "Metallica" }, - new Artist { Name = "M-Flo" }, - new Artist { Name = "Michael Bolton" }, - new Artist { Name = "Michael Tilson Thomas" }, - new Artist { Name = "Miles Davis" }, - new Artist { Name = "Milton Nascimento" }, - new Artist { Name = "Mobile" }, - new Artist { Name = "Modest Mouse" }, - new Artist { Name = "Mötley Crüe" }, - new Artist { Name = "Motörhead" }, - new Artist { Name = "Mumford & Sons" }, - new Artist { Name = "Munkle" }, - new Artist { Name = "Nash Ensemble" }, - new Artist { Name = "Neil Young" }, - new Artist { Name = "New York Dolls" }, - new Artist { Name = "Nick Cave and the Bad Seeds" }, - new Artist { Name = "Nicolaus Esterhazy Sinfonia" }, - new Artist { Name = "Nine Inch Nails" }, - new Artist { Name = "Nirvana" }, - new Artist { Name = "Norah Jones" }, - new Artist { Name = "Nujabes" }, - new Artist { Name = "O Terço" }, - new Artist { Name = "Oasis" }, - new Artist { Name = "Olodum" }, - new Artist { Name = "Opeth" }, - new Artist { Name = "Orchestra of The Age of Enlightenment" }, - new Artist { Name = "Os Paralamas Do Sucesso" }, - new Artist { Name = "Ozzy Osbourne" }, - new Artist { Name = "Paddy Casey" }, - new Artist { Name = "Page & Plant" }, - new Artist { Name = "Papa Wemba" }, - new Artist { Name = "Paul D'Ianno" }, - new Artist { Name = "Paul Oakenfold" }, - new Artist { Name = "Paul Van Dyk" }, - new Artist { Name = "Pearl Jam" }, - new Artist { Name = "Pet Shop Boys" }, - new Artist { Name = "Pink Floyd" }, - new Artist { Name = "Plug" }, - new Artist { Name = "Porcupine Tree" }, - new Artist { Name = "Portishead" }, - new Artist { Name = "Prince" }, - new Artist { Name = "Projected" }, - new Artist { Name = "PSY" }, - new Artist { Name = "Public Enemy" }, - new Artist { Name = "Queen" }, - new Artist { Name = "Queensrÿche" }, - new Artist { Name = "R.E.M." }, - new Artist { Name = "Radiohead" }, - new Artist { Name = "Rancid" }, - new Artist { Name = "Raul Seixas" }, - new Artist { Name = "Raunchy" }, - new Artist { Name = "Red Hot Chili Peppers" }, - new Artist { Name = "Rick Ross" }, - new Artist { Name = "Robert James" }, - new Artist { Name = "London Classical Players" }, - new Artist { Name = "Royal Philharmonic Orchestra" }, - new Artist { Name = "Run DMC" }, - new Artist { Name = "Rush" }, - new Artist { Name = "Santana" }, - new Artist { Name = "Sara Tavares" }, - new Artist { Name = "Sarah Brightman" }, - new Artist { Name = "Sasha" }, - new Artist { Name = "Scholars Baroque Ensemble" }, - new Artist { Name = "Scorpions" }, - new Artist { Name = "Sergei Prokofiev & Yuri Temirkanov" }, - new Artist { Name = "Sheryl Crow" }, - new Artist { Name = "Sir Georg Solti & Wiener Philharmoniker" }, - new Artist { Name = "Skank" }, - new Artist { Name = "Skrillex" }, - new Artist { Name = "Slash" }, - new Artist { Name = "Slayer" }, - new Artist { Name = "Soul-Junk" }, - new Artist { Name = "Soundgarden" }, - new Artist { Name = "Spyro Gyra" }, - new Artist { Name = "Stevie Ray Vaughan & Double Trouble" }, - new Artist { Name = "Stevie Ray Vaughan" }, - new Artist { Name = "Sting" }, - new Artist { Name = "Stone Temple Pilots" }, - new Artist { Name = "Styx" }, - new Artist { Name = "Sufjan Stevens" }, - new Artist { Name = "Supreme Beings of Leisure" }, - new Artist { Name = "System Of A Down" }, - new Artist { Name = "T&N" }, - new Artist { Name = "Talking Heads" }, - new Artist { Name = "Tears For Fears" }, - new Artist { Name = "Ted Nugent" }, - new Artist { Name = "Temple of the Dog" }, - new Artist { Name = "Terry Bozzio, Tony Levin & Steve Stevens" }, - new Artist { Name = "The 12 Cellists of The Berlin Philharmonic" }, - new Artist { Name = "The Axis of Awesome" }, - new Artist { Name = "The Beatles" }, - new Artist { Name = "The Black Crowes" }, - new Artist { Name = "The Black Keys" }, - new Artist { Name = "The Carpenters" }, - new Artist { Name = "The Cat Empire" }, - new Artist { Name = "The Cult" }, - new Artist { Name = "The Cure" }, - new Artist { Name = "The Decemberists" }, - new Artist { Name = "The Doors" }, - new Artist { Name = "The Eagles of Death Metal" }, - new Artist { Name = "The Go! Team" }, - new Artist { Name = "The Head and the Heart" }, - new Artist { Name = "The Jezabels" }, - new Artist { Name = "The King's Singers" }, - new Artist { Name = "The Lumineers" }, - new Artist { Name = "The Offspring" }, - new Artist { Name = "The Police" }, - new Artist { Name = "The Posies" }, - new Artist { Name = "The Prodigy" }, - new Artist { Name = "The Rolling Stones" }, - new Artist { Name = "The Rubberbandits" }, - new Artist { Name = "The Smashing Pumpkins" }, - new Artist { Name = "The Stone Roses" }, - new Artist { Name = "The Who" }, - new Artist { Name = "Them Crooked Vultures" }, - new Artist { Name = "TheStart" }, - new Artist { Name = "Thievery Corporation" }, - new Artist { Name = "Tiësto" }, - new Artist { Name = "Tim Maia" }, - new Artist { Name = "Ton Koopman" }, - new Artist { Name = "Tool" }, - new Artist { Name = "Tori Amos" }, - new Artist { Name = "Trampled By Turtles" }, - new Artist { Name = "Trans-Siberian Orchestra" }, - new Artist { Name = "Tygers of Pan Tang" }, - new Artist { Name = "U2" }, - new Artist { Name = "UB40" }, - new Artist { Name = "Uh Huh Her " }, - new Artist { Name = "Van Halen" }, - new Artist { Name = "Various Artists" }, - new Artist { Name = "Velvet Revolver" }, - new Artist { Name = "Venus Hum" }, - new Artist { Name = "Vicente Fernandez" }, - new Artist { Name = "Vinícius De Moraes" }, - new Artist { Name = "Weezer" }, - new Artist { Name = "Weird Al" }, - new Artist { Name = "Wendy Carlos" }, - new Artist { Name = "Wilhelm Kempff" }, - new Artist { Name = "Yano" }, - new Artist { Name = "Yehudi Menuhin" }, - new Artist { Name = "Yes" }, - new Artist { Name = "Yo-Yo Ma" }, - new Artist { Name = "Zeca Pagodinho" }, - new Artist { Name = "אריק אינשטיין"} - }; - - // TODO [EF] Swap to store generated keys when available - int artistId = 1; - artists = new Dictionary(); - foreach (Artist artist in artistsList) - { - artist.ArtistId = artistId++; - artists.Add(artist.Name, artist); - } - } - - return artists; - } - } - - private static Dictionary genres; - public static Dictionary Genres - { - get - { - if (genres == null) - { - var genresList = new Genre[] - { - new Genre { Name = "Pop" }, - new Genre { Name = "Rock" }, - new Genre { Name = "Jazz" }, - new Genre { Name = "Metal" }, - new Genre { Name = "Electronic" }, - new Genre { Name = "Blues" }, - new Genre { Name = "Latin" }, - new Genre { Name = "Rap" }, - new Genre { Name = "Classical" }, - new Genre { Name = "Alternative" }, - new Genre { Name = "Country" }, - new Genre { Name = "R&B" }, - new Genre { Name = "Indie" }, - new Genre { Name = "Punk" }, - new Genre { Name = "World" } - }; - - genres = new Dictionary(); - // TODO [EF] Swap to store generated keys when available - int genreId = 1; - foreach (Genre genre in genresList) - { - genre.GenreId = genreId++; - - // TODO [EF] Remove when null values are supported by update pipeline - genre.Description = genre.Name + " is great music (if you like it)."; - - genres.Add(genre.Name, genre); - } - } - - return genres; - } - } - } -} diff --git a/samples/angular/MusicStore/Apis/Models/SentimentAnalysis.cs b/samples/angular/MusicStore/Apis/Models/SentimentAnalysis.cs deleted file mode 100644 index 8167ec3..0000000 --- a/samples/angular/MusicStore/Apis/Models/SentimentAnalysis.cs +++ /dev/null @@ -1,38 +0,0 @@ -using System.Linq; -using System.Text.RegularExpressions; - -namespace MusicStore.Models -{ - // Obviously this is not a serious sentiment analyser. It is only here to provide an amusing demonstration of cross-property - // validation in AlbumsApiController. - public static class SentimentAnalysis - { - private static string[] positiveSentimentWords = new[] { "happy", "fun", "joy", "love", "delight", "bunny", "bunnies", "asp.net" }; - - private static string[] negativeSentimentWords = new[] { "sad", "pain", "despair", "hate", "scorn", "death", "package management" }; - - public static SentimentResult GetSentiment(string text) { - var numPositiveWords = CountWordOccurrences(text, positiveSentimentWords); - var numNegativeWords = CountWordOccurrences(text, negativeSentimentWords); - if (numPositiveWords > numNegativeWords) { - return SentimentResult.Positive; - } else if (numNegativeWords > numPositiveWords) { - return SentimentResult.Negative; - } else { - return SentimentResult.Neutral; - } - } - - private static int CountWordOccurrences(string text, string[] words) - { - // Very simplistic matching technique for this sample. Not scalable and not really even correct. - return new Regex(string.Join("|", words), RegexOptions.IgnoreCase).Matches(text).Count; - } - - public enum SentimentResult { - Negative, - Neutral, - Positive, - } - } -} diff --git a/samples/angular/MusicStore/Apis/Models/ShoppingCart.cs b/samples/angular/MusicStore/Apis/Models/ShoppingCart.cs deleted file mode 100644 index 1d2465a..0000000 --- a/samples/angular/MusicStore/Apis/Models/ShoppingCart.cs +++ /dev/null @@ -1,207 +0,0 @@ -using Microsoft.AspNetCore.Http; -using Microsoft.EntityFrameworkCore; -using System; -using System.Collections.Generic; -using System.Linq; - -namespace MusicStore.Models -{ - public partial class ShoppingCart - { - MusicStoreContext _db; - string ShoppingCartId { get; set; } - - public ShoppingCart(MusicStoreContext db) - { - _db = db; - } - - public static ShoppingCart GetCart(MusicStoreContext db, HttpContext context) - { - var cart = new ShoppingCart(db); - cart.ShoppingCartId = cart.GetCartId(context); - return cart; - } - - public void AddToCart(Album album) - { - // Get the matching cart and album instances - var cartItem = _db.CartItems.SingleOrDefault( - c => c.CartId == ShoppingCartId - && c.AlbumId == album.AlbumId); - - if (cartItem == null) - { - // TODO [EF] Swap to store generated key once we support identity pattern - var nextCartItemId = _db.CartItems.Any() - ? _db.CartItems.Max(c => c.CartItemId) + 1 - : 1; - - // Create a new cart item if no cart item exists - cartItem = new CartItem - { - CartItemId = nextCartItemId, - AlbumId = album.AlbumId, - CartId = ShoppingCartId, - Count = 1, - DateCreated = DateTime.Now - }; - - _db.CartItems.Add(cartItem); - } - else - { - // If the item does exist in the cart, then add one to the quantity - cartItem.Count++; - - // TODO [EF] Remove this line once change detection is available - _db.Update(cartItem); - } - } - - public int RemoveFromCart(int id) - { - // Get the cart - var cartItem = _db.CartItems.Single( - cart => cart.CartId == ShoppingCartId - && cart.CartItemId == id); - - int itemCount = 0; - - if (cartItem != null) - { - if (cartItem.Count > 1) - { - cartItem.Count--; - - // TODO [EF] Remove this line once change detection is available - _db.Update(cartItem); - - itemCount = cartItem.Count; - } - else - { - _db.CartItems.Remove(cartItem); - } - } - - return itemCount; - } - - public void EmptyCart() - { - var cartItems = _db.CartItems.Where(cart => cart.CartId == ShoppingCartId); - - foreach (var cartItem in cartItems) - { - _db.Remove(cartItem); - } - } - - public List GetCartItems() - { - var cartItems = _db.CartItems.Where(cart => cart.CartId == ShoppingCartId).ToList(); - //TODO: Auto population of the related album data not available until EF feature is lighted up. - foreach (var cartItem in cartItems) - { - cartItem.Album = _db.Albums.Single(a => a.AlbumId == cartItem.AlbumId); - } - - return cartItems; - } - - public int GetCount() - { - // Get the count of each item in the cart and sum them up - int? count = (from cartItems in _db.CartItems - where cartItems.CartId == ShoppingCartId - select (int?)cartItems.Count).Sum(); - - // Return 0 if all entries are null - return count ?? 0; - } - - public decimal GetTotal() - { - // Multiply album price by count of that album to get - // the current price for each of those albums in the cart - // sum all album price totals to get the cart total - - // TODO Collapse to a single query once EF supports querying related data - decimal total = 0; - foreach (var item in _db.CartItems.Where(c => c.CartId == ShoppingCartId)) - { - var album = _db.Albums.Single(a => a.AlbumId == item.AlbumId); - total += item.Count * album.Price; - } - - return total; - } - - public int CreateOrder(Order order) - { - decimal orderTotal = 0; - - var cartItems = GetCartItems(); - - // TODO [EF] Swap to store generated identity key when supported - var nextId = _db.OrderDetails.Any() - ? _db.OrderDetails.Max(o => o.OrderDetailId) + 1 - : 1; - - // Iterate over the items in the cart, adding the order details for each - foreach (var item in cartItems) - { - //var album = _db.Albums.Find(item.AlbumId); - var album = _db.Albums.Single(a => a.AlbumId == item.AlbumId); - - var orderDetail = new OrderDetail - { - OrderDetailId = nextId, - AlbumId = item.AlbumId, - OrderId = order.OrderId, - UnitPrice = album.Price, - Quantity = item.Count, - }; - - // Set the order total of the shopping cart - orderTotal += (item.Count * album.Price); - - _db.OrderDetails.Add(orderDetail); - - nextId++; - } - - // Set the order's total to the orderTotal count - order.Total = orderTotal; - - // Empty the shopping cart - EmptyCart(); - - // Return the OrderId as the confirmation number - return order.OrderId; - } - - // We're using HttpContextBase to allow access to cookies. - public string GetCartId(HttpContext context) - { - var sessionCookie = context.Request.Cookies["Session"]; - string cartId = null; - - if (string.IsNullOrWhiteSpace(sessionCookie)) - { - //A GUID to hold the cartId. - cartId = Guid.NewGuid().ToString(); - - // Send cart Id as a cookie to the client. - context.Response.Cookies.Append("Session", cartId); - } - else - { - cartId = sessionCookie; - } - - return cartId; - } - } -} diff --git a/samples/angular/MusicStore/Controllers/HomeController.cs b/samples/angular/MusicStore/Controllers/HomeController.cs deleted file mode 100755 index 07e9702..0000000 --- a/samples/angular/MusicStore/Controllers/HomeController.cs +++ /dev/null @@ -1,17 +0,0 @@ -using Microsoft.AspNetCore.Mvc; - -namespace MusicStore.Controllers -{ - public class HomeController : Controller - { - public IActionResult Index() - { - return View(); - } - - public IActionResult Error() - { - return View("~/Views/Shared/Error.cshtml"); - } - } -} diff --git a/samples/angular/MusicStore/Infrastructure/NoCacheAttribute.cs b/samples/angular/MusicStore/Infrastructure/NoCacheAttribute.cs deleted file mode 100644 index 856023a..0000000 --- a/samples/angular/MusicStore/Infrastructure/NoCacheAttribute.cs +++ /dev/null @@ -1,19 +0,0 @@ -using Microsoft.AspNetCore.Mvc; -using System; -using Microsoft.AspNetCore.Mvc.Filters; - -namespace MusicStore.Infrastructure -{ - [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method)] - public sealed class NoCacheAttribute : ActionFilterAttribute - { - public override void OnResultExecuting(ResultExecutingContext context) - { - context.HttpContext.Response.Headers["Cache-Control"] = "no-cache, no-store, max-age=0"; - context.HttpContext.Response.Headers["Pragma"] = "no-cache"; - context.HttpContext.Response.Headers["Expires"] = "-1"; - - base.OnResultExecuting(context); - } - } -} diff --git a/samples/angular/MusicStore/Infrastructure/PagedList.cs b/samples/angular/MusicStore/Infrastructure/PagedList.cs deleted file mode 100644 index b2cb2c5..0000000 --- a/samples/angular/MusicStore/Infrastructure/PagedList.cs +++ /dev/null @@ -1,150 +0,0 @@ -using Microsoft.EntityFrameworkCore; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Linq.Expressions; -using System.Threading.Tasks; - -namespace MusicStore.Infrastructure -{ - public interface IPagedList - { - IEnumerable Data { get; } - - int Page { get; } - - int PageSize { get; } - - int TotalCount { get; } - } - - internal class PagedList : IPagedList - { - public PagedList(IEnumerable data, int page, int pageSize, int totalCount) - { - Data = data; - Page = page; - PageSize = pageSize; - TotalCount = totalCount; - } - - public IEnumerable Data { get; private set; } - - public int Page { get; private set; } - - public int PageSize { get; private set; } - - public int TotalCount { get; private set; } - } - - public static class PagedListExtensions - { - public static IPagedList ToPagedList(this IQueryable query, int page, int pageSize) - { - if (query == null) - { - throw new ArgumentNullException("query"); - } - - var pagingConfig = new PagingConfig(page, pageSize); - var skipCount = ValidatePagePropertiesAndGetSkipCount(pagingConfig); - - var data = query - .Skip(skipCount) - .Take(pagingConfig.PageSize) - .ToList(); - - if (skipCount > 0 && data.Count == 0) - { - // Requested page has no records, just return the first page - pagingConfig.Page = 1; - data = query - .Take(pagingConfig.PageSize) - .ToList(); - } - - return new PagedList(data, pagingConfig.Page, pagingConfig.PageSize, query.Count()); - } - - public static Task> ToPagedListAsync(this IQueryable query, int page, int pageSize, string sortExpression, Expression> defaultSortExpression, SortDirection defaultSortDirection = SortDirection.Ascending) - where TModel : class - { - return ToPagedListAsync(query, page, pageSize, sortExpression, defaultSortExpression, defaultSortDirection, null); - } - - public static async Task> ToPagedListAsync(this IQueryable query, int page, int pageSize, string sortExpression, Expression> defaultSortExpression, SortDirection defaultSortDirection, Func selector) - where TModel : class - where TResult : class - { - if (query == null) - { - throw new ArgumentNullException("query"); - } - - var pagingConfig = new PagingConfig(page, pageSize); - var skipCount = ValidatePagePropertiesAndGetSkipCount(pagingConfig); - var dataQuery = query; - - if (defaultSortExpression != null) - { - dataQuery = dataQuery - .SortBy(sortExpression, defaultSortExpression); - } - - var data = await dataQuery - .Skip(skipCount) - .Take(pagingConfig.PageSize) - .ToListAsync(); - - if (skipCount > 0 && data.Count == 0) - { - // Requested page has no records, just return the first page - pagingConfig.Page = 1; - data = await dataQuery - .Take(pagingConfig.PageSize) - .ToListAsync(); - } - - var count = await query.CountAsync(); - - var resultData = selector != null - ? data.Select(selector) - : data.Cast(); - - return new PagedList(resultData, pagingConfig.Page, pagingConfig.PageSize, count); - } - - private static int ValidatePagePropertiesAndGetSkipCount(PagingConfig pagingConfig) - { - if (pagingConfig.Page < 1) - { - pagingConfig.Page = 1; - } - - if (pagingConfig.PageSize < 10) - { - pagingConfig.PageSize = 10; - } - - if (pagingConfig.PageSize > 100) - { - pagingConfig.PageSize = 100; - } - - return pagingConfig.PageSize * (pagingConfig.Page - 1); - } - - internal class PagingConfig - { - public PagingConfig(int page, int pageSize) - { - Page = page; - PageSize = pageSize; - } - - public int Page { get; set; } - - public int PageSize { get; set; } - } - } -} diff --git a/samples/angular/MusicStore/Infrastructure/SortDirection.cs b/samples/angular/MusicStore/Infrastructure/SortDirection.cs deleted file mode 100644 index 28f7e86..0000000 --- a/samples/angular/MusicStore/Infrastructure/SortDirection.cs +++ /dev/null @@ -1,13 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; - -namespace MusicStore.Infrastructure -{ - public enum SortDirection - { - Ascending, - Descending - } -} diff --git a/samples/angular/MusicStore/Infrastructure/SortExpression.cs b/samples/angular/MusicStore/Infrastructure/SortExpression.cs deleted file mode 100644 index 88ba312..0000000 --- a/samples/angular/MusicStore/Infrastructure/SortExpression.cs +++ /dev/null @@ -1,87 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Linq.Expressions; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Mvc.ViewFeatures.Internal; - -namespace MusicStore.Infrastructure -{ - public static class SortExpression - { - private const string SORT_DIRECTION_DESC = " DESC"; - - public static IQueryable SortBy(this IQueryable query, string sortExpression, Expression> defaultSortExpression, SortDirection defaultSortDirection = SortDirection.Ascending) where TModel : class - { - return SortBy(query, sortExpression ?? Create(defaultSortExpression, defaultSortDirection)); - } - - public static string Create(Expression> expression, SortDirection sortDirection = SortDirection.Ascending) where TModel : class - { - var expressionText = ExpressionHelper.GetExpressionText(expression); - // TODO: Validate the expression depth, etc. - - var sortExpression = expressionText; - - if (sortDirection == SortDirection.Descending) - { - sortExpression += SORT_DIRECTION_DESC; - } - - return sortExpression; - } - - public static IQueryable SortBy(this IQueryable source, string sortExpression) where T : class - { - if (source == null) - { - throw new ArgumentNullException("source"); - } - - if (String.IsNullOrWhiteSpace(sortExpression)) - { - return source; - } - - sortExpression = sortExpression.Trim(); - var isDescending = false; - - // DataSource control passes the sort parameter with a direction - // if the direction is descending - if (sortExpression.EndsWith(SORT_DIRECTION_DESC, StringComparison.OrdinalIgnoreCase)) - { - isDescending = true; - var descIndex = sortExpression.Length - SORT_DIRECTION_DESC.Length; - sortExpression = sortExpression.Substring(0, descIndex).Trim(); - } - - if (string.IsNullOrEmpty(sortExpression)) - { - return source; - } - - ParameterExpression parameter = Expression.Parameter(source.ElementType, String.Empty); - - // Build up the property expression, e.g.: (m => m.Foo.Bar) - var sortExpressionParts = sortExpression.Split('.'); - Expression propertyExpression = parameter; - foreach (var property in sortExpressionParts) - { - propertyExpression = Expression.Property(propertyExpression, property); - } - - LambdaExpression lambda = Expression.Lambda(propertyExpression, parameter); - - var methodName = (isDescending) ? "OrderByDescending" : "OrderBy"; - - Expression methodCallExpression = Expression.Call( - typeof(Queryable), - methodName, - new[] { source.ElementType, propertyExpression.Type }, - source.Expression, - Expression.Quote(lambda)); - - return (IQueryable)source.Provider.CreateQuery(methodCallExpression); - } - } -} diff --git a/samples/angular/MusicStore/MusicStore.csproj b/samples/angular/MusicStore/MusicStore.csproj deleted file mode 100644 index 8f81194..0000000 --- a/samples/angular/MusicStore/MusicStore.csproj +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - netcoreapp2.0 - true - false - - - - - - - - - - - - - - - - - - - - - - - diff --git a/samples/angular/MusicStore/Startup.cs b/samples/angular/MusicStore/Startup.cs deleted file mode 100755 index ae1961f..0000000 --- a/samples/angular/MusicStore/Startup.cs +++ /dev/null @@ -1,103 +0,0 @@ -using System; -using System.Collections.Generic; -using System.IO; -using Microsoft.AspNetCore.Authorization; -using Microsoft.AspNetCore.Builder; -using Microsoft.AspNetCore.Hosting; -using Microsoft.AspNetCore.Identity.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.Extensions.Configuration; -using Microsoft.Extensions.DependencyInjection; -using Microsoft.Extensions.Logging; -using Microsoft.Extensions.PlatformAbstractions; -using AutoMapper; -using MusicStore.Apis; -using MusicStore.Models; - -namespace MusicStore -{ - public class Startup - { - // This method gets called by the runtime. Use this method to add services to the container. - public void ConfigureServices(IServiceCollection services) - { - services.AddMvc().AddJsonOptions(options => - { - options.SerializerSettings.ContractResolver = null; - }); - - // Add EF services to the service container - services - .AddEntityFrameworkSqlite() - .AddDbContext(options => { - options.UseSqlite("Data Source=music-db.sqlite"); - }); - - // Add Identity services to the services container - services.AddIdentity() - .AddEntityFrameworkStores() - .AddDefaultTokenProviders(); - - // Configure Auth - services.Configure(options => - { - options.AddPolicy("app-ManageStore", new AuthorizationPolicyBuilder().RequireClaim("app-ManageStore", "Allowed").Build()); - }); - - Mapper.Initialize(cfg => - { - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - }); - } - - // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. - public void Configure(IApplicationBuilder app, ILoggerFactory loggerFactory, IHostingEnvironment env) - { - app.UseDeveloperExceptionPage(); - - // Initialize the sample data - SampleData.InitializeMusicStoreDatabaseAsync(app.ApplicationServices).Wait(); - - app.UseStaticFiles(); - loggerFactory.AddConsole(); - - // Add MVC to the request pipeline. - app.UseMvc(routes => - { - // Matches requests that correspond to an existent controller/action pair - routes.MapRoute( - name: "default", - template: "{controller=Home}/{action=Index}/{id?}"); - - // Matches any other request that doesn't appear to have a filename extension (defined as 'having a dot in the last URI segment'). - // This means you'll correctly get 404s for /some/dir/non-existent-image.png instead of returning the SPA HTML. - // However, it means requests like /customers/isaac.newton will *not* be mapped into the SPA, so if you need to accept - // URIs like that you'll need to match all URIs, e.g.: - // routes.MapRoute("spa-fallback", "{*anything}", new { controller = "Home", action = "Index" }); - // (which of course will match /customers/isaac.png too, so in that case it would serve the PNG image at that URL if one is on disk, - // or the SPA HTML if not). - routes.MapSpaFallbackRoute("spa-fallback", new { controller = "Home", action = "Index" }); - }); - } - - public static void Main(string[] args) - { - var host = new WebHostBuilder() - .UseContentRoot(Directory.GetCurrentDirectory()) - .UseIISIntegration() - .UseKestrel() - .UseStartup() - .Build(); - - host.Run(); - } - } -} diff --git a/samples/angular/MusicStore/Views/Home/Index.cshtml b/samples/angular/MusicStore/Views/Home/Index.cshtml deleted file mode 100755 index a2799f7..0000000 --- a/samples/angular/MusicStore/Views/Home/Index.cshtml +++ /dev/null @@ -1,23 +0,0 @@ -@{ - ViewData["Title"] = "Home Page"; -} - - - Loading... - @await Html.PrimeCacheAsync(Url.Action("GenreMenuList", "GenresApi")) - @await Html.PrimeCacheAsync(Url.Action("MostPopular", "AlbumsApi")) - - -@section scripts { - - - - - - - - - - - -} diff --git a/samples/angular/MusicStore/Views/Shared/Error.cshtml b/samples/angular/MusicStore/Views/Shared/Error.cshtml deleted file mode 100755 index 473b35d..0000000 --- a/samples/angular/MusicStore/Views/Shared/Error.cshtml +++ /dev/null @@ -1,6 +0,0 @@ -@{ - ViewData["Title"] = "Error"; -} - -

Error.

-

An error occurred while processing your request.

diff --git a/samples/angular/MusicStore/Views/Shared/_Layout.cshtml b/samples/angular/MusicStore/Views/Shared/_Layout.cshtml deleted file mode 100755 index 562ccf8..0000000 --- a/samples/angular/MusicStore/Views/Shared/_Layout.cshtml +++ /dev/null @@ -1,40 +0,0 @@ - - - - - - Music Store - - - - - - - - - - - - - @RenderBody() - - - - - - - - - - - @RenderSection("scripts", required: false) - - diff --git a/samples/angular/MusicStore/Views/_ViewImports.cshtml b/samples/angular/MusicStore/Views/_ViewImports.cshtml deleted file mode 100755 index 3e7a43a..0000000 --- a/samples/angular/MusicStore/Views/_ViewImports.cshtml +++ /dev/null @@ -1,4 +0,0 @@ -@using MusicStore -@using Microsoft.AspNetCore.AngularServices -@addTagHelper "*, Microsoft.AspNetCore.Mvc.TagHelpers" -@addTagHelper "*, Microsoft.AspNetCore.SpaServices" diff --git a/samples/angular/MusicStore/Views/_ViewStart.cshtml b/samples/angular/MusicStore/Views/_ViewStart.cshtml deleted file mode 100755 index 820a2f6..0000000 --- a/samples/angular/MusicStore/Views/_ViewStart.cshtml +++ /dev/null @@ -1,3 +0,0 @@ -@{ - Layout = "_Layout"; -} diff --git a/samples/angular/MusicStore/gulpfile.js b/samples/angular/MusicStore/gulpfile.js deleted file mode 100755 index 215f993..0000000 --- a/samples/angular/MusicStore/gulpfile.js +++ /dev/null @@ -1,53 +0,0 @@ -/// - -"use strict"; - -var path = require('path'); -var gulp = require('gulp'); -var del = require('del'); -var typescript = require('gulp-typescript'); -var inlineNg2Template = require('gulp-inline-ng2-template'); -var sourcemaps = require('gulp-sourcemaps'); - -var webroot = "./wwwroot/"; - -var config = { - libBase: 'node_modules', - lib: [ - require.resolve('bootstrap/dist/css/bootstrap.css'), - path.dirname(require.resolve('bootstrap/dist/fonts/glyphicons-halflings-regular.woff')) + '/**', - require.resolve('angular2/bundles/angular2-polyfills.js'), - require.resolve('traceur/bin/traceur-runtime.js'), - require.resolve('es6-module-loader/dist/es6-module-loader-sans-promises.js'), - require.resolve('systemjs/dist/system.src.js'), - require.resolve('angular2/bundles/angular2.dev.js'), - require.resolve('angular2/bundles/router.dev.js'), - require.resolve('angular2/bundles/http.dev.js'), - require.resolve('angular2-aspnet/bundles/angular2-aspnet.js'), - require.resolve('jquery/dist/jquery.js'), - require.resolve('bootstrap/dist/js/bootstrap.js'), - require.resolve('rxjs/bundles/Rx.js') - ] -}; - -gulp.task('build.lib', function () { - return gulp.src(config.lib, { base: config.libBase }) - .pipe(gulp.dest(webroot + 'lib')); -}); - -gulp.task('build', ['build.lib'], function () { - var tsProject = typescript.createProject('./tsconfig.json', { typescript: require('typescript') }); - var tsSrcInlined = gulp.src([webroot + '**/*.ts', 'typings/**/*.d.ts'], { base: webroot }) - .pipe(inlineNg2Template({ base: webroot })); - return tsSrcInlined - .pipe(sourcemaps.init()) - .pipe(typescript(tsProject)) - .pipe(sourcemaps.write()) - .pipe(gulp.dest(webroot)); -}); - -gulp.task('clean', function () { - return del([webroot + 'lib']); -}); - -gulp.task('default', ['build']); diff --git a/samples/angular/MusicStore/package.json b/samples/angular/MusicStore/package.json deleted file mode 100644 index 9946fcb..0000000 --- a/samples/angular/MusicStore/package.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "name": "MusicStore", - "version": "0.0.0", - "dependencies": { - "angular2": "2.0.0-beta.15", - "angular2-aspnet": "^0.0.6", - "angular2-universal": "0.98.1", - "angular2-express-engine": "0.11.1", - "angular2-hapi-engine": "0.11.1", - "aspnet-prerendering": "^1.0.1", - "bootstrap": "^3.3.5", - "css": "^2.2.1", - "es6-module-loader": "0.15.0", - "es6-shim": "^0.35.0", - "isomorphic-fetch": "^2.2.1", - "jquery": "^2.1.4", - "less": "^2.5.3", - "preboot": "2.0.5", - "rxjs": "5.0.0-beta.2", - "systemjs": "^0.19.3", - "traceur": "0.0.106", - "zone.js": "^0.6.10" - }, - "devDependencies": { - "del": "^2.0.2", - "gulp": "^3.9.0", - "gulp-inline-ng2-template": "0.0.7", - "gulp-sourcemaps": "^1.6.0", - "gulp-typescript": "^2.9.0", - "typescript": "^1.6.2" - } -} diff --git a/samples/angular/MusicStore/tsconfig.json b/samples/angular/MusicStore/tsconfig.json deleted file mode 100644 index a4c5eeb..0000000 --- a/samples/angular/MusicStore/tsconfig.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "compilerOptions": { - "module": "commonjs", - "target": "es5", - "sourceMap": false, - "emitDecoratorMetadata": true, - "experimentalDecorators": true, - "noLib": false - }, - "exclude": [ - "node_modules" - ] -} diff --git a/samples/angular/MusicStore/tsd.json b/samples/angular/MusicStore/tsd.json deleted file mode 100644 index dc2f967..0000000 --- a/samples/angular/MusicStore/tsd.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "version": "v4", - "repo": "borisyankov/DefinitelyTyped", - "ref": "master", - "path": "typings", - "bundle": "typings/tsd.d.ts", - "installed": { - "es6-shim/es6-shim.d.ts": { - "commit": "ec9eb4b28c74665a602c22db3457f0a76fa0fa23" - } - } -} diff --git a/samples/angular/MusicStore/typings/es6-shim/es6-shim.d.ts b/samples/angular/MusicStore/typings/es6-shim/es6-shim.d.ts deleted file mode 100644 index 1c3df0e..0000000 --- a/samples/angular/MusicStore/typings/es6-shim/es6-shim.d.ts +++ /dev/null @@ -1,668 +0,0 @@ -// Type definitions for es6-shim v0.31.2 -// Project: https://github.com/paulmillr/es6-shim -// Definitions by: Ron Buckton -// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped - -declare type PropertyKey = string | number | symbol; - -interface IteratorResult { - done: boolean; - value?: T; -} - -interface IterableShim { - /** - * Shim for an ES6 iterable. Not intended for direct use by user code. - */ - "_es6-shim iterator_"(): Iterator; -} - -interface Iterator { - next(value?: any): IteratorResult; - return?(value?: any): IteratorResult; - throw?(e?: any): IteratorResult; -} - -interface IterableIteratorShim extends IterableShim, Iterator { - /** - * Shim for an ES6 iterable iterator. Not intended for direct use by user code. - */ - "_es6-shim iterator_"(): IterableIteratorShim; -} - -interface StringConstructor { - /** - * Return the String value whose elements are, in order, the elements in the List elements. - * If length is 0, the empty string is returned. - */ - fromCodePoint(...codePoints: number[]): string; - - /** - * String.raw is intended for use as a tag function of a Tagged Template String. When called - * as such the first argument will be a well formed template call site object and the rest - * parameter will contain the substitution values. - * @param template A well-formed template string call site representation. - * @param substitutions A set of substitution values. - */ - raw(template: TemplateStringsArray, ...substitutions: any[]): string; -} - -interface String { - /** - * Returns a nonnegative integer Number less than 1114112 (0x110000) that is the code point - * value of the UTF-16 encoded code point starting at the string element at position pos in - * the String resulting from converting this object to a String. - * If there is no element at that position, the result is undefined. - * If a valid UTF-16 surrogate pair does not begin at pos, the result is the code unit at pos. - */ - codePointAt(pos: number): number; - - /** - * Returns true if searchString appears as a substring of the result of converting this - * object to a String, at one or more positions that are - * greater than or equal to position; otherwise, returns false. - * @param searchString search string - * @param position If position is undefined, 0 is assumed, so as to search all of the String. - */ - includes(searchString: string, position?: number): boolean; - - /** - * Returns true if the sequence of elements of searchString converted to a String is the - * same as the corresponding elements of this object (converted to a String) starting at - * endPosition – length(this). Otherwise returns false. - */ - endsWith(searchString: string, endPosition?: number): boolean; - - /** - * Returns a String value that is made from count copies appended together. If count is 0, - * T is the empty String is returned. - * @param count number of copies to append - */ - repeat(count: number): string; - - /** - * Returns true if the sequence of elements of searchString converted to a String is the - * same as the corresponding elements of this object (converted to a String) starting at - * position. Otherwise returns false. - */ - startsWith(searchString: string, position?: number): boolean; - - /** - * Returns an HTML anchor element and sets the name attribute to the text value - * @param name - */ - anchor(name: string): string; - - /** Returns a HTML element */ - big(): string; - - /** Returns a HTML element */ - blink(): string; - - /** Returns a HTML element */ - bold(): string; - - /** Returns a HTML element */ - fixed(): string - - /** Returns a HTML element and sets the color attribute value */ - fontcolor(color: string): string - - /** Returns a HTML element and sets the size attribute value */ - fontsize(size: number): string; - - /** Returns a HTML element and sets the size attribute value */ - fontsize(size: string): string; - - /** Returns an HTML element */ - italics(): string; - - /** Returns an HTML element and sets the href attribute value */ - link(url: string): string; - - /** Returns a HTML element */ - small(): string; - - /** Returns a HTML element */ - strike(): string; - - /** Returns a HTML element */ - sub(): string; - - /** Returns a HTML element */ - sup(): string; - - /** - * Shim for an ES6 iterable. Not intended for direct use by user code. - */ - "_es6-shim iterator_"(): IterableIteratorShim; -} - -interface ArrayConstructor { - /** - * Creates an array from an array-like object. - * @param arrayLike An array-like object to convert to an array. - * @param mapfn A mapping function to call on every element of the array. - * @param thisArg Value of 'this' used to invoke the mapfn. - */ - from(arrayLike: ArrayLike, mapfn: (v: T, k: number) => U, thisArg?: any): Array; - - /** - * Creates an array from an iterable object. - * @param iterable An iterable object to convert to an array. - * @param mapfn A mapping function to call on every element of the array. - * @param thisArg Value of 'this' used to invoke the mapfn. - */ - from(iterable: IterableShim, mapfn: (v: T, k: number) => U, thisArg?: any): Array; - - /** - * Creates an array from an array-like object. - * @param arrayLike An array-like object to convert to an array. - */ - from(arrayLike: ArrayLike): Array; - - /** - * Creates an array from an iterable object. - * @param iterable An iterable object to convert to an array. - */ - from(iterable: IterableShim): Array; - - /** - * Returns a new array from a set of elements. - * @param items A set of elements to include in the new array object. - */ - of(...items: T[]): Array; -} - -interface Array { - /** - * Returns the value of the first element in the array where predicate is true, and undefined - * otherwise. - * @param predicate find calls predicate once for each element of the array, in ascending - * order, until it finds one where predicate returns true. If such an element is found, find - * immediately returns that element value. Otherwise, find returns undefined. - * @param thisArg If provided, it will be used as the this value for each invocation of - * predicate. If it is not provided, undefined is used instead. - */ - find(predicate: (value: T, index: number, obj: Array) => boolean, thisArg?: any): T; - - /** - * Returns the index of the first element in the array where predicate is true, and undefined - * otherwise. - * @param predicate find calls predicate once for each element of the array, in ascending - * order, until it finds one where predicate returns true. If such an element is found, find - * immediately returns that element value. Otherwise, find returns undefined. - * @param thisArg If provided, it will be used as the this value for each invocation of - * predicate. If it is not provided, undefined is used instead. - */ - findIndex(predicate: (value: T) => boolean, thisArg?: any): number; - - /** - * Returns the this object after filling the section identified by start and end with value - * @param value value to fill array section with - * @param start index to start filling the array at. If start is negative, it is treated as - * length+start where length is the length of the array. - * @param end index to stop filling the array at. If end is negative, it is treated as - * length+end. - */ - fill(value: T, start?: number, end?: number): T[]; - - /** - * Returns the this object after copying a section of the array identified by start and end - * to the same array starting at position target - * @param target If target is negative, it is treated as length+target where length is the - * length of the array. - * @param start If start is negative, it is treated as length+start. If end is negative, it - * is treated as length+end. - * @param end If not specified, length of the this object is used as its default value. - */ - copyWithin(target: number, start: number, end?: number): T[]; - - /** - * Returns an array of key, value pairs for every entry in the array - */ - entries(): IterableIteratorShim<[number, T]>; - - /** - * Returns an list of keys in the array - */ - keys(): IterableIteratorShim; - - /** - * Returns an list of values in the array - */ - values(): IterableIteratorShim; - - /** - * Shim for an ES6 iterable. Not intended for direct use by user code. - */ - "_es6-shim iterator_"(): IterableIteratorShim; -} - -interface NumberConstructor { - /** - * The value of Number.EPSILON is the difference between 1 and the smallest value greater than 1 - * that is representable as a Number value, which is approximately: - * 2.2204460492503130808472633361816 x 10‍−‍16. - */ - EPSILON: number; - - /** - * Returns true if passed value is finite. - * Unlike the global isFininte, Number.isFinite doesn't forcibly convert the parameter to a - * number. Only finite values of the type number, result in true. - * @param number A numeric value. - */ - isFinite(number: number): boolean; - - /** - * Returns true if the value passed is an integer, false otherwise. - * @param number A numeric value. - */ - isInteger(number: number): boolean; - - /** - * Returns a Boolean value that indicates whether a value is the reserved value NaN (not a - * number). Unlike the global isNaN(), Number.isNaN() doesn't forcefully convert the parameter - * to a number. Only values of the type number, that are also NaN, result in true. - * @param number A numeric value. - */ - isNaN(number: number): boolean; - - /** - * Returns true if the value passed is a safe integer. - * @param number A numeric value. - */ - isSafeInteger(number: number): boolean; - - /** - * The value of the largest integer n such that n and n + 1 are both exactly representable as - * a Number value. - * The value of Number.MIN_SAFE_INTEGER is 9007199254740991 2^53 − 1. - */ - MAX_SAFE_INTEGER: number; - - /** - * The value of the smallest integer n such that n and n − 1 are both exactly representable as - * a Number value. - * The value of Number.MIN_SAFE_INTEGER is −9007199254740991 (−(2^53 − 1)). - */ - MIN_SAFE_INTEGER: number; - - /** - * Converts a string to a floating-point number. - * @param string A string that contains a floating-point number. - */ - parseFloat(string: string): number; - - /** - * Converts A string to an integer. - * @param s A string to convert into a number. - * @param radix A value between 2 and 36 that specifies the base of the number in numString. - * If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal. - * All other strings are considered decimal. - */ - parseInt(string: string, radix?: number): number; -} - -interface ObjectConstructor { - /** - * Copy the values of all of the enumerable own properties from one or more source objects to a - * target object. Returns the target object. - * @param target The target object to copy to. - * @param sources One or more source objects to copy properties from. - */ - assign(target: any, ...sources: any[]): any; - - /** - * Returns true if the values are the same value, false otherwise. - * @param value1 The first value. - * @param value2 The second value. - */ - is(value1: any, value2: any): boolean; - - /** - * Sets the prototype of a specified object o to object proto or null. Returns the object o. - * @param o The object to change its prototype. - * @param proto The value of the new prototype or null. - * @remarks Requires `__proto__` support. - */ - setPrototypeOf(o: any, proto: any): any; -} - -interface RegExp { - /** - * Returns a string indicating the flags of the regular expression in question. This field is read-only. - * The characters in this string are sequenced and concatenated in the following order: - * - * - "g" for global - * - "i" for ignoreCase - * - "m" for multiline - * - "u" for unicode - * - "y" for sticky - * - * If no flags are set, the value is the empty string. - */ - flags: string; -} - -interface Math { - /** - * Returns the number of leading zero bits in the 32-bit binary representation of a number. - * @param x A numeric expression. - */ - clz32(x: number): number; - - /** - * Returns the result of 32-bit multiplication of two numbers. - * @param x First number - * @param y Second number - */ - imul(x: number, y: number): number; - - /** - * Returns the sign of the x, indicating whether x is positive, negative or zero. - * @param x The numeric expression to test - */ - sign(x: number): number; - - /** - * Returns the base 10 logarithm of a number. - * @param x A numeric expression. - */ - log10(x: number): number; - - /** - * Returns the base 2 logarithm of a number. - * @param x A numeric expression. - */ - log2(x: number): number; - - /** - * Returns the natural logarithm of 1 + x. - * @param x A numeric expression. - */ - log1p(x: number): number; - - /** - * Returns the result of (e^x - 1) of x (e raised to the power of x, where e is the base of - * the natural logarithms). - * @param x A numeric expression. - */ - expm1(x: number): number; - - /** - * Returns the hyperbolic cosine of a number. - * @param x A numeric expression that contains an angle measured in radians. - */ - cosh(x: number): number; - - /** - * Returns the hyperbolic sine of a number. - * @param x A numeric expression that contains an angle measured in radians. - */ - sinh(x: number): number; - - /** - * Returns the hyperbolic tangent of a number. - * @param x A numeric expression that contains an angle measured in radians. - */ - tanh(x: number): number; - - /** - * Returns the inverse hyperbolic cosine of a number. - * @param x A numeric expression that contains an angle measured in radians. - */ - acosh(x: number): number; - - /** - * Returns the inverse hyperbolic sine of a number. - * @param x A numeric expression that contains an angle measured in radians. - */ - asinh(x: number): number; - - /** - * Returns the inverse hyperbolic tangent of a number. - * @param x A numeric expression that contains an angle measured in radians. - */ - atanh(x: number): number; - - /** - * Returns the square root of the sum of squares of its arguments. - * @param values Values to compute the square root for. - * If no arguments are passed, the result is +0. - * If there is only one argument, the result is the absolute value. - * If any argument is +Infinity or -Infinity, the result is +Infinity. - * If any argument is NaN, the result is NaN. - * If all arguments are either +0 or −0, the result is +0. - */ - hypot(...values: number[]): number; - - /** - * Returns the integral part of the a numeric expression, x, removing any fractional digits. - * If x is already an integer, the result is x. - * @param x A numeric expression. - */ - trunc(x: number): number; - - /** - * Returns the nearest single precision float representation of a number. - * @param x A numeric expression. - */ - fround(x: number): number; - - /** - * Returns an implementation-dependent approximation to the cube root of number. - * @param x A numeric expression. - */ - cbrt(x: number): number; -} - -interface PromiseLike { - /** - * Attaches callbacks for the resolution and/or rejection of the Promise. - * @param onfulfilled The callback to execute when the Promise is resolved. - * @param onrejected The callback to execute when the Promise is rejected. - * @returns A Promise for the completion of which ever callback is executed. - */ - then(onfulfilled?: (value: T) => TResult | PromiseLike, onrejected?: (reason: any) => TResult | PromiseLike): PromiseLike; - then(onfulfilled?: (value: T) => TResult | PromiseLike, onrejected?: (reason: any) => void): PromiseLike; -} - -/** - * Represents the completion of an asynchronous operation - */ -interface Promise { - /** - * Attaches callbacks for the resolution and/or rejection of the Promise. - * @param onfulfilled The callback to execute when the Promise is resolved. - * @param onrejected The callback to execute when the Promise is rejected. - * @returns A Promise for the completion of which ever callback is executed. - */ - then(onfulfilled?: (value: T) => TResult | PromiseLike, onrejected?: (reason: any) => TResult | PromiseLike): Promise; - then(onfulfilled?: (value: T) => TResult | PromiseLike, onrejected?: (reason: any) => void): Promise; - - /** - * Attaches a callback for only the rejection of the Promise. - * @param onrejected The callback to execute when the Promise is rejected. - * @returns A Promise for the completion of the callback. - */ - catch(onrejected?: (reason: any) => T | PromiseLike): Promise; - catch(onrejected?: (reason: any) => void): Promise; -} - -interface PromiseConstructor { - /** - * A reference to the prototype. - */ - prototype: Promise; - - /** - * Creates a new Promise. - * @param executor A callback used to initialize the promise. This callback is passed two arguments: - * a resolve callback used resolve the promise with a value or the result of another promise, - * and a reject callback used to reject the promise with a provided reason or error. - */ - new (executor: (resolve: (value?: T | PromiseLike) => void, reject: (reason?: any) => void) => void): Promise; - - /** - * Creates a Promise that is resolved with an array of results when all of the provided Promises - * resolve, or rejected when any Promise is rejected. - * @param values An array of Promises. - * @returns A new Promise. - */ - all(values: IterableShim>): Promise; - - /** - * Creates a Promise that is resolved or rejected when any of the provided Promises are resolved - * or rejected. - * @param values An array of Promises. - * @returns A new Promise. - */ - race(values: IterableShim>): Promise; - - /** - * Creates a new rejected promise for the provided reason. - * @param reason The reason the promise was rejected. - * @returns A new rejected Promise. - */ - reject(reason: any): Promise; - - /** - * Creates a new rejected promise for the provided reason. - * @param reason The reason the promise was rejected. - * @returns A new rejected Promise. - */ - reject(reason: any): Promise; - - /** - * Creates a new resolved promise for the provided value. - * @param value A promise. - * @returns A promise whose internal state matches the provided promise. - */ - resolve(value: T | PromiseLike): Promise; - - /** - * Creates a new resolved promise . - * @returns A resolved promise. - */ - resolve(): Promise; -} - -declare var Promise: PromiseConstructor; - -interface Map { - clear(): void; - delete(key: K): boolean; - forEach(callbackfn: (value: V, index: K, map: Map) => void, thisArg?: any): void; - get(key: K): V; - has(key: K): boolean; - set(key: K, value?: V): Map; - size: number; - entries(): IterableIteratorShim<[K, V]>; - keys(): IterableIteratorShim; - values(): IterableIteratorShim; -} - -interface MapConstructor { - new (): Map; - new (iterable: IterableShim<[K, V]>): Map; - prototype: Map; -} - -declare var Map: MapConstructor; - -interface Set { - add(value: T): Set; - clear(): void; - delete(value: T): boolean; - forEach(callbackfn: (value: T, index: T, set: Set) => void, thisArg?: any): void; - has(value: T): boolean; - size: number; - entries(): IterableIteratorShim<[T, T]>; - keys(): IterableIteratorShim; - values(): IterableIteratorShim; -} - -interface SetConstructor { - new (): Set; - new (iterable: IterableShim): Set; - prototype: Set; -} - -declare var Set: SetConstructor; - -interface WeakMap { - delete(key: K): boolean; - get(key: K): V; - has(key: K): boolean; - set(key: K, value?: V): WeakMap; -} - -interface WeakMapConstructor { - new (): WeakMap; - new (iterable: IterableShim<[K, V]>): WeakMap; - prototype: WeakMap; -} - -declare var WeakMap: WeakMapConstructor; - -interface WeakSet { - add(value: T): WeakSet; - delete(value: T): boolean; - has(value: T): boolean; -} - -interface WeakSetConstructor { - new (): WeakSet; - new (iterable: IterableShim): WeakSet; - prototype: WeakSet; -} - -declare var WeakSet: WeakSetConstructor; - -declare namespace Reflect { - function apply(target: Function, thisArgument: any, argumentsList: ArrayLike): any; - function construct(target: Function, argumentsList: ArrayLike): any; - function defineProperty(target: any, propertyKey: PropertyKey, attributes: PropertyDescriptor): boolean; - function deleteProperty(target: any, propertyKey: PropertyKey): boolean; - function enumerate(target: any): IterableIteratorShim; - function get(target: any, propertyKey: PropertyKey, receiver?: any): any; - function getOwnPropertyDescriptor(target: any, propertyKey: PropertyKey): PropertyDescriptor; - function getPrototypeOf(target: any): any; - function has(target: any, propertyKey: PropertyKey): boolean; - function isExtensible(target: any): boolean; - function ownKeys(target: any): Array; - function preventExtensions(target: any): boolean; - function set(target: any, propertyKey: PropertyKey, value: any, receiver?: any): boolean; - function setPrototypeOf(target: any, proto: any): boolean; -} - -declare module "es6-shim" { - var String: StringConstructor; - var Array: ArrayConstructor; - var Number: NumberConstructor; - var Math: Math; - var Object: ObjectConstructor; - var Map: MapConstructor; - var Set: SetConstructor; - var WeakMap: WeakMapConstructor; - var WeakSet: WeakSetConstructor; - var Promise: PromiseConstructor; - namespace Reflect { - function apply(target: Function, thisArgument: any, argumentsList: ArrayLike): any; - function construct(target: Function, argumentsList: ArrayLike): any; - function defineProperty(target: any, propertyKey: PropertyKey, attributes: PropertyDescriptor): boolean; - function deleteProperty(target: any, propertyKey: PropertyKey): boolean; - function enumerate(target: any): Iterator; - function get(target: any, propertyKey: PropertyKey, receiver?: any): any; - function getOwnPropertyDescriptor(target: any, propertyKey: PropertyKey): PropertyDescriptor; - function getPrototypeOf(target: any): any; - function has(target: any, propertyKey: PropertyKey): boolean; - function isExtensible(target: any): boolean; - function ownKeys(target: any): Array; - function preventExtensions(target: any): boolean; - function set(target: any, propertyKey: PropertyKey, value: any, receiver?: any): boolean; - function setPrototypeOf(target: any, proto: any): boolean; - } -} diff --git a/samples/angular/MusicStore/typings/tsd.d.ts b/samples/angular/MusicStore/typings/tsd.d.ts deleted file mode 100644 index 8b614f9..0000000 --- a/samples/angular/MusicStore/typings/tsd.d.ts +++ /dev/null @@ -1,2 +0,0 @@ - -/// diff --git a/samples/angular/MusicStore/typings/url-workaround.d.ts b/samples/angular/MusicStore/typings/url-workaround.d.ts deleted file mode 100644 index 9d16760..0000000 --- a/samples/angular/MusicStore/typings/url-workaround.d.ts +++ /dev/null @@ -1,7 +0,0 @@ -// This file is a workaround for angular2-universal-preview version 0.84.2 relying on the declaration of -// Node's 'url' module. Ideally it would not declare dependencies on Node APIs except where it also supplies -// the definitions itself. - -declare module 'url' { - export interface Url {} -} diff --git a/samples/angular/MusicStore/wwwroot/css/site.css b/samples/angular/MusicStore/wwwroot/css/site.css deleted file mode 100644 index 952e03f..0000000 --- a/samples/angular/MusicStore/wwwroot/css/site.css +++ /dev/null @@ -1,3 +0,0 @@ -body { - padding-top: 50px; -} diff --git a/samples/angular/MusicStore/wwwroot/css/styles.less b/samples/angular/MusicStore/wwwroot/css/styles.less deleted file mode 100644 index 564f8f4..0000000 --- a/samples/angular/MusicStore/wwwroot/css/styles.less +++ /dev/null @@ -1,14 +0,0 @@ -@base: #f938ab; - -.box-shadow(@style, @c) when (iscolor(@c)) { - -webkit-box-shadow: @style @c; - box-shadow: @style @c; -} -.box-shadow(@style, @alpha: 50%) when (isnumber(@alpha)) { - .box-shadow(@style, rgba(0, 0, 0, @alpha)); -} -.box { - color: saturate(@base, 5%); - border-color: lighten(@base, 30%); - div { .box-shadow(0 0 5px, 30%) } -} diff --git a/samples/angular/MusicStore/wwwroot/images/home-showcase.png b/samples/angular/MusicStore/wwwroot/images/home-showcase.png deleted file mode 100644 index 258c19d..0000000 Binary files a/samples/angular/MusicStore/wwwroot/images/home-showcase.png and /dev/null differ diff --git a/samples/angular/MusicStore/wwwroot/images/logo.png b/samples/angular/MusicStore/wwwroot/images/logo.png deleted file mode 100644 index d334c86..0000000 Binary files a/samples/angular/MusicStore/wwwroot/images/logo.png and /dev/null differ diff --git a/samples/angular/MusicStore/wwwroot/images/placeholder.png b/samples/angular/MusicStore/wwwroot/images/placeholder.png deleted file mode 100644 index 1f73dbb..0000000 Binary files a/samples/angular/MusicStore/wwwroot/images/placeholder.png and /dev/null differ diff --git a/samples/angular/MusicStore/wwwroot/ng-app/boot-client.ts b/samples/angular/MusicStore/wwwroot/ng-app/boot-client.ts deleted file mode 100644 index 65e24a0..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/boot-client.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { bootstrap } from 'angular2/platform/browser'; -import { FormBuilder } from 'angular2/common'; -import * as router from 'angular2/router'; -import { Http, HTTP_PROVIDERS } from 'angular2/http'; -import { CACHE_PRIMED_HTTP_PROVIDERS } from 'angular2-aspnet'; -import { App } from './components/app/app'; - -bootstrap(App, [router.ROUTER_BINDINGS, HTTP_PROVIDERS, CACHE_PRIMED_HTTP_PROVIDERS, FormBuilder]); diff --git a/samples/angular/MusicStore/wwwroot/ng-app/boot-server.ts b/samples/angular/MusicStore/wwwroot/ng-app/boot-server.ts deleted file mode 100644 index 10578a1..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/boot-server.ts +++ /dev/null @@ -1,30 +0,0 @@ -import 'angular2-universal/polyfills'; -import { FormBuilder } from 'angular2/common'; -import * as ngCore from 'angular2/core'; -import * as ngRouter from 'angular2/router'; -import * as ngUniversal from 'angular2-universal'; -import { BASE_URL, ORIGIN_URL, REQUEST_URL } from 'angular2-universal/common'; -import { App } from './components/app/app'; - -export default function (params: any): Promise<{ html: string, globals?: any }> { - const serverBindings = [ - ngCore.provide(BASE_URL, { useValue: '/' }), - ngCore.provide(ORIGIN_URL, { useValue: params.origin }), - ngCore.provide(REQUEST_URL, { useValue: params.url }), - ngUniversal.NODE_HTTP_PROVIDERS, - ngUniversal.NODE_ROUTER_PROVIDERS, - FormBuilder - ]; - - return ngUniversal.bootloader({ - directives: [App], - providers: serverBindings, - async: true, - preboot: false, - // TODO: Render just the component instead of wrapping it inside an extra HTML document - // Waiting on https://github.com/angular/universal/issues/347 - template: '\n' - }).serializeApplication().then(html => { - return { html }; - }); -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/admin-home/admin-home.html b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/admin-home/admin-home.html deleted file mode 100644 index 79e4fcd..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/admin-home/admin-home.html +++ /dev/null @@ -1,3 +0,0 @@ -

Store Manager

- - diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/admin-home/admin-home.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/admin-home/admin-home.ts deleted file mode 100644 index 47a501a..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/admin-home/admin-home.ts +++ /dev/null @@ -1,19 +0,0 @@ -import * as ng from 'angular2/core'; -import * as router from 'angular2/router'; -import { AlbumsList } from '../albums-list/albums-list'; -import { AlbumDetails } from '../album-details/album-details'; -import { AlbumEdit } from '../album-edit/album-edit'; - -@ng.Component({ - selector: 'admin-home', - templateUrl: './ng-app/components/admin/admin-home/admin-home.html', - directives: [router.ROUTER_DIRECTIVES] -}) -@router.RouteConfig([ - { path: 'albums', name: 'Albums', component: AlbumsList }, - { path: 'album/details/:albumId', name: 'AlbumDetails', component: AlbumDetails }, - { path: 'album/edit/:albumId', name: 'AlbumEdit', component: AlbumEdit } -]) -export class AdminHome { - -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-delete-prompt/album-delete-prompt.html b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-delete-prompt/album-delete-prompt.html deleted file mode 100644 index 2f6b0ba..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-delete-prompt/album-delete-prompt.html +++ /dev/null @@ -1,17 +0,0 @@ - diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-delete-prompt/album-delete-prompt.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-delete-prompt/album-delete-prompt.ts deleted file mode 100644 index 9ad6674..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-delete-prompt/album-delete-prompt.ts +++ /dev/null @@ -1,20 +0,0 @@ -import * as ng from 'angular2/core'; -import * as models from '../../../models/models'; - -@ng.Component({ - selector: 'album-delete-prompt', - templateUrl: './ng-app/components/admin/album-delete-prompt/album-delete-prompt.html' -}) -export class AlbumDeletePrompt { - public album: models.Album; - - constructor(@ng.Inject(ng.ElementRef) private _elementRef: ng.ElementRef) { - } - - public show(album: models.Album) { - this.album = album; - - // Consider rewriting this using Angular's "Renderer" API so as to avoid direct DOM access - (window).jQuery(".modal", this._elementRef.nativeElement).modal(); - } -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-details/album-details.html b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-details/album-details.html deleted file mode 100644 index a13e0d1..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-details/album-details.html +++ /dev/null @@ -1,50 +0,0 @@ -

Album Details

-
- -
- - diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-details/album-details.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-details/album-details.ts deleted file mode 100644 index 05ac4da..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-details/album-details.ts +++ /dev/null @@ -1,20 +0,0 @@ -import * as ng from 'angular2/core'; -import * as router from 'angular2/router'; -import * as models from '../../../models/models'; -import { Http, HTTP_BINDINGS } from 'angular2/http'; -import { AlbumDeletePrompt } from '../album-delete-prompt/album-delete-prompt'; - -@ng.Component({ - selector: 'album-details', - templateUrl: './ng-app/components/admin/album-details/album-details.html', - directives: [router.ROUTER_DIRECTIVES, AlbumDeletePrompt] -}) -export class AlbumDetails { - public albumData: models.Album; - - constructor(http: Http, routeParam: router.RouteParams) { - http.get('/api/albums/' + routeParam.params['albumId']).subscribe(result => { - this.albumData = result.json(); - }); - } -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-edit/album-edit.html b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-edit/album-edit.html deleted file mode 100644 index 3b09db1..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-edit/album-edit.html +++ /dev/null @@ -1,47 +0,0 @@ -

Album Edit

-
- -
- - - - - - - - - - - - - -
- $ - -
-
- - - - - - - - - - -
Done! Your changes were saved.
-
{{ errorMessage }}
- - - Back to List -
-
- - diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-edit/album-edit.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-edit/album-edit.ts deleted file mode 100644 index 4b83c3b..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/album-edit/album-edit.ts +++ /dev/null @@ -1,94 +0,0 @@ -import * as ng from 'angular2/core'; -import { Observable } from 'rxjs'; -import { Control, ControlGroup, FormBuilder, Validators, FORM_DIRECTIVES } from 'angular2/common'; -import * as router from 'angular2/router'; -import * as models from '../../../models/models'; -import { Http, HTTP_BINDINGS, Headers, Response } from 'angular2/http'; -import { AlbumDeletePrompt } from '../album-delete-prompt/album-delete-prompt'; -import { FormField } from '../form-field/form-field'; -import * as AspNet from 'angular2-aspnet'; - -@ng.Component({ - selector: 'album-edit', - templateUrl: './ng-app/components/admin/album-edit/album-edit.html', - directives: [router.ROUTER_DIRECTIVES, AlbumDeletePrompt, FormField, FORM_DIRECTIVES] -}) -export class AlbumEdit { - public form: ControlGroup; - public artists: models.Artist[]; - public genres: models.Genre[]; - public originalAlbum: models.Album; - public changesSaved: boolean; - public formErrors: string[] = []; - - private _http: Http; - - constructor(fb: FormBuilder, http: Http, routeParam: router.RouteParams) { - this._http = http; - - var albumId = parseInt(routeParam.params['albumId']); - http.get('/api/albums/' + albumId).subscribe(result => { - var json = result.json(); - this.originalAlbum = json; - (this.form.controls['Title']).updateValue(json.Title); - (this.form.controls['Price']).updateValue(json.Price); - (this.form.controls['ArtistId']).updateValue(json.ArtistId); - (this.form.controls['GenreId']).updateValue(json.GenreId); - (this.form.controls['AlbumArtUrl']).updateValue(json.AlbumArtUrl); - }); - - http.get('/api/artists/lookup').subscribe(result => { - this.artists = result.json(); - }); - - http.get('/api/genres/genre-lookup').subscribe(result => { - this.genres = result.json(); - }); - - this.form = fb.group({ - AlbumId: fb.control(albumId), - ArtistId: fb.control(0, Validators.required), - GenreId: fb.control(0, Validators.required), - Title: fb.control('', Validators.required), - Price: fb.control('', Validators.compose([Validators.required, AlbumEdit._validatePrice])), - AlbumArtUrl: fb.control('', Validators.required) - }); - - this.form.valueChanges.subscribe(() => { - this.changesSaved = false; - }); - } - - public onSubmitModelBased() { - // Force all fields to show any validation errors even if they haven't been touched - Object.keys(this.form.controls).forEach(controlName => { - this.form.controls[controlName].markAsTouched(); - }); - - if (this.form.valid) { - var controls = this.form.controls; - var albumId = this.originalAlbum.AlbumId; - - this._putJson(`/api/albums/${ albumId }/update`, this.form.value).subscribe(successResponse => { - this.changesSaved = true; - }, errorResponse => { - AspNet.Validation.showValidationErrors(errorResponse, this.form); - }); - } - } - - private static _validatePrice(control: Control): { [key: string]: boolean } { - return /^\d+\.\d+$/.test(control.value) ? null : { Price: true }; - } - - // Need feedback on whether this really is the easiest way to PUT some JSON - private _putJson(url: string, body: any): Observable { - return this._http.put(url, JSON.stringify(body), { - headers: new Headers({ 'Content-Type': 'application/json' }) - }); - } - - private ngDoCheck() { - this.formErrors = this.form.dirty ? Object.keys(this.form.errors || {}) : []; - } -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/albums-list/albums-list.html b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/albums-list/albums-list.html deleted file mode 100644 index 51889e7..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/albums-list/albums-list.html +++ /dev/null @@ -1,44 +0,0 @@ -

Albums

- - - - - - - - - - - - - - - - - - - - - - -
GenreArtistTitlePrice
{{ row.Genre.Name }}{{ row.Artist.Name }}{{ row.Title }}{{ row.Price | currency:'USD':true }} -
- Details - Edit - Delete -
-
- -
- - - - - -
- -

{{ totalCount }} total albums

diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/albums-list/albums-list.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/albums-list/albums-list.ts deleted file mode 100644 index 989d6e9..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/albums-list/albums-list.ts +++ /dev/null @@ -1,68 +0,0 @@ -import * as ng from 'angular2/core'; -import * as router from 'angular2/router'; -import { Http, HTTP_BINDINGS } from 'angular2/http'; -import * as models from '../../../models/models'; -import { AlbumDeletePrompt } from '../album-delete-prompt/album-delete-prompt'; - -@ng.Component({ - selector: 'albums-list', - templateUrl: './ng-app/components/admin/albums-list/albums-list.html', - directives: [router.ROUTER_DIRECTIVES, AlbumDeletePrompt] -}) -export class AlbumsList { - public rows: models.Album[]; - public canGoBack: boolean; - public canGoForward: boolean; - public pageLinks: any[]; - public totalCount: number; - public get pageIndex() { - return this._pageIndex; - } - - private _http: Http; - private _pageIndex = 1; - private _sortBy = "Title"; - private _sortByDesc = false; - - constructor(http: Http) { - this._http = http; - this.refreshData(); - } - - public sortBy(col: string) { - this._sortByDesc = col === this._sortBy ? !this._sortByDesc : false; - this._sortBy = col; - this.refreshData(); - } - - public goToPage(pageIndex: number) { - this._pageIndex = pageIndex; - this.refreshData(); - } - - public goToLast() { - this.goToPage(this.pageLinks[this.pageLinks.length - 1].index); - } - - refreshData() { - var sortBy = this._sortBy + (this._sortByDesc ? ' DESC' : ''); - this._http.get(`/api/albums?page=${ this._pageIndex }&pageSize=50&sortBy=${ sortBy }`).subscribe(result => { - var json = result.json(); - this.rows = json.Data; - - var numPages = Math.ceil(json.TotalCount / json.PageSize); - this.pageLinks = []; - for (var i = 1; i <= numPages; i++) { - this.pageLinks.push({ - index: i, - text: i.toString(), - isCurrent: i === json.Page - }); - } - - this.canGoBack = this.pageLinks.length && !this.pageLinks[0].isCurrent; - this.canGoForward = this.pageLinks.length && !this.pageLinks[this.pageLinks.length - 1].isCurrent; - this.totalCount = json.TotalCount; - }); - } -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/form-field/form-field.html b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/form-field/form-field.html deleted file mode 100644 index 82e773b..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/form-field/form-field.html +++ /dev/null @@ -1,9 +0,0 @@ -
- -
- - -
-
diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/form-field/form-field.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/admin/form-field/form-field.ts deleted file mode 100644 index 267d778..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/admin/form-field/form-field.ts +++ /dev/null @@ -1,19 +0,0 @@ -import * as ng from 'angular2/core'; -import { AbstractControl } from 'angular2/common'; - -@ng.Component({ - selector: 'form-field', - properties: ['label', 'validate'], - templateUrl: './ng-app/components/admin/form-field/form-field.html' -}) -export class FormField { - public errorMessages: string[] = []; - private validate: AbstractControl; - - private ngDoCheck() { - var errors = (this.validate && this.validate.dirty && this.validate.errors) || {}; - this.errorMessages = Object.keys(errors).map(key => { - return 'Error: ' + key; - }); - } -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/app/app.css b/samples/angular/MusicStore/wwwroot/ng-app/components/app/app.css deleted file mode 100644 index e69de29..0000000 diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/app/app.html b/samples/angular/MusicStore/wwwroot/ng-app/components/app/app.html deleted file mode 100644 index a257b20..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/app/app.html +++ /dev/null @@ -1,30 +0,0 @@ - -
- -
diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/app/app.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/app/app.ts deleted file mode 100644 index cd83aa4..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/app/app.ts +++ /dev/null @@ -1,33 +0,0 @@ -import * as ng from 'angular2/core'; -import * as router from 'angular2/router'; -import { Http, HTTP_BINDINGS } from 'angular2/http'; -import { Home } from '../public/home/home'; -import { AlbumDetails } from '../public/album-details/album-details'; -import { GenreContents } from '../public/genre-contents/genre-contents'; -import { GenresList } from '../public/genres-list/genres-list'; -import { AdminHome } from '../admin/admin-home/admin-home'; -import * as models from '../../models/models'; - -@ng.Component({ - selector: 'app', - templateUrl: './ng-app/components/app/app.html', - styleUrls: ['./ng-app/components/app/app.css'], - directives: [router.ROUTER_DIRECTIVES] -}) -@router.RouteConfig([ - { path: '/', component: Home, name: 'Home' }, - { path: '/album/:albumId', component: AlbumDetails, name: 'Album' }, - { path: '/genre/:genreId', component: GenreContents, name: 'Genre' }, - { path: '/genres', component: GenresList, name: 'GenresList' }, - { path: '/admin/...', component: AdminHome, name: 'Admin' } -]) -export class App { - public genres: models.Genre[]; - - constructor(http: Http) { - http.get('/api/genres/menu').subscribe(result => { - this.genres = result.json(); - }); - } -} - diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-details/album-details.html b/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-details/album-details.html deleted file mode 100644 index d015364..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-details/album-details.html +++ /dev/null @@ -1,26 +0,0 @@ -
-

{{ albumData.Title }}

- -

- {{ albumData.Title }} -

- -
-

- Genre: - {{ albumData.Genre.Name }} -

-

- Artist: - {{ albumData.Artist.Name }} -

-

- Price: - {{ albumData.Price | currency:'USD':true }} -

-

- - Add to cart -

-
-
diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-details/album-details.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-details/album-details.ts deleted file mode 100644 index 61d7d4e..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-details/album-details.ts +++ /dev/null @@ -1,18 +0,0 @@ -import * as ng from 'angular2/core'; -import * as router from 'angular2/router'; -import { Http } from 'angular2/http'; -import * as models from '../../../models/models'; - -@ng.Component({ - selector: 'album-details', - templateUrl: './ng-app/components/public/album-details/album-details.html' -}) -export class AlbumDetails { - public albumData: models.Album; - - constructor(http: Http, routeParam: router.RouteParams) { - http.get('/api/albums/' + routeParam.params['albumId']).subscribe(result => { - this.albumData = result.json(); - }); - } -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-tile/album-tile.html b/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-tile/album-tile.html deleted file mode 100644 index 0df947d..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-tile/album-tile.html +++ /dev/null @@ -1,4 +0,0 @@ - - {{ albumData.Title }} -

{{ albumData.Title }}

-
diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-tile/album-tile.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-tile/album-tile.ts deleted file mode 100644 index d289ec9..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/public/album-tile/album-tile.ts +++ /dev/null @@ -1,12 +0,0 @@ -import * as ng from 'angular2/core'; -import * as router from 'angular2/router'; -import * as models from '../../../models/models'; - -@ng.Component({ - selector: 'album-tile', - properties: ['albumData'], - templateUrl: './ng-app/components/public/album-tile/album-tile.html', - directives: [router.ROUTER_DIRECTIVES] -}) -export class AlbumTile { -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/public/genre-contents/genre-contents.html b/samples/angular/MusicStore/wwwroot/ng-app/components/public/genre-contents/genre-contents.html deleted file mode 100644 index 7738ce5..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/public/genre-contents/genre-contents.html +++ /dev/null @@ -1,7 +0,0 @@ -

Albums

- -
    -
  • - -
  • -
diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/public/genre-contents/genre-contents.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/public/genre-contents/genre-contents.ts deleted file mode 100644 index 0571cc8..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/public/genre-contents/genre-contents.ts +++ /dev/null @@ -1,20 +0,0 @@ -import * as ng from 'angular2/core'; -import * as router from 'angular2/router'; -import { Http } from 'angular2/http'; -import * as models from '../../../models/models'; -import { AlbumTile } from '../album-tile/album-tile'; - -@ng.Component({ - selector: 'genre-contents', - templateUrl: './ng-app/components/public/genre-contents/genre-contents.html', - directives: [AlbumTile] -}) -export class GenreContents { - public albums: models.Album[]; - - constructor(http: Http, routeParam: router.RouteParams) { - http.get(`/api/genres/${ routeParam.params['genreId'] }/albums`).subscribe(result => { - this.albums = result.json(); - }); - } -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/public/genres-list/genres-list.html b/samples/angular/MusicStore/wwwroot/ng-app/components/public/genres-list/genres-list.html deleted file mode 100644 index e91d6f3..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/public/genres-list/genres-list.html +++ /dev/null @@ -1,13 +0,0 @@ -

Browse Genres

- -

- Select from {{ genres.length }} genres: -

- - diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/public/genres-list/genres-list.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/public/genres-list/genres-list.ts deleted file mode 100644 index f45b77a..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/public/genres-list/genres-list.ts +++ /dev/null @@ -1,19 +0,0 @@ -import * as ng from 'angular2/core'; -import * as router from 'angular2/router'; -import { Http } from 'angular2/http'; -import * as models from '../../../models/models'; - -@ng.Component({ - selector: 'genres-list', - templateUrl: './ng-app/components/public/genres-list/genres-list.html', - directives: [router.ROUTER_DIRECTIVES] -}) -export class GenresList { - public genres: models.Genre[]; - - constructor(http: Http) { - http.get('/api/genres').subscribe(result => { - this.genres = result.json(); - }); - } -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/public/home/home.html b/samples/angular/MusicStore/wwwroot/ng-app/components/public/home/home.html deleted file mode 100644 index 133a495..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/public/home/home.html +++ /dev/null @@ -1,10 +0,0 @@ -
-

MVC Music Store

- -
- -
    -
  • - -
  • -
diff --git a/samples/angular/MusicStore/wwwroot/ng-app/components/public/home/home.ts b/samples/angular/MusicStore/wwwroot/ng-app/components/public/home/home.ts deleted file mode 100644 index 51989da..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/components/public/home/home.ts +++ /dev/null @@ -1,19 +0,0 @@ -import * as ng from 'angular2/core'; -import { Http } from 'angular2/http'; -import { AlbumTile } from '../album-tile/album-tile'; -import * as models from '../../../models/models'; - -@ng.Component({ - selector: 'home', - templateUrl: './ng-app/components/public/home/home.html', - directives: [AlbumTile] -}) -export class Home { - public mostPopular: models.Album[]; - - constructor(http: Http) { - http.get('/api/albums/mostPopular').subscribe(result => { - this.mostPopular = result.json(); - }); - } -} diff --git a/samples/angular/MusicStore/wwwroot/ng-app/models/models.ts b/samples/angular/MusicStore/wwwroot/ng-app/models/models.ts deleted file mode 100644 index 44c705a..0000000 --- a/samples/angular/MusicStore/wwwroot/ng-app/models/models.ts +++ /dev/null @@ -1,16 +0,0 @@ -export interface Album { - AlbumId: number; - Title: string; - AlbumArtUrl: string; -} - -export interface Genre { - GenreId: number; - Name: string; - Description: string; -} - -export interface Artist { - ArtistId: number; - Name: string; -} diff --git a/samples/angular/MusicStore/wwwroot/system.config.js b/samples/angular/MusicStore/wwwroot/system.config.js deleted file mode 100644 index 400211f..0000000 --- a/samples/angular/MusicStore/wwwroot/system.config.js +++ /dev/null @@ -1,3 +0,0 @@ -System.config({ - defaultJSExtensions: true -}); diff --git a/samples/angular/MusicStore/wwwroot/web.config b/samples/angular/MusicStore/wwwroot/web.config deleted file mode 100644 index bb50c71..0000000 --- a/samples/angular/MusicStore/wwwroot/web.config +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/samples/react/MusicStore/.babelrc b/samples/react/MusicStore/.babelrc deleted file mode 100644 index 86c445f..0000000 --- a/samples/react/MusicStore/.babelrc +++ /dev/null @@ -1,3 +0,0 @@ -{ - "presets": ["es2015", "react"] -} diff --git a/samples/react/MusicStore/.gitignore b/samples/react/MusicStore/.gitignore deleted file mode 100644 index 8d1beeb..0000000 --- a/samples/react/MusicStore/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -music-db.sqlite -/wwwroot/dist/ -/node_modules/ -yarn.lock diff --git a/samples/react/MusicStore/Apis/AlbumsApiController.cs b/samples/react/MusicStore/Apis/AlbumsApiController.cs deleted file mode 100644 index 511f63c..0000000 --- a/samples/react/MusicStore/Apis/AlbumsApiController.cs +++ /dev/null @@ -1,201 +0,0 @@ -using System.ComponentModel.DataAnnotations; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Authorization; -using Microsoft.AspNetCore.Mvc; -using Microsoft.EntityFrameworkCore; -using AutoMapper; -using MusicStore.Models; -using MusicStore.Infrastructure; - -namespace MusicStore.Apis -{ - [Route("api/albums")] - public class AlbumsApiController : Controller - { - private readonly MusicStoreContext _storeContext; - - public AlbumsApiController(MusicStoreContext storeContext) - { - _storeContext = storeContext; - } - - [HttpGet] - [NoCache] - public async Task Paged(int page = 1, int pageSize = 50, string sortBy = null) - { - await _storeContext.Genres.LoadAsync(); - await _storeContext.Artists.LoadAsync(); - - var albums = await _storeContext.Albums - .Include(a => a.Genre) - .Include(a => a.Artist) - .ToPagedListAsync(page, pageSize, sortBy, - a => a.Title, // sortExpression - SortDirection.Ascending, // defaultSortDirection - a => Mapper.Map(a, new AlbumResultDto())); // selector - - return Json(albums); - } - - [HttpGet("all")] - [NoCache] - public async Task All() - { - var albums = await _storeContext.Albums - .Include(a => a.Genre) - .Include(a => a.Artist) - .OrderBy(a => a.Title) - .ToListAsync(); - - return Json(albums.Select(a => Mapper.Map(a, new AlbumResultDto()))); - } - - [HttpGet("mostPopular")] - [NoCache] - public async Task MostPopular(int count = 6) - { - count = count > 0 && count < 20 ? count : 6; - var albums = await _storeContext.Albums - .OrderByDescending(a => a.OrderDetails.Count()) - .Take(count) - .ToListAsync(); - - // TODO: Move the .Select() to end of albums query when EF supports it - return Json(albums.Select(a => Mapper.Map(a, new AlbumResultDto()))); - } - - [HttpGet("{albumId:int}")] - [NoCache] - public async Task Details(int albumId) - { - await _storeContext.Genres.LoadAsync(); - await _storeContext.Artists.LoadAsync(); - - var album = await _storeContext.Albums - .Include(a => a.Artist) - .Include(a => a.Genre) - .Where(a => a.AlbumId == albumId) - .SingleOrDefaultAsync(); - - var albumResult = Mapper.Map(album, new AlbumResultDto()); - - // TODO: Add null checking and return 404 in that case - - return Json(albumResult); - } - - [HttpPost] - [Authorize("app-ManageStore")] - public async Task CreateAlbum([FromBody]AlbumChangeDto album) - { - if (!ModelState.IsValid) - { - // Return the model errors - return BadRequest(ModelState); - } - - // Save the changes to the DB - var dbAlbum = new Album(); - _storeContext.Albums.Add(Mapper.Map(album, dbAlbum)); - await _storeContext.SaveChangesAsync(); - - // TODO: Handle missing record, key violations, concurrency issues, etc. - - return new ObjectResult(new { - Data = dbAlbum.AlbumId, - Message = "Album created successfully." - }); - } - - [HttpPut("{albumId:int}/update")] - public async Task UpdateAlbum(int albumId, [FromBody] AlbumChangeDto album) - { - if (!ModelState.IsValid) - { - // Return the model errors - return BadRequest(ModelState); - } - - var dbAlbum = await _storeContext.Albums.SingleOrDefaultAsync(a => a.AlbumId == albumId); - - if (dbAlbum == null) - { - return new ObjectResult(new { - Message = string.Format("The album with ID {0} was not found.", albumId) - }) { StatusCode = 404 }; - } - - // Save the changes to the DB - Mapper.Map(album, dbAlbum); - await _storeContext.SaveChangesAsync(); - - // TODO: Handle missing record, key violations, concurrency issues, etc. - - return new ObjectResult (new { - Message = "Album updated successfully." - }); - } - - [HttpDelete("{albumId:int}")] - [Authorize("app-ManageStore")] - public async Task DeleteAlbum(int albumId) - { - var album = await _storeContext.Albums.SingleOrDefaultAsync(a => a.AlbumId == albumId); - - if (album != null) - { - _storeContext.Albums.Remove(album); - - // Save the changes to the DB - await _storeContext.SaveChangesAsync(); - - // TODO: Handle missing record, key violations, concurrency issues, etc. - } - - return new ObjectResult (new { - Message = "Album deleted successfully." - }); - } - } - - [ModelMetadataType(typeof(Album))] - public class AlbumChangeDto - { - public int GenreId { get; set; } - - public int ArtistId { get; set; } - - public string Title { get; set; } - - public decimal Price { get; set; } - - public string AlbumArtUrl { get; set; } - } - - public class AlbumResultDto : AlbumChangeDto - { - public AlbumResultDto() - { - Artist = new ArtistResultDto(); - Genre = new GenreResultDto(); - } - - public int AlbumId { get; set; } - - public ArtistResultDto Artist { get; private set; } - - public GenreResultDto Genre { get; private set; } - } - - public class ArtistResultDto - { - public string Name { get; set; } - } - - public class GenreResultDto - { - public string Name { get; set; } - } -} diff --git a/samples/react/MusicStore/Apis/ArtistsApiController.cs b/samples/react/MusicStore/Apis/ArtistsApiController.cs deleted file mode 100644 index f3568ae..0000000 --- a/samples/react/MusicStore/Apis/ArtistsApiController.cs +++ /dev/null @@ -1,30 +0,0 @@ -using System; -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Mvc; -using Microsoft.EntityFrameworkCore; -using MusicStore.Models; - -namespace MusicStore.Apis -{ - [Route("api/artists")] - public class ArtistsApiController : Controller - { - private readonly MusicStoreContext _storeContext; - - public ArtistsApiController(MusicStoreContext storeContext) - { - _storeContext = storeContext; - } - - [HttpGet("lookup")] - public async Task Lookup() - { - var artists = await _storeContext.Artists - .OrderBy(a => a.Name) - .ToListAsync(); - - return Json(artists); - } - } -} diff --git a/samples/react/MusicStore/Apis/GenresApiController.cs b/samples/react/MusicStore/Apis/GenresApiController.cs deleted file mode 100644 index 338ca2f..0000000 --- a/samples/react/MusicStore/Apis/GenresApiController.cs +++ /dev/null @@ -1,70 +0,0 @@ -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Mvc; -using Microsoft.EntityFrameworkCore; -using MusicStore.Models; -using MusicStore.Infrastructure; - -namespace MusicStore.Apis -{ - [Route("api/genres")] - public class GenresApiController : Controller - { - private readonly MusicStoreContext _storeContext; - - public GenresApiController(MusicStoreContext storeContext) - { - _storeContext = storeContext; - } - - [HttpGet] - public async Task GenreList() - { - var genres = await _storeContext.Genres - //.Include(g => g.Albums) - .OrderBy(g => g.Name) - .ToListAsync(); - - return Json(genres); - } - - [HttpGet("genre-lookup")] - public async Task Lookup() - { - var genres = await _storeContext.Genres - .Select(g => new { g.GenreId, g.Name }) - .ToListAsync(); - - return Json(genres); - } - - [HttpGet("menu")] - public async Task GenreMenuList(int count = 9) - { - count = count > 0 && count < 20 ? count : 9; - - var genres = await _storeContext.Genres - .OrderByDescending(g => - g.Albums.Sum(a => - a.OrderDetails.Sum(od => od.Quantity))) - .Take(count) - .ToListAsync(); - - return Json(genres); - } - - [HttpGet("{genreId:int}/albums")] - [NoCache] - public async Task GenreAlbums(int genreId) - { - var albums = await _storeContext.Albums - .Where(a => a.GenreId == genreId) - //.Include(a => a.Genre) - //.Include(a => a.Artist) - //.OrderBy(a => a.Genre.Name) - .ToListAsync(); - - return Json(albums); - } - } -} diff --git a/samples/react/MusicStore/Apis/Models/AccountViewModels.cs b/samples/react/MusicStore/Apis/Models/AccountViewModels.cs deleted file mode 100644 index 831978a..0000000 --- a/samples/react/MusicStore/Apis/Models/AccountViewModels.cs +++ /dev/null @@ -1,63 +0,0 @@ -using System.ComponentModel.DataAnnotations; - -namespace MusicStore.Models -{ - public class ExternalLoginConfirmationViewModel - { - [Required] - [Display(Name = "User name")] - public string UserName { get; set; } - } - - public class ManageUserViewModel - { - [Required] - [DataType(DataType.Password)] - [Display(Name = "Current password")] - public string OldPassword { get; set; } - - [Required] - [StringLength(100, ErrorMessage = "The {0} must be at least {2} characters long.", MinimumLength = 6)] - [DataType(DataType.Password)] - [Display(Name = "New password")] - public string NewPassword { get; set; } - - [DataType(DataType.Password)] - [Display(Name = "Confirm new password")] - [Compare("NewPassword", ErrorMessage = "The new password and confirmation password do not match.")] - public string ConfirmPassword { get; set; } - } - - public class LoginViewModel - { - [Required] - [Display(Name = "User name")] - public string UserName { get; set; } - - [Required] - [DataType(DataType.Password)] - [Display(Name = "Password")] - public string Password { get; set; } - - [Display(Name = "Remember me?")] - public bool RememberMe { get; set; } - } - - public class RegisterViewModel - { - [Required] - [Display(Name = "User name")] - public string UserName { get; set; } - - [Required] - [StringLength(100, ErrorMessage = "The {0} must be at least {2} characters long.", MinimumLength = 6)] - [DataType(DataType.Password)] - [Display(Name = "Password")] - public string Password { get; set; } - - [DataType(DataType.Password)] - [Display(Name = "Confirm password")] - [Compare("Password", ErrorMessage = "The password and confirmation password do not match.")] - public string ConfirmPassword { get; set; } - } -} diff --git a/samples/react/MusicStore/Apis/Models/Album.cs b/samples/react/MusicStore/Apis/Models/Album.cs deleted file mode 100644 index 68e26ff..0000000 --- a/samples/react/MusicStore/Apis/Models/Album.cs +++ /dev/null @@ -1,40 +0,0 @@ -using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; - -namespace MusicStore.Models -{ - public class Album - { - public Album() - { - // TODO: Temporary hack to populate the orderdetails until EF does this automatically. - OrderDetails = new List(); - } - - [ScaffoldColumn(false)] - public int AlbumId { get; set; } - - public int GenreId { get; set; } - - public int ArtistId { get; set; } - - [Required] - [StringLength(160, MinimumLength = 2)] - public string Title { get; set; } - - [Required] - [RangeAttribute(typeof(double), "0.01", "100")] // Long-form constructor to work around https://github.com/dotnet/coreclr/issues/2172 - [DataType(DataType.Currency)] - public decimal Price { get; set; } - - [Display(Name = "Album Art URL")] - [StringLength(1024)] - public string AlbumArtUrl { get; set; } - - public virtual Genre Genre { get; set; } - - public virtual Artist Artist { get; set; } - - public virtual ICollection OrderDetails { get; set; } - } -} diff --git a/samples/react/MusicStore/Apis/Models/Artist.cs b/samples/react/MusicStore/Apis/Models/Artist.cs deleted file mode 100644 index b364a89..0000000 --- a/samples/react/MusicStore/Apis/Models/Artist.cs +++ /dev/null @@ -1,12 +0,0 @@ -using System.ComponentModel.DataAnnotations; - -namespace MusicStore.Models -{ - public class Artist - { - public int ArtistId { get; set; } - - [Required] - public string Name { get; set; } - } -} diff --git a/samples/react/MusicStore/Apis/Models/CartItem.cs b/samples/react/MusicStore/Apis/Models/CartItem.cs deleted file mode 100644 index 7209462..0000000 --- a/samples/react/MusicStore/Apis/Models/CartItem.cs +++ /dev/null @@ -1,21 +0,0 @@ -using System; -using System.ComponentModel.DataAnnotations; - -namespace MusicStore.Models -{ - public class CartItem - { - [Key] - public int CartItemId { get; set; } - - [Required] - public string CartId { get; set; } - public int AlbumId { get; set; } - public int Count { get; set; } - - [DataType(DataType.DateTime)] - public DateTime DateCreated { get; set; } - - public virtual Album Album { get; set; } - } -} diff --git a/samples/react/MusicStore/Apis/Models/Genre.cs b/samples/react/MusicStore/Apis/Models/Genre.cs deleted file mode 100644 index eed5616..0000000 --- a/samples/react/MusicStore/Apis/Models/Genre.cs +++ /dev/null @@ -1,24 +0,0 @@ -using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; -using Newtonsoft.Json; - -namespace MusicStore.Models -{ - public class Genre - { - public Genre() - { - Albums = new List(); - } - - public int GenreId { get; set; } - - [Required] - public string Name { get; set; } - - public string Description { get; set; } - - [JsonIgnore] - public virtual ICollection Albums { get; set; } - } -} diff --git a/samples/react/MusicStore/Apis/Models/MusicStoreContext.cs b/samples/react/MusicStore/Apis/Models/MusicStoreContext.cs deleted file mode 100644 index aee7aed..0000000 --- a/samples/react/MusicStore/Apis/Models/MusicStoreContext.cs +++ /dev/null @@ -1,34 +0,0 @@ -using Microsoft.AspNetCore.Identity.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore; - -namespace MusicStore.Models -{ - public class ApplicationUser : IdentityUser { } - - public class MusicStoreContext : IdentityDbContext - { - public MusicStoreContext(DbContextOptions options) : base(options) - { - } - - public DbSet Albums { get; set; } - public DbSet Artists { get; set; } - public DbSet Orders { get; set; } - public DbSet Genres { get; set; } - public DbSet CartItems { get; set; } - public DbSet OrderDetails { get; set; } - - protected override void OnModelCreating(ModelBuilder builder) - { - // Configure pluralization - builder.Entity().ToTable("Albums"); - builder.Entity().ToTable("Artists"); - builder.Entity().ToTable("Orders"); - builder.Entity().ToTable("Genres"); - builder.Entity().ToTable("CartItems"); - builder.Entity().ToTable("OrderDetails"); - - base.OnModelCreating(builder); - } - } -} diff --git a/samples/react/MusicStore/Apis/Models/Order.cs b/samples/react/MusicStore/Apis/Models/Order.cs deleted file mode 100644 index 110a77d..0000000 --- a/samples/react/MusicStore/Apis/Models/Order.cs +++ /dev/null @@ -1,73 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel.DataAnnotations; - -namespace MusicStore.Models -{ - //[Bind(Include = "FirstName,LastName,Address,City,State,PostalCode,Country,Phone,Email")] - public class Order - { - public Order() - { - OrderDetails = new List(); - } - - [ScaffoldColumn(false)] - public int OrderId { get; set; } - - [ScaffoldColumn(false)] - public DateTime OrderDate { get; set; } - - [Required] - [ScaffoldColumn(false)] - public string Username { get; set; } - - [Required] - [Display(Name = "First Name")] - [StringLength(160)] - public string FirstName { get; set; } - - [Required] - [Display(Name = "Last Name")] - [StringLength(160)] - public string LastName { get; set; } - - [Required] - [StringLength(70, MinimumLength = 3)] - public string Address { get; set; } - - [Required] - [StringLength(40)] - public string City { get; set; } - - [Required] - [StringLength(40)] - public string State { get; set; } - - [Required] - [Display(Name = "Postal Code")] - [StringLength(10, MinimumLength = 5)] - public string PostalCode { get; set; } - - [Required] - [StringLength(40)] - public string Country { get; set; } - - [Required] - [StringLength(24)] - [DataType(DataType.PhoneNumber)] - public string Phone { get; set; } - - [Required] - [Display(Name = "Email Address")] - [RegularExpression(@"[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,4}", - ErrorMessage = "Email is not valid.")] - [DataType(DataType.EmailAddress)] - public string Email { get; set; } - - [ScaffoldColumn(false)] - public decimal Total { get; set; } - - public ICollection OrderDetails { get; set; } - } -} diff --git a/samples/react/MusicStore/Apis/Models/OrderDetail.cs b/samples/react/MusicStore/Apis/Models/OrderDetail.cs deleted file mode 100644 index cb1e693..0000000 --- a/samples/react/MusicStore/Apis/Models/OrderDetail.cs +++ /dev/null @@ -1,14 +0,0 @@ -namespace MusicStore.Models -{ - public class OrderDetail - { - public int OrderDetailId { get; set; } - public int OrderId { get; set; } - public int AlbumId { get; set; } - public int Quantity { get; set; } - public decimal UnitPrice { get; set; } - - public virtual Album Album { get; set; } - public virtual Order Order { get; set; } - } -} diff --git a/samples/react/MusicStore/Apis/Models/SampleData.cs b/samples/react/MusicStore/Apis/Models/SampleData.cs deleted file mode 100644 index b1d98a7..0000000 --- a/samples/react/MusicStore/Apis/Models/SampleData.cs +++ /dev/null @@ -1,915 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Security.Claims; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Identity; -using Microsoft.AspNetCore.Identity.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore; -using Microsoft.Extensions.DependencyInjection; -using Microsoft.Extensions.Options; - -namespace MusicStore.Models -{ - public static class SampleData - { - const string imgUrl = "/images/placeholder.png"; - - public static async Task InitializeMusicStoreDatabaseAsync(IServiceProvider serviceProvider) - { - using (var db = serviceProvider.GetService()) - { - if (await db.Database.EnsureCreatedAsync()) - { - await InsertTestData(serviceProvider); - } - } - } - - private static async Task InsertTestData(IServiceProvider serviceProvider) - { - var albums = GetAlbums(imgUrl, Genres, Artists); - await AddOrUpdateAsync(serviceProvider, g => g.GenreId, Genres.Select(genre => genre.Value)); - await AddOrUpdateAsync(serviceProvider, a => a.ArtistId, Artists.Select(artist => artist.Value)); - await AddOrUpdateAsync(serviceProvider, a => a.AlbumId, albums); - } - - // TODO [EF] This may be replaced by a first class mechanism in EF - private static async Task AddOrUpdateAsync( - IServiceProvider serviceProvider, - Func propertyToMatch, IEnumerable entities) - where TEntity : class - { - // Query in a separate context so that we can attach existing entities as modified - List existingData; - - using (var scope = serviceProvider.GetRequiredService().CreateScope()) - using (var db = scope.ServiceProvider.GetService()) - { - existingData = db.Set().ToList(); - } - - using (var scope = serviceProvider.GetRequiredService().CreateScope()) - using (var db = scope.ServiceProvider.GetService()) - { - foreach (var item in entities) - { - db.Entry(item).State = existingData.Any(g => propertyToMatch(g).Equals(propertyToMatch(item))) - ? EntityState.Modified - : EntityState.Added; - } - - await db.SaveChangesAsync(); - } - } - - private static Album[] GetAlbums(string imgUrl, Dictionary genres, Dictionary artists) - { - var albums = new Album[] - { - new Album { Title = "The Best Of The Men At Work", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Men At Work"], AlbumArtUrl = imgUrl }, - new Album { Title = "...And Justice For All", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "עד גבול האור", Genre = genres["World"], Price = 8.99M, Artist = artists["אריק אינשטיין"], AlbumArtUrl = imgUrl }, - new Album { Title = "Black Light Syndrome", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Terry Bozzio, Tony Levin & Steve Stevens"], AlbumArtUrl = imgUrl }, - new Album { Title = "10,000 Days", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Tool"], AlbumArtUrl = imgUrl }, - new Album { Title = "11i", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Supreme Beings of Leisure"], AlbumArtUrl = imgUrl }, - new Album { Title = "1960", Genre = genres["Indie"], Price = 8.99M, Artist = artists["Soul-Junk"], AlbumArtUrl = imgUrl }, - new Album { Title = "4x4=12 ", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["deadmau5"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Copland Celebration, Vol. I", Genre = genres["Classical"], Price = 8.99M, Artist = artists["London Symphony Orchestra"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Lively Mind", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Paul Oakenfold"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Matter of Life and Death", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Real Dead One", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Real Live One", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Rush of Blood to the Head", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Coldplay"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Soprano Inspired", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Britten Sinfonia, Ivor Bolton & Lesley Garrett"], AlbumArtUrl = imgUrl }, - new Album { Title = "A Winter Symphony", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Abbey Road", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Beatles"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ace Of Spades", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Motörhead"], AlbumArtUrl = imgUrl }, - new Album { Title = "Achtung Baby", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Acústico MTV", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Os Paralamas Do Sucesso"], AlbumArtUrl = imgUrl }, - new Album { Title = "Adams, John: The Chairman Dances", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Edo de Waart & San Francisco Symphony"], AlbumArtUrl = imgUrl }, - new Album { Title = "Adrenaline", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deftones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ænima", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Tool"], AlbumArtUrl = imgUrl }, - new Album { Title = "Afrociberdelia", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Chico Science & Nação Zumbi"], AlbumArtUrl = imgUrl }, - new Album { Title = "After the Goldrush", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Neil Young"], AlbumArtUrl = imgUrl }, - new Album { Title = "Airdrawn Dagger", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Sasha"], AlbumArtUrl = imgUrl }, - new Album { Title = "Album Title Goes Here", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["deadmau5"], AlbumArtUrl = imgUrl }, - new Album { Title = "Alcohol Fueled Brewtality Live! [Disc 1]", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Black Label Society"], AlbumArtUrl = imgUrl }, - new Album { Title = "Alcohol Fueled Brewtality Live! [Disc 2]", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Black Label Society"], AlbumArtUrl = imgUrl }, - new Album { Title = "Alive 2007", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Daft Punk"], AlbumArtUrl = imgUrl }, - new Album { Title = "All I Ask of You", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Amen (So Be It)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Paddy Casey"], AlbumArtUrl = imgUrl }, - new Album { Title = "Animal Vehicle", Genre = genres["Pop"], Price = 8.99M, Artist = artists["The Axis of Awesome"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ao Vivo [IMPORT]", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Zeca Pagodinho"], AlbumArtUrl = imgUrl }, - new Album { Title = "Apocalyptic Love", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Slash"], AlbumArtUrl = imgUrl }, - new Album { Title = "Appetite for Destruction", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Guns N' Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "Are You Experienced?", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Jimi Hendrix"], AlbumArtUrl = imgUrl }, - new Album { Title = "Arquivo II", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Os Paralamas Do Sucesso"], AlbumArtUrl = imgUrl }, - new Album { Title = "Arquivo Os Paralamas Do Sucesso", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Os Paralamas Do Sucesso"], AlbumArtUrl = imgUrl }, - new Album { Title = "A-Sides", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Soundgarden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Audioslave", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Audioslave"], AlbumArtUrl = imgUrl }, - new Album { Title = "Automatic for the People", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["R.E.M."], AlbumArtUrl = imgUrl }, - new Album { Title = "Axé Bahia 2001", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Various Artists"], AlbumArtUrl = imgUrl }, - new Album { Title = "Babel", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Mumford & Sons"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bach: Goldberg Variations", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Wilhelm Kempff"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bach: The Brandenburg Concertos", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Orchestra of The Age of Enlightenment"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bach: The Cello Suites", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Yo-Yo Ma"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bach: Toccata & Fugue in D Minor", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Ton Koopman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bad Motorfinger", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Soundgarden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Balls to the Wall", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Accept"], AlbumArtUrl = imgUrl }, - new Album { Title = "Banadeek Ta'ala", Genre = genres["World"], Price = 8.99M, Artist = artists["Amr Diab"], AlbumArtUrl = imgUrl }, - new Album { Title = "Barbie Girl", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Aqua"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bark at the Moon (Remastered)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bartok: Violin & Viola Concertos", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Yehudi Menuhin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Barulhinho Bom", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Marisa Monte"], AlbumArtUrl = imgUrl }, - new Album { Title = "BBC Sessions [Disc 1] [Live]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "BBC Sessions [Disc 2] [Live]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Be Here Now", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Oasis"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bedrock 11 Compiled & Mixed", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["John Digweed"], AlbumArtUrl = imgUrl }, - new Album { Title = "Berlioz: Symphonie Fantastique", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Michael Tilson Thomas"], AlbumArtUrl = imgUrl }, - new Album { Title = "Beyond Good And Evil", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Cult"], AlbumArtUrl = imgUrl }, - new Album { Title = "Big Bad Wolf ", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Armand Van Helden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Big Ones", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Aerosmith"], AlbumArtUrl = imgUrl }, - new Album { Title = "Black Album", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Black Sabbath Vol. 4 (Remaster)", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Black Sabbath"], AlbumArtUrl = imgUrl }, - new Album { Title = "Black Sabbath", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Black Sabbath"], AlbumArtUrl = imgUrl }, - new Album { Title = "Black", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Blackwater Park", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Opeth"], AlbumArtUrl = imgUrl }, - new Album { Title = "Blizzard of Ozz", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Blood", Genre = genres["Rock"], Price = 8.99M, Artist = artists["In This Moment"], AlbumArtUrl = imgUrl }, - new Album { Title = "Blue Moods", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Incognito"], AlbumArtUrl = imgUrl }, - new Album { Title = "Blue", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Weezer"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bongo Fury", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Frank Zappa & Captain Beefheart"], AlbumArtUrl = imgUrl }, - new Album { Title = "Boys & Girls", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Alabama Shakes"], AlbumArtUrl = imgUrl }, - new Album { Title = "Brave New World", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "B-Sides 1980-1990", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Bunkka", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Paul Oakenfold"], AlbumArtUrl = imgUrl }, - new Album { Title = "By The Way", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Red Hot Chili Peppers"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cake: B-Sides and Rarities", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Cake"], AlbumArtUrl = imgUrl }, - new Album { Title = "Californication", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Red Hot Chili Peppers"], AlbumArtUrl = imgUrl }, - new Album { Title = "Carmina Burana", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Boston Symphony Orchestra & Seiji Ozawa"], AlbumArtUrl = imgUrl }, - new Album { Title = "Carried to Dust (Bonus Track Version)", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Calexico"], AlbumArtUrl = imgUrl }, - new Album { Title = "Carry On", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Chris Cornell"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cássia Eller - Sem Limite [Disc 1]", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Cássia Eller"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chemical Wedding", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Bruce Dickinson"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chill: Brazil (Disc 1)", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Marcos Valle"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chill: Brazil (Disc 2)", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Antônio Carlos Jobim"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chocolate Starfish And The Hot Dog Flavored Water", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Limp Bizkit"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chronicle, Vol. 1", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Creedence Clearwater Revival"], AlbumArtUrl = imgUrl }, - new Album { Title = "Chronicle, Vol. 2", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Creedence Clearwater Revival"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ciao, Baby", Genre = genres["Rock"], Price = 8.99M, Artist = artists["TheStart"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cidade Negra - Hits", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Cidade Negra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Classic Munkle: Turbo Edition", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Munkle"], AlbumArtUrl = imgUrl }, - new Album { Title = "Classics: The Best of Sarah Brightman", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Coda", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Come Away With Me", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Norah Jones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Come Taste The Band", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Comfort Eagle", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Cake"], AlbumArtUrl = imgUrl }, - new Album { Title = "Common Reaction", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Uh Huh Her "], AlbumArtUrl = imgUrl }, - new Album { Title = "Compositores", Genre = genres["Rock"], Price = 8.99M, Artist = artists["O Terço"], AlbumArtUrl = imgUrl }, - new Album { Title = "Contraband", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Velvet Revolver"], AlbumArtUrl = imgUrl }, - new Album { Title = "Core", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Stone Temple Pilots"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cornerstone", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Styx"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cosmicolor", Genre = genres["Rap"], Price = 8.99M, Artist = artists["M-Flo"], AlbumArtUrl = imgUrl }, - new Album { Title = "Cross", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Justice"], AlbumArtUrl = imgUrl }, - new Album { Title = "Culture of Fear", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Thievery Corporation"], AlbumArtUrl = imgUrl }, - new Album { Title = "Da Lama Ao Caos", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Chico Science & Nação Zumbi"], AlbumArtUrl = imgUrl }, - new Album { Title = "Dakshina", Genre = genres["World"], Price = 8.99M, Artist = artists["Deva Premal"], AlbumArtUrl = imgUrl }, - new Album { Title = "Dark Side of the Moon", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pink Floyd"], AlbumArtUrl = imgUrl }, - new Album { Title = "Death Magnetic", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Deep End of Down", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Above the Fold"], AlbumArtUrl = imgUrl }, - new Album { Title = "Deep Purple In Rock", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Deixa Entrar", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Falamansa"], AlbumArtUrl = imgUrl }, - new Album { Title = "Deja Vu", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Crosby, Stills, Nash, and Young"], AlbumArtUrl = imgUrl }, - new Album { Title = "Di Korpu Ku Alma", Genre = genres["World"], Price = 8.99M, Artist = artists["Lura"], AlbumArtUrl = imgUrl }, - new Album { Title = "Diary of a Madman (Remastered)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Diary of a Madman", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Dirt", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Alice in Chains"], AlbumArtUrl = imgUrl }, - new Album { Title = "Diver Down", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Van Halen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Djavan Ao Vivo - Vol. 02", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Djavan"], AlbumArtUrl = imgUrl }, - new Album { Title = "Djavan Ao Vivo - Vol. 1", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Djavan"], AlbumArtUrl = imgUrl }, - new Album { Title = "Drum'n'bass for Papa", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Plug"], AlbumArtUrl = imgUrl }, - new Album { Title = "Duluth", Genre = genres["Country"], Price = 8.99M, Artist = artists["Trampled By Turtles"], AlbumArtUrl = imgUrl }, - new Album { Title = "Dummy", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Portishead"], AlbumArtUrl = imgUrl }, - new Album { Title = "Duos II", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Luciana Souza/Romero Lubambo"], AlbumArtUrl = imgUrl }, - new Album { Title = "Earl Scruggs and Friends", Genre = genres["Country"], Price = 8.99M, Artist = artists["Earl Scruggs"], AlbumArtUrl = imgUrl }, - new Album { Title = "Eden", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "El Camino", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Black Keys"], AlbumArtUrl = imgUrl }, - new Album { Title = "Elegant Gypsy", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Al di Meola"], AlbumArtUrl = imgUrl }, - new Album { Title = "Elements Of Life", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Tiësto"], AlbumArtUrl = imgUrl }, - new Album { Title = "Elis Regina-Minha História", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Elis Regina"], AlbumArtUrl = imgUrl }, - new Album { Title = "Emergency On Planet Earth", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Jamiroquai"], AlbumArtUrl = imgUrl }, - new Album { Title = "Emotion", Genre = genres["World"], Price = 8.99M, Artist = artists["Papa Wemba"], AlbumArtUrl = imgUrl }, - new Album { Title = "English Renaissance", Genre = genres["Classical"], Price = 8.99M, Artist = artists["The King's Singers"], AlbumArtUrl = imgUrl }, - new Album { Title = "Every Kind of Light", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Posies"], AlbumArtUrl = imgUrl }, - new Album { Title = "Faceless", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Godsmack"], AlbumArtUrl = imgUrl }, - new Album { Title = "Facelift", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Alice in Chains"], AlbumArtUrl = imgUrl }, - new Album { Title = "Fair Warning", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Van Halen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Fear of a Black Planet", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Public Enemy"], AlbumArtUrl = imgUrl }, - new Album { Title = "Fear Of The Dark", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Feels Like Home", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Norah Jones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Fireball", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Fly", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "For Those About To Rock We Salute You", Genre = genres["Rock"], Price = 8.99M, Artist = artists["AC/DC"], AlbumArtUrl = imgUrl }, - new Album { Title = "Four", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Blues Traveler"], AlbumArtUrl = imgUrl }, - new Album { Title = "Frank", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Amy Winehouse"], AlbumArtUrl = imgUrl }, - new Album { Title = "Further Down the Spiral", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Nine Inch Nails"], AlbumArtUrl = imgUrl }, - new Album { Title = "Garage Inc. (Disc 1)", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Garage Inc. (Disc 2)", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Garbage", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Garbage"], AlbumArtUrl = imgUrl }, - new Album { Title = "Good News For People Who Love Bad News", Genre = genres["Indie"], Price = 8.99M, Artist = artists["Modest Mouse"], AlbumArtUrl = imgUrl }, - new Album { Title = "Gordon", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Barenaked Ladies"], AlbumArtUrl = imgUrl }, - new Album { Title = "Górecki: Symphony No. 3", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Adrian Leaper & Doreen de Feis"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Hits I", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Queen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Hits II", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Queen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Hits", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Duck Sauce"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Hits", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Lenny Kravitz"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Hits", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Lenny Kravitz"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greatest Kiss", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Kiss"], AlbumArtUrl = imgUrl }, - new Album { Title = "Greetings from Michigan", Genre = genres["Indie"], Price = 8.99M, Artist = artists["Sufjan Stevens"], AlbumArtUrl = imgUrl }, - new Album { Title = "Group Therapy", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Above & Beyond"], AlbumArtUrl = imgUrl }, - new Album { Title = "Handel: The Messiah (Highlights)", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Scholars Baroque Ensemble"], AlbumArtUrl = imgUrl }, - new Album { Title = "Haydn: Symphonies 99 - 104", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Royal Philharmonic Orchestra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Heart of the Night", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Spyro Gyra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Heart On", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Eagles of Death Metal"], AlbumArtUrl = imgUrl }, - new Album { Title = "Holy Diver", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Dio"], AlbumArtUrl = imgUrl }, - new Album { Title = "Homework", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Daft Punk"], AlbumArtUrl = imgUrl }, - new Album { Title = "Hot Rocks, 1964-1971 (Disc 1)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Rolling Stones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Houses Of The Holy", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "How To Dismantle An Atomic Bomb", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Human", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Projected"], AlbumArtUrl = imgUrl }, - new Album { Title = "Hunky Dory", Genre = genres["Rock"], Price = 8.99M, Artist = artists["David Bowie"], AlbumArtUrl = imgUrl }, - new Album { Title = "Hymns", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Projected"], AlbumArtUrl = imgUrl }, - new Album { Title = "Hysteria", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Def Leppard"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Absentia", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Porcupine Tree"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Between", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Paul Van Dyk"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Rainbows", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Radiohead"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Step", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Stevie Ray Vaughan & Double Trouble"], AlbumArtUrl = imgUrl }, - new Album { Title = "In the court of the Crimson King", Genre = genres["Rock"], Price = 8.99M, Artist = artists["King Crimson"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Through The Out Door", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Your Honor [Disc 1]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Foo Fighters"], AlbumArtUrl = imgUrl }, - new Album { Title = "In Your Honor [Disc 2]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Foo Fighters"], AlbumArtUrl = imgUrl }, - new Album { Title = "Indestructible", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Rancid"], AlbumArtUrl = imgUrl }, - new Album { Title = "Infinity", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Journey"], AlbumArtUrl = imgUrl }, - new Album { Title = "Into The Light", Genre = genres["Rock"], Price = 8.99M, Artist = artists["David Coverdale"], AlbumArtUrl = imgUrl }, - new Album { Title = "Introspective", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Pet Shop Boys"], AlbumArtUrl = imgUrl }, - new Album { Title = "Iron Maiden", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "ISAM", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Amon Tobin"], AlbumArtUrl = imgUrl }, - new Album { Title = "IV", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Jagged Little Pill", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Alanis Morissette"], AlbumArtUrl = imgUrl }, - new Album { Title = "Jagged Little Pill", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Alanis Morissette"], AlbumArtUrl = imgUrl }, - new Album { Title = "Jorge Ben Jor 25 Anos", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Jorge Ben"], AlbumArtUrl = imgUrl }, - new Album { Title = "Jota Quest-1995", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Jota Quest"], AlbumArtUrl = imgUrl }, - new Album { Title = "Kick", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["INXS"], AlbumArtUrl = imgUrl }, - new Album { Title = "Kill 'Em All", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Kind of Blue", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Miles Davis"], AlbumArtUrl = imgUrl }, - new Album { Title = "King For A Day Fool For A Lifetime", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Faith No More"], AlbumArtUrl = imgUrl }, - new Album { Title = "Kiss", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Carly Rae Jepsen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Last Call", Genre = genres["Country"], Price = 8.99M, Artist = artists["Cayouche"], AlbumArtUrl = imgUrl }, - new Album { Title = "Le Freak", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Chic"], AlbumArtUrl = imgUrl }, - new Album { Title = "Le Tigre", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Le Tigre"], AlbumArtUrl = imgUrl }, - new Album { Title = "Led Zeppelin I", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Led Zeppelin II", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Led Zeppelin III", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Let There Be Rock", Genre = genres["Rock"], Price = 8.99M, Artist = artists["AC/DC"], AlbumArtUrl = imgUrl }, - new Album { Title = "Little Earthquakes", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Tori Amos"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live [Disc 1]", Genre = genres["Blues"], Price = 8.99M, Artist = artists["The Black Crowes"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live [Disc 2]", Genre = genres["Blues"], Price = 8.99M, Artist = artists["The Black Crowes"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live After Death", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live At Donington 1992 (Disc 1)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live At Donington 1992 (Disc 2)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live on Earth", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["The Cat Empire"], AlbumArtUrl = imgUrl }, - new Album { Title = "Live On Two Legs [Live]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pearl Jam"], AlbumArtUrl = imgUrl }, - new Album { Title = "Living After Midnight", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Judas Priest"], AlbumArtUrl = imgUrl }, - new Album { Title = "Living", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Paddy Casey"], AlbumArtUrl = imgUrl }, - new Album { Title = "Load", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Love Changes Everything", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "MacArthur Park Suite", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Donna Summer"], AlbumArtUrl = imgUrl }, - new Album { Title = "Machine Head", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Magical Mystery Tour", Genre = genres["Pop"], Price = 8.99M, Artist = artists["The Beatles"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mais Do Mesmo", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Legião Urbana"], AlbumArtUrl = imgUrl }, - new Album { Title = "Maquinarama", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Skank"], AlbumArtUrl = imgUrl }, - new Album { Title = "Marasim", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Jagjit Singh"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mascagni: Cavalleria Rusticana", Genre = genres["Classical"], Price = 8.99M, Artist = artists["James Levine"], AlbumArtUrl = imgUrl }, - new Album { Title = "Master of Puppets", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mechanics & Mathematics", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Venus Hum"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mental Jewelry", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Live"], AlbumArtUrl = imgUrl }, - new Album { Title = "Metallics", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "meteora", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Linkin Park"], AlbumArtUrl = imgUrl }, - new Album { Title = "Meus Momentos", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Gonzaguinha"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mezmerize", Genre = genres["Metal"], Price = 8.99M, Artist = artists["System Of A Down"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mezzanine", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Massive Attack"], AlbumArtUrl = imgUrl }, - new Album { Title = "Miles Ahead", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Miles Davis"], AlbumArtUrl = imgUrl }, - new Album { Title = "Milton Nascimento Ao Vivo", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Milton Nascimento"], AlbumArtUrl = imgUrl }, - new Album { Title = "Minas", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Milton Nascimento"], AlbumArtUrl = imgUrl }, - new Album { Title = "Minha Historia", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Chico Buarque"], AlbumArtUrl = imgUrl }, - new Album { Title = "Misplaced Childhood", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Marillion"], AlbumArtUrl = imgUrl }, - new Album { Title = "MK III The Final Concerts [Disc 1]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Morning Dance", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Spyro Gyra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Motley Crue Greatest Hits", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Mötley Crüe"], AlbumArtUrl = imgUrl }, - new Album { Title = "Moving Pictures", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Rush"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mozart: Chamber Music", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Nash Ensemble"], AlbumArtUrl = imgUrl }, - new Album { Title = "Mozart: Symphonies Nos. 40 & 41", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Berliner Philharmoniker"], AlbumArtUrl = imgUrl }, - new Album { Title = "Murder Ballads", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Nick Cave and the Bad Seeds"], AlbumArtUrl = imgUrl }, - new Album { Title = "Music For The Jilted Generation", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["The Prodigy"], AlbumArtUrl = imgUrl }, - new Album { Title = "My Generation - The Very Best Of The Who", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Who"], AlbumArtUrl = imgUrl }, - new Album { Title = "My Name is Skrillex", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Skrillex"], AlbumArtUrl = imgUrl }, - new Album { Title = "Na Pista", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Cláudio Zoli"], AlbumArtUrl = imgUrl }, - new Album { Title = "Nevermind", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Nirvana"], AlbumArtUrl = imgUrl }, - new Album { Title = "New Adventures In Hi-Fi", Genre = genres["Rock"], Price = 8.99M, Artist = artists["R.E.M."], AlbumArtUrl = imgUrl }, - new Album { Title = "New Divide", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Linkin Park"], AlbumArtUrl = imgUrl }, - new Album { Title = "New York Dolls", Genre = genres["Punk"], Price = 8.99M, Artist = artists["New York Dolls"], AlbumArtUrl = imgUrl }, - new Album { Title = "News Of The World", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Queen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Nielsen: The Six Symphonies", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Göteborgs Symfoniker & Neeme Järvi"], AlbumArtUrl = imgUrl }, - new Album { Title = "Night At The Opera", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Queen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Night Castle", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Trans-Siberian Orchestra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Nkolo", Genre = genres["World"], Price = 8.99M, Artist = artists["Lokua Kanza"], AlbumArtUrl = imgUrl }, - new Album { Title = "No More Tears (Remastered)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "No Prayer For The Dying", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "No Security", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Rolling Stones"], AlbumArtUrl = imgUrl }, - new Album { Title = "O Brother, Where Art Thou?", Genre = genres["Country"], Price = 8.99M, Artist = artists["Alison Krauss"], AlbumArtUrl = imgUrl }, - new Album { Title = "O Samba Poconé", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Skank"], AlbumArtUrl = imgUrl }, - new Album { Title = "O(+>", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Prince"], AlbumArtUrl = imgUrl }, - new Album { Title = "Oceania", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Smashing Pumpkins"], AlbumArtUrl = imgUrl }, - new Album { Title = "Off the Deep End", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Weird Al"], AlbumArtUrl = imgUrl }, - new Album { Title = "OK Computer", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Radiohead"], AlbumArtUrl = imgUrl }, - new Album { Title = "Olodum", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Olodum"], AlbumArtUrl = imgUrl }, - new Album { Title = "One Love", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["David Guetta"], AlbumArtUrl = imgUrl }, - new Album { Title = "Operation: Mindcrime", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Queensrÿche"], AlbumArtUrl = imgUrl }, - new Album { Title = "Opiate", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Tool"], AlbumArtUrl = imgUrl }, - new Album { Title = "Outbreak", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Dennis Chambers"], AlbumArtUrl = imgUrl }, - new Album { Title = "Pachelbel: Canon & Gigue", Genre = genres["Classical"], Price = 8.99M, Artist = artists["English Concert & Trevor Pinnock"], AlbumArtUrl = imgUrl }, - new Album { Title = "Paid in Full", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Eric B. and Rakim"], AlbumArtUrl = imgUrl }, - new Album { Title = "Para Siempre", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Vicente Fernandez"], AlbumArtUrl = imgUrl }, - new Album { Title = "Pause", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Four Tet"], AlbumArtUrl = imgUrl }, - new Album { Title = "Peace Sells... but Who's Buying", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Megadeth"], AlbumArtUrl = imgUrl }, - new Album { Title = "Physical Graffiti [Disc 1]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Physical Graffiti [Disc 2]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Physical Graffiti", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Piece Of Mind", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Pinkerton", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Weezer"], AlbumArtUrl = imgUrl }, - new Album { Title = "Plays Metallica By Four Cellos", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Apocalyptica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Pop", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Powerslave", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Prenda Minha", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Caetano Veloso"], AlbumArtUrl = imgUrl }, - new Album { Title = "Presence", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Pretty Hate Machine", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Nine Inch Nails"], AlbumArtUrl = imgUrl }, - new Album { Title = "Prisoner", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Jezabels"], AlbumArtUrl = imgUrl }, - new Album { Title = "Privateering", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Mark Knopfler"], AlbumArtUrl = imgUrl }, - new Album { Title = "Prokofiev: Romeo & Juliet", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Michael Tilson Thomas"], AlbumArtUrl = imgUrl }, - new Album { Title = "Prokofiev: Symphony No.1", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sergei Prokofiev & Yuri Temirkanov"], AlbumArtUrl = imgUrl }, - new Album { Title = "PSY's Best 6th Part 1", Genre = genres["Pop"], Price = 8.99M, Artist = artists["PSY"], AlbumArtUrl = imgUrl }, - new Album { Title = "Purcell: The Fairy Queen", Genre = genres["Classical"], Price = 8.99M, Artist = artists["London Classical Players"], AlbumArtUrl = imgUrl }, - new Album { Title = "Purpendicular", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Purple", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Stone Temple Pilots"], AlbumArtUrl = imgUrl }, - new Album { Title = "Quanta Gente Veio Ver (Live)", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Gilberto Gil"], AlbumArtUrl = imgUrl }, - new Album { Title = "Quanta Gente Veio ver--Bônus De Carnaval", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Gilberto Gil"], AlbumArtUrl = imgUrl }, - new Album { Title = "Quiet Songs", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Aisha Duo"], AlbumArtUrl = imgUrl }, - new Album { Title = "Raices", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Los Tigres del Norte"], AlbumArtUrl = imgUrl }, - new Album { Title = "Raising Hell", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Run DMC"], AlbumArtUrl = imgUrl }, - new Album { Title = "Raoul and the Kings of Spain ", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Tears For Fears"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rattle And Hum", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Raul Seixas", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Raul Seixas"], AlbumArtUrl = imgUrl }, - new Album { Title = "Recovery [Explicit]", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Eminem"], AlbumArtUrl = imgUrl }, - new Album { Title = "Reign In Blood", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Slayer"], AlbumArtUrl = imgUrl }, - new Album { Title = "Relayed", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Yes"], AlbumArtUrl = imgUrl }, - new Album { Title = "ReLoad", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Respighi:Pines of Rome", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Eugene Ormandy"], AlbumArtUrl = imgUrl }, - new Album { Title = "Restless and Wild", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Accept"], AlbumArtUrl = imgUrl }, - new Album { Title = "Retrospective I (1974-1980)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Rush"], AlbumArtUrl = imgUrl }, - new Album { Title = "Revelations", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Audioslave"], AlbumArtUrl = imgUrl }, - new Album { Title = "Revolver", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Beatles"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ride the Lighting ", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ride The Lightning", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ring My Bell", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Anita Ward"], AlbumArtUrl = imgUrl }, - new Album { Title = "Riot Act", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pearl Jam"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rise of the Phoenix", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Before the Dawn"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rock In Rio [CD1]", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rock In Rio [CD2]", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rock In Rio [CD2]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Roda De Funk", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Funk Como Le Gusta"], AlbumArtUrl = imgUrl }, - new Album { Title = "Room for Squares", Genre = genres["Pop"], Price = 8.99M, Artist = artists["John Mayer"], AlbumArtUrl = imgUrl }, - new Album { Title = "Root Down", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Jimmy Smith"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rounds", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Four Tet"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rubber Factory", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Black Keys"], AlbumArtUrl = imgUrl }, - new Album { Title = "Rust in Peace", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Megadeth"], AlbumArtUrl = imgUrl }, - new Album { Title = "Sambas De Enredo 2001", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Various Artists"], AlbumArtUrl = imgUrl }, - new Album { Title = "Santana - As Years Go By", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Santana"], AlbumArtUrl = imgUrl }, - new Album { Title = "Santana Live", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Santana"], AlbumArtUrl = imgUrl }, - new Album { Title = "Saturday Night Fever", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Bee Gees"], AlbumArtUrl = imgUrl }, - new Album { Title = "Scary Monsters and Nice Sprites", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Skrillex"], AlbumArtUrl = imgUrl }, - new Album { Title = "Scheherazade", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Chicago Symphony Orchestra & Fritz Reiner"], AlbumArtUrl = imgUrl }, - new Album { Title = "SCRIABIN: Vers la flamme", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Christopher O'Riley"], AlbumArtUrl = imgUrl }, - new Album { Title = "Second Coming", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Stone Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "Serie Sem Limite (Disc 1)", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Tim Maia"], AlbumArtUrl = imgUrl }, - new Album { Title = "Serie Sem Limite (Disc 2)", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Tim Maia"], AlbumArtUrl = imgUrl }, - new Album { Title = "Serious About Men", Genre = genres["Rap"], Price = 8.99M, Artist = artists["The Rubberbandits"], AlbumArtUrl = imgUrl }, - new Album { Title = "Seventh Son of a Seventh Son", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Short Bus", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Filter"], AlbumArtUrl = imgUrl }, - new Album { Title = "Sibelius: Finlandia", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Berliner Philharmoniker"], AlbumArtUrl = imgUrl }, - new Album { Title = "Singles Collection", Genre = genres["Rock"], Price = 8.99M, Artist = artists["David Bowie"], AlbumArtUrl = imgUrl }, - new Album { Title = "Six Degrees of Inner Turbulence", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Dream Theater"], AlbumArtUrl = imgUrl }, - new Album { Title = "Slave To The Empire", Genre = genres["Metal"], Price = 8.99M, Artist = artists["T&N"], AlbumArtUrl = imgUrl }, - new Album { Title = "Slaves And Masters", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Slouching Towards Bethlehem", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Robert James"], AlbumArtUrl = imgUrl }, - new Album { Title = "Smash", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Offspring"], AlbumArtUrl = imgUrl }, - new Album { Title = "Something Special", Genre = genres["Country"], Price = 8.99M, Artist = artists["Dolly Parton"], AlbumArtUrl = imgUrl }, - new Album { Title = "Somewhere in Time", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Song(s) You Know By Heart", Genre = genres["Country"], Price = 8.99M, Artist = artists["Jimmy Buffett"], AlbumArtUrl = imgUrl }, - new Album { Title = "Sound of Music", Genre = genres["Punk"], Price = 8.99M, Artist = artists["Adicts"], AlbumArtUrl = imgUrl }, - new Album { Title = "South American Getaway", Genre = genres["Classical"], Price = 8.99M, Artist = artists["The 12 Cellists of The Berlin Philharmonic"], AlbumArtUrl = imgUrl }, - new Album { Title = "Sozinho Remix Ao Vivo", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Caetano Veloso"], AlbumArtUrl = imgUrl }, - new Album { Title = "Speak of the Devil", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Spiritual State", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Nujabes"], AlbumArtUrl = imgUrl }, - new Album { Title = "St. Anger", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl }, - new Album { Title = "Still Life", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Opeth"], AlbumArtUrl = imgUrl }, - new Album { Title = "Stop Making Sense", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Talking Heads"], AlbumArtUrl = imgUrl }, - new Album { Title = "Stormbringer", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "Stranger than Fiction", Genre = genres["Punk"], Price = 8.99M, Artist = artists["Bad Religion"], AlbumArtUrl = imgUrl }, - new Album { Title = "Strauss: Waltzes", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Eugene Ormandy"], AlbumArtUrl = imgUrl }, - new Album { Title = "Supermodified", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Amon Tobin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Supernatural", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Santana"], AlbumArtUrl = imgUrl }, - new Album { Title = "Surfing with the Alien (Remastered)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Joe Satriani"], AlbumArtUrl = imgUrl }, - new Album { Title = "Switched-On Bach", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Wendy Carlos"], AlbumArtUrl = imgUrl }, - new Album { Title = "Symphony", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Szymanowski: Piano Works, Vol. 1", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Martin Roscoe"], AlbumArtUrl = imgUrl }, - new Album { Title = "Tchaikovsky: The Nutcracker", Genre = genres["Classical"], Price = 8.99M, Artist = artists["London Symphony Orchestra"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ted Nugent", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Ted Nugent"], AlbumArtUrl = imgUrl }, - new Album { Title = "Teflon Don", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Rick Ross"], AlbumArtUrl = imgUrl }, - new Album { Title = "Tell Another Joke at the Ol' Choppin' Block", Genre = genres["Indie"], Price = 8.99M, Artist = artists["Danielson Famile"], AlbumArtUrl = imgUrl }, - new Album { Title = "Temple of the Dog", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Temple of the Dog"], AlbumArtUrl = imgUrl }, - new Album { Title = "Ten", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pearl Jam"], AlbumArtUrl = imgUrl }, - new Album { Title = "Texas Flood", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Stevie Ray Vaughan"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Battle Rages On", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Beast Live", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Paul D'Ianno"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best Of 1980-1990", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best of 1990–2000", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best of Beethoven", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Nicolaus Esterhazy Sinfonia"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best Of Billy Cobham", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Billy Cobham"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best of Ed Motta", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Ed Motta"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Best Of Van Halen, Vol. I", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Van Halen"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Bridge", Genre = genres["R&B"], Price = 8.99M, Artist = artists["Melanie Fiona"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Cage", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Tygers of Pan Tang"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Chicago Transit Authority", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Chicago "], AlbumArtUrl = imgUrl }, - new Album { Title = "The Chronic", Genre = genres["Rap"], Price = 8.99M, Artist = artists["Dr. Dre"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Colour And The Shape", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Foo Fighters"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Crane Wife", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["The Decemberists"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Cream Of Clapton", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Eric Clapton"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Cure", Genre = genres["Pop"], Price = 8.99M, Artist = artists["The Cure"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Dark Side Of The Moon", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pink Floyd"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Divine Conspiracy", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Epica"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Doors", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Doors"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Dream of the Blue Turtles", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Sting"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Essential Miles Davis [Disc 1]", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Miles Davis"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Essential Miles Davis [Disc 2]", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Miles Davis"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Final Concerts (Disc 2)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deep Purple"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Final Frontier", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Head and the Heart", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Head and the Heart"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Joshua Tree", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Last Night of the Proms", Genre = genres["Classical"], Price = 8.99M, Artist = artists["BBC Concert Orchestra"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Lumineers", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Lumineers"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Number of The Beast", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Number of The Beast", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Police Greatest Hits", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Police"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Song Remains The Same (Disc 1)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Song Remains The Same (Disc 2)", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Southern Harmony and Musical Companion", Genre = genres["Blues"], Price = 8.99M, Artist = artists["The Black Crowes"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Spade", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Butch Walker & The Black Widows"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Stone Roses", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Stone Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Suburbs", Genre = genres["Indie"], Price = 8.99M, Artist = artists["Arcade Fire"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Three Tenors Disc1/Disc2", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Carreras, Pavarotti, Domingo"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Trees They Grow So High", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "The Wall", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pink Floyd"], AlbumArtUrl = imgUrl }, - new Album { Title = "The X Factor", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Them Crooked Vultures", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Them Crooked Vultures"], AlbumArtUrl = imgUrl }, - new Album { Title = "This Is Happening", Genre = genres["Rock"], Price = 8.99M, Artist = artists["LCD Soundsystem"], AlbumArtUrl = imgUrl }, - new Album { Title = "Thunder, Lightning, Strike", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Go! Team"], AlbumArtUrl = imgUrl }, - new Album { Title = "Time to Say Goodbye", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sarah Brightman"], AlbumArtUrl = imgUrl }, - new Album { Title = "Time, Love & Tenderness", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Michael Bolton"], AlbumArtUrl = imgUrl }, - new Album { Title = "Tomorrow Starts Today", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Mobile"], AlbumArtUrl = imgUrl }, - new Album { Title = "Tribute", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Ozzy Osbourne"], AlbumArtUrl = imgUrl }, - new Album { Title = "Tuesday Night Music Club", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Sheryl Crow"], AlbumArtUrl = imgUrl }, - new Album { Title = "Umoja", Genre = genres["Rock"], Price = 8.99M, Artist = artists["BLØF"], AlbumArtUrl = imgUrl }, - new Album { Title = "Under the Pink", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Tori Amos"], AlbumArtUrl = imgUrl }, - new Album { Title = "Undertow", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Tool"], AlbumArtUrl = imgUrl }, - new Album { Title = "Un-Led-Ed", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Dread Zeppelin"], AlbumArtUrl = imgUrl }, - new Album { Title = "Unplugged [Live]", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Kiss"], AlbumArtUrl = imgUrl }, - new Album { Title = "Unplugged", Genre = genres["Blues"], Price = 8.99M, Artist = artists["Eric Clapton"], AlbumArtUrl = imgUrl }, - new Album { Title = "Unplugged", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Eric Clapton"], AlbumArtUrl = imgUrl }, - new Album { Title = "Untrue", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Burial"], AlbumArtUrl = imgUrl }, - new Album { Title = "Use Your Illusion I", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Guns N' Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "Use Your Illusion II", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Guns N' Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "Use Your Illusion II", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Guns N' Roses"], AlbumArtUrl = imgUrl }, - new Album { Title = "Van Halen III", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Van Halen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Van Halen", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Van Halen"], AlbumArtUrl = imgUrl }, - new Album { Title = "Version 2.0", Genre = genres["Alternative"], Price = 8.99M, Artist = artists["Garbage"], AlbumArtUrl = imgUrl }, - new Album { Title = "Vinicius De Moraes", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Vinícius De Moraes"], AlbumArtUrl = imgUrl }, - new Album { Title = "Virtual XI", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Iron Maiden"], AlbumArtUrl = imgUrl }, - new Album { Title = "Voodoo Lounge", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Rolling Stones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Vozes do MPB", Genre = genres["Latin"], Price = 8.99M, Artist = artists["Various Artists"], AlbumArtUrl = imgUrl }, - new Album { Title = "Vs.", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pearl Jam"], AlbumArtUrl = imgUrl }, - new Album { Title = "Wagner: Favourite Overtures", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Sir Georg Solti & Wiener Philharmoniker"], AlbumArtUrl = imgUrl }, - new Album { Title = "Walking Into Clarksdale", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Page & Plant"], AlbumArtUrl = imgUrl }, - new Album { Title = "Wapi Yo", Genre = genres["World"], Price = 8.99M, Artist = artists["Lokua Kanza"], AlbumArtUrl = imgUrl }, - new Album { Title = "War", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Warner 25 Anos", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Antônio Carlos Jobim"], AlbumArtUrl = imgUrl }, - new Album { Title = "Wasteland R&Btheque", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Raunchy"], AlbumArtUrl = imgUrl }, - new Album { Title = "Watermark", Genre = genres["Electronic"], Price = 8.99M, Artist = artists["Enya"], AlbumArtUrl = imgUrl }, - new Album { Title = "We Were Exploding Anyway", Genre = genres["Rock"], Price = 8.99M, Artist = artists["65daysofstatic"], AlbumArtUrl = imgUrl }, - new Album { Title = "Weill: The Seven Deadly Sins", Genre = genres["Classical"], Price = 8.99M, Artist = artists["Orchestre de l'Opéra de Lyon"], AlbumArtUrl = imgUrl }, - new Album { Title = "White Pony", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Deftones"], AlbumArtUrl = imgUrl }, - new Album { Title = "Who's Next", Genre = genres["Rock"], Price = 8.99M, Artist = artists["The Who"], AlbumArtUrl = imgUrl }, - new Album { Title = "Wish You Were Here", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Pink Floyd"], AlbumArtUrl = imgUrl }, - new Album { Title = "With Oden on Our Side", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Amon Amarth"], AlbumArtUrl = imgUrl }, - new Album { Title = "Worlds", Genre = genres["Jazz"], Price = 8.99M, Artist = artists["Aaron Goldberg"], AlbumArtUrl = imgUrl }, - new Album { Title = "Worship Music", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Anthrax"], AlbumArtUrl = imgUrl }, - new Album { Title = "X&Y", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Coldplay"], AlbumArtUrl = imgUrl }, - new Album { Title = "Xinti", Genre = genres["World"], Price = 8.99M, Artist = artists["Sara Tavares"], AlbumArtUrl = imgUrl }, - new Album { Title = "Yano", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Yano"], AlbumArtUrl = imgUrl }, - new Album { Title = "Yesterday Once More Disc 1/Disc 2", Genre = genres["Pop"], Price = 8.99M, Artist = artists["The Carpenters"], AlbumArtUrl = imgUrl }, - new Album { Title = "Zooropa", Genre = genres["Rock"], Price = 8.99M, Artist = artists["U2"], AlbumArtUrl = imgUrl }, - new Album { Title = "Zoso", Genre = genres["Rock"], Price = 8.99M, Artist = artists["Led Zeppelin"], AlbumArtUrl = imgUrl }, - }; - - foreach (var album in albums) - { - album.ArtistId = album.Artist.ArtistId; - album.GenreId = album.Genre.GenreId; - } - - return albums; - } - - private static Dictionary artists; - public static Dictionary Artists - { - get - { - if (artists == null) - { - var artistsList = new Artist[] - { - new Artist { Name = "65daysofstatic" }, - new Artist { Name = "Aaron Goldberg" }, - new Artist { Name = "Above & Beyond" }, - new Artist { Name = "Above the Fold" }, - new Artist { Name = "AC/DC" }, - new Artist { Name = "Accept" }, - new Artist { Name = "Adicts" }, - new Artist { Name = "Adrian Leaper & Doreen de Feis" }, - new Artist { Name = "Aerosmith" }, - new Artist { Name = "Aisha Duo" }, - new Artist { Name = "Al di Meola" }, - new Artist { Name = "Alabama Shakes" }, - new Artist { Name = "Alanis Morissette" }, - new Artist { Name = "Alberto Turco & Nova Schola Gregoriana" }, - new Artist { Name = "Alice in Chains" }, - new Artist { Name = "Alison Krauss" }, - new Artist { Name = "Amon Amarth" }, - new Artist { Name = "Amon Tobin" }, - new Artist { Name = "Amr Diab" }, - new Artist { Name = "Amy Winehouse" }, - new Artist { Name = "Anita Ward" }, - new Artist { Name = "Anthrax" }, - new Artist { Name = "Antônio Carlos Jobim" }, - new Artist { Name = "Apocalyptica" }, - new Artist { Name = "Aqua" }, - new Artist { Name = "Armand Van Helden" }, - new Artist { Name = "Arcade Fire" }, - new Artist { Name = "Audioslave" }, - new Artist { Name = "Bad Religion" }, - new Artist { Name = "Barenaked Ladies" }, - new Artist { Name = "BBC Concert Orchestra" }, - new Artist { Name = "Bee Gees" }, - new Artist { Name = "Before the Dawn" }, - new Artist { Name = "Berliner Philharmoniker" }, - new Artist { Name = "Billy Cobham" }, - new Artist { Name = "Black Label Society" }, - new Artist { Name = "Black Sabbath" }, - new Artist { Name = "BLØF" }, - new Artist { Name = "Blues Traveler" }, - new Artist { Name = "Boston Symphony Orchestra & Seiji Ozawa" }, - new Artist { Name = "Britten Sinfonia, Ivor Bolton & Lesley Garrett" }, - new Artist { Name = "Bruce Dickinson" }, - new Artist { Name = "Buddy Guy" }, - new Artist { Name = "Burial" }, - new Artist { Name = "Butch Walker & The Black Widows" }, - new Artist { Name = "Caetano Veloso" }, - new Artist { Name = "Cake" }, - new Artist { Name = "Calexico" }, - new Artist { Name = "Carly Rae Jepsen" }, - new Artist { Name = "Carreras, Pavarotti, Domingo" }, - new Artist { Name = "Cássia Eller" }, - new Artist { Name = "Cayouche" }, - new Artist { Name = "Chic" }, - new Artist { Name = "Chicago " }, - new Artist { Name = "Chicago Symphony Orchestra & Fritz Reiner" }, - new Artist { Name = "Chico Buarque" }, - new Artist { Name = "Chico Science & Nação Zumbi" }, - new Artist { Name = "Choir Of Westminster Abbey & Simon Preston" }, - new Artist { Name = "Chris Cornell" }, - new Artist { Name = "Christopher O'Riley" }, - new Artist { Name = "Cidade Negra" }, - new Artist { Name = "Cláudio Zoli" }, - new Artist { Name = "Coldplay" }, - new Artist { Name = "Creedence Clearwater Revival" }, - new Artist { Name = "Crosby, Stills, Nash, and Young" }, - new Artist { Name = "Daft Punk" }, - new Artist { Name = "Danielson Famile" }, - new Artist { Name = "David Bowie" }, - new Artist { Name = "David Coverdale" }, - new Artist { Name = "David Guetta" }, - new Artist { Name = "deadmau5" }, - new Artist { Name = "Deep Purple" }, - new Artist { Name = "Def Leppard" }, - new Artist { Name = "Deftones" }, - new Artist { Name = "Dennis Chambers" }, - new Artist { Name = "Deva Premal" }, - new Artist { Name = "Dio" }, - new Artist { Name = "Djavan" }, - new Artist { Name = "Dolly Parton" }, - new Artist { Name = "Donna Summer" }, - new Artist { Name = "Dr. Dre" }, - new Artist { Name = "Dread Zeppelin" }, - new Artist { Name = "Dream Theater" }, - new Artist { Name = "Duck Sauce" }, - new Artist { Name = "Earl Scruggs" }, - new Artist { Name = "Ed Motta" }, - new Artist { Name = "Edo de Waart & San Francisco Symphony" }, - new Artist { Name = "Elis Regina" }, - new Artist { Name = "Eminem" }, - new Artist { Name = "English Concert & Trevor Pinnock" }, - new Artist { Name = "Enya" }, - new Artist { Name = "Epica" }, - new Artist { Name = "Eric B. and Rakim" }, - new Artist { Name = "Eric Clapton" }, - new Artist { Name = "Eugene Ormandy" }, - new Artist { Name = "Faith No More" }, - new Artist { Name = "Falamansa" }, - new Artist { Name = "Filter" }, - new Artist { Name = "Foo Fighters" }, - new Artist { Name = "Four Tet" }, - new Artist { Name = "Frank Zappa & Captain Beefheart" }, - new Artist { Name = "Fretwork" }, - new Artist { Name = "Funk Como Le Gusta" }, - new Artist { Name = "Garbage" }, - new Artist { Name = "Gerald Moore" }, - new Artist { Name = "Gilberto Gil" }, - new Artist { Name = "Godsmack" }, - new Artist { Name = "Gonzaguinha" }, - new Artist { Name = "Göteborgs Symfoniker & Neeme Järvi" }, - new Artist { Name = "Guns N' Roses" }, - new Artist { Name = "Gustav Mahler" }, - new Artist { Name = "In This Moment" }, - new Artist { Name = "Incognito" }, - new Artist { Name = "INXS" }, - new Artist { Name = "Iron Maiden" }, - new Artist { Name = "Jagjit Singh" }, - new Artist { Name = "James Levine" }, - new Artist { Name = "Jamiroquai" }, - new Artist { Name = "Jimi Hendrix" }, - new Artist { Name = "Jimmy Buffett" }, - new Artist { Name = "Jimmy Smith" }, - new Artist { Name = "Joe Satriani" }, - new Artist { Name = "John Digweed" }, - new Artist { Name = "John Mayer" }, - new Artist { Name = "Jorge Ben" }, - new Artist { Name = "Jota Quest" }, - new Artist { Name = "Journey" }, - new Artist { Name = "Judas Priest" }, - new Artist { Name = "Julian Bream" }, - new Artist { Name = "Justice" }, - new Artist { Name = "Orchestre de l'Opéra de Lyon" }, - new Artist { Name = "King Crimson" }, - new Artist { Name = "Kiss" }, - new Artist { Name = "LCD Soundsystem" }, - new Artist { Name = "Le Tigre" }, - new Artist { Name = "Led Zeppelin" }, - new Artist { Name = "Legião Urbana" }, - new Artist { Name = "Lenny Kravitz" }, - new Artist { Name = "Les Arts Florissants & William Christie" }, - new Artist { Name = "Limp Bizkit" }, - new Artist { Name = "Linkin Park" }, - new Artist { Name = "Live" }, - new Artist { Name = "Lokua Kanza" }, - new Artist { Name = "London Symphony Orchestra" }, - new Artist { Name = "Los Tigres del Norte" }, - new Artist { Name = "Luciana Souza/Romero Lubambo" }, - new Artist { Name = "Lulu Santos" }, - new Artist { Name = "Lura" }, - new Artist { Name = "Marcos Valle" }, - new Artist { Name = "Marillion" }, - new Artist { Name = "Marisa Monte" }, - new Artist { Name = "Mark Knopfler" }, - new Artist { Name = "Martin Roscoe" }, - new Artist { Name = "Massive Attack" }, - new Artist { Name = "Maurizio Pollini" }, - new Artist { Name = "Megadeth" }, - new Artist { Name = "Mela Tenenbaum, Pro Musica Prague & Richard Kapp" }, - new Artist { Name = "Melanie Fiona" }, - new Artist { Name = "Men At Work" }, - new Artist { Name = "Metallica" }, - new Artist { Name = "M-Flo" }, - new Artist { Name = "Michael Bolton" }, - new Artist { Name = "Michael Tilson Thomas" }, - new Artist { Name = "Miles Davis" }, - new Artist { Name = "Milton Nascimento" }, - new Artist { Name = "Mobile" }, - new Artist { Name = "Modest Mouse" }, - new Artist { Name = "Mötley Crüe" }, - new Artist { Name = "Motörhead" }, - new Artist { Name = "Mumford & Sons" }, - new Artist { Name = "Munkle" }, - new Artist { Name = "Nash Ensemble" }, - new Artist { Name = "Neil Young" }, - new Artist { Name = "New York Dolls" }, - new Artist { Name = "Nick Cave and the Bad Seeds" }, - new Artist { Name = "Nicolaus Esterhazy Sinfonia" }, - new Artist { Name = "Nine Inch Nails" }, - new Artist { Name = "Nirvana" }, - new Artist { Name = "Norah Jones" }, - new Artist { Name = "Nujabes" }, - new Artist { Name = "O Terço" }, - new Artist { Name = "Oasis" }, - new Artist { Name = "Olodum" }, - new Artist { Name = "Opeth" }, - new Artist { Name = "Orchestra of The Age of Enlightenment" }, - new Artist { Name = "Os Paralamas Do Sucesso" }, - new Artist { Name = "Ozzy Osbourne" }, - new Artist { Name = "Paddy Casey" }, - new Artist { Name = "Page & Plant" }, - new Artist { Name = "Papa Wemba" }, - new Artist { Name = "Paul D'Ianno" }, - new Artist { Name = "Paul Oakenfold" }, - new Artist { Name = "Paul Van Dyk" }, - new Artist { Name = "Pearl Jam" }, - new Artist { Name = "Pet Shop Boys" }, - new Artist { Name = "Pink Floyd" }, - new Artist { Name = "Plug" }, - new Artist { Name = "Porcupine Tree" }, - new Artist { Name = "Portishead" }, - new Artist { Name = "Prince" }, - new Artist { Name = "Projected" }, - new Artist { Name = "PSY" }, - new Artist { Name = "Public Enemy" }, - new Artist { Name = "Queen" }, - new Artist { Name = "Queensrÿche" }, - new Artist { Name = "R.E.M." }, - new Artist { Name = "Radiohead" }, - new Artist { Name = "Rancid" }, - new Artist { Name = "Raul Seixas" }, - new Artist { Name = "Raunchy" }, - new Artist { Name = "Red Hot Chili Peppers" }, - new Artist { Name = "Rick Ross" }, - new Artist { Name = "Robert James" }, - new Artist { Name = "London Classical Players" }, - new Artist { Name = "Royal Philharmonic Orchestra" }, - new Artist { Name = "Run DMC" }, - new Artist { Name = "Rush" }, - new Artist { Name = "Santana" }, - new Artist { Name = "Sara Tavares" }, - new Artist { Name = "Sarah Brightman" }, - new Artist { Name = "Sasha" }, - new Artist { Name = "Scholars Baroque Ensemble" }, - new Artist { Name = "Scorpions" }, - new Artist { Name = "Sergei Prokofiev & Yuri Temirkanov" }, - new Artist { Name = "Sheryl Crow" }, - new Artist { Name = "Sir Georg Solti & Wiener Philharmoniker" }, - new Artist { Name = "Skank" }, - new Artist { Name = "Skrillex" }, - new Artist { Name = "Slash" }, - new Artist { Name = "Slayer" }, - new Artist { Name = "Soul-Junk" }, - new Artist { Name = "Soundgarden" }, - new Artist { Name = "Spyro Gyra" }, - new Artist { Name = "Stevie Ray Vaughan & Double Trouble" }, - new Artist { Name = "Stevie Ray Vaughan" }, - new Artist { Name = "Sting" }, - new Artist { Name = "Stone Temple Pilots" }, - new Artist { Name = "Styx" }, - new Artist { Name = "Sufjan Stevens" }, - new Artist { Name = "Supreme Beings of Leisure" }, - new Artist { Name = "System Of A Down" }, - new Artist { Name = "T&N" }, - new Artist { Name = "Talking Heads" }, - new Artist { Name = "Tears For Fears" }, - new Artist { Name = "Ted Nugent" }, - new Artist { Name = "Temple of the Dog" }, - new Artist { Name = "Terry Bozzio, Tony Levin & Steve Stevens" }, - new Artist { Name = "The 12 Cellists of The Berlin Philharmonic" }, - new Artist { Name = "The Axis of Awesome" }, - new Artist { Name = "The Beatles" }, - new Artist { Name = "The Black Crowes" }, - new Artist { Name = "The Black Keys" }, - new Artist { Name = "The Carpenters" }, - new Artist { Name = "The Cat Empire" }, - new Artist { Name = "The Cult" }, - new Artist { Name = "The Cure" }, - new Artist { Name = "The Decemberists" }, - new Artist { Name = "The Doors" }, - new Artist { Name = "The Eagles of Death Metal" }, - new Artist { Name = "The Go! Team" }, - new Artist { Name = "The Head and the Heart" }, - new Artist { Name = "The Jezabels" }, - new Artist { Name = "The King's Singers" }, - new Artist { Name = "The Lumineers" }, - new Artist { Name = "The Offspring" }, - new Artist { Name = "The Police" }, - new Artist { Name = "The Posies" }, - new Artist { Name = "The Prodigy" }, - new Artist { Name = "The Rolling Stones" }, - new Artist { Name = "The Rubberbandits" }, - new Artist { Name = "The Smashing Pumpkins" }, - new Artist { Name = "The Stone Roses" }, - new Artist { Name = "The Who" }, - new Artist { Name = "Them Crooked Vultures" }, - new Artist { Name = "TheStart" }, - new Artist { Name = "Thievery Corporation" }, - new Artist { Name = "Tiësto" }, - new Artist { Name = "Tim Maia" }, - new Artist { Name = "Ton Koopman" }, - new Artist { Name = "Tool" }, - new Artist { Name = "Tori Amos" }, - new Artist { Name = "Trampled By Turtles" }, - new Artist { Name = "Trans-Siberian Orchestra" }, - new Artist { Name = "Tygers of Pan Tang" }, - new Artist { Name = "U2" }, - new Artist { Name = "UB40" }, - new Artist { Name = "Uh Huh Her " }, - new Artist { Name = "Van Halen" }, - new Artist { Name = "Various Artists" }, - new Artist { Name = "Velvet Revolver" }, - new Artist { Name = "Venus Hum" }, - new Artist { Name = "Vicente Fernandez" }, - new Artist { Name = "Vinícius De Moraes" }, - new Artist { Name = "Weezer" }, - new Artist { Name = "Weird Al" }, - new Artist { Name = "Wendy Carlos" }, - new Artist { Name = "Wilhelm Kempff" }, - new Artist { Name = "Yano" }, - new Artist { Name = "Yehudi Menuhin" }, - new Artist { Name = "Yes" }, - new Artist { Name = "Yo-Yo Ma" }, - new Artist { Name = "Zeca Pagodinho" }, - new Artist { Name = "אריק אינשטיין"} - }; - - // TODO [EF] Swap to store generated keys when available - int artistId = 1; - artists = new Dictionary(); - foreach (Artist artist in artistsList) - { - artist.ArtistId = artistId++; - artists.Add(artist.Name, artist); - } - } - - return artists; - } - } - - private static Dictionary genres; - public static Dictionary Genres - { - get - { - if (genres == null) - { - var genresList = new Genre[] - { - new Genre { Name = "Pop" }, - new Genre { Name = "Rock" }, - new Genre { Name = "Jazz" }, - new Genre { Name = "Metal" }, - new Genre { Name = "Electronic" }, - new Genre { Name = "Blues" }, - new Genre { Name = "Latin" }, - new Genre { Name = "Rap" }, - new Genre { Name = "Classical" }, - new Genre { Name = "Alternative" }, - new Genre { Name = "Country" }, - new Genre { Name = "R&B" }, - new Genre { Name = "Indie" }, - new Genre { Name = "Punk" }, - new Genre { Name = "World" } - }; - - genres = new Dictionary(); - // TODO [EF] Swap to store generated keys when available - int genreId = 1; - foreach (Genre genre in genresList) - { - genre.GenreId = genreId++; - - // TODO [EF] Remove when null values are supported by update pipeline - genre.Description = genre.Name + " is great music (if you like it)."; - - genres.Add(genre.Name, genre); - } - } - - return genres; - } - } - } -} diff --git a/samples/react/MusicStore/Apis/Models/ShoppingCart.cs b/samples/react/MusicStore/Apis/Models/ShoppingCart.cs deleted file mode 100644 index 1d2465a..0000000 --- a/samples/react/MusicStore/Apis/Models/ShoppingCart.cs +++ /dev/null @@ -1,207 +0,0 @@ -using Microsoft.AspNetCore.Http; -using Microsoft.EntityFrameworkCore; -using System; -using System.Collections.Generic; -using System.Linq; - -namespace MusicStore.Models -{ - public partial class ShoppingCart - { - MusicStoreContext _db; - string ShoppingCartId { get; set; } - - public ShoppingCart(MusicStoreContext db) - { - _db = db; - } - - public static ShoppingCart GetCart(MusicStoreContext db, HttpContext context) - { - var cart = new ShoppingCart(db); - cart.ShoppingCartId = cart.GetCartId(context); - return cart; - } - - public void AddToCart(Album album) - { - // Get the matching cart and album instances - var cartItem = _db.CartItems.SingleOrDefault( - c => c.CartId == ShoppingCartId - && c.AlbumId == album.AlbumId); - - if (cartItem == null) - { - // TODO [EF] Swap to store generated key once we support identity pattern - var nextCartItemId = _db.CartItems.Any() - ? _db.CartItems.Max(c => c.CartItemId) + 1 - : 1; - - // Create a new cart item if no cart item exists - cartItem = new CartItem - { - CartItemId = nextCartItemId, - AlbumId = album.AlbumId, - CartId = ShoppingCartId, - Count = 1, - DateCreated = DateTime.Now - }; - - _db.CartItems.Add(cartItem); - } - else - { - // If the item does exist in the cart, then add one to the quantity - cartItem.Count++; - - // TODO [EF] Remove this line once change detection is available - _db.Update(cartItem); - } - } - - public int RemoveFromCart(int id) - { - // Get the cart - var cartItem = _db.CartItems.Single( - cart => cart.CartId == ShoppingCartId - && cart.CartItemId == id); - - int itemCount = 0; - - if (cartItem != null) - { - if (cartItem.Count > 1) - { - cartItem.Count--; - - // TODO [EF] Remove this line once change detection is available - _db.Update(cartItem); - - itemCount = cartItem.Count; - } - else - { - _db.CartItems.Remove(cartItem); - } - } - - return itemCount; - } - - public void EmptyCart() - { - var cartItems = _db.CartItems.Where(cart => cart.CartId == ShoppingCartId); - - foreach (var cartItem in cartItems) - { - _db.Remove(cartItem); - } - } - - public List GetCartItems() - { - var cartItems = _db.CartItems.Where(cart => cart.CartId == ShoppingCartId).ToList(); - //TODO: Auto population of the related album data not available until EF feature is lighted up. - foreach (var cartItem in cartItems) - { - cartItem.Album = _db.Albums.Single(a => a.AlbumId == cartItem.AlbumId); - } - - return cartItems; - } - - public int GetCount() - { - // Get the count of each item in the cart and sum them up - int? count = (from cartItems in _db.CartItems - where cartItems.CartId == ShoppingCartId - select (int?)cartItems.Count).Sum(); - - // Return 0 if all entries are null - return count ?? 0; - } - - public decimal GetTotal() - { - // Multiply album price by count of that album to get - // the current price for each of those albums in the cart - // sum all album price totals to get the cart total - - // TODO Collapse to a single query once EF supports querying related data - decimal total = 0; - foreach (var item in _db.CartItems.Where(c => c.CartId == ShoppingCartId)) - { - var album = _db.Albums.Single(a => a.AlbumId == item.AlbumId); - total += item.Count * album.Price; - } - - return total; - } - - public int CreateOrder(Order order) - { - decimal orderTotal = 0; - - var cartItems = GetCartItems(); - - // TODO [EF] Swap to store generated identity key when supported - var nextId = _db.OrderDetails.Any() - ? _db.OrderDetails.Max(o => o.OrderDetailId) + 1 - : 1; - - // Iterate over the items in the cart, adding the order details for each - foreach (var item in cartItems) - { - //var album = _db.Albums.Find(item.AlbumId); - var album = _db.Albums.Single(a => a.AlbumId == item.AlbumId); - - var orderDetail = new OrderDetail - { - OrderDetailId = nextId, - AlbumId = item.AlbumId, - OrderId = order.OrderId, - UnitPrice = album.Price, - Quantity = item.Count, - }; - - // Set the order total of the shopping cart - orderTotal += (item.Count * album.Price); - - _db.OrderDetails.Add(orderDetail); - - nextId++; - } - - // Set the order's total to the orderTotal count - order.Total = orderTotal; - - // Empty the shopping cart - EmptyCart(); - - // Return the OrderId as the confirmation number - return order.OrderId; - } - - // We're using HttpContextBase to allow access to cookies. - public string GetCartId(HttpContext context) - { - var sessionCookie = context.Request.Cookies["Session"]; - string cartId = null; - - if (string.IsNullOrWhiteSpace(sessionCookie)) - { - //A GUID to hold the cartId. - cartId = Guid.NewGuid().ToString(); - - // Send cart Id as a cookie to the client. - context.Response.Cookies.Append("Session", cartId); - } - else - { - cartId = sessionCookie; - } - - return cartId; - } - } -} diff --git a/samples/react/MusicStore/Controllers/HomeController.cs b/samples/react/MusicStore/Controllers/HomeController.cs deleted file mode 100755 index 1048e08..0000000 --- a/samples/react/MusicStore/Controllers/HomeController.cs +++ /dev/null @@ -1,16 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Mvc; - -namespace MusicStore.Controllers -{ - public class HomeController : Controller - { - public IActionResult Index() - { - return View(); - } - } -} diff --git a/samples/react/MusicStore/Infrastructure/NoCacheAttribute.cs b/samples/react/MusicStore/Infrastructure/NoCacheAttribute.cs deleted file mode 100644 index 856023a..0000000 --- a/samples/react/MusicStore/Infrastructure/NoCacheAttribute.cs +++ /dev/null @@ -1,19 +0,0 @@ -using Microsoft.AspNetCore.Mvc; -using System; -using Microsoft.AspNetCore.Mvc.Filters; - -namespace MusicStore.Infrastructure -{ - [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method)] - public sealed class NoCacheAttribute : ActionFilterAttribute - { - public override void OnResultExecuting(ResultExecutingContext context) - { - context.HttpContext.Response.Headers["Cache-Control"] = "no-cache, no-store, max-age=0"; - context.HttpContext.Response.Headers["Pragma"] = "no-cache"; - context.HttpContext.Response.Headers["Expires"] = "-1"; - - base.OnResultExecuting(context); - } - } -} diff --git a/samples/react/MusicStore/Infrastructure/PagedList.cs b/samples/react/MusicStore/Infrastructure/PagedList.cs deleted file mode 100644 index b2cb2c5..0000000 --- a/samples/react/MusicStore/Infrastructure/PagedList.cs +++ /dev/null @@ -1,150 +0,0 @@ -using Microsoft.EntityFrameworkCore; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Linq.Expressions; -using System.Threading.Tasks; - -namespace MusicStore.Infrastructure -{ - public interface IPagedList - { - IEnumerable Data { get; } - - int Page { get; } - - int PageSize { get; } - - int TotalCount { get; } - } - - internal class PagedList : IPagedList - { - public PagedList(IEnumerable data, int page, int pageSize, int totalCount) - { - Data = data; - Page = page; - PageSize = pageSize; - TotalCount = totalCount; - } - - public IEnumerable Data { get; private set; } - - public int Page { get; private set; } - - public int PageSize { get; private set; } - - public int TotalCount { get; private set; } - } - - public static class PagedListExtensions - { - public static IPagedList ToPagedList(this IQueryable query, int page, int pageSize) - { - if (query == null) - { - throw new ArgumentNullException("query"); - } - - var pagingConfig = new PagingConfig(page, pageSize); - var skipCount = ValidatePagePropertiesAndGetSkipCount(pagingConfig); - - var data = query - .Skip(skipCount) - .Take(pagingConfig.PageSize) - .ToList(); - - if (skipCount > 0 && data.Count == 0) - { - // Requested page has no records, just return the first page - pagingConfig.Page = 1; - data = query - .Take(pagingConfig.PageSize) - .ToList(); - } - - return new PagedList(data, pagingConfig.Page, pagingConfig.PageSize, query.Count()); - } - - public static Task> ToPagedListAsync(this IQueryable query, int page, int pageSize, string sortExpression, Expression> defaultSortExpression, SortDirection defaultSortDirection = SortDirection.Ascending) - where TModel : class - { - return ToPagedListAsync(query, page, pageSize, sortExpression, defaultSortExpression, defaultSortDirection, null); - } - - public static async Task> ToPagedListAsync(this IQueryable query, int page, int pageSize, string sortExpression, Expression> defaultSortExpression, SortDirection defaultSortDirection, Func selector) - where TModel : class - where TResult : class - { - if (query == null) - { - throw new ArgumentNullException("query"); - } - - var pagingConfig = new PagingConfig(page, pageSize); - var skipCount = ValidatePagePropertiesAndGetSkipCount(pagingConfig); - var dataQuery = query; - - if (defaultSortExpression != null) - { - dataQuery = dataQuery - .SortBy(sortExpression, defaultSortExpression); - } - - var data = await dataQuery - .Skip(skipCount) - .Take(pagingConfig.PageSize) - .ToListAsync(); - - if (skipCount > 0 && data.Count == 0) - { - // Requested page has no records, just return the first page - pagingConfig.Page = 1; - data = await dataQuery - .Take(pagingConfig.PageSize) - .ToListAsync(); - } - - var count = await query.CountAsync(); - - var resultData = selector != null - ? data.Select(selector) - : data.Cast(); - - return new PagedList(resultData, pagingConfig.Page, pagingConfig.PageSize, count); - } - - private static int ValidatePagePropertiesAndGetSkipCount(PagingConfig pagingConfig) - { - if (pagingConfig.Page < 1) - { - pagingConfig.Page = 1; - } - - if (pagingConfig.PageSize < 10) - { - pagingConfig.PageSize = 10; - } - - if (pagingConfig.PageSize > 100) - { - pagingConfig.PageSize = 100; - } - - return pagingConfig.PageSize * (pagingConfig.Page - 1); - } - - internal class PagingConfig - { - public PagingConfig(int page, int pageSize) - { - Page = page; - PageSize = pageSize; - } - - public int Page { get; set; } - - public int PageSize { get; set; } - } - } -} diff --git a/samples/react/MusicStore/Infrastructure/SortDirection.cs b/samples/react/MusicStore/Infrastructure/SortDirection.cs deleted file mode 100644 index 28f7e86..0000000 --- a/samples/react/MusicStore/Infrastructure/SortDirection.cs +++ /dev/null @@ -1,13 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; - -namespace MusicStore.Infrastructure -{ - public enum SortDirection - { - Ascending, - Descending - } -} diff --git a/samples/react/MusicStore/Infrastructure/SortExpression.cs b/samples/react/MusicStore/Infrastructure/SortExpression.cs deleted file mode 100644 index 88ba312..0000000 --- a/samples/react/MusicStore/Infrastructure/SortExpression.cs +++ /dev/null @@ -1,87 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Linq.Expressions; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Mvc.ViewFeatures.Internal; - -namespace MusicStore.Infrastructure -{ - public static class SortExpression - { - private const string SORT_DIRECTION_DESC = " DESC"; - - public static IQueryable SortBy(this IQueryable query, string sortExpression, Expression> defaultSortExpression, SortDirection defaultSortDirection = SortDirection.Ascending) where TModel : class - { - return SortBy(query, sortExpression ?? Create(defaultSortExpression, defaultSortDirection)); - } - - public static string Create(Expression> expression, SortDirection sortDirection = SortDirection.Ascending) where TModel : class - { - var expressionText = ExpressionHelper.GetExpressionText(expression); - // TODO: Validate the expression depth, etc. - - var sortExpression = expressionText; - - if (sortDirection == SortDirection.Descending) - { - sortExpression += SORT_DIRECTION_DESC; - } - - return sortExpression; - } - - public static IQueryable SortBy(this IQueryable source, string sortExpression) where T : class - { - if (source == null) - { - throw new ArgumentNullException("source"); - } - - if (String.IsNullOrWhiteSpace(sortExpression)) - { - return source; - } - - sortExpression = sortExpression.Trim(); - var isDescending = false; - - // DataSource control passes the sort parameter with a direction - // if the direction is descending - if (sortExpression.EndsWith(SORT_DIRECTION_DESC, StringComparison.OrdinalIgnoreCase)) - { - isDescending = true; - var descIndex = sortExpression.Length - SORT_DIRECTION_DESC.Length; - sortExpression = sortExpression.Substring(0, descIndex).Trim(); - } - - if (string.IsNullOrEmpty(sortExpression)) - { - return source; - } - - ParameterExpression parameter = Expression.Parameter(source.ElementType, String.Empty); - - // Build up the property expression, e.g.: (m => m.Foo.Bar) - var sortExpressionParts = sortExpression.Split('.'); - Expression propertyExpression = parameter; - foreach (var property in sortExpressionParts) - { - propertyExpression = Expression.Property(propertyExpression, property); - } - - LambdaExpression lambda = Expression.Lambda(propertyExpression, parameter); - - var methodName = (isDescending) ? "OrderByDescending" : "OrderBy"; - - Expression methodCallExpression = Expression.Call( - typeof(Queryable), - methodName, - new[] { source.ElementType, propertyExpression.Type }, - source.Expression, - Expression.Quote(lambda)); - - return (IQueryable)source.Provider.CreateQuery(methodCallExpression); - } - } -} diff --git a/samples/react/MusicStore/MusicStore.csproj b/samples/react/MusicStore/MusicStore.csproj deleted file mode 100644 index e8ab8d9..0000000 --- a/samples/react/MusicStore/MusicStore.csproj +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - netcoreapp2.0 - true - false - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/samples/react/MusicStore/Properties/launchSettings.json b/samples/react/MusicStore/Properties/launchSettings.json deleted file mode 100644 index e436043..0000000 --- a/samples/react/MusicStore/Properties/launchSettings.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "iisSettings": { - "windowsAuthentication": false, - "anonymousAuthentication": true, - "iisExpress": { - "applicationUrl": "http://localhost:51586/", - "sslPort": 0 - } - }, - "profiles": { - "IIS Express": { - "commandName": "IISExpress", - "launchBrowser": true, - "environmentVariables": { - "ASPNETCORE_ENVIRONMENT": "Development" - } - }, - "dotnet cli": { - "commandName": "Project", - "environmentVariables": { - "ASPNETCORE_ENVIRONMENT": "Development" - } - } - } -} \ No newline at end of file diff --git a/samples/react/MusicStore/ReactApp/boot-server.tsx b/samples/react/MusicStore/ReactApp/boot-server.tsx deleted file mode 100644 index 7aaa1f1..0000000 --- a/samples/react/MusicStore/ReactApp/boot-server.tsx +++ /dev/null @@ -1,50 +0,0 @@ -import * as React from 'react'; -import { Provider } from 'react-redux'; -import { renderToString } from 'react-dom/server'; -import { match, RouterContext } from 'react-router'; -import createMemoryHistory from 'history/lib/createMemoryHistory'; -import { routes } from './routes'; -import configureStore from './configureStore'; -type BootResult = { html?: string, globals?: { [key: string]: any }, redirectUrl?: string}; - -export default function (params: any): Promise<{ html: string }> { - return new Promise((resolve, reject) => { - // Match the incoming request against the list of client-side routes - match({ routes, location: params.location }, (error, redirectLocation, renderProps: any) => { - if (error) { - throw error; - } - - // If there's a redirection, just send this information back to the host application - if (redirectLocation) { - resolve({ redirectUrl: redirectLocation.pathname }); - return; - } - - // If it didn't match any route, renderProps will be undefined - if (!renderProps) { - throw new Error(`The location '${ params.url }' doesn't match any route configured in react-router.`); - } - - // Build an instance of the application - const store = configureStore(); - const app = ( - - - - ); - - // Perform an initial render that will cause any async tasks (e.g., data access) to begin - renderToString(app); - - // Once the tasks are done, we can perform the final render - // We also send the redux store state, so the client can continue execution where the server left off - params.domainTasks.then(() => { - resolve({ - html: renderToString(app), - globals: { initialReduxState: store.getState() } - }); - }, reject); // Also propagate any errors back into the host application - }); - }); -} diff --git a/samples/react/MusicStore/ReactApp/boot.tsx b/samples/react/MusicStore/ReactApp/boot.tsx deleted file mode 100644 index ea3807d..0000000 --- a/samples/react/MusicStore/ReactApp/boot.tsx +++ /dev/null @@ -1,25 +0,0 @@ -import './styles/styles.css'; -import 'bootstrap/dist/css/bootstrap.css'; - -import * as React from 'react'; -import * as ReactDOM from 'react-dom'; -import { browserHistory, Router } from 'react-router'; -import { Provider } from 'react-redux'; -import { syncHistoryWithStore } from 'react-router-redux'; -import { routes } from './routes'; -import configureStore from './configureStore'; -import { ApplicationState } from './store'; - -// Get the application-wide store instance, prepopulating with state from the server where available. -const initialState = (window as any).initialReduxState as ApplicationState; -const store = configureStore(initialState); -const history = syncHistoryWithStore(browserHistory, store); - -// This code starts up the React app when it runs in a browser. It sets up the routing configuration -// and injects the app into a DOM element. -ReactDOM.render( - - - , - document.getElementById('react-app') -); diff --git a/samples/react/MusicStore/ReactApp/components/NavMenu.tsx b/samples/react/MusicStore/ReactApp/components/NavMenu.tsx deleted file mode 100644 index 6e85da8..0000000 --- a/samples/react/MusicStore/ReactApp/components/NavMenu.tsx +++ /dev/null @@ -1,49 +0,0 @@ -import * as React from 'react'; -import { Navbar, Nav, NavItem, NavDropdown, MenuItem } from 'react-bootstrap'; -import { Link } from 'react-router'; -import { LinkContainer } from 'react-router-bootstrap'; -import { provide } from 'redux-typed'; -import { ApplicationState } from '../store'; -import * as GenreList from '../store/GenreList'; - -class NavMenu extends React.Component { - componentWillMount() { - this.props.requestGenresList(); - } - - public render() { - const genres = this.props.genres.slice(0, 5); - return ( - - - Music Store - - - - - - - ); - } -} - -// Selects which part of global state maps to this component, and defines a type for the resulting props -const provider = provide( - (state: ApplicationState) => state.genreList, - GenreList.actionCreators -); -type NavMenuProps = typeof provider.allProps; -export default provider.connect(NavMenu); diff --git a/samples/react/MusicStore/ReactApp/components/public/AlbumDetails.tsx b/samples/react/MusicStore/ReactApp/components/public/AlbumDetails.tsx deleted file mode 100644 index 6e6fab2..0000000 --- a/samples/react/MusicStore/ReactApp/components/public/AlbumDetails.tsx +++ /dev/null @@ -1,58 +0,0 @@ -import * as React from 'react'; -import { Link } from 'react-router'; -import { provide } from 'redux-typed'; -import { ApplicationState } from '../../store'; -import * as AlbumDetailsState from '../../store/AlbumDetails'; - -interface RouteParams { - albumId: string; -} - -class AlbumDetails extends React.Component { - componentWillMount() { - this.props.requestAlbumDetails(parseInt(this.props.params.albumId)); - } - - componentWillReceiveProps(nextProps: AlbumDetailsProps) { - this.props.requestAlbumDetails(parseInt(nextProps.params.albumId)); - } - - public render() { - if (this.props.album) { - const albumData = this.props.album; - return
-

{ albumData.Title }

- -

{

- -
-

- Genre: - { albumData.Genre.Name } -

-

- Artist: - { albumData.Artist.Name } -

-

- Price: - ${ albumData.Price.toFixed(2) } -

-

- Add to cart -

-
-
; - } else { - return

Loading...

; - } - } -} - -// Selects which part of global state maps to this component, and defines a type for the resulting props -const provider = provide( - (state: ApplicationState) => state.albumDetails, - AlbumDetailsState.actionCreators -).withExternalProps<{ params: RouteParams }>(); -type AlbumDetailsProps = typeof provider.allProps; -export default provider.connect(AlbumDetails); diff --git a/samples/react/MusicStore/ReactApp/components/public/AlbumTile.tsx b/samples/react/MusicStore/ReactApp/components/public/AlbumTile.tsx deleted file mode 100644 index 04b74d5..0000000 --- a/samples/react/MusicStore/ReactApp/components/public/AlbumTile.tsx +++ /dev/null @@ -1,17 +0,0 @@ -import * as React from 'react'; -import { Link } from 'react-router'; -import { Album } from '../../store/FeaturedAlbums'; - -export class AlbumTile extends React.Component<{ album: Album, key?: any }, void> { - public render() { - const { album } = this.props; - return ( -
  • - - { -

    { album.Title }

    - -
  • - ); - } -} diff --git a/samples/react/MusicStore/ReactApp/components/public/GenreDetails.tsx b/samples/react/MusicStore/ReactApp/components/public/GenreDetails.tsx deleted file mode 100644 index 59dc50b..0000000 --- a/samples/react/MusicStore/ReactApp/components/public/GenreDetails.tsx +++ /dev/null @@ -1,45 +0,0 @@ -import * as React from 'react'; -import { Link } from 'react-router'; -import { provide } from 'redux-typed'; -import { ApplicationState } from '../../store'; -import * as GenreDetailsStore from '../../store/GenreDetails'; -import { AlbumTile } from './AlbumTile'; - -interface RouteParams { - genreId: string -} - -class GenreDetails extends React.Component { - componentWillMount() { - this.props.requestGenreDetails(parseInt(this.props.params.genreId)); - } - - componentWillReceiveProps(nextProps: GenreDetailsProps) { - this.props.requestGenreDetails(parseInt(nextProps.params.genreId)); - } - - public render() { - if (this.props.isLoaded) { - return
    -

    Albums

    - -
      - {this.props.albums.map(album => - - )} -
    -
    ; - } else { - return

    Loading...

    ; - } - } -} - -// Selects which part of global state maps to this component, and defines a type for the resulting props -const provider = provide( - (state: ApplicationState) => state.genreDetails, - GenreDetailsStore.actionCreators -).withExternalProps<{ params: RouteParams }>(); - -type GenreDetailsProps = typeof provider.allProps; -export default provider.connect(GenreDetails); diff --git a/samples/react/MusicStore/ReactApp/components/public/Genres.tsx b/samples/react/MusicStore/ReactApp/components/public/Genres.tsx deleted file mode 100644 index 1e03789..0000000 --- a/samples/react/MusicStore/ReactApp/components/public/Genres.tsx +++ /dev/null @@ -1,38 +0,0 @@ -import * as React from 'react'; -import { Link } from 'react-router'; -import { provide } from 'redux-typed'; -import { ApplicationState } from '../../store'; -import * as GenreList from '../../store/GenreList'; - -class Genres extends React.Component { - componentWillMount() { - this.props.requestGenresList(); - } - - public render() { - const { genres } = this.props; - return
    -

    Browse Genres

    - -

    Select from { this.props.isLoaded ? genres.length : '...' } genres:

    - -
      - {genres.map(genre => -
    • - - { genre.Name } - -
    • - )} -
    -
    ; - } -} - -// Selects which part of global state maps to this component, and defines a type for the resulting props -const provider = provide( - (state: ApplicationState) => state.genreList, - GenreList.actionCreators -); -type GenresProps = typeof provider.allProps; -export default provider.connect(Genres); diff --git a/samples/react/MusicStore/ReactApp/components/public/Home.tsx b/samples/react/MusicStore/ReactApp/components/public/Home.tsx deleted file mode 100644 index b0f03d8..0000000 --- a/samples/react/MusicStore/ReactApp/components/public/Home.tsx +++ /dev/null @@ -1,34 +0,0 @@ -import * as React from 'react'; -import { Link } from 'react-router'; -import { provide } from 'redux-typed'; -import { ApplicationState } from '../../store'; -import { actionCreators } from '../../store/FeaturedAlbums'; -import { AlbumTile } from './AlbumTile'; - -class Home extends React.Component { - componentWillMount() { - this.props.requestFeaturedAlbums(); - } - - public render() { - return
    -
    -

    MVC Music Store

    - -
    -
      - {this.props.albums.map(album => - - )} -
    -
    ; - } -} - -// Selects which part of global state maps to this component, and defines a type for the resulting props -const provider = provide( - (state: ApplicationState) => state.featuredAlbums, - actionCreators -); -type HomeProps = typeof provider.allProps; -export default provider.connect(Home); diff --git a/samples/react/MusicStore/ReactApp/configureStore.ts b/samples/react/MusicStore/ReactApp/configureStore.ts deleted file mode 100644 index cda811e..0000000 --- a/samples/react/MusicStore/ReactApp/configureStore.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { createStore, applyMiddleware, compose, combineReducers, GenericStoreEnhancer, Store as ReduxStore } from 'redux'; -import thunk from 'redux-thunk'; -import { routerReducer } from 'react-router-redux'; -import * as Store from './store'; -import { typedToPlain } from 'redux-typed'; - -export default function configureStore(initialState?: Store.ApplicationState) { - // Build middleware. These are functions that can process the actions before they reach the store. - const windowIfDefined = typeof window === 'undefined' ? null : window as any; - // If devTools is installed, connect to it - const devToolsExtension = windowIfDefined && windowIfDefined.devToolsExtension as () => GenericStoreEnhancer; - const createStoreWithMiddleware = compose( - applyMiddleware(thunk, typedToPlain), - devToolsExtension ? devToolsExtension() : f => f - )(createStore); - - // Combine all reducers and instantiate the app-wide store instance - const allReducers = buildRootReducer(Store.reducers); - const store = createStoreWithMiddleware(allReducers, initialState) as ReduxStore; - - // Enable Webpack hot module replacement for reducers - if (module.hot) { - module.hot.accept('./store', () => { - const nextRootReducer = require('./store'); - store.replaceReducer(buildRootReducer(nextRootReducer.reducers)); - }); - } - - return store; -} - -function buildRootReducer(allReducers) { - return combineReducers(Object.assign({}, allReducers, { routing: routerReducer })); -} diff --git a/samples/react/MusicStore/ReactApp/routes.tsx b/samples/react/MusicStore/ReactApp/routes.tsx deleted file mode 100644 index bf4f5fc..0000000 --- a/samples/react/MusicStore/ReactApp/routes.tsx +++ /dev/null @@ -1,25 +0,0 @@ -import * as React from 'react'; -import { Router, Route, HistoryBase } from 'react-router'; -import NavMenu from './components/NavMenu'; -import Home from './components/public/Home'; -import Genres from './components/public/Genres'; -import GenreDetails from './components/public/GenreDetails'; -import AlbumDetails from './components/public/AlbumDetails'; - -class Layout extends React.Component<{ body: React.ReactElement }, void> { - public render() { - return
    - -
    - { this.props.body } -
    -
    ; - } -} - -export const routes = - - - - -; diff --git a/samples/react/MusicStore/ReactApp/store/AlbumDetails.ts b/samples/react/MusicStore/ReactApp/store/AlbumDetails.ts deleted file mode 100644 index ad3f458..0000000 --- a/samples/react/MusicStore/ReactApp/store/AlbumDetails.ts +++ /dev/null @@ -1,81 +0,0 @@ -import { fetch, addTask } from 'domain-task'; -import { typeName, isActionType, Action, Reducer } from 'redux-typed'; -import { ActionCreator } from './'; -import { Genre } from './GenreList'; - -// ----------------- -// STATE - This defines the type of data maintained in the Redux store. - -export interface AlbumDetailsState { - album: AlbumDetails; - requestedAlbumId: number; -} - -export interface AlbumDetails { - AlbumId: number; - Title: string; - AlbumArtUrl: string; - Genre: Genre; - Artist: Artist; - Price: number; -} - -interface Artist { - Name: string; -} - -// ----------------- -// ACTIONS - These are serializable (hence replayable) descriptions of state transitions. -// They do not themselves have any side-effects; they just describe something that is going to happen. -// Use @typeName and isActionType for type detection that works even after serialization/deserialization. - -@typeName("REQUEST_ALBUM_DETAILS") -class RequestAlbumDetails extends Action { - constructor(public albumId: number) { - super(); - } -} - -@typeName("RECEIVE_ALBUM_DETAILS") -class ReceiveAlbumDetails extends Action { - constructor(public album: AlbumDetails) { - super(); - } -} - -// ---------------- -// ACTION CREATORS - These are functions exposed to UI components that will trigger a state transition. -// They don't directly mutate state, but they can have external side-effects (such as loading data). - -export const actionCreators = { - requestAlbumDetails: (albumId: number): ActionCreator => (dispatch, getState) => { - // Only load if it's not already loaded (or currently being loaded) - if (albumId !== getState().albumDetails.requestedAlbumId) { - let fetchTask = fetch(`/api/albums/${ albumId }`) - .then(results => results.json()) - .then(album => { - // Only replace state if it's still the most recent request - if (albumId === getState().albumDetails.requestedAlbumId) { - dispatch(new ReceiveAlbumDetails(album)); - } - }); - - addTask(fetchTask); // Ensure server-side prerendering waits for this to complete - dispatch(new RequestAlbumDetails(albumId)); - } - } -}; - -// ---------------- -// REDUCER - For a given state and action, returns the new state. To support time travel, this must not mutate the old state. -// For unrecognized actions, must return the existing state (or default initial state if none was supplied). -const unloadedState: AlbumDetailsState = { requestedAlbumId: null as number, album: null }; -export const reducer: Reducer = (state, action) => { - if (isActionType(action, RequestAlbumDetails)) { - return { requestedAlbumId: action.albumId, album: null }; - } else if (isActionType(action, ReceiveAlbumDetails)) { - return { requestedAlbumId: action.album.AlbumId, album: action.album }; - } else { - return state || unloadedState; - } -}; diff --git a/samples/react/MusicStore/ReactApp/store/FeaturedAlbums.ts b/samples/react/MusicStore/ReactApp/store/FeaturedAlbums.ts deleted file mode 100644 index f9e7828..0000000 --- a/samples/react/MusicStore/ReactApp/store/FeaturedAlbums.ts +++ /dev/null @@ -1,62 +0,0 @@ -import { fetch, addTask } from 'domain-task'; -import { typeName, isActionType, Action, Reducer } from 'redux-typed'; -import { ActionCreator } from './'; - -// ----------------- -// STATE - This defines the type of data maintained in the Redux store. - -export interface FeaturedAlbumsState { - albums: Album[]; - isLoaded: boolean; -} - -export interface Album { - AlbumId: number; - Title: string; - AlbumArtUrl: string; -} - -// ----------------- -// ACTIONS - These are serializable (hence replayable) descriptions of state transitions. -// They do not themselves have any side-effects; they just describe something that is going to happen. -// Use @typeName and isActionType for type detection that works even after serialization/deserialization. - -@typeName("REQUEST_FEATURED_ALBUMS") -class RequestFeaturedAlbums extends Action { -} - -@typeName("RECEIVE_FEATURED_ALBUMS") -class ReceiveFeaturedAlbums extends Action { - constructor(public albums: Album[]) { - super(); - } -} - -// ---------------- -// ACTION CREATORS - These are functions exposed to UI components that will trigger a state transition. -// They don't directly mutate state, but they can have external side-effects (such as loading data). - -export const actionCreators = { - requestFeaturedAlbums: (): ActionCreator => (dispatch, getState) => { - if (!getState().featuredAlbums.isLoaded) { - let fetchTask = fetch('/api/albums/mostPopular') - .then(results => results.json()) - .then(albums => dispatch(new ReceiveFeaturedAlbums(albums))); - - addTask(fetchTask); // Ensure server-side prerendering waits for this to complete - return dispatch(new RequestFeaturedAlbums()); - } - } -}; - -// ---------------- -// REDUCER - For a given state and action, returns the new state. To support time travel, this must not mutate the old state. -// For unrecognized actions, must return the existing state (or default initial state if none was supplied). - -export const reducer: Reducer = (state, action) => { - if (isActionType(action, ReceiveFeaturedAlbums)) { - return { albums: action.albums, isLoaded: true }; - } else { - return state || { albums: [], isLoaded: false }; - } -}; diff --git a/samples/react/MusicStore/ReactApp/store/GenreDetails.ts b/samples/react/MusicStore/ReactApp/store/GenreDetails.ts deleted file mode 100644 index 24848a1..0000000 --- a/samples/react/MusicStore/ReactApp/store/GenreDetails.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { fetch, addTask } from 'domain-task'; -import { typeName, isActionType, Action, Reducer } from 'redux-typed'; -import { ActionCreator } from './'; -import { Album } from './FeaturedAlbums'; - -// ----------------- -// STATE - This defines the type of data maintained in the Redux store. - -export interface GenreDetailsState { - requestedGenreId: number; - albums: Album[]; - isLoaded: boolean; -} - -// ----------------- -// ACTIONS - These are serializable (hence replayable) descriptions of state transitions. -// They do not themselves have any side-effects; they just describe something that is going to happen. -// Use @typeName and isActionType for type detection that works even after serialization/deserialization. - -@typeName("REQUEST_GENRE_DETAILS") -class RequestGenreDetails extends Action { - constructor(public genreId: number) { - super(); - } -} - -@typeName("RECEIVE_GENRE_DETAILS") -class ReceiveGenreDetails extends Action { - constructor(public genreId: number, public albums: Album[]) { - super(); - } -} - -// ---------------- -// ACTION CREATORS - These are functions exposed to UI components that will trigger a state transition. -// They don't directly mutate state, but they can have external side-effects (such as loading data). - -export const actionCreators = { - requestGenreDetails: (genreId: number): ActionCreator => (dispatch, getState) => { - // Only load if it's not already loaded (or currently being loaded) - if (genreId !== getState().genreDetails.requestedGenreId) { - let fetchTask = fetch(`/api/genres/${ genreId }/albums`) - .then(results => results.json()) - .then(albums => { - // Only replace state if it's still the most recent request - if (genreId === getState().genreDetails.requestedGenreId) { - dispatch(new ReceiveGenreDetails(genreId, albums)); - } - }); - - addTask(fetchTask); // Ensure server-side prerendering waits for this to complete - dispatch(new RequestGenreDetails(genreId)); - } - } -}; - -// ---------------- -// REDUCER - For a given state and action, returns the new state. To support time travel, this must not mutate the old state. -// For unrecognized actions, must return the existing state (or default initial state if none was supplied). -export const reducer: Reducer = (state, action) => { - if (isActionType(action, RequestGenreDetails)) { - return { requestedGenreId: action.genreId, albums: [], isLoaded: false }; - } else if (isActionType(action, ReceiveGenreDetails)) { - return { requestedGenreId: action.genreId, albums: action.albums, isLoaded: true }; - } else { - return state || { requestedGenreId: null as number, albums: [], isLoaded: false }; - } -}; diff --git a/samples/react/MusicStore/ReactApp/store/GenreList.ts b/samples/react/MusicStore/ReactApp/store/GenreList.ts deleted file mode 100644 index 8843f22..0000000 --- a/samples/react/MusicStore/ReactApp/store/GenreList.ts +++ /dev/null @@ -1,55 +0,0 @@ -import { fetch, addTask } from 'domain-task'; -import { typeName, isActionType, Action, Reducer } from 'redux-typed'; -import { ActionCreator } from './'; - -// ----------------- -// STATE - This defines the type of data maintained in the Redux store. - -export interface GenresListState { - genres: Genre[]; - isLoaded: boolean; -} - -export interface Genre { - GenreId: string; - Name: string; -} - -// ----------------- -// ACTIONS - These are serializable (hence replayable) descriptions of state transitions. -// They do not themselves have any side-effects; they just describe something that is going to happen. -// Use @typeName and isActionType for type detection that works even after serialization/deserialization. - -@typeName("RECEIVE_GENRES_LIST") -class ReceiveGenresList extends Action { - constructor(public genres: Genre[]) { - super(); - } -} - -// ---------------- -// ACTION CREATORS - These are functions exposed to UI components that will trigger a state transition. -// They don't directly mutate state, but they can have external side-effects (such as loading data). - -export const actionCreators = { - requestGenresList: (): ActionCreator => (dispatch, getState) => { - if (!getState().genreList.isLoaded) { - let fetchTask = fetch('/api/genres') - .then(results => results.json()) - .then(genres => dispatch(new ReceiveGenresList(genres))); - addTask(fetchTask); // Ensure server-side prerendering waits for this to complete - } - } -}; - -// ---------------- -// REDUCER - For a given state and action, returns the new state. To support time travel, this must not mutate the old state. -// For unrecognized actions, must return the existing state (or default initial state if none was supplied). - -export const reducer: Reducer = (state, action) => { - if (isActionType(action, ReceiveGenresList)) { - return { genres: action.genres, isLoaded: true }; - } else { - return state || { genres: [], isLoaded: false }; - } -}; diff --git a/samples/react/MusicStore/ReactApp/store/index.ts b/samples/react/MusicStore/ReactApp/store/index.ts deleted file mode 100644 index 50f6178..0000000 --- a/samples/react/MusicStore/ReactApp/store/index.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { ActionCreatorGeneric } from 'redux-typed'; -import * as FeaturedAlbums from './FeaturedAlbums'; -import * as GenreList from './GenreList'; -import * as GenreDetails from './GenreDetails'; -import * as AlbumDetails from './AlbumDetails'; - -// The top-level state object -export interface ApplicationState { - featuredAlbums: FeaturedAlbums.FeaturedAlbumsState; - genreList: GenreList.GenresListState, - genreDetails: GenreDetails.GenreDetailsState, - albumDetails: AlbumDetails.AlbumDetailsState -} - -// Whenever an action is dispatched, Redux will update each top-level application state property using -// the reducer with the matching name. It's important that the names match exactly, and that the reducer -// acts on the corresponding ApplicationState property type. -export const reducers = { - featuredAlbums: FeaturedAlbums.reducer, - genreList: GenreList.reducer, - genreDetails: GenreDetails.reducer, - albumDetails: AlbumDetails.reducer -}; - -// This type can be used as a hint on action creators so that its 'dispatch' and 'getState' params are -// correctly typed to match your store. -export type ActionCreator = ActionCreatorGeneric; diff --git a/samples/react/MusicStore/ReactApp/styles/styles.css b/samples/react/MusicStore/ReactApp/styles/styles.css deleted file mode 100644 index a8fc8a1..0000000 --- a/samples/react/MusicStore/ReactApp/styles/styles.css +++ /dev/null @@ -1,3 +0,0 @@ -body { - padding-top: 50px; -} diff --git a/samples/react/MusicStore/SiteSettings.cs b/samples/react/MusicStore/SiteSettings.cs deleted file mode 100644 index 50a86c2..0000000 --- a/samples/react/MusicStore/SiteSettings.cs +++ /dev/null @@ -1,13 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; - -namespace MusicStore -{ - public class SiteSettings - { - public string DefaultAdminUsername { get; set; } - public string DefaultAdminPassword { get; set; } - } -} diff --git a/samples/react/MusicStore/Startup.cs b/samples/react/MusicStore/Startup.cs deleted file mode 100755 index 6b649e9..0000000 --- a/samples/react/MusicStore/Startup.cs +++ /dev/null @@ -1,114 +0,0 @@ -using System; -using System.Collections.Generic; -using System.IO; -using Microsoft.AspNetCore.Authorization; -using Microsoft.AspNetCore.Builder; -using Microsoft.AspNetCore.Hosting; -using Microsoft.AspNetCore.Identity.EntityFrameworkCore; -using Microsoft.AspNetCore.SpaServices.Webpack; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.Extensions.Configuration; -using Microsoft.Extensions.DependencyInjection; -using Microsoft.Extensions.Logging; -using Microsoft.Extensions.PlatformAbstractions; -using AutoMapper; -using MusicStore.Apis; -using MusicStore.Models; -using Newtonsoft.Json.Serialization; - -namespace MusicStore -{ - public class Startup - { - // This method gets called by the runtime. Use this method to add services to the container. - public void ConfigureServices(IServiceCollection services) - { - services.AddMvc().AddJsonOptions(options => - { - options.SerializerSettings.ContractResolver = null; - }); - - // Add EF services to the service container - services - .AddEntityFrameworkSqlite() - .AddDbContext(options => { - options.UseSqlite("Data Source=music-db.sqlite"); - }); - - // Add Identity services to the services container - services.AddIdentity() - .AddEntityFrameworkStores() - .AddDefaultTokenProviders(); - - // Configure Auth - services.Configure(options => - { - options.AddPolicy("app-ManageStore", new AuthorizationPolicyBuilder().RequireClaim("app-ManageStore", "Allowed").Build()); - }); - - Mapper.Initialize(cfg => - { - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - cfg.CreateMap(); - }); - } - - // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. - public void Configure(IApplicationBuilder app, ILoggerFactory loggerFactory, IHostingEnvironment env) - { - app.UseDeveloperExceptionPage(); - - // Initialize the sample data - SampleData.InitializeMusicStoreDatabaseAsync(app.ApplicationServices).Wait(); - - // In dev mode, the JS/TS/etc is compiled and served dynamically and supports hot replacement. - // In production, we assume you've used webpack to emit the prebuilt content to disk. - if (env.IsDevelopment()) { - app.UseWebpackDevMiddleware(new WebpackDevMiddlewareOptions { - HotModuleReplacement = true, - ReactHotModuleReplacement = true - }); - } - - app.UseStaticFiles(); - loggerFactory.AddConsole(); - - // Add MVC to the request pipeline. - app.UseMvc(routes => - { - // Matches requests that correspond to an existent controller/action pair - routes.MapRoute( - name: "default", - template: "{controller=Home}/{action=Index}/{id?}"); - - // Matches any other request that doesn't appear to have a filename extension (defined as 'having a dot in the last URI segment'). - // This means you'll correctly get 404s for /some/dir/non-existent-image.png instead of returning the SPA HTML. - // However, it means requests like /customers/isaac.newton will *not* be mapped into the SPA, so if you need to accept - // URIs like that you'll need to match all URIs, e.g.: - // routes.MapRoute("spa-fallback", "{*anything}", new { controller = "Home", action = "Index" }); - // (which of course will match /customers/isaac.png too, so in that case it would serve the PNG image at that URL if one is on disk, - // or the SPA HTML if not). - routes.MapSpaFallbackRoute("spa-fallback", new { controller = "Home", action = "Index" }); - }); - } - - public static void Main(string[] args) - { - var host = new WebHostBuilder() - .UseContentRoot(Directory.GetCurrentDirectory()) - .UseIISIntegration() - .UseKestrel() - .UseStartup() - .Build(); - - host.Run(); - } - } -} diff --git a/samples/react/MusicStore/Views/Home/Index.cshtml b/samples/react/MusicStore/Views/Home/Index.cshtml deleted file mode 100755 index 9595e01..0000000 --- a/samples/react/MusicStore/Views/Home/Index.cshtml +++ /dev/null @@ -1,11 +0,0 @@ -@{ - ViewData["Title"] = "Home Page"; -} - -
    - -@section scripts { - - -} diff --git a/samples/react/MusicStore/Views/Shared/Error.cshtml b/samples/react/MusicStore/Views/Shared/Error.cshtml deleted file mode 100755 index 473b35d..0000000 --- a/samples/react/MusicStore/Views/Shared/Error.cshtml +++ /dev/null @@ -1,6 +0,0 @@ -@{ - ViewData["Title"] = "Error"; -} - -

    Error.

    -

    An error occurred while processing your request.

    diff --git a/samples/react/MusicStore/Views/Shared/_Layout.cshtml b/samples/react/MusicStore/Views/Shared/_Layout.cshtml deleted file mode 100755 index 47e4e48..0000000 --- a/samples/react/MusicStore/Views/Shared/_Layout.cshtml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - @ViewData["Title"] - - - - @RenderBody() - @RenderSection("scripts", required: false) - - diff --git a/samples/react/MusicStore/Views/_ViewImports.cshtml b/samples/react/MusicStore/Views/_ViewImports.cshtml deleted file mode 100755 index 1730292..0000000 --- a/samples/react/MusicStore/Views/_ViewImports.cshtml +++ /dev/null @@ -1,3 +0,0 @@ -@using MusicStore -@addTagHelper "*, Microsoft.AspNetCore.Mvc.TagHelpers" -@addTagHelper "*, Microsoft.AspNetCore.SpaServices" diff --git a/samples/react/MusicStore/Views/_ViewStart.cshtml b/samples/react/MusicStore/Views/_ViewStart.cshtml deleted file mode 100755 index 820a2f6..0000000 --- a/samples/react/MusicStore/Views/_ViewStart.cshtml +++ /dev/null @@ -1,3 +0,0 @@ -@{ - Layout = "_Layout"; -} diff --git a/samples/react/MusicStore/package.json b/samples/react/MusicStore/package.json deleted file mode 100644 index bd501e7..0000000 --- a/samples/react/MusicStore/package.json +++ /dev/null @@ -1,52 +0,0 @@ -{ - "name": "music-store", - "version": "0.0.0", - "dependencies": { - "@types/history": "^2.0.0", - "@types/react": "^0.14.29", - "@types/react-bootstrap": "^0.0.35", - "@types/react-dom": "^0.14.14", - "@types/react-redux": "^4.4.29", - "@types/react-router": "^2.0.30", - "@types/react-router-bootstrap": "^0.0.27", - "@types/react-router-redux": "^4.0.30", - "@types/redux-thunk": "^2.1.28", - "@types/source-map": "^0.1.28", - "@types/uglify-js": "^2.0.27", - "@types/webpack": "^1.12.35", - "@types/webpack-env": "^1.12.1", - "@types/whatwg-fetch": "0.0.28", - "aspnet-prerendering": "^1.0.7", - "aspnet-webpack": "^1.0.17", - "aspnet-webpack-react": "^1.0.2", - "babel-core": "^6.5.2", - "babel-loader": "^6.2.3", - "babel-preset-es2015": "^6.5.0", - "babel-preset-react": "^6.5.0", - "bootstrap": "^3.3.6", - "css-loader": "^0.23.1", - "domain-task": "^2.0.1", - "event-source-polyfill": "^0.0.7", - "extract-text-webpack-plugin": "^1.0.1", - "file-loader": "^0.8.5", - "jquery": "^2.2.1", - "react": "^15.3.2", - "react-bootstrap": "^0.30.6", - "react-dom": "^15.3.2", - "react-redux": "^4.4.5", - "react-router": "^2.8.1", - "react-router-bootstrap": "^0.23.1", - "react-router-redux": "^4.0.6", - "redux": "^3.6.0", - "redux-thunk": "^2.1.0", - "redux-typed": "^2.0.0", - "style-loader": "^0.13.0", - "ts-loader": "^0.8.1", - "typescript": "^2.0.3", - "url-loader": "^0.5.7", - "webpack": "^1.13.2", - "webpack-hot-middleware": "^2.12.2", - "webpack-merge": "^0.14.1", - "webpack-node-externals": "^1.4.3" - } -} diff --git a/samples/react/MusicStore/tsconfig.json b/samples/react/MusicStore/tsconfig.json deleted file mode 100644 index 15a9f3f..0000000 --- a/samples/react/MusicStore/tsconfig.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "compilerOptions": { - "baseUrl": ".", - "moduleResolution": "node", - "target": "es6", - "jsx": "preserve", - "sourceMap": true, - "experimentalDecorators": true, - "types": [ "webpack-env", "whatwg-fetch" ], - "paths": { - // Fix "Duplicate identifier" errors caused by multiple dependencies fetching their own copies of type definitions. - // We tell TypeScript which type definitions module to treat as the canonical one (instead of combining all of them). - "history": ["./node_modules/@types/history/index"], - "redux": ["./node_modules/@types/redux/index"], - "react": ["./node_modules/@types/react/index"] - } - }, - "exclude": [ - "node_modules" - ] -} diff --git a/samples/react/MusicStore/webpack.config.js b/samples/react/MusicStore/webpack.config.js deleted file mode 100644 index 521e68d..0000000 --- a/samples/react/MusicStore/webpack.config.js +++ /dev/null @@ -1,32 +0,0 @@ -var path = require('path'); -var webpack = require('webpack'); -var ExtractTextPlugin = require('extract-text-webpack-plugin'); - -module.exports = { - devtool: 'inline-source-map', - resolve: { - extensions: [ '', '.js', '.jsx', '.ts', '.tsx' ] - }, - module: { - loaders: [ - { test: /\.ts(x?)$/, include: /ReactApp/, exclude: /node_modules/, loader: 'babel-loader' }, - { test: /\.ts(x?)$/, include: /ReactApp/, exclude: /node_modules/, loader: 'ts-loader?silent' }, - { test: /\.css$/, loader: ExtractTextPlugin.extract('style-loader', 'css-loader') }, - { test: /\.(png|woff|woff2|eot|ttf|svg)$/, loader: 'url-loader?limit=100000' } - ] - }, - entry: { - main: ['./ReactApp/boot.tsx'], - vendor: ['react'] - }, - output: { - path: path.join(__dirname, 'wwwroot', 'dist'), - filename: '[name].js', - publicPath: '/dist/' - }, - plugins: [ - new webpack.optimize.OccurenceOrderPlugin(), - new ExtractTextPlugin('main.css'), - new webpack.optimize.CommonsChunkPlugin('vendor', 'vendor.bundle.js') // Moves vendor content out of other bundles - ] -}; diff --git a/samples/react/MusicStore/wwwroot/favicon.ico b/samples/react/MusicStore/wwwroot/favicon.ico deleted file mode 100755 index a3a7999..0000000 Binary files a/samples/react/MusicStore/wwwroot/favicon.ico and /dev/null differ diff --git a/samples/react/MusicStore/wwwroot/images/home-showcase.png b/samples/react/MusicStore/wwwroot/images/home-showcase.png deleted file mode 100644 index 258c19d..0000000 Binary files a/samples/react/MusicStore/wwwroot/images/home-showcase.png and /dev/null differ diff --git a/samples/react/MusicStore/wwwroot/images/logo.png b/samples/react/MusicStore/wwwroot/images/logo.png deleted file mode 100644 index d334c86..0000000 Binary files a/samples/react/MusicStore/wwwroot/images/logo.png and /dev/null differ diff --git a/samples/react/MusicStore/wwwroot/images/placeholder.png b/samples/react/MusicStore/wwwroot/images/placeholder.png deleted file mode 100644 index 1f73dbb..0000000 Binary files a/samples/react/MusicStore/wwwroot/images/placeholder.png and /dev/null differ diff --git a/samples/react/MusicStore/wwwroot/web.config b/samples/react/MusicStore/wwwroot/web.config deleted file mode 100644 index e70a777..0000000 --- a/samples/react/MusicStore/wwwroot/web.config +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/samples/react/ReactGrid/.babelrc b/samples/react/ReactGrid/.babelrc deleted file mode 100644 index d4e5f8d..0000000 --- a/samples/react/ReactGrid/.babelrc +++ /dev/null @@ -1,3 +0,0 @@ -{ - "presets": ["es2015", "react"] -} diff --git a/samples/react/ReactGrid/.gitignore b/samples/react/ReactGrid/.gitignore deleted file mode 100644 index f050c80..0000000 --- a/samples/react/ReactGrid/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -/node_modules/ -/wwwroot/dist/ -/Properties/launchSettings.json diff --git a/samples/react/ReactGrid/Controllers/HomeController.cs b/samples/react/ReactGrid/Controllers/HomeController.cs deleted file mode 100755 index b7a48c4..0000000 --- a/samples/react/ReactGrid/Controllers/HomeController.cs +++ /dev/null @@ -1,17 +0,0 @@ -using Microsoft.AspNetCore.Mvc; - -namespace ReactExample.Controllers -{ - public class HomeController : Controller - { - public IActionResult Index() - { - return View(); - } - - public IActionResult Error() - { - return View("~/Views/Shared/Error.cshtml"); - } - } -} diff --git a/samples/react/ReactGrid/Controllers/PeopleApiController.cs b/samples/react/ReactGrid/Controllers/PeopleApiController.cs deleted file mode 100644 index fd3e29c..0000000 --- a/samples/react/ReactGrid/Controllers/PeopleApiController.cs +++ /dev/null @@ -1,30 +0,0 @@ -using System.ComponentModel.DataAnnotations; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Mvc; - -namespace ReactExample.Controllers -{ - public class PeopleApiController : Controller - { - [HttpPut("api/people/{personId:int}")] - public ActionResult UpdatePerson([FromBody] PersonDto person) - { - if (!ModelState.IsValid) { - return BadRequest(ModelState); - } else { - return new OkResult(); - } - } - } - - public class PersonDto { - public string name { get; set; } - public string city { get; set; } - public string state { get; set; } - public string country { get; set; } - public string company { get; set; } - - [Range(1, 10)] - public int favoriteNumber { get; set; } - } -} diff --git a/samples/react/ReactGrid/README.txt b/samples/react/ReactGrid/README.txt deleted file mode 100644 index e702b30..0000000 --- a/samples/react/ReactGrid/README.txt +++ /dev/null @@ -1,2 +0,0 @@ -Portions of this sample application (particularly, the fake data) are based -on https://github.com/DavidWells/isomorphic-react-example diff --git a/samples/react/ReactGrid/ReactApp/boot-client.jsx b/samples/react/ReactGrid/ReactApp/boot-client.jsx deleted file mode 100644 index d109cdf..0000000 --- a/samples/react/ReactGrid/ReactApp/boot-client.jsx +++ /dev/null @@ -1,8 +0,0 @@ -import React from 'react'; -import ReactDOM from 'react-dom'; -import { browserHistory } from 'react-router'; -import { ReactApp } from './components/ReactApp.jsx'; -import 'bootstrap/dist/css/bootstrap.css'; - -// In the browser, we render into a DOM node and hook up to the browser's history APIs -ReactDOM.render(, document.getElementById('react-app')); diff --git a/samples/react/ReactGrid/ReactApp/boot-server.jsx b/samples/react/ReactGrid/ReactApp/boot-server.jsx deleted file mode 100644 index b41e0c7..0000000 --- a/samples/react/ReactGrid/ReactApp/boot-server.jsx +++ /dev/null @@ -1,23 +0,0 @@ -import React from 'react'; -import { renderToString } from 'react-dom/server'; -import { match, RouterContext } from 'react-router'; -import { routes } from './components/ReactApp'; -React; - -export default function renderApp (params) { - return new Promise((resolve, reject) => { - // Match the incoming request against the list of client-side routes - match({ routes, location: params.location }, (error, redirectLocation, renderProps) => { - if (error) { - throw error; - } - - // Build an instance of the application - const app = ; - - // Render it as an HTML string which can be injected into the response - const html = renderToString(app); - resolve({ html }); - }); - }); -} diff --git a/samples/react/ReactGrid/ReactApp/components/CustomPager.jsx b/samples/react/ReactGrid/ReactApp/components/CustomPager.jsx deleted file mode 100644 index 50a3008..0000000 --- a/samples/react/ReactGrid/ReactApp/components/CustomPager.jsx +++ /dev/null @@ -1,50 +0,0 @@ -import * as React from 'react'; -import { Link } from 'react-router'; - -export class CustomPager extends React.Component { - pageChange(event) { - this.props.setPage(parseInt(event.target.getAttribute("data-value"))); - } - - render() { - var previous = null; - var next = null; - - if(this.props.currentPage > 0){ - previous =
    {this.props.previousText}
    ; - } - - if(this.props.currentPage != (this.props.maxPage -1)){ - next =
    {this.props.nextText}
    ; - } - - var options = []; - - var startIndex = Math.max(this.props.currentPage - 5, 0); - var endIndex = Math.min(startIndex + 11, this.props.maxPage); - - if (this.props.maxPage >= 11 && (endIndex - startIndex) <= 10) { - startIndex = endIndex - 11; - } - - for(var i = startIndex; i < endIndex ; i++){ - var selected = this.props.currentPage == i ? "btn-default" : ""; - options.push(
    {i+1}
    ); - } - - return ( -
    - {previous} - {options} - {next} -
    - ); - } -} - -CustomPager.defaultProps = { - maxPage: 0, - nextText: '', - previousText: '', - currentPage: 0 -}; diff --git a/samples/react/ReactGrid/ReactApp/components/PeopleGrid.jsx b/samples/react/ReactGrid/ReactApp/components/PeopleGrid.jsx deleted file mode 100644 index 6ce0ade..0000000 --- a/samples/react/ReactGrid/ReactApp/components/PeopleGrid.jsx +++ /dev/null @@ -1,31 +0,0 @@ -import React from 'react'; -import Griddle from 'griddle-react'; -import { CustomPager } from './CustomPager.jsx'; -import { fakeData } from '../data/fakeData.js'; -import { columnMeta } from '../data/columnMeta.jsx'; -const resultsPerPage = 10; - -// Griddle requires each row to have a property matching each column, even if you're not displaying -// any data from the row in that column -fakeData.forEach(row => { row.actions = ''; }); - -export class PeopleGrid extends React.Component { - render() { - var pageIndex = this.props.params ? (this.props.params.pageIndex || 1) - 1 : 0; - return ( -
    -

    People

    -
    - x.columnName)} - columnMetadata={columnMeta} - resultsPerPage={resultsPerPage} - tableClassName="table" - useCustomPagerComponent="true" - customPagerComponent={CustomPager} - externalCurrentPage={pageIndex} /> -
    -
    - ); - } -} diff --git a/samples/react/ReactGrid/ReactApp/components/PersonEditor.jsx b/samples/react/ReactGrid/ReactApp/components/PersonEditor.jsx deleted file mode 100644 index 3c78f58..0000000 --- a/samples/react/ReactGrid/ReactApp/components/PersonEditor.jsx +++ /dev/null @@ -1,57 +0,0 @@ -import React from 'react'; -import Formsy from 'formsy-react'; -import { Input } from 'formsy-react-components'; -import { fakeData } from '../data/fakeData.js'; - -export class PersonEditor extends React.Component { - constructor() { - super(); - this.state = { savedChanges: false }; - } - - onChange() { - this.setState({ savedChanges: false }); - } - - submit(model, reset, setErrors) { - PersonEditor.sendJson('put', `/api/people/${ this.props.params.personId }`, model).then(response => { - if (response.ok) { - this.setState({ savedChanges: true }); - } else { - // Parse server-side validation errors from the response and display them - response.json().then(setErrors); - } - }); - } - - render() { - var personId = parseInt(this.props.params.personId); - var person = fakeData.filter(p => p.id === personId)[0]; - var notificationBox = this.state.savedChanges - &&
    Done! Your changes were saved.
    ; - - return
    -
    -

    Edit { person.name }

    -
    - - - - - - - - { notificationBox } - - -
    ; - } - - static sendJson(method, url, object) { - return fetch(url, { - method: method, - headers: { 'Content-Type': 'application/json' }, - body: JSON.stringify(object) - }); - } -} diff --git a/samples/react/ReactGrid/ReactApp/components/ReactApp.jsx b/samples/react/ReactGrid/ReactApp/components/ReactApp.jsx deleted file mode 100644 index 64977a7..0000000 --- a/samples/react/ReactGrid/ReactApp/components/ReactApp.jsx +++ /dev/null @@ -1,18 +0,0 @@ -import React from 'react'; -import { Router, Route } from 'react-router'; -import { PeopleGrid } from './PeopleGrid.jsx'; -import { PersonEditor } from './PersonEditor.jsx'; - -export const routes = - - - -; - -export class ReactApp extends React.Component { - render() { - return ( - - ); - } -} diff --git a/samples/react/ReactGrid/ReactApp/data/columnMeta.jsx b/samples/react/ReactGrid/ReactApp/data/columnMeta.jsx deleted file mode 100644 index f66a8a9..0000000 --- a/samples/react/ReactGrid/ReactApp/data/columnMeta.jsx +++ /dev/null @@ -1,60 +0,0 @@ -import React from 'react'; -import { Link } from 'react-router'; - -class RowActionsComponent extends React.Component { - render() { - return Edit; - } -} - -export const columnMeta = [ - { - "columnName": "id", - "order": 1, - "locked": false, - "visible": true - }, - { - "columnName": "name", - "order": 2, - "locked": false, - "visible": true - }, - { - "columnName": "city", - "order": 3, - "locked": false, - "visible": true - }, - { - "columnName": "state", - "order": 4, - "locked": false, - "visible": true - }, - { - "columnName": "country", - "order": 5, - "locked": false, - "visible": true - }, - { - "columnName": "company", - "order": 6, - "locked": false, - "visible": true - }, - { - "columnName": "favoriteNumber", - "order": 7, - "locked": false, - "visible": true - }, - { - "columnName": "actions", - "order": 8, - "locked": true, - "visible": true, - "customComponent": RowActionsComponent - } -]; diff --git a/samples/react/ReactGrid/ReactApp/data/fakeData.js b/samples/react/ReactGrid/ReactApp/data/fakeData.js deleted file mode 100644 index 08c8c0e..0000000 --- a/samples/react/ReactGrid/ReactApp/data/fakeData.js +++ /dev/null @@ -1,2486 +0,0 @@ -export const fakeData = [ - { - "id": 0, - "name": "Mayer Leonard", - "city": "Kapowsin", - "state": "Hawaii", - "country": "United Kingdom", - "company": "Ovolo", - "favoriteNumber": 7 - }, - { - "id": 1, - "name": "Koch Becker", - "city": "Johnsonburg", - "state": "New Jersey", - "country": "Madagascar", - "company": "Eventage", - "favoriteNumber": 2 - }, - { - "id": 2, - "name": "Lowery Hopkins", - "city": "Blanco", - "state": "Arizona", - "country": "Ukraine", - "company": "Comtext", - "favoriteNumber": 3 - }, - { - "id": 3, - "name": "Walters Mays", - "city": "Glendale", - "state": "Illinois", - "country": "New Zealand", - "company": "Corporana", - "favoriteNumber": 6 - }, - { - "id": 4, - "name": "Shaw Lowe", - "city": "Coultervillle", - "state": "Wyoming", - "country": "Ecuador", - "company": "Isologica", - "favoriteNumber": 2 - }, - { - "id": 5, - "name": "Ola Fernandez", - "city": "Deltaville", - "state": "Delaware", - "country": "Virgin Islands (US)", - "company": "Pawnagra", - "favoriteNumber": 7 - }, - { - "id": 6, - "name": "Park Carr", - "city": "Welda", - "state": "Kentucky", - "country": "Sri Lanka", - "company": "Cosmetex", - "favoriteNumber": 7 - }, - { - "id": 7, - "name": "Laverne Johnson", - "city": "Rosburg", - "state": "New Mexico", - "country": "Croatia", - "company": "Housedown", - "favoriteNumber": 9 - }, - { - "id": 8, - "name": "Lizzie Nelson", - "city": "Chumuckla", - "state": "Montana", - "country": "Turks & Caicos", - "company": "Everest", - "favoriteNumber": 2 - }, - { - "id": 9, - "name": "Clarke Clemons", - "city": "Inkerman", - "state": "Rhode Island", - "country": "Cambodia", - "company": "Apexia", - "favoriteNumber": 3 - }, - { - "id": 10, - "name": "Cindy Phelps", - "city": "Hachita", - "state": "North Carolina", - "country": "Namibia", - "company": "Pholio", - "favoriteNumber": 6 - }, - { - "id": 11, - "name": "Danielle Keller", - "city": "Stockdale", - "state": "Maryland", - "country": "Cape Verde", - "company": "Netility", - "favoriteNumber": 10 - }, - { - "id": 12, - "name": "Duke Hutchinson", - "city": "Needmore", - "state": "Indiana", - "country": "Brunei", - "company": "Electonic", - "favoriteNumber": 1 - }, - { - "id": 13, - "name": "Aimee Duffy", - "city": "Brownlee", - "state": "Vermont", - "country": "Lebanon", - "company": "Repetwire", - "favoriteNumber": 2 - }, - { - "id": 14, - "name": "Meadows Jimenez", - "city": "Winesburg", - "state": "Kansas", - "country": "Timor L'Este", - "company": "Quonk", - "favoriteNumber": 0 - }, - { - "id": 15, - "name": "Karla Potts", - "city": "Juarez", - "state": "Alaska", - "country": "Samoa", - "company": "Zentime", - "favoriteNumber": 3 - }, - { - "id": 16, - "name": "Rita Jensen", - "city": "Elwood", - "state": "North Dakota", - "country": "Greece", - "company": "Valpreal", - "favoriteNumber": 9 - }, - { - "id": 17, - "name": "Jackie Burke", - "city": "Delwood", - "state": "Arkansas", - "country": "Greenland", - "company": "Magmina", - "favoriteNumber": 4 - }, - { - "id": 18, - "name": "Corinne Moreno", - "city": "Wollochet", - "state": "New Hampshire", - "country": "Sierra Leone", - "company": "Marketoid", - "favoriteNumber": 1 - }, - { - "id": 19, - "name": "Giles Cohen", - "city": "Carbonville", - "state": "Massachusetts", - "country": "Tonga", - "company": "Ginkogene", - "favoriteNumber": 10 - }, - { - "id": 20, - "name": "Maynard Barnes", - "city": "Boling", - "state": "Utah", - "country": "Nepal", - "company": "Kyaguru", - "favoriteNumber": 8 - }, - { - "id": 21, - "name": "Singleton Lindsay", - "city": "Weogufka", - "state": "Tennessee", - "country": "Falkland Islands", - "company": "Egypto", - "favoriteNumber": 5 - }, - { - "id": 22, - "name": "Etta Kemp", - "city": "Como", - "state": "Pennsylvania", - "country": "Syria", - "company": "Marqet", - "favoriteNumber": 3 - }, - { - "id": 23, - "name": "Whitney Pennington", - "city": "Farmington", - "state": "Louisiana", - "country": "Suriname", - "company": "Prosure", - "favoriteNumber": 10 - }, - { - "id": 24, - "name": "Sophie Ellison", - "city": "Whitewater", - "state": "Idaho", - "country": "Malta", - "company": "Evidends", - "favoriteNumber": 1 - }, - { - "id": 25, - "name": "Logan Forbes", - "city": "Idledale", - "state": "Michigan", - "country": "Dominican Republic", - "company": "Pigzart", - "favoriteNumber": 3 - }, - { - "id": 26, - "name": "Haley Mcclure", - "city": "Eggertsville", - "state": "Colorado", - "country": "Honduras", - "company": "Ginkle", - "favoriteNumber": 8 - }, - { - "id": 27, - "name": "Williamson Hurley", - "city": "Edgar", - "state": "Texas", - "country": "Yemen", - "company": "Tetratrex", - "favoriteNumber": 3 - }, - { - "id": 28, - "name": "Heidi Hurst", - "city": "Curtice", - "state": "Nebraska", - "country": "Aruba", - "company": "Vendblend", - "favoriteNumber": 10 - }, - { - "id": 29, - "name": "Barker Long", - "city": "Orovada", - "state": "West Virginia", - "country": "Egypt", - "company": "Uniworld", - "favoriteNumber": 8 - }, - { - "id": 30, - "name": "Richard Patrick", - "city": "Gordon", - "state": "Oregon", - "country": "Malawi", - "company": "Quarx", - "favoriteNumber": 8 - }, - { - "id": 31, - "name": "Cameron Graham", - "city": "Noblestown", - "state": "Oklahoma", - "country": "Slovenia", - "company": "Zilidium", - "favoriteNumber": 5 - }, - { - "id": 32, - "name": "Lucy Quinn", - "city": "Greenock", - "state": "Ohio", - "country": "Australia", - "company": "Geoform", - "favoriteNumber": 10 - }, - { - "id": 33, - "name": "Dickson Greene", - "city": "Jeff", - "state": "Virginia", - "country": "Iraq", - "company": "Niquent", - "favoriteNumber": 6 - }, - { - "id": 34, - "name": "Jasmine Brock", - "city": "Tolu", - "state": "Mississippi", - "country": "Hungary", - "company": "Cytrek", - "favoriteNumber": 8 - }, - { - "id": 35, - "name": "Byers Donaldson", - "city": "Jugtown", - "state": "South Dakota", - "country": "Mongolia", - "company": "Slambda", - "favoriteNumber": 4 - }, - { - "id": 36, - "name": "Burns Blake", - "city": "Shawmut", - "state": "Iowa", - "country": "Ethiopia", - "company": "Comstar", - "favoriteNumber": 9 - }, - { - "id": 37, - "name": "Norman Wynn", - "city": "Hasty", - "state": "Washington", - "country": "Bangladesh", - "company": "Netplode", - "favoriteNumber": 7 - }, - { - "id": 38, - "name": "Anthony Weeks", - "city": "Chautauqua", - "state": "Florida", - "country": "Sudan", - "company": "Rubadub", - "favoriteNumber": 9 - }, - { - "id": 39, - "name": "Courtney Marshall", - "city": "Grazierville", - "state": "California", - "country": "Zambia", - "company": "Medicroix", - "favoriteNumber": 0 - }, - { - "id": 40, - "name": "Wilda Foster", - "city": "Ebro", - "state": "New York", - "country": "Cameroon", - "company": "Xixan", - "favoriteNumber": 0 - }, - { - "id": 41, - "name": "Buckner Hyde", - "city": "Century", - "state": "Minnesota", - "country": "Mexico", - "company": "Plasmos", - "favoriteNumber": 6 - }, - { - "id": 42, - "name": "Montgomery Woodard", - "city": "Nadine", - "state": "Georgia", - "country": "Zimbabwe", - "company": "Neptide", - "favoriteNumber": 1 - }, - { - "id": 43, - "name": "Shirley Boyle", - "city": "Groveville", - "state": "Connecticut", - "country": "Tunisia", - "company": "Interodeo", - "favoriteNumber": 1 - }, - { - "id": 44, - "name": "Mavis Welch", - "city": "Springhill", - "state": "South Carolina", - "country": "Italy", - "company": "Asimiline", - "favoriteNumber": 9 - }, - { - "id": 45, - "name": "Barr Flowers", - "city": "Bowden", - "state": "Missouri", - "country": "South Korea", - "company": "Terragen", - "favoriteNumber": 7 - }, - { - "id": 46, - "name": "Cabrera Koch", - "city": "Wanship", - "state": "Maine", - "country": "Mauritius", - "company": "Norsul", - "favoriteNumber": 9 - }, - { - "id": 47, - "name": "Williams Gamble", - "city": "Homestead", - "state": "Wisconsin", - "country": "Romania", - "company": "Gynk", - "favoriteNumber": 4 - }, - { - "id": 48, - "name": "Angelica Washington", - "city": "Roulette", - "state": "Alabama", - "country": "South Africa", - "company": "Exoswitch", - "favoriteNumber": 3 - }, - { - "id": 49, - "name": "Morse Navarro", - "city": "Balm", - "state": "Hawaii", - "country": "Malaysia", - "company": "Comtours", - "favoriteNumber": 7 - }, - { - "id": 50, - "name": "Harding Chambers", - "city": "Lupton", - "state": "New Jersey", - "country": "Oman", - "company": "Gadtron", - "favoriteNumber": 6 - }, - { - "id": 51, - "name": "Frederick Mcdowell", - "city": "Kimmell", - "state": "Arizona", - "country": "Ireland", - "company": "Delphide", - "favoriteNumber": 2 - }, - { - "id": 52, - "name": "Valentine Turner", - "city": "Hobucken", - "state": "Illinois", - "country": "France", - "company": "Sloganaut", - "favoriteNumber": 0 - }, - { - "id": 53, - "name": "Ruby Cooper", - "city": "Connerton", - "state": "Wyoming", - "country": "Iceland", - "company": "Exospace", - "favoriteNumber": 5 - }, - { - "id": 54, - "name": "Natalia Nielsen", - "city": "Holtville", - "state": "Delaware", - "country": "Equatorial Guinea", - "company": "Isoswitch", - "favoriteNumber": 6 - }, - { - "id": 55, - "name": "Bobbie Silva", - "city": "Fivepointville", - "state": "Kentucky", - "country": "Luxembourg", - "company": "Futuris", - "favoriteNumber": 0 - }, - { - "id": 56, - "name": "Clarice Hays", - "city": "Floriston", - "state": "New Mexico", - "country": "Cruise Ship", - "company": "Skyplex", - "favoriteNumber": 5 - }, - { - "id": 57, - "name": "Leblanc Bartlett", - "city": "Catherine", - "state": "Montana", - "country": "Belarus", - "company": "Ezentia", - "favoriteNumber": 10 - }, - { - "id": 58, - "name": "Jodie Martinez", - "city": "Edneyville", - "state": "Rhode Island", - "country": "Antigua & Barbuda", - "company": "Satiance", - "favoriteNumber": 7 - }, - { - "id": 59, - "name": "Pennington Townsend", - "city": "Ahwahnee", - "state": "North Carolina", - "country": "Chad", - "company": "Orbiflex", - "favoriteNumber": 8 - }, - { - "id": 60, - "name": "Garrison Buchanan", - "city": "Coinjock", - "state": "Maryland", - "country": "Reunion", - "company": "Zanity", - "favoriteNumber": 3 - }, - { - "id": 61, - "name": "Cardenas Reeves", - "city": "Greensburg", - "state": "Indiana", - "country": "Gabon", - "company": "Cogentry", - "favoriteNumber": 1 - }, - { - "id": 62, - "name": "Angeline Jacobson", - "city": "Freeburn", - "state": "Vermont", - "country": "Fiji", - "company": "Pearlessa", - "favoriteNumber": 4 - }, - { - "id": 63, - "name": "Turner Franks", - "city": "Fairforest", - "state": "Kansas", - "country": "New Caledonia", - "company": "Maximind", - "favoriteNumber": 1 - }, - { - "id": 64, - "name": "Murphy Santos", - "city": "Waiohinu", - "state": "Alaska", - "country": "Haiti", - "company": "Isodrive", - "favoriteNumber": 0 - }, - { - "id": 65, - "name": "Walls Cherry", - "city": "Avalon", - "state": "North Dakota", - "country": "Mozambique", - "company": "Bolax", - "favoriteNumber": 10 - }, - { - "id": 66, - "name": "Carney Olson", - "city": "Nanafalia", - "state": "Arkansas", - "country": "Pakistan", - "company": "Unq", - "favoriteNumber": 10 - }, - { - "id": 67, - "name": "Jennings Bowers", - "city": "Kenwood", - "state": "New Hampshire", - "country": "Cayman Islands", - "company": "Deepends", - "favoriteNumber": 10 - }, - { - "id": 68, - "name": "Browning Wooten", - "city": "Jessie", - "state": "Massachusetts", - "country": "Guam", - "company": "Eventex", - "favoriteNumber": 5 - }, - { - "id": 69, - "name": "Preston Britt", - "city": "Dennard", - "state": "Utah", - "country": "Cyprus", - "company": "Sureplex", - "favoriteNumber": 4 - }, - { - "id": 70, - "name": "Holly Martin", - "city": "Carrizo", - "state": "Tennessee", - "country": "Nicaragua", - "company": "Sonique", - "favoriteNumber": 1 - }, - { - "id": 71, - "name": "Zelma Barker", - "city": "Zarephath", - "state": "Pennsylvania", - "country": "Czech Republic", - "company": "Xanide", - "favoriteNumber": 9 - }, - { - "id": 72, - "name": "Burgess Zamora", - "city": "Tampico", - "state": "Louisiana", - "country": "Poland", - "company": "Isopop", - "favoriteNumber": 10 - }, - { - "id": 73, - "name": "Galloway Rich", - "city": "Zeba", - "state": "Idaho", - "country": "Uzbekistan", - "company": "Dragbot", - "favoriteNumber": 4 - }, - { - "id": 74, - "name": "Morris Lott", - "city": "Wattsville", - "state": "Michigan", - "country": "Turkmenistan", - "company": "Slumberia", - "favoriteNumber": 3 - }, - { - "id": 75, - "name": "Paul Mcleod", - "city": "Glenbrook", - "state": "Colorado", - "country": "Cuba", - "company": "Candecor", - "favoriteNumber": 6 - }, - { - "id": 76, - "name": "Phoebe Orr", - "city": "Holcombe", - "state": "Texas", - "country": "Faroe Islands", - "company": "Cubicide", - "favoriteNumber": 4 - }, - { - "id": 77, - "name": "Dalton Christensen", - "city": "Rossmore", - "state": "Nebraska", - "country": "Belgium", - "company": "Enormo", - "favoriteNumber": 4 - }, - { - "id": 78, - "name": "Flora Goff", - "city": "Gila", - "state": "West Virginia", - "country": "Philippines", - "company": "Miracula", - "favoriteNumber": 4 - }, - { - "id": 79, - "name": "Sheree Ross", - "city": "Welch", - "state": "Oregon", - "country": "French Polynesia", - "company": "Illumity", - "favoriteNumber": 0 - }, - { - "id": 80, - "name": "Nita Jefferson", - "city": "Calverton", - "state": "Oklahoma", - "country": "Estonia", - "company": "Cincyr", - "favoriteNumber": 2 - }, - { - "id": 81, - "name": "Elma Mendoza", - "city": "Cornfields", - "state": "Ohio", - "country": "Botswana", - "company": "Isotronic", - "favoriteNumber": 6 - }, - { - "id": 82, - "name": "Garcia Hensley", - "city": "Kohatk", - "state": "Virginia", - "country": "Congo", - "company": "Plasmox", - "favoriteNumber": 4 - }, - { - "id": 83, - "name": "Delgado Osborn", - "city": "Nescatunga", - "state": "Mississippi", - "country": "Montenegro", - "company": "Magneato", - "favoriteNumber": 1 - }, - { - "id": 84, - "name": "Chavez Simmons", - "city": "Roderfield", - "state": "South Dakota", - "country": "Norway", - "company": "Waab", - "favoriteNumber": 1 - }, - { - "id": 85, - "name": "Stuart Roach", - "city": "Hebron", - "state": "Iowa", - "country": "Georgia", - "company": "Applica", - "favoriteNumber": 0 - }, - { - "id": 86, - "name": "Georgia Henson", - "city": "Greenbackville", - "state": "Washington", - "country": "Guinea Bissau", - "company": "Talkalot", - "favoriteNumber": 7 - }, - { - "id": 87, - "name": "Ila Sanders", - "city": "Zortman", - "state": "Florida", - "country": "Brazil", - "company": "Koffee", - "favoriteNumber": 10 - }, - { - "id": 88, - "name": "Shepard Maldonado", - "city": "Lawrence", - "state": "California", - "country": "Netherlands", - "company": "Knowlysis", - "favoriteNumber": 1 - }, - { - "id": 89, - "name": "Ramirez Collins", - "city": "Healy", - "state": "New York", - "country": "Guernsey", - "company": "Entroflex", - "favoriteNumber": 4 - }, - { - "id": 90, - "name": "Magdalena Mcgee", - "city": "Goldfield", - "state": "Minnesota", - "country": "Qatar", - "company": "Xelegyl", - "favoriteNumber": 0 - }, - { - "id": 91, - "name": "Crystal Kinney", - "city": "Nogal", - "state": "Georgia", - "country": "Kuwait", - "company": "Zork", - "favoriteNumber": 3 - }, - { - "id": 92, - "name": "Witt Colon", - "city": "Yorklyn", - "state": "Connecticut", - "country": "Singapore", - "company": "Techmania", - "favoriteNumber": 8 - }, - { - "id": 93, - "name": "Joyce Randolph", - "city": "Leland", - "state": "South Carolina", - "country": "Dominica", - "company": "Realmo", - "favoriteNumber": 2 - }, - { - "id": 94, - "name": "Ora Oneil", - "city": "Gilgo", - "state": "Missouri", - "country": "Bahamas", - "company": "Hinway", - "favoriteNumber": 7 - }, - { - "id": 95, - "name": "Hansen Rose", - "city": "Starks", - "state": "Maine", - "country": "Iran", - "company": "Virxo", - "favoriteNumber": 6 - }, - { - "id": 96, - "name": "Isabelle Rush", - "city": "Datil", - "state": "Wisconsin", - "country": "Switzerland", - "company": "Ecraze", - "favoriteNumber": 4 - }, - { - "id": 97, - "name": "Hoffman Crosby", - "city": "Trucksville", - "state": "Alabama", - "country": "Indonesia", - "company": "Multron", - "favoriteNumber": 10 - }, - { - "id": 98, - "name": "Louella Cotton", - "city": "Shelby", - "state": "Hawaii", - "country": "Tajikistan", - "company": "Supportal", - "favoriteNumber": 0 - }, - { - "id": 99, - "name": "Elvia Drake", - "city": "Albrightsville", - "state": "New Jersey", - "country": "Grenada", - "company": "Kiosk", - "favoriteNumber": 10 - }, - { - "id": 100, - "name": "Tyson Guerra", - "city": "Sutton", - "state": "Arizona", - "country": "Benin", - "company": "Dadabase", - "favoriteNumber": 4 - }, - { - "id": 101, - "name": "Marion Sloan", - "city": "Winchester", - "state": "Illinois", - "country": "Venezuela", - "company": "Exostream", - "favoriteNumber": 0 - }, - { - "id": 102, - "name": "Faulkner Diaz", - "city": "Logan", - "state": "Wyoming", - "country": "Monaco", - "company": "Oceanica", - "favoriteNumber": 10 - }, - { - "id": 103, - "name": "Penelope Price", - "city": "Alafaya", - "state": "Delaware", - "country": "Chile", - "company": "Nebulean", - "favoriteNumber": 10 - }, - { - "id": 104, - "name": "Kaitlin Glover", - "city": "Succasunna", - "state": "Kentucky", - "country": "Puerto Rico", - "company": "Orbean", - "favoriteNumber": 4 - }, - { - "id": 105, - "name": "Elena English", - "city": "Wedgewood", - "state": "New Mexico", - "country": "Algeria", - "company": "Kiggle", - "favoriteNumber": 0 - }, - { - "id": 106, - "name": "Clemons Sweeney", - "city": "Saranap", - "state": "Montana", - "country": "Ghana", - "company": "Konnect", - "favoriteNumber": 8 - }, - { - "id": 107, - "name": "Kelsey Blevins", - "city": "Vincent", - "state": "Rhode Island", - "country": "Albania", - "company": "Xymonk", - "favoriteNumber": 7 - }, - { - "id": 108, - "name": "Schroeder Craft", - "city": "Roosevelt", - "state": "North Carolina", - "country": "Satellite", - "company": "Isotrack", - "favoriteNumber": 8 - }, - { - "id": 109, - "name": "Hill Clark", - "city": "Elrama", - "state": "Maryland", - "country": "Slovakia", - "company": "Waterbaby", - "favoriteNumber": 0 - }, - { - "id": 110, - "name": "Glover Meyers", - "city": "Riviera", - "state": "Indiana", - "country": "Liberia", - "company": "Digigene", - "favoriteNumber": 0 - }, - { - "id": 111, - "name": "Lola Parrish", - "city": "Ellerslie", - "state": "Vermont", - "country": "Azerbaijan", - "company": "Myopium", - "favoriteNumber": 1 - }, - { - "id": 112, - "name": "Nora Rivers", - "city": "Belvoir", - "state": "Kansas", - "country": "Afghanistan", - "company": "Comtrek", - "favoriteNumber": 10 - }, - { - "id": 113, - "name": "Cohen Pacheco", - "city": "Bethpage", - "state": "Alaska", - "country": "Netherlands Antilles", - "company": "Accufarm", - "favoriteNumber": 7 - }, - { - "id": 114, - "name": "Diann Horn", - "city": "Derwood", - "state": "North Dakota", - "country": "Seychelles", - "company": "Synkgen", - "favoriteNumber": 3 - }, - { - "id": 115, - "name": "Amalia Nicholson", - "city": "Hendersonville", - "state": "Arkansas", - "country": "Lesotho", - "company": "Geekus", - "favoriteNumber": 2 - }, - { - "id": 116, - "name": "Mcgee Kane", - "city": "Dante", - "state": "New Hampshire", - "country": "Nigeria", - "company": "Kinetica", - "favoriteNumber": 9 - }, - { - "id": 117, - "name": "Shaffer Simpson", - "city": "Verdi", - "state": "Massachusetts", - "country": "Costa Rica", - "company": "Orbixtar", - "favoriteNumber": 0 - }, - { - "id": 118, - "name": "Lott Heath", - "city": "Castleton", - "state": "Utah", - "country": "Burkina Faso", - "company": "Reversus", - "favoriteNumber": 8 - }, - { - "id": 119, - "name": "Sasha Alvarez", - "city": "Foxworth", - "state": "Tennessee", - "country": "Montserrat", - "company": "Farmex", - "favoriteNumber": 9 - }, - { - "id": 120, - "name": "Sonja Rhodes", - "city": "Trona", - "state": "Pennsylvania", - "country": "Liechtenstein", - "company": "Pyramis", - "favoriteNumber": 2 - }, - { - "id": 121, - "name": "Rachel Elliott", - "city": "Hessville", - "state": "Louisiana", - "country": "Vietnam", - "company": "Centice", - "favoriteNumber": 0 - }, - { - "id": 122, - "name": "Elisa Justice", - "city": "Urie", - "state": "Idaho", - "country": "Senegal", - "company": "Dancerity", - "favoriteNumber": 2 - }, - { - "id": 123, - "name": "Velazquez Anderson", - "city": "Lowell", - "state": "Michigan", - "country": "Burundi", - "company": "Digial", - "favoriteNumber": 5 - }, - { - "id": 124, - "name": "Janet Ford", - "city": "Darlington", - "state": "Colorado", - "country": "Turkey", - "company": "Sportan", - "favoriteNumber": 10 - }, - { - "id": 125, - "name": "Simon Peterson", - "city": "Linwood", - "state": "Texas", - "country": "Kazakhstan", - "company": "Zytrac", - "favoriteNumber": 7 - }, - { - "id": 126, - "name": "Smith Baird", - "city": "Marne", - "state": "Nebraska", - "country": "Swaziland", - "company": "Genmy", - "favoriteNumber": 7 - }, - { - "id": 127, - "name": "Rogers Peters", - "city": "Tedrow", - "state": "West Virginia", - "country": "Spain", - "company": "Octocore", - "favoriteNumber": 1 - }, - { - "id": 128, - "name": "Bowers Ayers", - "city": "Matthews", - "state": "Oregon", - "country": "St Lucia", - "company": "Biotica", - "favoriteNumber": 6 - }, - { - "id": 129, - "name": "Paulette Delaney", - "city": "Riegelwood", - "state": "Oklahoma", - "country": "Guinea", - "company": "Netbook", - "favoriteNumber": 3 - }, - { - "id": 130, - "name": "Pat Klein", - "city": "Jacksonburg", - "state": "Ohio", - "country": "El Salvador", - "company": "Recrisys", - "favoriteNumber": 5 - }, - { - "id": 131, - "name": "Dena Rosa", - "city": "Hollymead", - "state": "Virginia", - "country": "Russia", - "company": "Sealoud", - "favoriteNumber": 6 - }, - { - "id": 132, - "name": "Rochelle Barnett", - "city": "Genoa", - "state": "Mississippi", - "country": "Kenya", - "company": "Ersum", - "favoriteNumber": 6 - }, - { - "id": 133, - "name": "Odom Schultz", - "city": "Blende", - "state": "South Dakota", - "country": "Papua New Guinea", - "company": "Elentrix", - "favoriteNumber": 0 - }, - { - "id": 134, - "name": "Anderson Franco", - "city": "Yardville", - "state": "Iowa", - "country": "Sweden", - "company": "Wazzu", - "favoriteNumber": 4 - }, - { - "id": 135, - "name": "Rebecca Wyatt", - "city": "Berwind", - "state": "Washington", - "country": "St Vincent", - "company": "Bristo", - "favoriteNumber": 2 - }, - { - "id": 136, - "name": "Dollie Hooper", - "city": "Richmond", - "state": "Florida", - "country": "Uruguay", - "company": "Vantage", - "favoriteNumber": 1 - }, - { - "id": 137, - "name": "Mathews Sharpe", - "city": "Glenshaw", - "state": "California", - "country": "Trinidad & Tobago", - "company": "Quilk", - "favoriteNumber": 4 - }, - { - "id": 138, - "name": "Debra Skinner", - "city": "Leming", - "state": "New York", - "country": "Saint Pierre & Miquelon", - "company": "Billmed", - "favoriteNumber": 1 - }, - { - "id": 139, - "name": "Cross Wells", - "city": "Caroline", - "state": "Minnesota", - "country": "Mauritania", - "company": "Strozen", - "favoriteNumber": 3 - }, - { - "id": 140, - "name": "Dodson Aguirre", - "city": "Nash", - "state": "Georgia", - "country": "Palestine", - "company": "Tripsch", - "favoriteNumber": 5 - }, - { - "id": 141, - "name": "Edna Copeland", - "city": "Harrison", - "state": "Connecticut", - "country": "Macedonia", - "company": "Flum", - "favoriteNumber": 10 - }, - { - "id": 142, - "name": "Dominguez Goodwin", - "city": "Condon", - "state": "South Carolina", - "country": "Laos", - "company": "Interloo", - "favoriteNumber": 0 - }, - { - "id": 143, - "name": "Fry Leach", - "city": "Advance", - "state": "Missouri", - "country": "Angola", - "company": "Recritube", - "favoriteNumber": 7 - }, - { - "id": 144, - "name": "Mann Malone", - "city": "Lumberton", - "state": "Maine", - "country": "India", - "company": "Xylar", - "favoriteNumber": 9 - }, - { - "id": 145, - "name": "Bridget Ayala", - "city": "Bellamy", - "state": "Wisconsin", - "country": "Cote D Ivoire", - "company": "Comvex", - "favoriteNumber": 7 - }, - { - "id": 146, - "name": "Blackwell Blanchard", - "city": "Ticonderoga", - "state": "Alabama", - "country": "Barbados", - "company": "Applideck", - "favoriteNumber": 7 - }, - { - "id": 147, - "name": "Maxine Irwin", - "city": "Longoria", - "state": "Hawaii", - "country": "Armenia", - "company": "Pearlesex", - "favoriteNumber": 10 - }, - { - "id": 148, - "name": "Laura Bryant", - "city": "Chicopee", - "state": "New Jersey", - "country": "Bosnia & Herzegovina", - "company": "Poshome", - "favoriteNumber": 0 - }, - { - "id": 149, - "name": "Zimmerman Little", - "city": "Rosewood", - "state": "Arizona", - "country": "Guatemala", - "company": "Boink", - "favoriteNumber": 4 - }, - { - "id": 150, - "name": "Barlow Reed", - "city": "Buxton", - "state": "Illinois", - "country": "Tanzania", - "company": "Premiant", - "favoriteNumber": 5 - }, - { - "id": 151, - "name": "Anita Briggs", - "city": "Laurelton", - "state": "Wyoming", - "country": "United Arab Emirates", - "company": "Codact", - "favoriteNumber": 3 - }, - { - "id": 152, - "name": "Ortiz Newton", - "city": "Blandburg", - "state": "Delaware", - "country": "Moldova", - "company": "Enersave", - "favoriteNumber": 7 - }, - { - "id": 153, - "name": "Cox Monroe", - "city": "Dupuyer", - "state": "Kentucky", - "country": "Taiwan", - "company": "Uneeq", - "favoriteNumber": 3 - }, - { - "id": 154, - "name": "Elinor Hughes", - "city": "Yukon", - "state": "New Mexico", - "country": "Bulgaria", - "company": "Bovis", - "favoriteNumber": 5 - }, - { - "id": 155, - "name": "Ronda Burks", - "city": "Ferney", - "state": "Montana", - "country": "Isle of Man", - "company": "Signity", - "favoriteNumber": 6 - }, - { - "id": 156, - "name": "Lourdes Walls", - "city": "Norwood", - "state": "Rhode Island", - "country": "Argentina", - "company": "Snacktion", - "favoriteNumber": 5 - }, - { - "id": 157, - "name": "Susana Mcintosh", - "city": "Manchester", - "state": "North Carolina", - "country": "Israel", - "company": "Teraprene", - "favoriteNumber": 5 - }, - { - "id": 158, - "name": "Alfreda Henry", - "city": "Wilsonia", - "state": "Maryland", - "country": "Bhutan", - "company": "Coash", - "favoriteNumber": 3 - }, - { - "id": 159, - "name": "Tiffany Chaney", - "city": "Carrsville", - "state": "Indiana", - "country": "Morocco", - "company": "Cinaster", - "favoriteNumber": 7 - }, - { - "id": 160, - "name": "Morton Edwards", - "city": "Barstow", - "state": "Vermont", - "country": "Hong Kong", - "company": "Ultrasure", - "favoriteNumber": 10 - }, - { - "id": 161, - "name": "Marcy Serrano", - "city": "Idamay", - "state": "Kansas", - "country": "Finland", - "company": "Isbol", - "favoriteNumber": 3 - }, - { - "id": 162, - "name": "Wendi Gutierrez", - "city": "Camas", - "state": "Alaska", - "country": "Andorra", - "company": "Turnling", - "favoriteNumber": 6 - }, - { - "id": 163, - "name": "Miriam Gates", - "city": "Helen", - "state": "North Dakota", - "country": "Djibouti", - "company": "Undertap", - "favoriteNumber": 8 - }, - { - "id": 164, - "name": "Adrienne Horne", - "city": "Snyderville", - "state": "Arkansas", - "country": "Gambia", - "company": "Olympix", - "favoriteNumber": 2 - }, - { - "id": 165, - "name": "Steele Morales", - "city": "Kenvil", - "state": "New Hampshire", - "country": "Macau", - "company": "Animalia", - "favoriteNumber": 3 - }, - { - "id": 166, - "name": "Ericka Morgan", - "city": "Leroy", - "state": "Massachusetts", - "country": "Kyrgyz Republic", - "company": "Opticall", - "favoriteNumber": 5 - }, - { - "id": 167, - "name": "Deborah Davenport", - "city": "Albany", - "state": "Utah", - "country": "Thailand", - "company": "Vetron", - "favoriteNumber": 10 - }, - { - "id": 168, - "name": "Tameka Mcneil", - "city": "Frierson", - "state": "Tennessee", - "country": "St. Lucia", - "company": "Martgo", - "favoriteNumber": 1 - }, - { - "id": 169, - "name": "Jewell Shields", - "city": "Bannock", - "state": "Pennsylvania", - "country": "Maldives", - "company": "Lotron", - "favoriteNumber": 8 - }, - { - "id": 170, - "name": "Crawford Fox", - "city": "Nicholson", - "state": "Louisiana", - "country": "Rwanda", - "company": "Progenex", - "favoriteNumber": 8 - }, - { - "id": 171, - "name": "Vaughan Tanner", - "city": "Cuylerville", - "state": "Idaho", - "country": "Jamaica", - "company": "Zeam", - "favoriteNumber": 3 - }, - { - "id": 172, - "name": "Shauna Wagner", - "city": "Disautel", - "state": "Michigan", - "country": "China", - "company": "Isologia", - "favoriteNumber": 6 - }, - { - "id": 173, - "name": "Meagan Hines", - "city": "Whitmer", - "state": "Colorado", - "country": "Jordan", - "company": "Grainspot", - "favoriteNumber": 8 - }, - { - "id": 174, - "name": "Palmer Bender", - "city": "Beechmont", - "state": "Texas", - "country": "Japan", - "company": "Vurbo", - "favoriteNumber": 10 - }, - { - "id": 175, - "name": "Amanda Buck", - "city": "Elfrida", - "state": "Nebraska", - "country": "Latvia", - "company": "Frosnex", - "favoriteNumber": 5 - }, - { - "id": 176, - "name": "Kristin Cleveland", - "city": "Richville", - "state": "West Virginia", - "country": "Lithuania", - "company": "Honotron", - "favoriteNumber": 2 - }, - { - "id": 177, - "name": "Harrell Vaughan", - "city": "Munjor", - "state": "Oregon", - "country": "Anguilla", - "company": "Orbalix", - "favoriteNumber": 9 - }, - { - "id": 178, - "name": "Stanley Webb", - "city": "Harleigh", - "state": "Oklahoma", - "country": "Mali", - "company": "Motovate", - "favoriteNumber": 6 - }, - { - "id": 179, - "name": "Briana Mitchell", - "city": "Kansas", - "state": "Ohio", - "country": "Libya", - "company": "Zillatide", - "favoriteNumber": 10 - }, - { - "id": 180, - "name": "Lillian Osborne", - "city": "Eastmont", - "state": "Virginia", - "country": "Belize", - "company": "Circum", - "favoriteNumber": 6 - }, - { - "id": 181, - "name": "Hughes Morse", - "city": "Herlong", - "state": "Mississippi", - "country": "French West Indies", - "company": "Endipine", - "favoriteNumber": 0 - }, - { - "id": 182, - "name": "Elise Whitehead", - "city": "Hailesboro", - "state": "South Dakota", - "country": "Saudi Arabia", - "company": "Geekmosis", - "favoriteNumber": 10 - }, - { - "id": 183, - "name": "Alyce Chavez", - "city": "Bendon", - "state": "Iowa", - "country": "Portugal", - "company": "Dognost", - "favoriteNumber": 8 - }, - { - "id": 184, - "name": "Goff Walker", - "city": "Sultana", - "state": "Washington", - "country": "Germany", - "company": "Uncorp", - "favoriteNumber": 4 - }, - { - "id": 185, - "name": "Brennan Melton", - "city": "Baker", - "state": "Florida", - "country": "Austria", - "company": "Thredz", - "favoriteNumber": 0 - }, - { - "id": 186, - "name": "Toni Brennan", - "city": "Newry", - "state": "California", - "country": "Serbia", - "company": "Bitendrex", - "favoriteNumber": 0 - }, - { - "id": 187, - "name": "Mcmillan Lane", - "city": "Thornport", - "state": "New York", - "country": "Panama", - "company": "Kengen", - "favoriteNumber": 2 - }, - { - "id": 188, - "name": "Yang Trujillo", - "city": "Falmouth", - "state": "Minnesota", - "country": "Paraguay", - "company": "Vitricomp", - "favoriteNumber": 7 - }, - { - "id": 189, - "name": "Osborn Love", - "city": "Rehrersburg", - "state": "Georgia", - "country": "Peru", - "company": "Newcube", - "favoriteNumber": 7 - }, - { - "id": 190, - "name": "Randolph Giles", - "city": "Sandston", - "state": "Connecticut", - "country": "Niger", - "company": "Manglo", - "favoriteNumber": 6 - }, - { - "id": 191, - "name": "Alison Eaton", - "city": "Wauhillau", - "state": "South Carolina", - "country": "St Kitts & Nevis", - "company": "Buzzmaker", - "favoriteNumber": 7 - }, - { - "id": 192, - "name": "Frankie Pollard", - "city": "Salix", - "state": "Missouri", - "country": "Uganda", - "company": "Jasper", - "favoriteNumber": 3 - }, - { - "id": 193, - "name": "Shields Cole", - "city": "Olney", - "state": "Maine", - "country": "British Virgin Islands", - "company": "Anivet", - "favoriteNumber": 3 - }, - { - "id": 194, - "name": "Frieda Wilkins", - "city": "Darrtown", - "state": "Wisconsin", - "country": "Gibraltar", - "company": "Elemantra", - "favoriteNumber": 6 - }, - { - "id": 195, - "name": "Parker Meyer", - "city": "Deseret", - "state": "Alabama", - "country": "Bermuda", - "company": "Cablam", - "favoriteNumber": 6 - }, - { - "id": 196, - "name": "Sharpe Blankenship", - "city": "Sparkill", - "state": "Hawaii", - "country": "Jersey", - "company": "Affluex", - "favoriteNumber": 0 - }, - { - "id": 197, - "name": "Fletcher Pope", - "city": "Libertytown", - "state": "New Jersey", - "country": "Bahrain", - "company": "Veraq", - "favoriteNumber": 6 - }, - { - "id": 198, - "name": "Brittany Holland", - "city": "Stonybrook", - "state": "Arizona", - "country": "Cook Islands", - "company": "Menbrain", - "favoriteNumber": 6 - }, - { - "id": 199, - "name": "Tammi Good", - "city": "Gwynn", - "state": "Illinois", - "country": "Denmark", - "company": "Kangle", - "favoriteNumber": 5 - }, - { - "id": 200, - "name": "Durham Valentine", - "city": "Dodge", - "state": "Wyoming", - "country": "Bolivia", - "company": "Amtas", - "favoriteNumber": 9 - }, - { - "id": 201, - "name": "Gina Savage", - "city": "Camptown", - "state": "Delaware", - "country": "San Marino", - "company": "Golistic", - "favoriteNumber": 8 - }, - { - "id": 202, - "name": "Faith Crane", - "city": "Kingstowne", - "state": "Kentucky", - "country": "Guyana", - "company": "Providco", - "favoriteNumber": 1 - }, - { - "id": 203, - "name": "Mullins Hewitt", - "city": "Courtland", - "state": "New Mexico", - "country": "Colombia", - "company": "Paprikut", - "favoriteNumber": 0 - }, - { - "id": 204, - "name": "Kemp Barber", - "city": "Morriston", - "state": "Montana", - "country": "United Kingdom", - "company": "Geekfarm", - "favoriteNumber": 3 - }, - { - "id": 205, - "name": "Sheppard Shaw", - "city": "Vandiver", - "state": "Rhode Island", - "country": "Madagascar", - "company": "Fossiel", - "favoriteNumber": 9 - }, - { - "id": 206, - "name": "Keith Bradshaw", - "city": "Mulberry", - "state": "North Carolina", - "country": "Ukraine", - "company": "Comtent", - "favoriteNumber": 9 - }, - { - "id": 207, - "name": "Dianne Conley", - "city": "Tonopah", - "state": "Maryland", - "country": "New Zealand", - "company": "Joviold", - "favoriteNumber": 5 - }, - { - "id": 208, - "name": "Love Griffin", - "city": "Day", - "state": "Indiana", - "country": "Ecuador", - "company": "Vortexaco", - "favoriteNumber": 6 - }, - { - "id": 209, - "name": "Melody Delacruz", - "city": "Hanover", - "state": "Vermont", - "country": "Virgin Islands (US)", - "company": "Pyramia", - "favoriteNumber": 6 - }, - { - "id": 210, - "name": "Patsy Kramer", - "city": "Southmont", - "state": "Kansas", - "country": "Sri Lanka", - "company": "Bedder", - "favoriteNumber": 8 - }, - { - "id": 211, - "name": "Becky Richard", - "city": "Crenshaw", - "state": "Alaska", - "country": "Croatia", - "company": "Polarium", - "favoriteNumber": 1 - }, - { - "id": 212, - "name": "Leon Rivera", - "city": "Gibbsville", - "state": "North Dakota", - "country": "Turks & Caicos", - "company": "Micronaut", - "favoriteNumber": 3 - }, - { - "id": 213, - "name": "Simpson Randall", - "city": "Cetronia", - "state": "Arkansas", - "country": "Cambodia", - "company": "Intergeek", - "favoriteNumber": 2 - }, - { - "id": 214, - "name": "Daugherty Duke", - "city": "Levant", - "state": "New Hampshire", - "country": "Namibia", - "company": "Nutralab", - "favoriteNumber": 3 - }, - { - "id": 215, - "name": "Payne Morton", - "city": "Jamestown", - "state": "Massachusetts", - "country": "Cape Verde", - "company": "Insource", - "favoriteNumber": 7 - }, - { - "id": 216, - "name": "Perkins Leblanc", - "city": "Boyd", - "state": "Utah", - "country": "Brunei", - "company": "Dognosis", - "favoriteNumber": 1 - }, - { - "id": 217, - "name": "Phillips Douglas", - "city": "Wikieup", - "state": "Tennessee", - "country": "Lebanon", - "company": "Ziore", - "favoriteNumber": 9 - }, - { - "id": 218, - "name": "Graves Stark", - "city": "Barrelville", - "state": "Pennsylvania", - "country": "Timor L'Este", - "company": "Exovent", - "favoriteNumber": 8 - }, - { - "id": 219, - "name": "Munoz Johns", - "city": "Wyano", - "state": "Louisiana", - "country": "Samoa", - "company": "Escenta", - "favoriteNumber": 10 - }, - { - "id": 220, - "name": "Myra Salazar", - "city": "Gorst", - "state": "Idaho", - "country": "Greece", - "company": "Acrodance", - "favoriteNumber": 10 - }, - { - "id": 221, - "name": "Flynn Miranda", - "city": "Movico", - "state": "Michigan", - "country": "Greenland", - "company": "Artiq", - "favoriteNumber": 6 - }, - { - "id": 222, - "name": "Eloise Barr", - "city": "Greer", - "state": "Colorado", - "country": "Sierra Leone", - "company": "Insuresys", - "favoriteNumber": 5 - }, - { - "id": 223, - "name": "Harrington Daniels", - "city": "Dawn", - "state": "Texas", - "country": "Tonga", - "company": "Pharmex", - "favoriteNumber": 3 - }, - { - "id": 224, - "name": "Lester Carey", - "city": "Keller", - "state": "Nebraska", - "country": "Nepal", - "company": "Melbacor", - "favoriteNumber": 4 - }, - { - "id": 225, - "name": "Malinda Pittman", - "city": "Wyoming", - "state": "West Virginia", - "country": "Falkland Islands", - "company": "Rodeocean", - "favoriteNumber": 1 - }, - { - "id": 226, - "name": "Crane Smith", - "city": "Hoagland", - "state": "Oregon", - "country": "Syria", - "company": "Eclipsent", - "favoriteNumber": 8 - }, - { - "id": 227, - "name": "Ellison Underwood", - "city": "Neahkahnie", - "state": "Oklahoma", - "country": "Suriname", - "company": "Visualix", - "favoriteNumber": 4 - }, - { - "id": 228, - "name": "Shelby Hardy", - "city": "Bascom", - "state": "Ohio", - "country": "Malta", - "company": "Genekom", - "favoriteNumber": 8 - }, - { - "id": 229, - "name": "Sheena Maynard", - "city": "Morningside", - "state": "Virginia", - "country": "Dominican Republic", - "company": "Zillar", - "favoriteNumber": 10 - }, - { - "id": 230, - "name": "Tamera Roman", - "city": "Freelandville", - "state": "Mississippi", - "country": "Honduras", - "company": "Comtract", - "favoriteNumber": 6 - }, - { - "id": 231, - "name": "Juliette Hammond", - "city": "Lindcove", - "state": "South Dakota", - "country": "Yemen", - "company": "Coriander", - "favoriteNumber": 5 - }, - { - "id": 232, - "name": "Dean Holden", - "city": "Brantleyville", - "state": "Iowa", - "country": "Aruba", - "company": "Plexia", - "favoriteNumber": 5 - }, - { - "id": 233, - "name": "Whitfield Meadows", - "city": "Fedora", - "state": "Washington", - "country": "Egypt", - "company": "Isosure", - "favoriteNumber": 1 - }, - { - "id": 234, - "name": "Wiley Kelley", - "city": "Torboy", - "state": "Florida", - "country": "Malawi", - "company": "Zilladyne", - "favoriteNumber": 5 - }, - { - "id": 235, - "name": "Sherry Scott", - "city": "Garfield", - "state": "California", - "country": "Slovenia", - "company": "Otherway", - "favoriteNumber": 5 - }, - { - "id": 236, - "name": "Aline Sosa", - "city": "Martinez", - "state": "New York", - "country": "Australia", - "company": "Comstruct", - "favoriteNumber": 4 - }, - { - "id": 237, - "name": "Leta Rice", - "city": "Utting", - "state": "Minnesota", - "country": "Iraq", - "company": "Jumpstack", - "favoriteNumber": 8 - }, - { - "id": 238, - "name": "Ford Ingram", - "city": "Lafferty", - "state": "Georgia", - "country": "Hungary", - "company": "Sarasonic", - "favoriteNumber": 3 - }, - { - "id": 239, - "name": "Chan David", - "city": "Collins", - "state": "Connecticut", - "country": "Mongolia", - "company": "Velos", - "favoriteNumber": 6 - }, - { - "id": 240, - "name": "Jeanne Murray", - "city": "Carlos", - "state": "South Carolina", - "country": "Ethiopia", - "company": "Equitox", - "favoriteNumber": 6 - }, - { - "id": 241, - "name": "Fernandez Dean", - "city": "Wintersburg", - "state": "Missouri", - "country": "Bangladesh", - "company": "Orboid", - "favoriteNumber": 5 - }, - { - "id": 242, - "name": "Jordan Cox", - "city": "Orin", - "state": "Maine", - "country": "Sudan", - "company": "Roboid", - "favoriteNumber": 6 - }, - { - "id": 243, - "name": "Catherine Harper", - "city": "Bedias", - "state": "Wisconsin", - "country": "Zambia", - "company": "Photobin", - "favoriteNumber": 2 - }, - { - "id": 244, - "name": "Suarez Kelly", - "city": "Cressey", - "state": "Alabama", - "country": "Cameroon", - "company": "Xurban", - "favoriteNumber": 7 - }, - { - "id": 245, - "name": "Henderson Mcdonald", - "city": "Adamstown", - "state": "Hawaii", - "country": "Mexico", - "company": "Skinserve", - "favoriteNumber": 1 - }, - { - "id": 246, - "name": "Hardy Gibbs", - "city": "Chical", - "state": "New Jersey", - "country": "Zimbabwe", - "company": "Limage", - "favoriteNumber": 6 - }, - { - "id": 247, - "name": "Kimberley Yang", - "city": "Kenmar", - "state": "Arizona", - "country": "Tunisia", - "company": "Exotechno", - "favoriteNumber": 9 - }, - { - "id": 248, - "name": "Kristie Gilmore", - "city": "Fairview", - "state": "Illinois", - "country": "Italy", - "company": "Equicom", - "favoriteNumber": 4 - }, - { - "id": 249, - "name": "Jewel Hansen", - "city": "Worton", - "state": "Wyoming", - "country": "South Korea", - "company": "Sulfax", - "favoriteNumber": 6 - }, - { - "id": 250, - "name": "Cheryl Carter", - "city": "Caron", - "state": "Delaware", - "country": "Mauritius", - "company": "Netropic", - "favoriteNumber": 9 - }, - { - "id": 251, - "name": "Keisha Snider", - "city": "Waterloo", - "state": "Kentucky", - "country": "Romania", - "company": "Besto", - "favoriteNumber": 6 - }, - { - "id": 252, - "name": "Minnie Michael", - "city": "Cascades", - "state": "New Mexico", - "country": "South Africa", - "company": "Kidgrease", - "favoriteNumber": 10 - }, - { - "id": 253, - "name": "Sandy Mccullough", - "city": "Remington", - "state": "Montana", - "country": "Malaysia", - "company": "Zosis", - "favoriteNumber": 3 - }, - { - "id": 254, - "name": "Cervantes Maddox", - "city": "Sisquoc", - "state": "Rhode Island", - "country": "Oman", - "company": "Extremo", - "favoriteNumber": 6 - }, - { - "id": 255, - "name": "Sophia Logan", - "city": "Winfred", - "state": "North Carolina", - "country": "Ireland", - "company": "Enaut", - "favoriteNumber": 4 - }, - { - "id": 256, - "name": "Bertha Watson", - "city": "Caroleen", - "state": "Maryland", - "country": "France", - "company": "Musix", - "favoriteNumber": 9 - }, - { - "id": 257, - "name": "Emily Wilson", - "city": "Fairacres", - "state": "Indiana", - "country": "Iceland", - "company": "Comvene", - "favoriteNumber": 8 - }, - { - "id": 258, - "name": "Winters Petersen", - "city": "Wildwood", - "state": "Vermont", - "country": "Equatorial Guinea", - "company": "Webiotic", - "favoriteNumber": 0 - }, - { - "id": 259, - "name": "Chambers Finch", - "city": "Topaz", - "state": "Kansas", - "country": "Luxembourg", - "company": "Sultraxin", - "favoriteNumber": 5 - }, - { - "id": 260, - "name": "Byrd Mills", - "city": "Cloverdale", - "state": "Alaska", - "country": "Cruise Ship", - "company": "Accel", - "favoriteNumber": 2 - }, - { - "id": 261, - "name": "Gross Jacobs", - "city": "Duryea", - "state": "North Dakota", - "country": "Belarus", - "company": "Insuron", - "favoriteNumber": 5 - }, - { - "id": 262, - "name": "Jackson Sherman", - "city": "Waterview", - "state": "Arkansas", - "country": "Antigua & Barbuda", - "company": "Viagreat", - "favoriteNumber": 2 - }, - { - "id": 263, - "name": "Rhodes Boyer", - "city": "Enlow", - "state": "New Hampshire", - "country": "Chad", - "company": "Conferia", - "favoriteNumber": 4 - }, - { - "id": 264, - "name": "Campbell Rodgers", - "city": "Cumminsville", - "state": "Massachusetts", - "country": "Reunion", - "company": "Frolix", - "favoriteNumber": 10 - }, - { - "id": 265, - "name": "Bryant Sawyer", - "city": "Guilford", - "state": "Utah", - "country": "Gabon", - "company": "Rooforia", - "favoriteNumber": 10 - }, - { - "id": 266, - "name": "Joan Browning", - "city": "Elizaville", - "state": "Tennessee", - "country": "Fiji", - "company": "Kneedles", - "favoriteNumber": 6 - }, - { - "id": 267, - "name": "Jennie Mcintyre", - "city": "Draper", - "state": "Pennsylvania", - "country": "New Caledonia", - "company": "Isostream", - "favoriteNumber": 4 - }, - { - "id": 268, - "name": "Merle Jones", - "city": "Caspar", - "state": "Louisiana", - "country": "Haiti", - "company": "Tubesys", - "favoriteNumber": 4 - }, - { - "id": 269, - "name": "Ortega Burgess", - "city": "Thermal", - "state": "Idaho", - "country": "Mozambique", - "company": "Lovepad", - "favoriteNumber": 9 - }, - { - "id": 270, - "name": "Deanna Grimes", - "city": "Flintville", - "state": "Michigan", - "country": "Pakistan", - "company": "Omatom", - "favoriteNumber": 10 - }, - { - "id": 271, - "name": "Jeanie Ochoa", - "city": "Ruckersville", - "state": "Colorado", - "country": "Cayman Islands", - "company": "Momentia", - "favoriteNumber": 8 - }, - { - "id": 272, - "name": "Morrow Valencia", - "city": "Roberts", - "state": "Texas", - "country": "Guam", - "company": "Permadyne", - "favoriteNumber": 4 - }, - { - "id": 273, - "name": "Hull Wade", - "city": "Monument", - "state": "Nebraska", - "country": "Cyprus", - "company": "Indexia", - "favoriteNumber": 10 - }, - { - "id": 274, - "name": "Blanca Sheppard", - "city": "Wadsworth", - "state": "West Virginia", - "country": "Nicaragua", - "company": "Gogol", - "favoriteNumber": 7 - }, - { - "id": 275, - "name": "Stella Luna", - "city": "Dubois", - "state": "Oregon", - "country": "Czech Republic", - "company": "Intrawear", - "favoriteNumber": 1 - } -]; diff --git a/samples/react/ReactGrid/ReactGrid.csproj b/samples/react/ReactGrid/ReactGrid.csproj deleted file mode 100644 index cefd991..0000000 --- a/samples/react/ReactGrid/ReactGrid.csproj +++ /dev/null @@ -1,25 +0,0 @@ - - - - - - netcoreapp2.0 - true - false - - - - - - - - - - - - - - - - - diff --git a/samples/react/ReactGrid/Startup.cs b/samples/react/ReactGrid/Startup.cs deleted file mode 100755 index 147659b..0000000 --- a/samples/react/ReactGrid/Startup.cs +++ /dev/null @@ -1,65 +0,0 @@ -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Builder; -using Microsoft.AspNetCore.Hosting; -using Microsoft.AspNetCore.Http; -using Microsoft.AspNetCore.SpaServices.Webpack; -using Microsoft.Extensions.DependencyInjection; -using Microsoft.Extensions.Logging; -using Newtonsoft.Json.Serialization; - -namespace ReactGrid -{ - public class Startup - { - // This method gets called by the runtime. Use this method to add services to the container. - public void ConfigureServices(IServiceCollection services) - { - services.AddMvc().AddJsonOptions(options => - { - options.SerializerSettings.ContractResolver = new CamelCasePropertyNamesContractResolver(); - }); - } - - // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. - public void Configure(IApplicationBuilder app, ILoggerFactory loggerFactory, IHostingEnvironment env) - { - app.UseDeveloperExceptionPage(); - - if (env.IsDevelopment()) { - app.UseWebpackDevMiddleware(new WebpackDevMiddlewareOptions { - HotModuleReplacement = true, - ReactHotModuleReplacement = true - }); - } - - app.UseStaticFiles(); - loggerFactory.AddConsole(); - app.UseMvc(routes => - { - routes.MapRoute( - name: "default", - template: "{controller=Home}/{action=Index}/{id?}"); - - routes.MapSpaFallbackRoute( - name: "spa-fallback", - defaults: new { controller = "Home", action = "Index" }); - }); - } - - public static void Main(string[] args) - { - var host = new WebHostBuilder() - .UseContentRoot(Directory.GetCurrentDirectory()) - .UseIISIntegration() - .UseKestrel() - .UseStartup() - .Build(); - - host.Run(); - } - } -} diff --git a/samples/react/ReactGrid/Views/Home/Index.cshtml b/samples/react/ReactGrid/Views/Home/Index.cshtml deleted file mode 100755 index 59b13d5..0000000 --- a/samples/react/ReactGrid/Views/Home/Index.cshtml +++ /dev/null @@ -1,6 +0,0 @@ -
    - -@section scripts { - -} diff --git a/samples/react/ReactGrid/Views/Shared/Error.cshtml b/samples/react/ReactGrid/Views/Shared/Error.cshtml deleted file mode 100755 index 473b35d..0000000 --- a/samples/react/ReactGrid/Views/Shared/Error.cshtml +++ /dev/null @@ -1,6 +0,0 @@ -@{ - ViewData["Title"] = "Error"; -} - -

    Error.

    -

    An error occurred while processing your request.

    diff --git a/samples/react/ReactGrid/Views/Shared/_Layout.cshtml b/samples/react/ReactGrid/Views/Shared/_Layout.cshtml deleted file mode 100755 index 7ea6273..0000000 --- a/samples/react/ReactGrid/Views/Shared/_Layout.cshtml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - ReactExample - - - -
    - @RenderBody() -
    - @RenderSection("scripts", required: false) - - diff --git a/samples/react/ReactGrid/Views/_ViewImports.cshtml b/samples/react/ReactGrid/Views/_ViewImports.cshtml deleted file mode 100755 index 3043884..0000000 --- a/samples/react/ReactGrid/Views/_ViewImports.cshtml +++ /dev/null @@ -1,3 +0,0 @@ -@using ReactExample -@addTagHelper "*, Microsoft.AspNetCore.Mvc.TagHelpers" -@addTagHelper "*, Microsoft.AspNetCore.SpaServices" diff --git a/samples/react/ReactGrid/Views/_ViewStart.cshtml b/samples/react/ReactGrid/Views/_ViewStart.cshtml deleted file mode 100755 index 820a2f6..0000000 --- a/samples/react/ReactGrid/Views/_ViewStart.cshtml +++ /dev/null @@ -1,3 +0,0 @@ -@{ - Layout = "_Layout"; -} diff --git a/samples/react/ReactGrid/appsettings.json b/samples/react/ReactGrid/appsettings.json deleted file mode 100755 index 0967ef4..0000000 --- a/samples/react/ReactGrid/appsettings.json +++ /dev/null @@ -1 +0,0 @@ -{} diff --git a/samples/react/ReactGrid/jsconfig.json b/samples/react/ReactGrid/jsconfig.json deleted file mode 100644 index 875bb90..0000000 --- a/samples/react/ReactGrid/jsconfig.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "compilerOptions": { - "target": "ES6", - "module": "commonjs" - } -} diff --git a/samples/react/ReactGrid/package.json b/samples/react/ReactGrid/package.json deleted file mode 100644 index 9329a55..0000000 --- a/samples/react/ReactGrid/package.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "name": "ReactExample", - "version": "0.0.0", - "dependencies": { - "babel-core": "^6.13.2", - "bootstrap": "^3.3.7", - "domain-task": "^2.0.1", - "formsy-react": "^0.18.1", - "formsy-react-components": "^0.8.1", - "griddle-react": "^0.6.1", - "history": "^3.0.0", - "memory-fs": "^0.3.0", - "react": "^15.3.0", - "react-dom": "^15.3.0", - "react-router": "^2.6.1", - "require-from-string": "^1.2.0", - "underscore": "^1.8.3", - "webpack-externals-plugin": "^1.0.0" - }, - "devDependencies": { - "aspnet-prerendering": "^1.0.4", - "aspnet-webpack": "^1.0.9", - "aspnet-webpack-react": "^1.0.1", - "babel-loader": "^6.2.4", - "babel-plugin-react-transform": "^2.0.2", - "babel-preset-es2015": "^6.13.2", - "babel-preset-react": "^6.11.1", - "css-loader": "^0.23.1", - "express": "^4.14.0", - "extract-text-webpack-plugin": "^1.0.1", - "file-loader": "^0.9.0", - "react-transform-hmr": "^1.0.4", - "style-loader": "^0.13.1", - "url-loader": "^0.5.7", - "webpack": "^1.13.1", - "webpack-dev-middleware": "^1.6.1", - "webpack-hot-middleware": "^2.12.2" - } -} diff --git a/samples/react/ReactGrid/webpack.config.js b/samples/react/ReactGrid/webpack.config.js deleted file mode 100644 index b1151f1..0000000 --- a/samples/react/ReactGrid/webpack.config.js +++ /dev/null @@ -1,28 +0,0 @@ -var path = require('path'); -var webpack = require('webpack'); -var ExtractTextPlugin = require('extract-text-webpack-plugin'); - -module.exports = { - devtool: 'eval-source-map', - resolve: { - extensions: [ '', '.js', '.jsx' ] - }, - module: { - loaders: [ - { test: /\.jsx?$/, loader: 'babel-loader', exclude: /node_modules/ }, - { test: /\.css$/, loader: ExtractTextPlugin.extract('style-loader', 'css-loader') }, - { test: /\.(png|woff|woff2|eot|ttf|svg)$/, loader: 'url-loader?limit=100000' } - ] - }, - entry: { - main: ['./ReactApp/boot-client.jsx'] - }, - output: { - path: path.join(__dirname, '/wwwroot/dist'), - filename: '[name].js', - publicPath: '/dist/' // Tells webpack-dev-middleware where to serve the dynamically compiled content from - }, - plugins: [ - new ExtractTextPlugin('main.css') - ] -}; diff --git a/samples/react/ReactGrid/wwwroot/favicon.ico b/samples/react/ReactGrid/wwwroot/favicon.ico deleted file mode 100755 index a3a7999..0000000 Binary files a/samples/react/ReactGrid/wwwroot/favicon.ico and /dev/null differ diff --git a/samples/react/ReactGrid/wwwroot/web.config b/samples/react/ReactGrid/wwwroot/web.config deleted file mode 100644 index e70a777..0000000 --- a/samples/react/ReactGrid/wwwroot/web.config +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - - - - diff --git a/src/Microsoft.AspNetCore.AngularServices/.gitignore b/src/Microsoft.AspNetCore.AngularServices/.gitignore deleted file mode 100644 index ae3c172..0000000 --- a/src/Microsoft.AspNetCore.AngularServices/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/bin/ diff --git a/src/Microsoft.AspNetCore.AngularServices/Microsoft.AspNetCore.AngularServices.csproj b/src/Microsoft.AspNetCore.AngularServices/Microsoft.AspNetCore.AngularServices.csproj deleted file mode 100644 index 9b7863f..0000000 --- a/src/Microsoft.AspNetCore.AngularServices/Microsoft.AspNetCore.AngularServices.csproj +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - Helpers for building Angular applications on ASP.NET Core. - netcoreapp2.0 - aspnetcore;aspnetcoremvc;nodeservices - true - - - - - - - - - - - diff --git a/src/Microsoft.AspNetCore.AngularServices/PrimeCacheHelper.cs b/src/Microsoft.AspNetCore.AngularServices/PrimeCacheHelper.cs deleted file mode 100644 index a755d70..0000000 --- a/src/Microsoft.AspNetCore.AngularServices/PrimeCacheHelper.cs +++ /dev/null @@ -1,81 +0,0 @@ -using System; -using System.Net; -using System.Net.Http; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Mvc.Rendering; -using Microsoft.AspNetCore.Html; -using Microsoft.Extensions.Logging; -using Newtonsoft.Json; - -namespace Microsoft.AspNetCore.AngularServices -{ - /// - /// Helpers for prepopulating Angular's 'http' service with data. - /// - public static class PrimeCacheHelper - { - /// - /// Performs an HTTP GET request to the specified URL and adds the resulting JSON data - /// to the Angular 'http' service cache. - /// - /// The . - /// The URL to be requested. - /// A task representing the HTML content to be rendered into the document. - [Obsolete("Use PrimeCacheAsync instead")] - public static Task PrimeCache(this IHtmlHelper html, string url) - { - return PrimeCacheAsync(html, url); - } - - /// - /// Performs an HTTP GET request to the specified URL and adds the resulting JSON data - /// to the Angular 'http' service cache. - /// - /// The . - /// The URL to be requested. - /// A task representing the HTML content to be rendered into the document. - public static async Task PrimeCacheAsync(this IHtmlHelper html, string url) - { - // TODO: Consider deduplicating the PrimeCacheAsync calls (that is, if there are multiple requests to precache - // the same URL, only return nonempty for one of them). This will make it easier to auto-prime-cache any - // HTTP requests made during server-side rendering, without risking unnecessary duplicate requests. - - if (string.IsNullOrEmpty(url)) - { - throw new ArgumentException("Value cannot be null or empty", nameof(url)); - } - - try - { - var request = html.ViewContext.HttpContext.Request; - var baseUriString = string.Concat( - request.Scheme, - "://", - request.Host.ToUriComponent(), - request.PathBase.ToUriComponent(), - request.Path.ToUriComponent(), - request.QueryString.ToUriComponent()); - var fullUri = new Uri(new Uri(baseUriString), url); - var response = await new HttpClient().GetAsync(fullUri.ToString()); - var responseBody = await response.Content.ReadAsStringAsync(); - return new HtmlString(FormatAsScript(url, response.StatusCode, responseBody)); - } - catch (Exception ex) - { - var logger = (ILogger)html.ViewContext.HttpContext.RequestServices.GetService(typeof(ILogger)); - logger?.LogWarning("Error priming cache for URL: " + url, ex); - return new HtmlString(string.Empty); - } - } - - private static string FormatAsScript(string url, HttpStatusCode responseStatusCode, string responseBody) - { - var preCachedUrl = JsonConvert.SerializeObject(url); - var preCachedJson = JsonConvert.SerializeObject(new { statusCode = responseStatusCode, body = responseBody }); - return ""; - } - } -} \ No newline at end of file diff --git a/src/Microsoft.AspNetCore.ReactServices/.gitignore b/src/Microsoft.AspNetCore.ReactServices/.gitignore deleted file mode 100644 index ae3c172..0000000 --- a/src/Microsoft.AspNetCore.ReactServices/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/bin/ diff --git a/src/Microsoft.AspNetCore.ReactServices/Microsoft.AspNetCore.ReactServices.csproj b/src/Microsoft.AspNetCore.ReactServices/Microsoft.AspNetCore.ReactServices.csproj deleted file mode 100644 index 97f288a..0000000 --- a/src/Microsoft.AspNetCore.ReactServices/Microsoft.AspNetCore.ReactServices.csproj +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - Helpers for building React applications on ASP.NET Core. - netcoreapp2.0 - aspnetcore;aspnetcoremvc;nodeservices - true - - - - - - - - - - - diff --git a/templates/WebApplicationBasic/ClientApp/App.ts b/templates/WebApplicationBasic/ClientApp/App.ts deleted file mode 100644 index 4cde26c..0000000 --- a/templates/WebApplicationBasic/ClientApp/App.ts +++ /dev/null @@ -1,5 +0,0 @@ -import 'bootstrap'; -import './css/site.css'; - -// Replace with your TypeScript code -console.log('Hello, world!'); diff --git a/templates/WebApplicationBasic/ClientApp/css/site.css b/templates/WebApplicationBasic/ClientApp/css/site.css deleted file mode 100755 index af0456d..0000000 --- a/templates/WebApplicationBasic/ClientApp/css/site.css +++ /dev/null @@ -1,24 +0,0 @@ -body { - padding-top: 50px; - padding-bottom: 20px; -} - -/* Wrapping element */ -/* Set some basic padding to keep content from hitting the edges */ -.body-content { - padding-left: 15px; - padding-right: 15px; -} - -/* Set widths on the form inputs since otherwise they're 100% wide */ -input, -select, -textarea { - max-width: 280px; -} - -/* Carousel */ -.carousel-caption p { - font-size: 20px; - line-height: 1.4; -} diff --git a/templates/WebApplicationBasic/Controllers/HomeController.cs b/templates/WebApplicationBasic/Controllers/HomeController.cs deleted file mode 100755 index 03b3a06..0000000 --- a/templates/WebApplicationBasic/Controllers/HomeController.cs +++ /dev/null @@ -1,35 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Mvc; - -namespace WebApplicationBasic.Controllers -{ - public class HomeController : Controller - { - public IActionResult Index() - { - return View(); - } - - public IActionResult About() - { - ViewData["Message"] = "Your application description page."; - - return View(); - } - - public IActionResult Contact() - { - ViewData["Message"] = "Your contact page."; - - return View(); - } - - public IActionResult Error() - { - return View(); - } - } -} diff --git a/templates/WebApplicationBasic/Program.cs b/templates/WebApplicationBasic/Program.cs deleted file mode 100644 index b2e5e4b..0000000 --- a/templates/WebApplicationBasic/Program.cs +++ /dev/null @@ -1,31 +0,0 @@ -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Hosting; -using Microsoft.Extensions.Configuration; - -namespace WebApplicationBasic -{ - public class Program - { - public static void Main(string[] args) - { - var config = new ConfigurationBuilder() - .AddCommandLine(args) - .AddEnvironmentVariables(prefix: "ASPNETCORE_") - .Build(); - - var host = new WebHostBuilder() - .UseConfiguration(config) - .UseKestrel() - .UseContentRoot(Directory.GetCurrentDirectory()) - .UseIISIntegration() - .UseStartup() - .Build(); - - host.Run(); - } - } -} diff --git a/templates/WebApplicationBasic/Startup.cs b/templates/WebApplicationBasic/Startup.cs deleted file mode 100755 index fe5473d..0000000 --- a/templates/WebApplicationBasic/Startup.cs +++ /dev/null @@ -1,59 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using Microsoft.AspNetCore.Builder; -using Microsoft.AspNetCore.Hosting; -using Microsoft.Extensions.Configuration; -using Microsoft.Extensions.DependencyInjection; -using Microsoft.Extensions.Logging; - -namespace WebApplicationBasic -{ - public class Startup - { - public Startup(IHostingEnvironment env) - { - var builder = new ConfigurationBuilder() - .SetBasePath(env.ContentRootPath) - .AddJsonFile("appsettings.json", optional: true, reloadOnChange: true) - .AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true) - .AddEnvironmentVariables(); - Configuration = builder.Build(); - } - - public IConfigurationRoot Configuration { get; } - - // This method gets called by the runtime. Use this method to add services to the container. - public void ConfigureServices(IServiceCollection services) - { - // Add framework services. - services.AddMvc(); - } - - // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. - public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory) - { - loggerFactory.AddConsole(Configuration.GetSection("Logging")); - loggerFactory.AddDebug(); - - if (env.IsDevelopment()) - { - app.UseDeveloperExceptionPage(); - } - else - { - app.UseExceptionHandler("/Home/Error"); - } - - app.UseStaticFiles(); - - app.UseMvc(routes => - { - routes.MapRoute( - name: "default", - template: "{controller=Home}/{action=Index}/{id?}"); - }); - } - } -} diff --git a/templates/WebApplicationBasic/Views/Home/About.cshtml b/templates/WebApplicationBasic/Views/Home/About.cshtml deleted file mode 100755 index b653a26..0000000 --- a/templates/WebApplicationBasic/Views/Home/About.cshtml +++ /dev/null @@ -1,7 +0,0 @@ -@{ - ViewData["Title"] = "About"; -} -

    @ViewData["Title"].

    -

    @ViewData["Message"]

    - -

    Use this area to provide additional information.

    diff --git a/templates/WebApplicationBasic/Views/Home/Contact.cshtml b/templates/WebApplicationBasic/Views/Home/Contact.cshtml deleted file mode 100755 index f953aa6..0000000 --- a/templates/WebApplicationBasic/Views/Home/Contact.cshtml +++ /dev/null @@ -1,17 +0,0 @@ -@{ - ViewData["Title"] = "Contact"; -} -

    @ViewData["Title"].

    -

    @ViewData["Message"]

    - -
    - One Microsoft Way
    - Redmond, WA 98052-6399
    - P: - 425.555.0100 -
    - -
    - Support: Support@example.com
    - Marketing: Marketing@example.com -
    diff --git a/templates/WebApplicationBasic/Views/Home/Index.cshtml b/templates/WebApplicationBasic/Views/Home/Index.cshtml deleted file mode 100755 index 6fef9ae..0000000 --- a/templates/WebApplicationBasic/Views/Home/Index.cshtml +++ /dev/null @@ -1,114 +0,0 @@ -@{ - ViewData["Title"] = "Home Page"; -} - - - - - -@section scripts { - -} diff --git a/templates/WebApplicationBasic/Views/Shared/Error.cshtml b/templates/WebApplicationBasic/Views/Shared/Error.cshtml deleted file mode 100755 index 473b35d..0000000 --- a/templates/WebApplicationBasic/Views/Shared/Error.cshtml +++ /dev/null @@ -1,6 +0,0 @@ -@{ - ViewData["Title"] = "Error"; -} - -

    Error.

    -

    An error occurred while processing your request.

    diff --git a/templates/WebApplicationBasic/Views/Shared/_Layout.cshtml b/templates/WebApplicationBasic/Views/Shared/_Layout.cshtml deleted file mode 100755 index 787de23..0000000 --- a/templates/WebApplicationBasic/Views/Shared/_Layout.cshtml +++ /dev/null @@ -1,43 +0,0 @@ - - - - - - @ViewData["Title"] - WebApplicationBasic - - - - - - -
    - @RenderBody() -
    -
    -

    © 2016 - WebApplicationBasic

    -
    -
    - - - @RenderSection("scripts", required: false) - - diff --git a/templates/WebApplicationBasic/Views/_ViewImports.cshtml b/templates/WebApplicationBasic/Views/_ViewImports.cshtml deleted file mode 100755 index 6b9e366..0000000 --- a/templates/WebApplicationBasic/Views/_ViewImports.cshtml +++ /dev/null @@ -1,2 +0,0 @@ -@using WebApplicationBasic -@addTagHelper "*, Microsoft.AspNetCore.Mvc.TagHelpers" diff --git a/templates/WebApplicationBasic/Views/_ViewStart.cshtml b/templates/WebApplicationBasic/Views/_ViewStart.cshtml deleted file mode 100755 index 820a2f6..0000000 --- a/templates/WebApplicationBasic/Views/_ViewStart.cshtml +++ /dev/null @@ -1,3 +0,0 @@ -@{ - Layout = "_Layout"; -} diff --git a/templates/WebApplicationBasic/WebApplicationBasic.csproj b/templates/WebApplicationBasic/WebApplicationBasic.csproj deleted file mode 100644 index 12a3277..0000000 --- a/templates/WebApplicationBasic/WebApplicationBasic.csproj +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - netcoreapp2.0 - true - false - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/templates/WebApplicationBasic/appsettings.json b/templates/WebApplicationBasic/appsettings.json deleted file mode 100755 index 723c096..0000000 --- a/templates/WebApplicationBasic/appsettings.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "Logging": { - "IncludeScopes": false, - "LogLevel": { - "Default": "Debug", - "System": "Information", - "Microsoft": "Information" - } - } -} diff --git a/templates/WebApplicationBasic/global.json b/templates/WebApplicationBasic/global.json deleted file mode 100644 index 5a3dc98..0000000 --- a/templates/WebApplicationBasic/global.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "sdk": { "version": "1.0.0-preview2-1-003177" } -} diff --git a/templates/WebApplicationBasic/package.json b/templates/WebApplicationBasic/package.json deleted file mode 100644 index 8cc9458..0000000 --- a/templates/WebApplicationBasic/package.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "name": "WebApplicationBasic", - "version": "0.0.0", - "devDependencies": { - "bootstrap": "^3.3.7", - "css-loader": "^0.23.1", - "event-source-polyfill": "^0.0.7", - "extendify": "^1.0.0", - "extract-text-webpack-plugin": "^1.0.1", - "file-loader": "^0.8.5", - "jquery": "^2.2.1", - "style-loader": "^0.13.0", - "ts-loader": "^0.8.1", - "typescript": "^2.0.3", - "url-loader": "^0.5.7", - "webpack": "^1.13.2" - } -} diff --git a/templates/WebApplicationBasic/template_gitignore b/templates/WebApplicationBasic/template_gitignore deleted file mode 100644 index 3e035ee..0000000 --- a/templates/WebApplicationBasic/template_gitignore +++ /dev/null @@ -1,236 +0,0 @@ -/Properties/launchSettings.json - -## Ignore Visual Studio temporary files, build results, and -## files generated by popular Visual Studio add-ons. - -# User-specific files -*.suo -*.user -*.userosscache -*.sln.docstates - -# User-specific files (MonoDevelop/Xamarin Studio) -*.userprefs - -# Build results -[Dd]ebug/ -[Dd]ebugPublic/ -[Rr]elease/ -[Rr]eleases/ -x64/ -x86/ -build/ -bld/ -bin/ -Bin/ -obj/ -Obj/ - -# Visual Studio 2015 cache/options directory -.vs/ -/wwwroot/dist/ - -/yarn.lock - -# MSTest test Results -[Tt]est[Rr]esult*/ -[Bb]uild[Ll]og.* - -# NUNIT -*.VisualState.xml -TestResult.xml - -# Build Results of an ATL Project -[Dd]ebugPS/ -[Rr]eleasePS/ -dlldata.c - -*_i.c -*_p.c -*_i.h -*.ilk -*.meta -*.obj -*.pch -*.pdb -*.pgc -*.pgd -*.rsp -*.sbr -*.tlb -*.tli -*.tlh -*.tmp -*.tmp_proj -*.log -*.vspscc -*.vssscc -.builds -*.pidb -*.svclog -*.scc - -# Chutzpah Test files -_Chutzpah* - -# Visual C++ cache files -ipch/ -*.aps -*.ncb -*.opendb -*.opensdf -*.sdf -*.cachefile - -# Visual Studio profiler -*.psess -*.vsp -*.vspx -*.sap - -# TFS 2012 Local Workspace -$tf/ - -# Guidance Automation Toolkit -*.gpState - -# ReSharper is a .NET coding add-in -_ReSharper*/ -*.[Rr]e[Ss]harper -*.DotSettings.user - -# JustCode is a .NET coding add-in -.JustCode - -# TeamCity is a build add-in -_TeamCity* - -# DotCover is a Code Coverage Tool -*.dotCover - -# NCrunch -_NCrunch_* -.*crunch*.local.xml -nCrunchTemp_* - -# MightyMoose -*.mm.* -AutoTest.Net/ - -# Web workbench (sass) -.sass-cache/ - -# Installshield output folder -[Ee]xpress/ - -# DocProject is a documentation generator add-in -DocProject/buildhelp/ -DocProject/Help/*.HxT -DocProject/Help/*.HxC -DocProject/Help/*.hhc -DocProject/Help/*.hhk -DocProject/Help/*.hhp -DocProject/Help/Html2 -DocProject/Help/html - -# Click-Once directory -publish/ - -# Publish Web Output -*.[Pp]ublish.xml -*.azurePubxml -# TODO: Comment the next line if you want to checkin your web deploy settings -# but database connection strings (with potential passwords) will be unencrypted -*.pubxml -*.publishproj - -# NuGet Packages -*.nupkg -# The packages folder can be ignored because of Package Restore -**/packages/* -# except build/, which is used as an MSBuild target. -!**/packages/build/ -# Uncomment if necessary however generally it will be regenerated when needed -#!**/packages/repositories.config - -# Microsoft Azure Build Output -csx/ -*.build.csdef - -# Microsoft Azure Emulator -ecf/ -rcf/ - -# Microsoft Azure ApplicationInsights config file -ApplicationInsights.config - -# Windows Store app package directory -AppPackages/ -BundleArtifacts/ - -# Visual Studio cache files -# files ending in .cache can be ignored -*.[Cc]ache -# but keep track of directories ending in .cache -!*.[Cc]ache/ - -# Others -ClientBin/ -~$* -*~ -*.dbmdl -*.dbproj.schemaview -*.pfx -*.publishsettings -orleans.codegen.cs - -/node_modules - -# RIA/Silverlight projects -Generated_Code/ - -# Backup & report files from converting an old project file -# to a newer Visual Studio version. Backup files are not needed, -# because we have git ;-) -_UpgradeReport_Files/ -Backup*/ -UpgradeLog*.XML -UpgradeLog*.htm - -# SQL Server files -*.mdf -*.ldf - -# Business Intelligence projects -*.rdl.data -*.bim.layout -*.bim_*.settings - -# Microsoft Fakes -FakesAssemblies/ - -# GhostDoc plugin setting file -*.GhostDoc.xml - -# Node.js Tools for Visual Studio -.ntvs_analysis.dat - -# Visual Studio 6 build log -*.plg - -# Visual Studio 6 workspace options file -*.opt - -# Visual Studio LightSwitch build output -**/*.HTMLClient/GeneratedArtifacts -**/*.DesktopClient/GeneratedArtifacts -**/*.DesktopClient/ModelManifest.xml -**/*.Server/GeneratedArtifacts -**/*.Server/ModelManifest.xml -_Pvt_Extensions - -# Paket dependency manager -.paket/paket.exe - -# FAKE - F# Make -.fake/ diff --git a/templates/WebApplicationBasic/tsconfig.json b/templates/WebApplicationBasic/tsconfig.json deleted file mode 100644 index 046eabe..0000000 --- a/templates/WebApplicationBasic/tsconfig.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "compilerOptions": { - "moduleResolution": "node", - "target": "es5", - "sourceMap": true, - "lib": ["es6", "dom"], - "skipDefaultLibCheck": true - }, - "exclude": [ - "bin", - "node_modules" - ] -} diff --git a/templates/WebApplicationBasic/web.config b/templates/WebApplicationBasic/web.config deleted file mode 100644 index a8d6672..0000000 --- a/templates/WebApplicationBasic/web.config +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - diff --git a/templates/WebApplicationBasic/webpack.config.dev.js b/templates/WebApplicationBasic/webpack.config.dev.js deleted file mode 100644 index e3410f6..0000000 --- a/templates/WebApplicationBasic/webpack.config.dev.js +++ /dev/null @@ -1,12 +0,0 @@ -var path = require('path'); -var webpack = require('webpack'); - -module.exports = { - plugins: [ - // Plugins that apply in development builds only - new webpack.SourceMapDevToolPlugin({ - filename: '[file].map', // Remove this line if you prefer inline source maps - moduleFilenameTemplate: path.relative('./wwwroot/dist', '[resourcePath]') // Point sourcemap entries to the original file locations on disk - }) - ] -}; diff --git a/templates/WebApplicationBasic/webpack.config.js b/templates/WebApplicationBasic/webpack.config.js deleted file mode 100644 index 80ff461..0000000 --- a/templates/WebApplicationBasic/webpack.config.js +++ /dev/null @@ -1,35 +0,0 @@ -var path = require('path'); -var webpack = require('webpack'); -var ExtractTextPlugin = require('extract-text-webpack-plugin'); -var merge = require('extendify')({ isDeep: true, arrays: 'concat' }); -var devConfig = require('./webpack.config.dev'); -var prodConfig = require('./webpack.config.prod'); -var isDevelopment = process.env.ASPNETCORE_ENVIRONMENT === 'Development'; -var extractCSS = new ExtractTextPlugin('site.css'); - -module.exports = merge({ - resolve: { - extensions: [ '', '.js', '.jsx', '.ts', '.tsx' ] - }, - module: { - loaders: [ - { test: /\.ts(x?)$/, include: /ClientApp/, loader: 'ts-loader?silent=true' }, - { test: /\.css/, loader: extractCSS.extract([ isDevelopment ? 'css-loader' : 'css-loader?minimize' ]) } - ] - }, - entry: { - main: ['./ClientApp/App.ts'] - }, - output: { - path: path.join(__dirname, 'wwwroot', 'dist'), - filename: '[name].js', - publicPath: '/dist/' - }, - plugins: [ - extractCSS, - new webpack.DllReferencePlugin({ - context: __dirname, - manifest: require('./wwwroot/dist/vendor-manifest.json') - }) - ] -}, isDevelopment ? devConfig : prodConfig); diff --git a/templates/WebApplicationBasic/webpack.config.prod.js b/templates/WebApplicationBasic/webpack.config.prod.js deleted file mode 100644 index 775f115..0000000 --- a/templates/WebApplicationBasic/webpack.config.prod.js +++ /dev/null @@ -1,8 +0,0 @@ -var webpack = require('webpack'); - -module.exports = { - plugins: [ - new webpack.optimize.OccurenceOrderPlugin(), - new webpack.optimize.UglifyJsPlugin({ minimize: true }) - ] -}; diff --git a/templates/WebApplicationBasic/webpack.config.vendor.js b/templates/WebApplicationBasic/webpack.config.vendor.js deleted file mode 100644 index 2efe99e..0000000 --- a/templates/WebApplicationBasic/webpack.config.vendor.js +++ /dev/null @@ -1,36 +0,0 @@ -var path = require('path'); -var webpack = require('webpack'); -var ExtractTextPlugin = require('extract-text-webpack-plugin'); -var extractCSS = new ExtractTextPlugin('vendor.css'); -var isDevelopment = process.env.ASPNETCORE_ENVIRONMENT === 'Development'; - -module.exports = { - resolve: { - extensions: [ '', '.js' ] - }, - module: { - loaders: [ - { test: /\.(png|woff|woff2|eot|ttf|svg)$/, loader: 'url-loader?limit=100000' }, - { test: /\.css/, loader: extractCSS.extract([ isDevelopment ? 'css-loader' : 'css-loader?minimize' ]) } - ] - }, - entry: { - vendor: ['bootstrap', 'bootstrap/dist/css/bootstrap.css', 'event-source-polyfill', 'style-loader', 'jquery'] - }, - output: { - path: path.join(__dirname, 'wwwroot', 'dist'), - filename: '[name].js', - library: '[name]_[hash]', - }, - plugins: [ - extractCSS, - new webpack.ProvidePlugin({ $: 'jquery', jQuery: 'jquery' }), // Maps these identifiers to the jQuery package (because Bootstrap expects it to be a global variable) - new webpack.optimize.OccurenceOrderPlugin(), - new webpack.DllPlugin({ - path: path.join(__dirname, 'wwwroot', 'dist', '[name]-manifest.json'), - name: '[name]_[hash]' - }) - ].concat(isDevelopment ? [] : [ - new webpack.optimize.UglifyJsPlugin({ compress: { warnings: false } }) - ]) -}; diff --git a/templates/WebApplicationBasic/wwwroot/favicon.ico b/templates/WebApplicationBasic/wwwroot/favicon.ico deleted file mode 100755 index a3a7999..0000000 Binary files a/templates/WebApplicationBasic/wwwroot/favicon.ico and /dev/null differ diff --git a/templates/WebApplicationBasic/wwwroot/images/ASP-NET-Banners-01.png b/templates/WebApplicationBasic/wwwroot/images/ASP-NET-Banners-01.png deleted file mode 100755 index ad3c267..0000000 Binary files a/templates/WebApplicationBasic/wwwroot/images/ASP-NET-Banners-01.png and /dev/null differ diff --git a/templates/WebApplicationBasic/wwwroot/images/ASP-NET-Banners-02.png b/templates/WebApplicationBasic/wwwroot/images/ASP-NET-Banners-02.png deleted file mode 100755 index 16c37fc..0000000 Binary files a/templates/WebApplicationBasic/wwwroot/images/ASP-NET-Banners-02.png and /dev/null differ diff --git a/templates/WebApplicationBasic/wwwroot/images/Banner-01-Azure.png b/templates/WebApplicationBasic/wwwroot/images/Banner-01-Azure.png deleted file mode 100755 index 59fb923..0000000 Binary files a/templates/WebApplicationBasic/wwwroot/images/Banner-01-Azure.png and /dev/null differ diff --git a/templates/WebApplicationBasic/wwwroot/images/Banner-02-VS.png b/templates/WebApplicationBasic/wwwroot/images/Banner-02-VS.png deleted file mode 100755 index c9f4611..0000000 Binary files a/templates/WebApplicationBasic/wwwroot/images/Banner-02-VS.png and /dev/null differ
    -
    - -
    -

    {{ albumData.Artist.Name }}

    -
    -
    -
    - -
    -

    {{ albumData.Genre.Name }}

    -
    -
    -
    - -
    -

    {{ albumData.Title }}

    -
    -
    -
    - -
    -

    {{ albumData.Price | currency:'USD':true }}

    -
    -
    -
    - -
    -

    {{ albumData.AlbumArtUrl }}

    -
    -
    -
    - -
    - {{ albumData.Title }} -
    -
    -
    -
    - Edit - - Back to List -
    -
    -