IDEMPIERE-3421 wtable dir editor load wrong list
This commit is contained in:
parent
b0f7cda146
commit
a2150cf29f
|
@ -744,10 +744,12 @@ DataStatusListener, IADTabpanel, IdSpace, IFieldEditorContainer
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
comp.dynamicDisplay();
|
|
||||||
boolean rw = mField.isEditable(true); // r/w - check Context
|
boolean rw = mField.isEditable(true); // r/w - check Context
|
||||||
|
if (rw && !comp.isReadWrite()) // IDEMPIERE-3421 - if it was read-only the list can contain direct values
|
||||||
|
mField.refreshLookup();
|
||||||
comp.setReadWrite(rw);
|
comp.setReadWrite(rw);
|
||||||
comp.setMandatory(mField.isMandatory(true)); // check context
|
comp.setMandatory(mField.isMandatory(true)); // check context
|
||||||
|
comp.dynamicDisplay();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (comp.isVisible())
|
else if (comp.isVisible())
|
||||||
|
|
|
@ -996,9 +996,12 @@ public class GridView extends Vbox implements EventListener<Event>, IdSpace, IFi
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
comp.dynamicDisplay();
|
boolean rw = mField.isEditable(true); // r/w - check Context
|
||||||
boolean rw = mField.isEditableGrid(true); // r/w - check Context
|
if (rw && !comp.isReadWrite()) // IDEMPIERE-3421 - if it was read-only the list can contain direct values
|
||||||
|
mField.refreshLookup();
|
||||||
comp.setReadWrite(rw);
|
comp.setReadWrite(rw);
|
||||||
|
comp.setMandatory(mField.isMandatory(true)); // check context
|
||||||
|
comp.dynamicDisplay();
|
||||||
}
|
}
|
||||||
|
|
||||||
Properties ctx = isDetailPane() ? new GridRowCtx(Env.getCtx(), gridTab, gridTab.getCurrentRow())
|
Properties ctx = isDetailPane() ? new GridRowCtx(Env.getCtx(), gridTab, gridTab.getCurrentRow())
|
||||||
|
|
|
@ -93,8 +93,6 @@ public abstract class WEditor implements EventListener<Event>, PropertyChangeLis
|
||||||
|
|
||||||
private boolean readOnly;
|
private boolean readOnly;
|
||||||
|
|
||||||
private boolean updateable;
|
|
||||||
|
|
||||||
private String columnName;
|
private String columnName;
|
||||||
|
|
||||||
protected WEditorPopupMenu popupMenu;
|
protected WEditorPopupMenu popupMenu;
|
||||||
|
@ -177,7 +175,6 @@ public abstract class WEditor implements EventListener<Event>, PropertyChangeLis
|
||||||
this.setMandatory(gridField.isMandatory(true));
|
this.setMandatory(gridField.isMandatory(true));
|
||||||
this.readOnly = gridField.isReadOnly();
|
this.readOnly = gridField.isReadOnly();
|
||||||
this.description = gridField.getDescription();
|
this.description = gridField.getDescription();
|
||||||
this.updateable = gridField.isUpdateable();
|
|
||||||
this.columnName = gridField.getColumnName();
|
this.columnName = gridField.getColumnName();
|
||||||
this.strLabel = gridField.getHeader();
|
this.strLabel = gridField.getHeader();
|
||||||
init();
|
init();
|
||||||
|
@ -227,7 +224,6 @@ public abstract class WEditor implements EventListener<Event>, PropertyChangeLis
|
||||||
this.setMandatory(mandatory);
|
this.setMandatory(mandatory);
|
||||||
this.readOnly = readonly;
|
this.readOnly = readonly;
|
||||||
this.description = description;
|
this.description = description;
|
||||||
this.updateable = updateable;
|
|
||||||
this.strLabel = label;
|
this.strLabel = label;
|
||||||
init();
|
init();
|
||||||
}
|
}
|
||||||
|
@ -253,7 +249,6 @@ public abstract class WEditor implements EventListener<Event>, PropertyChangeLis
|
||||||
this.setMandatory(mandatory);
|
this.setMandatory(mandatory);
|
||||||
this.readOnly = readonly;
|
this.readOnly = readonly;
|
||||||
this.description = description;
|
this.description = description;
|
||||||
this.updateable = updateable;
|
|
||||||
this.strLabel = label;
|
this.strLabel = label;
|
||||||
this.columnName = columnName;
|
this.columnName = columnName;
|
||||||
init();
|
init();
|
||||||
|
@ -277,15 +272,7 @@ public abstract class WEditor implements EventListener<Event>, PropertyChangeLis
|
||||||
label.setMandatory(mandatory);
|
label.setMandatory(mandatory);
|
||||||
|
|
||||||
this.setMandatory (mandatory);
|
this.setMandatory (mandatory);
|
||||||
|
this.setReadWrite(!readOnly);
|
||||||
if (readOnly || !updateable)
|
|
||||||
{
|
|
||||||
this.setReadWrite(false);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
this.setReadWrite(true);
|
|
||||||
}
|
|
||||||
|
|
||||||
((HtmlBasedComponent)component).setTooltiptext(description);
|
((HtmlBasedComponent)component).setTooltiptext(description);
|
||||||
label.setTooltiptext(description);
|
label.setTooltiptext(description);
|
||||||
|
|
Loading…
Reference in New Issue