mirror of
https://gitee.com/jmix/cuba.git
synced 2024-12-03 19:57:36 +08:00
PL-9044 Generated column in table is not editable if Table editable = false
This commit is contained in:
parent
b77968c5ee
commit
bf9b9814d1
@ -225,8 +225,8 @@ public abstract class DesktopAbstractField<C extends JComponent> extends Desktop
|
||||
this.editable = editable;
|
||||
|
||||
boolean parentEditable = true;
|
||||
if (parent instanceof Editable) {
|
||||
parentEditable = ((Editable) parent).isEditable();
|
||||
if (parent instanceof ChildEditableController) {
|
||||
parentEditable = ((ChildEditableController) parent).isEditable();
|
||||
}
|
||||
boolean finalEditable = parentEditable && editable;
|
||||
|
||||
|
@ -507,6 +507,12 @@ public interface Component {
|
||||
void setEditable(boolean editable);
|
||||
}
|
||||
|
||||
/**
|
||||
* Component that manages editable property of child components.
|
||||
*/
|
||||
interface ChildEditableController extends Editable {
|
||||
}
|
||||
|
||||
/**
|
||||
* Event that is fired when "editable" property of Editable component has been changed.
|
||||
*/
|
||||
|
@ -29,7 +29,7 @@ import java.util.Map;
|
||||
*/
|
||||
public interface FieldGroup extends Component, Component.BelongToFrame, Component.HasCaption, Component.HasIcon,
|
||||
Component.HasBorder, Component.Editable, Component.Validatable,
|
||||
Component.EditableChangeNotifier {
|
||||
Component.EditableChangeNotifier, Component.ChildEditableController {
|
||||
String NAME = "fieldGroup";
|
||||
|
||||
/**
|
||||
|
@ -269,8 +269,8 @@ public abstract class WebAbstractField<T extends com.vaadin.ui.AbstractField>
|
||||
this.editable = editable;
|
||||
|
||||
boolean parentEditable = true;
|
||||
if (parent instanceof Editable) {
|
||||
parentEditable = ((Editable) parent).isEditable();
|
||||
if (parent instanceof ChildEditableController) {
|
||||
parentEditable = ((ChildEditableController) parent).isEditable();
|
||||
}
|
||||
boolean finalEditable = parentEditable && editable;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user