Permissions & Authorization for Users #24

Initial Release; Includes Database and MVC refactoring
This commit is contained in:
Gary Sharp
2013-10-10 19:13:16 +11:00
parent 172ce5524a
commit a099d68915
458 changed files with 40221 additions and 12130 deletions
+3 -3
View File
@@ -32,7 +32,7 @@ namespace Disco.BI
if (deviceModel == null)
{
// Create the Device Model in a different DataContext so we don't have to commit unrelated changes
using (DiscoDataContext dbContext = new DiscoDataContext())
using (DiscoDataContext database = new DiscoDataContext())
{
var addDeviceModel = new DeviceModel
{
@@ -41,8 +41,8 @@ namespace Disco.BI
ModelType = ModelType,
Description = string.Format("{0} {1}", Manufacturer, Model)
};
dbContext.DeviceModels.Add(addDeviceModel);
dbContext.SaveChanges();
database.DeviceModels.Add(addDeviceModel);
database.SaveChanges();
}
// Obtain the Device Model with the in-scope DataContext