This commit is contained in:
44
Controllers/OpsController.cs
Normal file
44
Controllers/OpsController.cs
Normal file
@@ -0,0 +1,44 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using rockfishCore.Models;
|
||||
using rockfishCore.Util;
|
||||
|
||||
namespace rockfishCore.Controllers
|
||||
{
|
||||
[Produces("application/json")]
|
||||
[Route("api/ops")]
|
||||
[Authorize]
|
||||
public class OpsController : Controller
|
||||
{
|
||||
private readonly rockfishContext _context;
|
||||
|
||||
public OpsController(rockfishContext context)
|
||||
{
|
||||
_context = context;
|
||||
}
|
||||
|
||||
|
||||
//status of ops
|
||||
[HttpGet("status")]
|
||||
public dtoOpsStatus GetOpsStatus()
|
||||
{
|
||||
dtoOpsStatus ret= new dtoOpsStatus();
|
||||
ret.MailMirrorOK=RfMail.MailIsMirroringProperly();
|
||||
return ret;
|
||||
}
|
||||
|
||||
public class dtoOpsStatus
|
||||
{
|
||||
public bool MailMirrorOK;
|
||||
|
||||
}
|
||||
|
||||
|
||||
}//eoc
|
||||
}//eons
|
||||
Reference in New Issue
Block a user