更新设备变量新追加

This commit is contained in:
dell
2023-03-10 16:39:39 +08:00
parent 80564727ea
commit a3a51fd6e2
6 changed files with 660 additions and 52 deletions

View File

@ -8,6 +8,7 @@ using HT.Cloud.Domain.ChartsManage;
using HT.Cloud.Service;
using Microsoft.AspNetCore.Authorization;
using HT.Cloud.Service.DevicesManage;
using System.Text.RegularExpressions;
namespace HT.Cloud.Web.Areas.DevicesManage.Controllers
{
@ -27,7 +28,42 @@ namespace HT.Cloud.Web.Areas.DevicesManage.Controllers
var data = await _metaTagService.GetALLNode();
return Content(data);
}
[HttpPost]
public async Task<ActionResult> GetDriverArgument(string[] driverId)
{
int drivreIId = 0;
try
{
drivreIId = int.Parse(Regex.Replace(driverId[0], "[a-zA-Z]", "", RegexOptions.IgnoreCase));
}
catch(Exception ex)
{
Console.WriteLine(ex.Message);
}
var data = await _metaTagService.GetDriverArgument(drivreIId);
return Content(data);
}
[HttpPost]
public async Task<ActionResult> GetGroupVarTable(string[] groupId)
{
int groupIId = 0;
try
{
groupIId = int.Parse(Regex.Replace(groupId[0], "[a-zA-Z]", "", RegexOptions.IgnoreCase));
}
catch (Exception ex)
{
Console.WriteLine(ex.Message);
}
var data = await _metaTagService.GetGroupVarTable(groupIId);
return Content(data);
}
[HttpPost]
public async Task<ActionResult> SaveArgument(string driverId, string name, string value)
{
var data = "";
return Content(data);
}
}
}