fix some bug

This commit is contained in:
QIDI TECH
2025-05-23 20:18:49 +08:00
parent 5ac6bf0ccb
commit 031525a16e
88 changed files with 994 additions and 141 deletions

View File

@@ -246,7 +246,10 @@ bool OctoPrint::upload(PrintHostUpload upload_data, ProgressFn prorgess_fn, Erro
http.form_add("print", "true");
//y61
// http.form_add("plateindex", std::to_string(partplate_list.get_curr_plate_index()));
if (upload_data.is_3mf) {
http.form_add("plateindex", std::to_string(GUI::wxGetApp().plater()->get_partplate_list().get_curr_plate_index() + 1));
// json_body = "{\"plateindex\" : \"" + std::to_string(GUI::wxGetApp().plater()->get_partplate_list().get_curr_plate_index()) + "\" }";
}
//y53
progress_percentage = 0;

View File

@@ -33,7 +33,7 @@ struct PrintHostUpload
boost::filesystem::path upload_path;
std::string group;
std::string storage;
bool is_3mf = false;
PrintHostPostUploadAction post_action { PrintHostPostUploadAction::None };
};
@@ -88,7 +88,6 @@ struct PrintHostJob
PrintHostUpload upload_data;
std::unique_ptr<PrintHost> printhost;
bool cancelled = false;
bool is_3mf = false;
PrintHostJob() {}
PrintHostJob(const PrintHostJob&) = delete;
@@ -98,7 +97,6 @@ struct PrintHostJob
, cancelled(other.cancelled)
, create_time(std::move(other.create_time))
, sendinginterval(other.sendinginterval)
, is_3mf(other.is_3mf)
{}
PrintHostJob(DynamicPrintConfig *config)
@@ -115,8 +113,6 @@ struct PrintHostJob
// y10
create_time = std::move(other.create_time);
sendinginterval = other.sendinginterval;
//y58
is_3mf = other.is_3mf;
return *this;
}