Visible / hidden / editable flags do nothing


Hi, is are there any working examples of visible / hidden / editable flags for form and grid fields? The following codes, despite appearing in the userguide and source files, do not work:

$this->addField('TEST', [
  'caption' => 'here is my caption', 
  'ui'   => ['editable' => false, 'visible' => false, 'hidden' => true]
]);  /* the field is required and shows my caption, but is editable and visible  */

$myModel->getElement(‘TEST’)->ui[‘visible’] = false; /* field is still visible */

Thank you,


Field visibility logic is one area which can be better defined.

The logic is mainly outlined here:

but it’s presence in the atk4/data is questionable. Perhaps there should be a mechanism in UI that determines if fields should appear on certain component.

The best way to work-around is simply to specify list of fields to your Grid/Form during setModel().

Another rule is that system fields are not displayed by default.

The rest deserves a bit of a “refactor”. Perhaps after we’re done with the fields here:


I tried using a subset of fields in setModel() but that prevented them from appearing in the modal editing form. I was wanting to assign hidden + editable properties to a field, so that it would not appear in the grid but would appear when editing, as per I do understand though that thread was written regarding the old Agile Toolkit though :slight_smile:


When using CRUD:

editable - field is editable in form
visible - field is visible in grid

So if you want field which is not visible in grid, but is editable in form, then: visible=false, editable=true.


actually, you can define set of field for editing adding and listing separately.


Works perfectly! Thank you! :slight_smile: