Read only grid column fix

Is it possible to fix some columns in a read only grid?

  Discussion posts and replies are publicly visible

Parents Reply Children
  • Here you go

    a!localVariables(
      local!items: {
        {item: "Item 1 Dummy"},
        {item: "Item 2 Dummy"},
        {item: "Item 1 Dummy"},
        {item: "Item 2 Dummy"},
        {item: "Item 1 Dummy"},
        {item: "Item 2 Dummy"},
        {item: "Item 1 Dummy"},
        {item: "Item 2 Dummy"},
        {item: "Item 1 Dummy"},
        {item: "Item 2 Dummy"},
        {item: "Item 1 Dummy"},
        {item: "Item 2 Dummy"}
      },
      a!columnsLayout(
        spacing: "NONE",
        columns: {
          a!columnLayout(
            width: "MEDIUM_PLUS",
            contents: a!gridLayout(
              headerCells: {
                a!gridLayoutHeaderCell(label: "Item"),
                a!gridLayoutHeaderCell(label: "Qty"),
                a!gridLayoutHeaderCell(label: "Unit Price")
              },
              rows: {
                a!forEach(
                  items: local!items,
                  expression: a!gridRowLayout(
                    contents: {
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      ),
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      ),
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      )
                    }
                  ),
                )
              },
              rowHeader: 1
            )
          ),
          a!columnLayout(
            contents: a!gridLayout(
              columnConfigs: {
                a!gridLayoutColumnConfig(
                  width: "NARROW_PLUS",
                ),a!gridLayoutColumnConfig(
                  width: "NARROW_PLUS"
                ),a!gridLayoutColumnConfig(
                  width: "NARROW_PLUS"
                ),a!gridLayoutColumnConfig(
                  width: "NARROW_PLUS"
                ),a!gridLayoutColumnConfig(
                  width: "NARROW_PLUS"
                ),a!gridLayoutColumnConfig(
                  width: "NARROW_PLUS"
                ),a!gridLayoutColumnConfig(
                  width: "NARROW_PLUS"
                ),a!gridLayoutColumnConfig(
                  width: "NARROW_PLUS"
                ),a!gridLayoutColumnConfig(
                  width: "NARROW_PLUS"
                )
              },
              headerCells: {
                a!gridLayoutHeaderCell(label: "Item"),
                a!gridLayoutHeaderCell(label: "Qty"),
                a!gridLayoutHeaderCell(label: "Unit Price"),
                a!gridLayoutHeaderCell(label: "Item"),
                a!gridLayoutHeaderCell(label: "Qty"),
                a!gridLayoutHeaderCell(label: "Unit Price"),
                a!gridLayoutHeaderCell(label: "Item"),
                a!gridLayoutHeaderCell(label: "Qty"),
                a!gridLayoutHeaderCell(label: "Unit Price")
              },
              rows: {
                a!forEach(
                  items: local!items,
                  expression: a!gridRowLayout(
                    contents: {
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      ),
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      ),
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      ),
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      ),
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      ),
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      ),
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      ),
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      ),
                      a!textField(
                        readOnly: true,
                        value: local!items[fv!index].item,
                        saveInto: local!items[1].item
                      )
                    }
                  ),
                )
              },
              rowHeader: 1
            )
          )
        }
      )
    )