Skip to content

Hidden

Hidden is invisible technical component that allows to send field value to frontend

Basics

Live Sample · GitHub

How does it look?

img_list.png

img_info.png

img_form.png

How to add?

Example

Step1 Add String field to corresponding DataResponseDTO.

@Entity
@Table(name = "HiddenBasic")
@Getter
@Setter
@NoArgsConstructor
public class HiddenBasic extends BaseEntity {

    private String customField;

}

Step2 Add String field to corresponding BaseEntity.

@Getter
@Setter
@NoArgsConstructor
public class HiddenBasicDTO extends DataResponseDTO {

    private String customField;

    public HiddenBasicDTO(HiddenBasic entity) {
        this.id = entity.getId().toString();
        this.customField = entity.getCustomField();
    }

}

Step3 Add to .widget.json.

{
  "name": "HiddenBasicList",
  "title": "List title",
  "type": "List",
  "bc": "hiddenBasic",
  "fields": [
    {
      "title": "custom Field",
      "key": "customField",
      "type": "hidden"
    }
  ]
}

Step3 Add to .widget.json.

{
  "name": "HiddenBasicInfo",
  "title": "Info title",
  "type": "Info",
  "bc": "hiddenBasic",
  "fields": [
    {
      "label": "custom Field",
      "key": "customField",
      "type": "hidden"
    }
  ],
  "options": {
    "layout": {
      "rows": [
        {
          "cols": [
          ]
        }
      ]
    }
  }
}

Step3 Add to .widget.json.

{
  "name": "HiddenBasicForm",
  "title": "Form title",
  "type": "Form",
  "bc": "hiddenBasic",
  "fields": [
    {
      "label": "custom Field",
      "key": "customField",
      "type": "hidden"
    }
  ],
  "options": {
    "layout": {
      "rows": [
        {
          "cols": [
          ]
        }
      ]
    }
  }
}

Placeholder

not applicable

Color

not applicable

Readonly/Editable

not applicable

Filtering

not applicable

Drilldown

not applicable

Validation

not applicable

Sorting

not applicable

Required

not applicable