Update 'samples' projects for .NET Core 1.0 RTM

This commit is contained in:
SteveSandersonMS
2016-06-28 11:37:37 +01:00
parent eebf509846
commit a986f8d2cc
8 changed files with 72 additions and 65 deletions

View File

@@ -15,6 +15,7 @@ using Microsoft.Extensions.PlatformAbstractions;
using AutoMapper;
using MusicStore.Apis;
using MusicStore.Models;
using Newtonsoft.Json.Serialization;
namespace MusicStore
{
@@ -23,8 +24,11 @@ namespace MusicStore
// This method gets called by the runtime. Use this method to add services to the container.
public void ConfigureServices(IServiceCollection services)
{
services.AddMvc();
services.AddMvc().AddJsonOptions(options =>
{
options.SerializerSettings.ContractResolver = null;
});
// Add EF services to the service container
services.AddEntityFramework()
.AddEntityFrameworkSqlite()