mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-08 15:37:30 -06:00
FIX:fixed amsdata not sync after changed ams
Change-Id: If1c087c42258897fec7df5d44ff039bb0eec3b25
This commit is contained in:
parent
5444f69fc2
commit
459fe36235
2 changed files with 20 additions and 3 deletions
|
@ -379,15 +379,19 @@ void MachineInfoPanel::update_ams(MachineObject *obj)
|
|||
|
||||
|
||||
auto it = ver_list.find(atoi(iter->first.c_str()));
|
||||
auto ams_id = std::stoi(iter->second->id);
|
||||
|
||||
|
||||
if (it == ver_list.end()) {
|
||||
// hide this ams
|
||||
wxString ams_text = wxString::Format("AMS%s", std::to_string(ams_index + 1));
|
||||
wxString ams_text = wxString::Format("AMS%s", std::to_string(ams_id + 1));
|
||||
|
||||
ams_name = ams_text;
|
||||
ams_sn = "-";
|
||||
ams_ver = "-";
|
||||
} else {
|
||||
// update ams img
|
||||
wxString ams_text = wxString::Format("AMS%s", std::to_string(ams_index + 1));
|
||||
wxString ams_text = wxString::Format("AMS%s", std::to_string(ams_id + 1));
|
||||
ams_name = ams_text;
|
||||
|
||||
std::string ams_id = "ams/" + std::to_string(ams_index);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue