From 3b2fd3d9fe7ac25d36166babef70cf76456899f5 Mon Sep 17 00:00:00 2001 From: dev02 Date: Mon, 12 Jun 2023 19:23:02 +0800 Subject: [PATCH] =?UTF-8?q?[=E5=BE=8C=E7=AB=AF]=20=E4=BF=AE=E6=94=B9device?= =?UTF-8?q?=5Fitem=20=E8=88=87building=5Ftag=20=E9=8F=88=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Backend/appsettings.Development.json | 3 ++- FrontendWebApi/ApiControllers/HistoryController.cs | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Backend/appsettings.Development.json b/Backend/appsettings.Development.json index 83cd09a..4009248 100644 --- a/Backend/appsettings.Development.json +++ b/Backend/appsettings.Development.json @@ -18,10 +18,11 @@ "Port": "js2LutKe+rdjzdxMPQUrvQ==", //"Database": "VJB2XC+lAtzuHObDGMVOAA==", //30 //"Database": "IgYBsgG2VLKKxFb64j7LOA==", //wsp - "Database": "7gWfmZ28HGIJZbxEbK+0yg==", //tpe_dome_dome + //"Database": "7gWfmZ28HGIJZbxEbK+0yg==", //tpe_dome_dome //"Database": "siTUcDaC/g2yGTMFWD72Kg==", //tpe_dome_hotel //"Database": "iuaY0h0+TWkir44/eZLDqw==", //tpe_dome_office //"Database": "Rq7Gn4x6LwBvVtl7GY8LbA==", //mcut + "Database": "2U+9jYGy0dCbMzLaguBXow==", //tpe_dome_mall "Root": "SzdxEgaJJ7tcTCrUl2zKsA==", "Password": "FVAPxztxpY4gJJKQ/se4bQ==" }, diff --git a/FrontendWebApi/ApiControllers/HistoryController.cs b/FrontendWebApi/ApiControllers/HistoryController.cs index a1f8c2b..8ba7341 100644 --- a/FrontendWebApi/ApiControllers/HistoryController.cs +++ b/FrontendWebApi/ApiControllers/HistoryController.cs @@ -305,8 +305,9 @@ namespace FrontendWebApi.ApiControllers List deviceItems = new List(); var main_system_value = hf.device_number.Split('_')[2]; var sub_system_value = hf.device_number.Split('_')[3]; - var sqlString = $@"select * from device_item where deleted = 0 and device_system_tag = @main_system_value and device_name_tag = @sub_system_value and is_show_history = 1"; - deviceItems = await frontendRepository.GetAllAsync(sqlString, new { @main_system_value = main_system_value, @sub_system_value = sub_system_value }); + var building_tag = hf.device_number.Split('_')[1]; + var sqlString = $@"select * from device_item where deleted = 0 and device_system_tag = @main_system_value and device_name_tag = @sub_system_value and is_show_history = 1 and device_building_tag = @building_tag"; + deviceItems = await frontendRepository.GetAllAsync(sqlString, new { @main_system_value = main_system_value, @sub_system_value = sub_system_value, building_tag = building_tag }); apiResult.Data = deviceItems; apiResult.Code = "0000";