Success! Looks like we've fixed this one. According to our records the fix was applied for EXTGWT-2065 in a recent build.
  1. #1
    Sencha User
    Join Date
    Mar 2012
    Posts
    39
    Vote Rating
    0
    rmulcha is on a distinguished road

      0  

    Default CheckBoxSelectionModel not showing up in the grid header

    CheckBoxSelectionModel not showing up in the grid header


    Hello There..,


    I am using gxt-3.0.0.jar and trying a checkbox selection model. And somehow the select all checkbox is not showing up in the header, I see that it was working fine on the explorer demo. Not sure if I am missing something or there is a bug with the jar that took, pls help.

    Here is the code.
    final NumberFormat number = NumberFormat.getFormat("0.00");IdentityValueProvider<Stock> identity = new IdentityValueProvider<Stock>(); final CheckBoxSelectionModel<Stock> sm = new CheckBoxSelectionModel<Stock>(identity);ColumnConfig<Stock, String> nameCol = new ColumnConfig<Stock, String>(props.name(), 50, "Company");ColumnConfig<Stock, String> symbolCol = new ColumnConfig<Stock, String>(props.symbol(), 100, "Symbol");ColumnConfig<Stock, Double> lastCol = new ColumnConfig<Stock, Double>(props.last(), 75, "Last");ColumnConfig<Stock, Double> changeCol = new ColumnConfig<Stock, Double>(props.change(), 100, "Change");changeCol.setCell(new AbstractCell<Double>() {@Override
    publicvoid render(Context context, Double value, SafeHtmlBuilder sb) {String style = "style='color: " + (value < 0 ? "red" : "green") + "'";String v = number.format(value);sb.appendHtmlConstant("<span " + style + " qtitle='Change' qtip='" + v + "'>" + v + "</span>");}});ColumnConfig<Stock, Date> lastTransCol = new ColumnConfig<Stock, Date>(props.lastTrans(), 100, "Last Updated");lastTransCol.setCell(new DateCell(DateTimeFormat.getFormat("MM/dd/yyyy")));List<ColumnConfig<Stock, ?>> l = new ArrayList<ColumnConfig<Stock, ?>>();l.add(sm.getColumn());l.add(nameCol);l.add(symbolCol);l.add(lastCol);l.add(changeCol);l.add(lastTransCol);ColumnModel cm = new ColumnModel<Stock>(l);ListStore<Stock> store = new ListStore<Stock>(props.key());store.addAll(TestData.getStocks());Grid<Stock> grid = new Grid<Stock>(store, cm);grid.setSelectionModel(sm);getView().setGrid(grid);
    grid.getView().setAutoExpandColumn(nameCol);


    Response:

    grid.jpg

    Attached Images

  2. #2
    Sencha User WesleyMoy's Avatar
    Join Date
    Oct 2009
    Location
    Redwood City, California
    Posts
    402
    Vote Rating
    2
    WesleyMoy is on a distinguished road

      0  

    Default


    I don't see the checkbox you're describing in the Explorer demo. Do you mean this example? http://sencha.com/examples/#ExamplePlace:checkboxgrid

    Nevertheless, I've filed this against the team to add or determine how to implement such a select-all checkbox.

  3. #3
    Ext GWT Premium Member
    Join Date
    Aug 2010
    Location
    Germany, Solingen
    Posts
    238
    Vote Rating
    2
    gishmo is on a distinguished road

      0  

    Default


    The select all box was removed with the final version of GXT 3.0.0.

    http://www.sencha.com/forum/showthre...-CheckBox-Grid

  4. #4
    Sencha User
    Join Date
    Mar 2012
    Posts
    39
    Vote Rating
    0
    rmulcha is on a distinguished road

      0  

    Default


    I was looking at this link http://sencha.com/examples-dev/#Exam...e:checkboxgrid . And yes I was talking about Select All Check Box, this is kind of a very basic requirement for us, please confirm.

  5. #5
    Ext GWT Premium Member
    Join Date
    Jun 2011
    Posts
    9
    Vote Rating
    0
    dierp is on a distinguished road

      0  

    Default


    I can confirm that the checkbox was present in all the beta releases up to at least RC1. It vanished with either the RC2 or final release.

  6. #6
    Sencha Premium Member
    Join Date
    Feb 2011
    Posts
    48
    Vote Rating
    -3
    sblommers is infamous around these parts

      0  

    Default Fix / Hack

    Fix / Hack


    1) Grab 3.0.0b from maven

    or:

    2)
    Add
    Code:
    <groupId>com.googlecode.gwtquery</groupId>
    <artifactId>gwtquery</artifactId>
    <version>1.1.0</version>
    to pom.xml

    and add
    Code:
    <inherits name='com.google.gwt.query.Query'/>
    to your *.gwt.xml

    and add
    Code:
            // This fixes the invisible checkbox to select all in the grid using Jquery, fix underway by Sencha
            grid.getLoader().addLoadHandler(new LoadHandler() {
                @Override
                public void onLoad(LoadEvent event) {
                    $(".x-grid-td-checker").css(CSS.HEIGHT.with(Length.px(22)));
                }    
            });
    in your grid loading code

  7. #7
    Sencha User
    Join Date
    Mar 2012
    Posts
    39
    Vote Rating
    0
    rmulcha is on a distinguished road

      0  

    Default


    I don't use maven, should I add any jars? Pls provide details for ant aswell

  8. #8
    Sencha Premium Member
    Join Date
    Feb 2011
    Posts
    48
    Vote Rating
    -3
    sblommers is infamous around these parts

      0  

    Default


    Quote Originally Posted by rmulcha View Post
    I don't use maven, should I add any jars? Pls provide details for ant aswell
    Then add jars, zippy is here: https://maven.sencha.com/repo//gxt-gpl-release/com/sencha/gxt/gxt-release/3.0.0b/gxt-release-3.0.0b.zip

    Get GwtQuery at http://code.google.com/p/gwtquery/

    I do recommend using the gxt releases but 3.0.0b has some bugs like cell bleed.

    Good luck

    Note: add import static com.google.gwt.query.client.GQuery.$; (eclipse doesn't pick that one up from your dependencies)

  9. #9
    Sencha Premium Member
    Join Date
    Feb 2011
    Posts
    48
    Vote Rating
    -3
    sblommers is infamous around these parts

      0  

    Default 3.0.0 bleeds also but only firefox when scaling

    3.0.0 bleeds also but only firefox when scaling


    I just realized that 3.0.0b is fine except for firefox when scaling but that bug is in 3.0.0 also so don't bother going for the jQuery solution go straight to 3.0.0b

  10. #10
    Sencha User
    Join Date
    May 2012
    Posts
    6
    Vote Rating
    0
    klimeryk is on a distinguished road

      0  

    Default


    This missing basic functionality is also bothering us...
    Here's a solution not requiring any external dependencies:
    Code:
    grid.addViewReadyHandler(new ViewReadyHandler() {
        @Override
        public void onViewReady(ViewReadyEvent event) {
            XElement checker = grid.getView().getHeader().getElement().child(".x-grid-td-checker");
            checker.getStyle().setHeight(22, Unit.PX);
        }
    });

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar