82 lines
2.4 KiB
C#
82 lines
2.4 KiB
C#
using Microsoft.AspNetCore.Mvc;
|
|
using Microsoft.Extensions.Logging;
|
|
using Sarand.Net.Standard.Base.Bus;
|
|
using Sarand.Net.Standard.Base.Core;
|
|
using Sarand.Net.Standard.Base.Dbas;
|
|
using Sarand.Net.Standard.Base.Utils;
|
|
using Saxonite.Net.Core.Web.Base.App;
|
|
using Saxonite.Net.Core.Web.Online.Models;
|
|
using Saxonite.Net.Standard.Base.App;
|
|
using Saxonite.Net.Standard.Base.Bus;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace Saxonite.Net.Core.Web.Online.Controllers
|
|
{
|
|
//=======================================================================
|
|
// Online Support Controller.
|
|
//=======================================================================
|
|
public partial class SupportController : SaxController_Online
|
|
{
|
|
//-------------------------------------------------------------------
|
|
// Construction.
|
|
public SupportController(SaxLocaliser localiser, ILogger<HomeController> logger) :
|
|
base(localiser, logger)
|
|
{
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
[HttpGet]
|
|
public IActionResult Index()
|
|
{
|
|
// Validate session.
|
|
if (!ValidUserSession)
|
|
return RedirectToAction("", "");
|
|
|
|
// No Support index page.
|
|
return RedirectToAction("", "");
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
[HttpGet,HttpPost]
|
|
public IActionResult Feedback()
|
|
{
|
|
// Validate session.
|
|
if (!ValidUserSession)
|
|
return RedirectToAction("", "");
|
|
Model_Support model = new Model_Support(Localiser);
|
|
|
|
// User must be a member of the 'Reviewers' role.
|
|
if (!SessionData_Online.User.SupportMenuAllowed)
|
|
return RedirectToAction("", "");
|
|
|
|
// Applincation index page.
|
|
model.ProhibitCache = false;
|
|
return View(model);
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
[HttpGet, HttpPost]
|
|
public IActionResult Versions()
|
|
{
|
|
// Validate session.
|
|
if (!ValidUserSession)
|
|
return RedirectToAction("", "");
|
|
Model_Support model = new Model_Support(Localiser);
|
|
|
|
// User must be a member of the 'Reviewers' role.
|
|
if (!SessionData_Online.User.SupportMenuAllowed)
|
|
return RedirectToAction("", "");
|
|
|
|
// Applincation index page.
|
|
model.ProhibitCache = false;
|
|
return View(model);
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
}
|
|
//=======================================================================
|
|
}
|