Fix problem with [3007342] - Included tab context conflict issue
https://sourceforge.net/tracker/index.php?func=detail&aid=3007342&group_id=176962&atid=879332 This functionality must preserve the value of the parent tab JUST when is an included tab not included tabs can have Processed fields and is valid to add records in details on these cases like the Payment Schedule tab on Invoice (Customer) window
This commit is contained in:
parent
e72d1fdf4c
commit
fb189f010c
|
@ -1872,6 +1872,11 @@ public class GridField
|
||||||
{
|
{
|
||||||
if (m_gridTab == null)
|
if (m_gridTab == null)
|
||||||
return false;
|
return false;
|
||||||
|
// this functionality must preserve the value of the parent tab JUST when is an included tab
|
||||||
|
// not included tabs can have Processed fields and is valid to add records in details on these cases
|
||||||
|
// like the Payment Schedule tab on Invoice (Customer) window
|
||||||
|
if (!m_gridTab.isIncluded())
|
||||||
|
return false;
|
||||||
GridTab parentTab = m_gridTab.getParentTab();
|
GridTab parentTab = m_gridTab.getParentTab();
|
||||||
if (parentTab == null)
|
if (parentTab == null)
|
||||||
return false;
|
return false;
|
||||||
|
|
|
@ -107,7 +107,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
private static final long serialVersionUID = -8055500064230704903L;
|
private static final long serialVersionUID = -3825605601192688998L;
|
||||||
|
|
||||||
public static final String DEFAULT_STATUS_MESSAGE = "NavigateOrUpdate";
|
public static final String DEFAULT_STATUS_MESSAGE = "NavigateOrUpdate";
|
||||||
|
|
||||||
|
@ -196,6 +196,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
|
||||||
private volatile boolean m_loadComplete = false;
|
private volatile boolean m_loadComplete = false;
|
||||||
/** Is Tab Included in other Tab */
|
/** Is Tab Included in other Tab */
|
||||||
private boolean m_included = false;
|
private boolean m_included = false;
|
||||||
|
private boolean m_includedAlreadyCalc = false;
|
||||||
|
|
||||||
/** Logger */
|
/** Logger */
|
||||||
protected CLogger log = CLogger.getCLogger(getClass());
|
protected CLogger log = CLogger.getCLogger(getClass());
|
||||||
|
@ -1349,12 +1350,25 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
|
||||||
*/
|
*/
|
||||||
public boolean isIncluded()
|
public boolean isIncluded()
|
||||||
{
|
{
|
||||||
|
if (! m_includedAlreadyCalc) {
|
||||||
|
m_included = false;
|
||||||
|
if (getParentTab() != null) {
|
||||||
|
for (GridTab tab : getParentTab().getIncludedTabs()) {
|
||||||
|
if (tab.equals(this)) {
|
||||||
|
m_included = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
m_includedAlreadyCalc = true;
|
||||||
|
}
|
||||||
return m_included;
|
return m_included;
|
||||||
} // isIncluded
|
} // isIncluded
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Is Tab Included in other Tab
|
* Is Tab Included in other Tab
|
||||||
* @param isIncluded true if included
|
* @param isIncluded true if included
|
||||||
|
* @deprecated The method getIncluded now validate against the structure, this method is called nowhere
|
||||||
*/
|
*/
|
||||||
public void setIncluded(boolean isIncluded)
|
public void setIncluded(boolean isIncluded)
|
||||||
{
|
{
|
||||||
|
@ -1603,6 +1617,7 @@ public class GridTab implements DataStatusListener, Evaluatee, Serializable
|
||||||
/**
|
/**
|
||||||
* Get Included Tab ID
|
* Get Included Tab ID
|
||||||
* @return Included_Tab_ID
|
* @return Included_Tab_ID
|
||||||
|
* @deprecated the functionality related to AD_Tab.Included_Tab_ID was not developed
|
||||||
*/
|
*/
|
||||||
public int getIncluded_Tab_ID()
|
public int getIncluded_Tab_ID()
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue