Permalink
Browse files

Appharbor connection string being used for sure

  • Loading branch information...
1 parent 9e47e0d commit e126bf143d82a3280d32efb5b3e9f99b050471ab @ryanki1 committed Feb 21, 2013
@@ -34,6 +34,7 @@ public ViewResult Index()
{
//var orderedModel = context.SalesmanModels.ToList().OrderBy(salesman => salesman.LastName);
//return View(orderedModel);
+ //context.Database.Connection.ConnectionString = System.Configuration.ConfigurationManager.ConnectionStrings["DefaultConnection"].ToString();
return View(context.SalesmanModels.ToList().OrderBy(salesman => salesman.LastName));
}
@@ -17,8 +17,15 @@ public class AddConTravellingSalesmanContext : DbContext
//
// System.Data.Entity.Database.SetInitializer(new System.Data.Entity.DropCreateDatabaseIfModelChanges<AddCon_TravellingSalesman.Models.AddConTravellingSalesmanContext>());
+
+ public AddConTravellingSalesmanContext()
+ : base("AddConTravellingSalesmanContextDatabase")
+ {
+
+ }
public DbSet<AddCon_TravellingSalesman.Models.SalesmanModel> SalesmanModels { get; set; }
public DbSet<AddCon_TravellingSalesman.Models.EventModel> EventModel { get; set; }
+
}
//public class fred : DropCreateDatabaseAlways<AddConTravellingSalesmanContext>
//{
Binary file not shown.
Binary file not shown.
@@ -45,4 +45,3 @@ C:\Users\ryanki1\Documents\Visual Studio 2012\Projects\AddCon_TravellingSalesman
C:\Users\ryanki1\Documents\Visual Studio 2012\Projects\AddCon_TravellingSalesman\AddCon_TravellingSalesman\obj\Debug\AddCon_TravellingSalesman.csproj.GenerateResource.Cache
C:\Users\ryanki1\Documents\Visual Studio 2012\Projects\AddCon_TravellingSalesman\AddCon_TravellingSalesman\obj\Debug\AddCon_TravellingSalesman.dll
C:\Users\ryanki1\Documents\Visual Studio 2012\Projects\AddCon_TravellingSalesman\AddCon_TravellingSalesman\obj\Debug\AddCon_TravellingSalesman.pdb
-C:\Users\ryanki1\documents\visual studio 2012\Projects\AddCon_TravellingSalesman\AddCon_TravellingSalesman\obj\Debug\AddCon_TravellingSalesman.csprojResolveAssemblyReference.cache
@@ -8,8 +8,10 @@
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
<section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=5.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
</configSections>
- <connectionStrings>
- <add name="DefaultConnection" providerName="System.Data.SqlClient" connectionString="Data Source=e2460aee-7fdd-4b46-ae72-a16b0131968c.sqlserver.sequelizer.com;Initial Catalog=dbe2460aee7fdd4b46ae72a16b0131968c;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|\dbe2460aee7fdd4b46ae72a16b0131968c.mdf" />
+ <connectionStrings>
+ <add name="AddConTravellingSalesmanContextDatabase" providerName="System.Data.SqlClient"
+ connectionString="Data Source=e2460aee-7fdd-4b46-ae72-a16b0131968c.sqlserver.sequelizer.com;Initial Catalog=dbe2460aee7fdd4b46ae72a16b0131968c;User ID=aojzwbadsaqyqmrd; Password=AM6FwvRwc8urSvjHubFGAepGRtUjEEbfhujEozQPZ723SRyvZeKK6gNvwxXdHGZE;" />
+ <!--<add name="DefaultConnection" providerName="System.Data.SqlClient" connectionString="Data Source=e2460aee-7fdd-4b46-ae72-a16b0131968c.sqlserver.sequelizer.com;Initial Catalog=dbe2460aee7fdd4b46ae72a16b0131968c;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|\dbe2460aee7fdd4b46ae72a16b0131968c.mdf" />-->
<!--<add name="DefaultConnection" providerName="System.Data.SqlClient" connectionString="Data Source=(LocalDb)\v11.0;Initial Catalog=aspnet-AddCon_TravellingSalesman-20120911095112;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|\aspnet-AddCon_TravellingSalesman-20120911095112.mdf" />-->
</connectionStrings>
<appSettings>

0 comments on commit e126bf1

Please sign in to comment.