IDEMPIERE-2935 New record on GridMode error on fields with DisplayLogic / IDEMPIERE-2148

This commit is contained in:
Carlos Ruiz 2015-12-14 13:20:03 -05:00
parent 488e442c98
commit 93c31a73a4
1 changed files with 4 additions and 9 deletions

View File

@ -17,7 +17,6 @@ import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
import java.util.Properties;
import org.adempiere.util.GridRowCtx;
import org.adempiere.webui.LayoutUtils;
@ -505,9 +504,8 @@ public class GridTabRowRenderer implements RowRenderer<Object[]>, RowRendererExt
else if (DisplayType.isNumeric(gridPanelFields[i].getDisplayType())) {
divStyle = CELL_DIV_STYLE_ALIGN_RIGHT;
}
GridRowCtx ctx = new GridRowCtx(Env.getCtx(), gridTab, rowIndex);
if (!gridPanelFields[i].isDisplayed(ctx, true)){
if (!gridPanelFields[i].isDisplayedGrid()){
// IDEMPIERE-2253
div.removeChild(component);
}
@ -644,12 +642,9 @@ public class GridTabRowRenderer implements RowRenderer<Object[]>, RowRendererExt
div.appendChild(popupMenu);
popupMenu.addContextElement((XulElement) editor.getComponent());
}
Properties ctx = isDetailPane() ? new GridRowCtx(Env.getCtx(), gridTab, gridTab.getCurrentRow())
: gridPanelFields[i].getVO().ctx;
//check context
if (!gridPanelFields[i].isDisplayed(ctx, true)){
if (!gridPanelFields[i].isDisplayedGrid()){
// IDEMPIERE-2253
div.removeChild(editor.getComponent());
}