wip
This commit is contained in:
parent
1550c1965a
commit
23dc69c72b
@ -407,25 +407,25 @@ class TableAPI final : public BaseAPI
|
||||
return util::json::Value(util::json::Number(
|
||||
std::round(from_alias<double>(distance) * 10) / 10.));
|
||||
});
|
||||
// json_table.values.emplace_back(util::json::Value{std::move(json_row)});
|
||||
json_table.values.push_back(util::json::Value{json_row});
|
||||
}
|
||||
return json_table;
|
||||
}
|
||||
|
||||
virtual util::json::Array
|
||||
MakeEstimatesTable(const std::vector<TableCellRef> &/*fallback_speed_cells*/) const
|
||||
MakeEstimatesTable(const std::vector<TableCellRef> &fallback_speed_cells) const
|
||||
{
|
||||
util::json::Array json_table;
|
||||
// std::for_each(fallback_speed_cells.begin(),
|
||||
// fallback_speed_cells.end(),
|
||||
// [&](const auto &cell)
|
||||
// {
|
||||
// util::json::Array row;
|
||||
// row.values.emplace_back(util::json::Value{util::json::Number(static_cast<double>(cell.row))});
|
||||
// row.values.emplace_back(
|
||||
// util::json::Value{util::json::Number(static_cast<double>(cell.column))});
|
||||
// json_table.values.emplace_back(util::json::Value{std::move(row)});
|
||||
// });
|
||||
std::for_each(fallback_speed_cells.begin(),
|
||||
fallback_speed_cells.end(),
|
||||
[&](const auto &cell)
|
||||
{
|
||||
util::json::Array row;
|
||||
row.values.emplace_back(util::json::Value{util::json::Number(static_cast<double>(cell.row))});
|
||||
row.values.emplace_back(
|
||||
util::json::Value{util::json::Number(static_cast<double>(cell.column))});
|
||||
json_table.values.push_back(util::json::Value{row});
|
||||
});
|
||||
return json_table;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user