1、优化树模型存储路径以及数据结构,以适配业务系统具体设备数据获取。

2、完善树模型数据查询接口,以支持模式匹配字段查询。
This commit is contained in:
ChenYi 2026-02-26 17:12:50 +08:00
parent 2ec55aec51
commit d5b6651e56
5 changed files with 18 additions and 8 deletions

View File

@ -83,7 +83,7 @@
"DistributedMessage": 2, "DistributedMessage": 2,
"SnowflakeWorkerId": 1, "SnowflakeWorkerId": 1,
"DownloadDeviceFirmwareBasicUrl": "http://121.42.175.177:32580/Aggregation/Device/DownloadFirmware?Id=", "DownloadDeviceFirmwareBasicUrl": "http://121.42.175.177:32580/Aggregation/Device/DownloadFirmware?Id=",
"MQTTServerType": 2 "MQTTServerType": 1
}, },
"Jwt": { "Jwt": {
"Audience": "JiShe.IoT", "Audience": "JiShe.IoT",

View File

@ -458,6 +458,8 @@ namespace JiShe.IoT.BusinessSystemAggregation
return HttpDataResultExtensions.Failed<List<IoTDBDynamicObject>>(null, $"设备地址格式不正确: {messageBody.DeviceAddress}", -107); return HttpDataResultExtensions.Failed<List<IoTDBDynamicObject>>(null, $"设备地址格式不正确: {messageBody.DeviceAddress}", -107);
} }
logger.LogWarning($"{nameof(QueryDeviceDataInfoAsync)} 业务系统查询单个设备数据调用数据查询接口,集中器地址为:{messageBody.DeviceAddress}");
//执行脚本 //执行脚本
var result = await FreeRedisProvider.Instance.EvalAsync var result = await FreeRedisProvider.Instance.EvalAsync
( (

View File

@ -3,6 +3,7 @@ using JiShe.IoT.Jobs;
using JiShe.ServicePro.CTWingManagement; using JiShe.ServicePro.CTWingManagement;
using JiShe.ServicePro.DeviceManagement; using JiShe.ServicePro.DeviceManagement;
using JiShe.ServicePro.DynamicMenuManagement; using JiShe.ServicePro.DynamicMenuManagement;
using JiShe.ServicePro.EMQXProvider;
using JiShe.ServicePro.FileManagement; using JiShe.ServicePro.FileManagement;
using JiShe.ServicePro.FreeRedisProvider; using JiShe.ServicePro.FreeRedisProvider;
using JiShe.ServicePro.FreeSqlProvider; using JiShe.ServicePro.FreeSqlProvider;
@ -29,6 +30,7 @@ namespace JiShe.IoT
typeof(ServiceProFreeRedisProviderModule), typeof(ServiceProFreeRedisProviderModule),
typeof(CTWingManagementApplicationModule), typeof(CTWingManagementApplicationModule),
typeof(OneNETManagementApplicationModule), typeof(OneNETManagementApplicationModule),
typeof(JiSheServiceProEMQXProviderModule),
typeof(DeviceManagementApplicationModule) typeof(DeviceManagementApplicationModule)
)] )]
public class IoTApplicationModule : AbpModule public class IoTApplicationModule : AbpModule

View File

@ -123,6 +123,8 @@ namespace JiShe.IoT
createDeviceInput.PlatformPassword = productInfo.ProductAccesskey; createDeviceInput.PlatformPassword = productInfo.ProductAccesskey;
createDeviceInput.IoTPlatformProductName = productInfo.ProductName; createDeviceInput.IoTPlatformProductName = productInfo.ProductName;
createDeviceInput.AccountPhoneNumber = productInfo.AccountPhoneNumber; createDeviceInput.AccountPhoneNumber = productInfo.AccountPhoneNumber;
createDeviceInput.ReadingMode = DeviceReadingModeEnum.StandardMode;
createDeviceInput.FirmwareVersion = "default";
if (input.DeviceType.HasValue) if (input.DeviceType.HasValue)
{ {
createDeviceInput.DeviceType = input.DeviceType.Value; createDeviceInput.DeviceType = input.DeviceType.Value;
@ -228,13 +230,7 @@ namespace JiShe.IoT
if (input.DeviceType.HasValue) if (input.DeviceType.HasValue)
{ {
createDeviceInput.DeviceType = input.DeviceType.Value; createDeviceInput.DeviceType = input.DeviceType.Value;
} }
if (item.BusinessSystemDeviceDataId.HasValue)
{
createDeviceInput.BusinessSystemDeviceDataId = item.BusinessSystemDeviceDataId.Value;
}
batchCreateDeviceInput.DeviceInputs.Add(createDeviceInput); batchCreateDeviceInput.DeviceInputs.Add(createDeviceInput);
} }

View File

@ -35,6 +35,16 @@ namespace JiShe.IoT.Controllers
return await _businessSystemAggregationService.BatchQueryDeviceDataInfoAsync(input); return await _businessSystemAggregationService.BatchQueryDeviceDataInfoAsync(input);
} }
/// <summary>
/// 业务系统查询单个设备数据
/// </summary>
[HttpPost(nameof(QueryDeviceDataInfoAsync))]
[SwaggerOperation(summary: "业务系统查询单个设备数据", Tags = new[] { "AggregationBusiness" })]
public async Task<HttpDataResult> QueryDeviceDataInfoAsync(OpenApiRequest input)
{
return await _businessSystemAggregationService.QueryDeviceDataInfoAsync(input);
}
/// <summary> /// <summary>
/// 业务系统批量新增设备数据 /// 业务系统批量新增设备数据