IDEMPIERE-3156 SubAcct not working on Account Combination Dialog / supressed m_elements array from MAcctSchema in favour of cache - changing elements required a reboot instead of a cache reset
This commit is contained in:
parent
34926b0409
commit
d2524019e3
|
@ -39,8 +39,7 @@ public class MAcctSchema extends X_C_AcctSchema
|
|||
/**
|
||||
*
|
||||
*/
|
||||
private static final long serialVersionUID = -7228171623905614596L;
|
||||
|
||||
private static final long serialVersionUID = 8940388112876468770L;
|
||||
|
||||
/**
|
||||
* Get AccountSchema of Client
|
||||
|
@ -201,8 +200,6 @@ public class MAcctSchema extends X_C_AcctSchema
|
|||
} // MAcctSchema
|
||||
|
||||
|
||||
/** Element List */
|
||||
private MAcctSchemaElement[] m_elements = null;
|
||||
/** GL Info */
|
||||
private MAcctSchemaGL m_gl = null;
|
||||
/** Default Info */
|
||||
|
@ -228,9 +225,7 @@ public class MAcctSchema extends X_C_AcctSchema
|
|||
*/
|
||||
public MAcctSchemaElement[] getAcctSchemaElements()
|
||||
{
|
||||
if (m_elements == null)
|
||||
m_elements = MAcctSchemaElement.getAcctSchemaElements(this);
|
||||
return m_elements;
|
||||
return MAcctSchemaElement.getAcctSchemaElements(this);
|
||||
} // getAcctSchemaElements
|
||||
|
||||
/**
|
||||
|
@ -240,11 +235,8 @@ public class MAcctSchema extends X_C_AcctSchema
|
|||
*/
|
||||
public MAcctSchemaElement getAcctSchemaElement (String elementType)
|
||||
{
|
||||
if (m_elements == null)
|
||||
getAcctSchemaElements();
|
||||
for (int i = 0; i < m_elements.length; i++)
|
||||
{
|
||||
MAcctSchemaElement ase = m_elements[i];
|
||||
/** Element List */
|
||||
for (MAcctSchemaElement ase : getAcctSchemaElements()) {
|
||||
if (ase.getElementType().equals(elementType))
|
||||
return ase;
|
||||
}
|
||||
|
|
|
@ -1210,7 +1210,11 @@ public final class WAccountDialog extends Window
|
|||
*/
|
||||
public void valueChange(ValueChangeEvent evt) {
|
||||
Object newValue = evt.getNewValue();
|
||||
if (newValue instanceof Integer)
|
||||
if (newValue instanceof Integer) {
|
||||
Env.setContext(Env.getCtx(), m_WindowNo, "Account_ID", ((Integer)newValue).intValue());
|
||||
if (f_SubAcct_ID != null) {
|
||||
f_SubAcct_ID.dynamicDisplay();
|
||||
}
|
||||
}
|
||||
}
|
||||
} // WAccountDialog
|
||||
|
|
Loading…
Reference in New Issue