Fix camera

This commit is contained in:
xiaoyeliu
2025-12-24 17:32:54 +08:00
parent 22c1753708
commit 6c549d996c
4 changed files with 8 additions and 5 deletions

View File

@@ -2267,7 +2267,7 @@ void Moonraker_Mqtt::async_machine_files_directory(const std::string& path, bool
}
}
void Moonraker_Mqtt::async_camera_start(const std::string& domain, int interval, std::function<void(const nlohmann::json& response)> callback) {
void Moonraker_Mqtt::async_camera_start(const std::string& domain, int interval, bool expect_pw, std::function<void(const nlohmann::json& response)> callback) {
auto& wcp_loger = GUI::WCP_Logger::getInstance();
BOOST_LOG_TRIVIAL(warning) << "[Moonraker_Mqtt] 开始启动摄像头监控,域名: " << domain;
wcp_loger.add_log("开始启动摄像头监控,域名: " + domain, false, "", "Moonraker_Mqtt", "info");
@@ -2276,6 +2276,7 @@ void Moonraker_Mqtt::async_camera_start(const std::string& domain, int interval,
json params;
params["domain"] = domain;
params["interval"] = interval;
params["expect_pw"] = expect_pw;
if (!send_to_request(method, params, true, callback,
[callback, &wcp_loger]() {