mirror of
https://gitee.com/js-yhsec/energy_storage.git
synced 2026-05-28 03:09:24 +08:00
修改应用exe编译环境Win32->x64
This commit is contained in:
@@ -769,7 +769,7 @@ QVariantMap MyWebHandler::getStatisticTotal()
|
||||
result["elect_charge"] = 0.0; // 累计充电电量
|
||||
result["income_elect"] = 100.0; // 累计发电收益
|
||||
result["income_charge"] = 100.0; // 累计充电收益
|
||||
result["ccers"] = 100.0; // 累计碳减排量
|
||||
result["ccers"] = 82.3; // 累计碳减排量
|
||||
|
||||
return result;
|
||||
}
|
||||
@@ -777,41 +777,46 @@ QVariantMap MyWebHandler::getStatisticTotal()
|
||||
// 获取按天统计数据
|
||||
QVariantList MyWebHandler::getStatisticDay(const QString& startDate, int nday)
|
||||
{
|
||||
QVariantList result;
|
||||
static QVariantList result;
|
||||
static std::once_flag flagOnce;
|
||||
std::call_once(flagOnce, []() {
|
||||
// 查询数据库获取累计统计数据
|
||||
for (int i = 1; i<=7; i++)
|
||||
{
|
||||
QVariantMap row;
|
||||
row["dt"] = "";
|
||||
|
||||
// 查询数据库获取累计统计数据
|
||||
for (int i=1; i<=7; i++)
|
||||
{
|
||||
QVariantMap row;
|
||||
row["dt"] = "";
|
||||
// 光伏:发电量、入网电量、发电时长、故障次数
|
||||
row["elect_gen"] = 136.2 + Utils::random(0, 50);
|
||||
row["elect_in"] = 36.9 + Utils::random(0, 50);
|
||||
row["elect_gen_t"] = float(i);
|
||||
row["income_elect"] = float(i); // 发电收益
|
||||
row["num_fault_solar"] = Utils::random(1, 6);
|
||||
|
||||
// 光伏:发电量、入网电量、发电时长、故障次数
|
||||
row["elect_gen"] = float(i);
|
||||
row["elect_in"] = float(i);
|
||||
row["elect_gen_t"] = float(i);
|
||||
row["income_elect"] = float(i); // 发电收益
|
||||
row["num_fault_solar"] = float(i);
|
||||
|
||||
// 储能:储能电量、放电电量、储能时长、放电时长、故障次数
|
||||
row["elect_store"] = float(i);
|
||||
row["elect_discharge"] = float(i);
|
||||
row["elect_store_t"] = float(i);
|
||||
row["elect_discharge_t"] = float(i);
|
||||
row["num_fault_store"] = float(i);
|
||||
// 储能:储能电量、放电电量、储能时长、放电时长、故障次数
|
||||
row["elect_store"] = 37.5 + Utils::random(0, 20);
|
||||
row["elect_discharge"] = 16.3+ Utils::random(0, 20);
|
||||
row["elect_store_t"] = float(i);
|
||||
row["elect_discharge_t"] = float(i);
|
||||
row["num_fault_store"] = Utils::random(1, 6);
|
||||
|
||||
// 充电:充电电量、充电收益、充电次数、充电时长、故障次数
|
||||
row["elect_charge"] = float(i);
|
||||
row["elect_charge_t"] = float(i);
|
||||
row["income_charge"] = float(i);
|
||||
row["num_charge"] = float(i);
|
||||
row["num_fault_charge"] = float(i);
|
||||
// 充电:充电电量、充电收益、充电次数、充电时长、故障次数
|
||||
row["elect_charge"] = 25.6+ Utils::random(0, 20);
|
||||
row["elect_charge_t"] = float(i);
|
||||
row["income_charge"] = 327;
|
||||
row["num_charge"] = 23;
|
||||
row["num_fault_charge"] = Utils::random(1, 6);
|
||||
|
||||
// 负载:
|
||||
row["elect_load"] = float(i);
|
||||
row["num_fault_load"] = float(i);
|
||||
|
||||
result << row;
|
||||
}
|
||||
// 负载:
|
||||
row["elect_load"] = 20.8 + Utils::random(0, 10);
|
||||
row["power_max_load"] = 10.3 + Utils::random(0, 10);
|
||||
row["num_fault_load"] = Utils::random(1, 6);
|
||||
|
||||
result << row;
|
||||
}
|
||||
});
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user