加皮带秤接口

This commit is contained in:
陈向学 2024-06-26 09:35:20 +08:00
parent 32566e047f
commit 27fdc1d59c
1 changed files with 12 additions and 0 deletions

View File

@ -77,6 +77,18 @@ namespace CompetitionAPI.Controllers.api
return Json(Tool.GetJsonWithCode(APICode.Success, tmp));
}
/// <summary>
/// 根据企业id获取所有皮带秤实时数据
/// </summary>
/// <param name="monitorId"></param>
/// <returns></returns>
[HttpGet]
public JsonResult GetRealTimeDataByMonitorId(string monitorId)
{
var mysql = Configuration.GetConnectionString("MySQL").ToString();
var tmp = bll_pipeReal.GetModelList(string.Format("MONITOR_ID = '{0}'",monitorId));
return Json(Tool.GetJsonWithCode(APICode.Success, tmp));
}
/// <summary>
/// 获取一个皮带秤历史数据列表(按时间倒序,间隔筛选出N条)