Added various

- Added DOC
- Added Patient
- Added Notifications
- Added Messages
- Various Refactoring
This commit is contained in:
2019-01-04 15:52:13 +01:00
parent e98b0ee6ce
commit 3751680fd3
23 changed files with 831 additions and 265 deletions

View File

@@ -1,6 +1,4 @@
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc;
namespace SeniorAssistant.Controllers
{
@@ -45,9 +43,15 @@ namespace SeniorAssistant.Controllers
return CheckAuthorized("Data", user);
}
[Route("Message/{Id}")]
public IActionResult Message(int id)
{
return CheckAuthorized("Message", id);
}
private IActionResult CheckAuthorized(string view, object model = null)
{
if (HttpContext.Session.GetString("username") == null)
if (!IsLogged())
{
model = "/" + view;
view = "Index";