summaryrefslogtreecommitdiff
path: root/Project-Unite/Controllers/DeveloperController.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Project-Unite/Controllers/DeveloperController.cs')
-rw-r--r--Project-Unite/Controllers/DeveloperController.cs19
1 files changed, 19 insertions, 0 deletions
diff --git a/Project-Unite/Controllers/DeveloperController.cs b/Project-Unite/Controllers/DeveloperController.cs
index 62be944..9e3d6c0 100644
--- a/Project-Unite/Controllers/DeveloperController.cs
+++ b/Project-Unite/Controllers/DeveloperController.cs
@@ -15,18 +15,24 @@ namespace Project_Unite.Controllers
// GET: Developer
public ActionResult Index()
{
+ if (!ACL.Granted(User.Identity.Name, "CanAccessDevCP"))
+ return new HttpStatusCodeResult(403);
ViewBag.Developer = true;
return View();
}
public ActionResult Releases()
{
+ if (!ACL.Granted(User.Identity.Name, "CanAccessDevCP"))
+ return new HttpStatusCodeResult(403);
var db = new ApplicationDbContext();
return View(db.Downloads);
}
public ActionResult AddRelease()
{
+ if (!ACL.Granted(User.Identity.Name, "CanAccessDevCP"))
+ return new HttpStatusCodeResult(403);
if (!ACL.Granted(User.Identity.Name, "CanReleaseBuild"))
return new HttpStatusCodeResult(403);
ViewBag.Developer = true;
@@ -41,6 +47,8 @@ namespace Project_Unite.Controllers
[ValidateAntiForgeryToken]
public ActionResult AddRelease(PostDownloadViewModel model)
{
+ if (!ACL.Granted(User.Identity.Name, "CanAccessDevCP"))
+ return new HttpStatusCodeResult(403);
if (!ACL.Granted(User.Identity.Name, "CanReleaseBuild"))
return new HttpStatusCodeResult(403);
if (!ModelState.IsValid)
@@ -121,6 +129,17 @@ namespace Project_Unite.Controllers
return RedirectToAction("Releases");
}
+
+ [Authorize]
+ public ActionResult Wiki()
+ {
+ if (!ACL.Granted(User.Identity.Name, "CanAccessDevCP"))
+ return new HttpStatusCodeResult(403);
+ ViewBag.Developer = true;
+ var db = new ApplicationDbContext();
+ var cats = db.WikiCategories;
+ return View(cats);
+ }
}