mirror of
https://github.com/claunia/marechai.git
synced 2025-12-16 19:14:25 +00:00
Set all admin controllers as requiring authorization.
This commit is contained in:
@@ -38,6 +38,7 @@ using Microsoft.EntityFrameworkCore;
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class BrowserTestsController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
@@ -48,10 +49,7 @@ namespace cicm_web.Areas.Admin.Controllers
|
||||
}
|
||||
|
||||
// GET: Admin/BrowserTests
|
||||
public async Task<IActionResult> Index()
|
||||
{
|
||||
return View(await _context.BrowserTests.ToListAsync());
|
||||
}
|
||||
public async Task<IActionResult> Index() => View(await _context.BrowserTests.ToListAsync());
|
||||
|
||||
// GET: Admin/BrowserTests/Details/5
|
||||
public async Task<IActionResult> Details(int? id)
|
||||
@@ -65,10 +63,7 @@ namespace cicm_web.Areas.Admin.Controllers
|
||||
}
|
||||
|
||||
// GET: Admin/BrowserTests/Create
|
||||
public IActionResult Create()
|
||||
{
|
||||
return View();
|
||||
}
|
||||
public IActionResult Create() => View();
|
||||
|
||||
// POST: Admin/BrowserTests/Create
|
||||
// To protect from overposting attacks, please enable the specific properties you want to bind to, for
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Mvc.Rendering;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
@@ -39,6 +40,7 @@ using Microsoft.EntityFrameworkCore.Query;
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class CompanyDescriptionsController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Mvc.Rendering;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
@@ -39,6 +40,7 @@ using Microsoft.EntityFrameworkCore.Query;
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class GpusController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
|
||||
@@ -31,12 +31,14 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class InstructionSetExtensionsController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
@@ -47,10 +49,7 @@ namespace cicm_web.Areas.Admin.Controllers
|
||||
}
|
||||
|
||||
// GET: Admin/InstructionSetExtensions
|
||||
public async Task<IActionResult> Index()
|
||||
{
|
||||
return View(await _context.InstructionSetExtensions.ToListAsync());
|
||||
}
|
||||
public async Task<IActionResult> Index() => View(await _context.InstructionSetExtensions.ToListAsync());
|
||||
|
||||
// GET: Admin/InstructionSetExtensions/Details/5
|
||||
public async Task<IActionResult> Details(int? id)
|
||||
@@ -65,10 +64,7 @@ namespace cicm_web.Areas.Admin.Controllers
|
||||
}
|
||||
|
||||
// GET: Admin/InstructionSetExtensions/Create
|
||||
public IActionResult Create()
|
||||
{
|
||||
return View();
|
||||
}
|
||||
public IActionResult Create() => View();
|
||||
|
||||
// POST: Admin/InstructionSetExtensions/Create
|
||||
// To protect from overposting attacks, please enable the specific properties you want to bind to, for
|
||||
|
||||
@@ -31,12 +31,14 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class InstructionSetsController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
@@ -47,10 +49,7 @@ namespace cicm_web.Areas.Admin.Controllers
|
||||
}
|
||||
|
||||
// GET: Admin/InstructionSets
|
||||
public async Task<IActionResult> Index()
|
||||
{
|
||||
return View(await _context.InstructionSets.ToListAsync());
|
||||
}
|
||||
public async Task<IActionResult> Index() => View(await _context.InstructionSets.ToListAsync());
|
||||
|
||||
// GET: Admin/InstructionSets/Details/5
|
||||
public async Task<IActionResult> Details(int? id)
|
||||
@@ -64,10 +63,7 @@ namespace cicm_web.Areas.Admin.Controllers
|
||||
}
|
||||
|
||||
// GET: Admin/InstructionSets/Create
|
||||
public IActionResult Create()
|
||||
{
|
||||
return View();
|
||||
}
|
||||
public IActionResult Create() => View();
|
||||
|
||||
// POST: Admin/InstructionSets/Create
|
||||
// To protect from overposting attacks, please enable the specific properties you want to bind to, for
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Mvc.Rendering;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
@@ -39,6 +40,7 @@ using Microsoft.EntityFrameworkCore.Query;
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class MachineFamiliesController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Mvc.Rendering;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
@@ -39,6 +40,7 @@ using Microsoft.EntityFrameworkCore.Query;
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class MachinesController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Mvc.Rendering;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
@@ -39,6 +40,7 @@ using Microsoft.EntityFrameworkCore.Query;
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class MemoryByMachinesController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
|
||||
@@ -31,12 +31,14 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class NewsController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
@@ -47,10 +49,7 @@ namespace cicm_web.Areas.Admin.Controllers
|
||||
}
|
||||
|
||||
// GET: Admin/News
|
||||
public async Task<IActionResult> Index()
|
||||
{
|
||||
return View(await _context.News.ToListAsync());
|
||||
}
|
||||
public async Task<IActionResult> Index() => View(await _context.News.ToListAsync());
|
||||
|
||||
// GET: Admin/News/Details/5
|
||||
public async Task<IActionResult> Details(int? id)
|
||||
@@ -64,10 +63,7 @@ namespace cicm_web.Areas.Admin.Controllers
|
||||
}
|
||||
|
||||
// GET: Admin/News/Create
|
||||
public IActionResult Create()
|
||||
{
|
||||
return View();
|
||||
}
|
||||
public IActionResult Create() => View();
|
||||
|
||||
// POST: Admin/News/Create
|
||||
// To protect from overposting attacks, please enable the specific properties you want to bind to, for
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Mvc.Rendering;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
@@ -39,6 +40,7 @@ using Microsoft.EntityFrameworkCore.Query;
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class ProcessorsByMachinesController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Mvc.Rendering;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
@@ -39,6 +40,7 @@ using Microsoft.EntityFrameworkCore.Query;
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class ProcessorsController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
|
||||
@@ -31,12 +31,14 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class ResolutionsController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
@@ -47,10 +49,7 @@ namespace cicm_web.Areas.Admin.Controllers
|
||||
}
|
||||
|
||||
// GET: Admin/Resolutions
|
||||
public async Task<IActionResult> Index()
|
||||
{
|
||||
return View(await _context.Resolutions.ToListAsync());
|
||||
}
|
||||
public async Task<IActionResult> Index() => View(await _context.Resolutions.ToListAsync());
|
||||
|
||||
// GET: Admin/Resolutions/Details/5
|
||||
public async Task<IActionResult> Details(int? id)
|
||||
@@ -64,10 +63,7 @@ namespace cicm_web.Areas.Admin.Controllers
|
||||
}
|
||||
|
||||
// GET: Admin/Resolutions/Create
|
||||
public IActionResult Create()
|
||||
{
|
||||
return View();
|
||||
}
|
||||
public IActionResult Create() => View();
|
||||
|
||||
// POST: Admin/Resolutions/Create
|
||||
// To protect from overposting attacks, please enable the specific properties you want to bind to, for
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Mvc.Rendering;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
@@ -39,6 +40,7 @@ using Microsoft.EntityFrameworkCore.Query;
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class SoundSynthsController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Cicm.Database.Models;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Mvc.Rendering;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
@@ -39,6 +40,7 @@ using Microsoft.EntityFrameworkCore.Query;
|
||||
namespace cicm_web.Areas.Admin.Controllers
|
||||
{
|
||||
[Area("Admin")]
|
||||
[Authorize]
|
||||
public class StorageByMachinesController : Controller
|
||||
{
|
||||
readonly cicmContext _context;
|
||||
|
||||
Reference in New Issue
Block a user