using iWareCommon.Utils; using iWareDataCore.RBAC.Service; using iWarePod.Properties; using iWarePod.Utils; using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.Mvc; namespace iWarePod.Controllers { public class AuthController : Controller { // // GET: /Auth/ public ActionResult Index() { return View(); } /// /// 获取客户端 /// /// 是否运行访问 [HttpPost] public ActionResult GetAuth() { string msg; var mac = IpHelper.GetMacAddress(System.Web.HttpContext.Current.Request.ServerVariables["REMOTE_ADDR"]); LogTextHelper.WriteLine(Resources.LogDir,"登录的IP:{0}",mac); return Json(new { Result = MacAuthService.GetInstance().GetAuth(mac, out msg), Message = msg }, JsonRequestBehavior.DenyGet); } } }