Results 1 to 10 of 20

Thread: [SOLVED] Is there a way to do a nested grid or grid within a cell?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Ext GWT Premium Member icfantv's Avatar
    Join Date
    Sep 2011
    Location
    Superior, CO
    Posts
    413
    Answers
    20
    Vote Rating
    21
      0  

    Question Unanswered: [SOLVED] Is there a way to do a nested grid or grid within a cell?

    In our legacy code grid, we have cells in a column that can have multiple lines of anchor tags with each link operating on the specific linked text (pop a dialog, navigate to a new page, whatever...).

    The ClickableTextCell won't work here because it applies to an entire cell. What I'd like to be able to do is render a vertical list of clickable text cells in a single grid cell or a nested grid inside a single grid cell but don't see any way to do this.

    Does anyone know how I might accomplish this or an example somewhere? Thanks.

    --adam

  2. #2
    Sencha Premium Member
    Join Date
    Sep 2007
    Posts
    13,976
    Answers
    60
    Vote Rating
    132
      0  

    Default

    What I'd like to be able to do is render a vertical list of clickable text cells in
    Wouldnt CompositeCell work for you?

  3. #3
    Ext GWT Premium Member icfantv's Avatar
    Join Date
    Sep 2011
    Location
    Superior, CO
    Posts
    413
    Answers
    20
    Vote Rating
    21
      0  

    Default

    *looks sheepishly downward*

    Ja.*

    * - Aber, Ich weiss nicht das es war da.

  4. #4
    Ext GWT Premium Member icfantv's Avatar
    Join Date
    Sep 2011
    Location
    Superior, CO
    Posts
    413
    Answers
    20
    Vote Rating
    21
      0  

    Question

    So, it's not exactly clear how I get the list of HasCell to the constructor.

    I.e., if I have:
    Code:
        ColumnConfig<MyBean, MyBean> myCol =
          new ColumnConfig<MyBean, MyBean>(new IdentityValueProvider<MyBean>(), 100, "My Col");
        productCol.setCell(new CompositeCell<MyBean>(...));
    MyBean has a getter that returns List<String> - I would need to create, say, a ClickableTextCell for each of these, add them to a list and get that list to the constructor (marked with the ellipsis above).

    It's not at all clear how to create this. I'm using GXT's PropertyAccess interface to provide the values for the columns.

  5. #5
    Sencha Premium Member
    Join Date
    Sep 2007
    Posts
    13,976
    Answers
    60
    Vote Rating
    132
      0  

    Default

    HasCell is just an interface. You can simple create an "instance" from it and make it return your "inner" cell.

  6. #6
    Ext GWT Premium Member icfantv's Avatar
    Join Date
    Sep 2011
    Location
    Superior, CO
    Posts
    413
    Answers
    20
    Vote Rating
    21
      0  

    Default

    Right, but the instances would need to each provide a corresponding value from the list of strings off of my bean. A list I don't have because we are dealing with the class type and not an instance type when we are defining the column config.

    Is there a way you can provide a generic example, please? Thanks.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •