Fix [ 1881480 ] Navigation problem between tabs
This commit is contained in:
parent
8e67bce559
commit
7ca3ef5043
|
@ -1162,6 +1162,29 @@ public class GridField
|
|||
// m_propertyChangeListeners.firePropertyChange(PROPERTY, s_oldValue, null);
|
||||
} // setValue
|
||||
|
||||
/**
|
||||
* Set Value to null.
|
||||
* <p>
|
||||
* Do update context - called from GridTab.setCurrentRow
|
||||
* Send Bean PropertyChange if there is a change
|
||||
*/
|
||||
public void setValueAndUpdateContext ()
|
||||
{
|
||||
// log.fine(ColumnName + "=" + newValue);
|
||||
if (m_valueNoFire) // set the old value
|
||||
m_oldValue = m_value;
|
||||
m_value = null;
|
||||
m_inserting = false;
|
||||
m_error = false; // reset error
|
||||
|
||||
// [ 1881480 ] Navigation problem between tabs
|
||||
Env.setContext(m_vo.ctx, m_vo.WindowNo, m_vo.ColumnName, (String) m_value);
|
||||
|
||||
// Does not fire, if same value
|
||||
m_propertyChangeListeners.firePropertyChange(PROPERTY, m_oldValue, m_value);
|
||||
// m_propertyChangeListeners.firePropertyChange(PROPERTY, s_oldValue, null);
|
||||
} // setValue
|
||||
|
||||
/**
|
||||
* Set Value.
|
||||
* <p>
|
||||
|
|
|
@ -2190,7 +2190,16 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
|
|||
// Object value = null;
|
||||
// if (mField.isKey() || mField.isParent() || mField.getColumnName().equals(m_linkColumnName))
|
||||
// value = mField.getDefault();
|
||||
mField.setValue();
|
||||
|
||||
// CarlosRuiz - globalqss [ 1881480 ] Navigation problem between tabs
|
||||
// the implementation of linking with window context variables is very weak
|
||||
// you must be careful when defining a column in a detail tab with a field
|
||||
// with the same column name as some of the links of the tabs above
|
||||
// this can cause bad behavior of linking
|
||||
if (mField.getColumnName().equals(m_linkColumnName))
|
||||
mField.setValue();
|
||||
else
|
||||
mField.setValueAndUpdateContext();
|
||||
}
|
||||
}
|
||||
loadDependentInfo();
|
||||
|
|
Loading…
Reference in New Issue