wankeda
2 天以前 6cc35000a6e138cfad96e7b02f8aeddcdb4ba6bf
´úÂë¹ÜÀí/NEWCode/WIDESEAWCS_Server/WIDESEAWCS_Server/Controllers/System/Dt_StationinfoController.cs
@@ -1,8 +1,13 @@
using Microsoft.AspNetCore.Http;
using Autofac.Core;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json;
using WIDESEAWCS_Core;
using WIDESEAWCS_Core.BaseController;
using WIDESEAWCS_ISystemServices;
using WIDESEAWCS_Model.Models;
using WIDESEAWCS_SystemServices;
namespace WIDESEAWCS_Server.Controllers.System
{
@@ -13,5 +18,32 @@
        public Dt_StationinfoController(IDt_StationinfoService service) : base(service)
        {
        }
        [HttpPost, Route("SetStationEnable"), AllowAnonymous]
        public WebResponseContent SetStationEnable([FromBody] object parm)
        {
            return Service.SetStationEnable(parm);
        }
        //public WebResponseContent SetStationEnable(object parm)
        //{
        //    WebResponseContent content = new WebResponseContent();
        //    try
        //    {
        //        var data = JsonConvert.DeserializeObject<Parm>(parm.ToString());
        //        var res = BaseDal.QueryFirst(x => data.data.Contains(x.id.ToString()));
        //        res.Enable = data.type.ObjToBool();
        //        var isTrue = BaseDal.UpdateData(res);
        //        if (isTrue)
        //        {
        //            content.OK("缓存架状态更新成功");
        //        }
        //    }
        //    catch (Exception ex)
        //    {
        //        content.Error(ex.Message);
        //    }
        //    return content;
        //}
    }
}