没计算时默认显示当前选择的井

feature/UI-20260528
lvjunjie 2 weeks ago
parent c6eaa7940b
commit 1fb8f767a8

@ -210,6 +210,11 @@ void nmWxNumericalDesign::fillResultWellCombo(const QString& selectedWellName)
}
}
// 未计算时没有结果井列表,先显示当前井,避免下拉框空白。
if(m_pResultWellCombo->count() == 0 && !sCurrentWellName.isEmpty()) {
m_pResultWellCombo->addItem(sCurrentWellName);
}
int nIndex = m_pResultWellCombo->findText(sCurrentWellName);
if(nIndex < 0 && m_pResultWellCombo->count() > 0) {
nIndex = 0;

Loading…
Cancel
Save