[後端] 修改waterList param問題
This commit is contained in:
parent
40a3cf68e6
commit
b4f79d4a0f
@ -160,7 +160,7 @@ namespace FrontendWebApi.ApiControllers
|
|||||||
{sqlWhere}
|
{sqlWhere}
|
||||||
order by created_at desc;";
|
order by created_at desc;";
|
||||||
var rawData = await backendRepository.GetAllAsync<HydroMeterRawDataOutput>(sql,
|
var rawData = await backendRepository.GetAllAsync<HydroMeterRawDataOutput>(sql,
|
||||||
new { table = table, starTime = startTime, endTime = endTime, building_tag = input.building_tag, floor_tag = input.floor_tag, dateFormat = dateFormat });
|
new { startTime = startTime, endTime = endTime, building_tag = input.building_tag, floor_tag = input.floor_tag, dateFormat = dateFormat });
|
||||||
var list = rawData
|
var list = rawData
|
||||||
.GroupBy(x => new { building_tag = x.device_number.Split("_")[0], floor_tag = x.device_number.Split("_")[2], device_serial_tag = x.device_number.Split("_")[4] })
|
.GroupBy(x => new { building_tag = x.device_number.Split("_")[0], floor_tag = x.device_number.Split("_")[2], device_serial_tag = x.device_number.Split("_")[4] })
|
||||||
.Select(x => new HydroMeterOutput { building_tag = x.Key.building_tag, floor_tag = x.Key.floor_tag, device_serial_tag = x.Key.device_serial_tag })
|
.Select(x => new HydroMeterOutput { building_tag = x.Key.building_tag, floor_tag = x.Key.floor_tag, device_serial_tag = x.Key.device_serial_tag })
|
||||||
|
Loading…
Reference in New Issue
Block a user