1. #1
    Sencha User
    Join Date
    May 2010
    Location
    Dallas, TX
    Posts
    68
    Vote Rating
    1
    Answers
    6
    rkanemeier is on a distinguished road

      0  

    Default Answered: RadioGroup Inside Grid Cell?

    Answered: RadioGroup Inside Grid Cell?


    I've been looking for an example of putting a radio group inside a grid cell (approve or deny a record). I found a progress bar that seems promising, but i cannot seem to make it work. So my first question is, is it even possible to put a radio group inside a grid cell? If so, does anyone have a suggestion that will push me in the right direction? I'm going to want this thing to fire an immediate ajax request to update a database file when they click approve or deny.

  2. Ok,

    I'm actually getting better at researching ExtJS stuff. I forgot to include the css link:

    Code:
    <link rel="stylesheet" type="text/css" href="/extjs4/examples/ux/css/CheckHeader.css" />
    Now I can code 2 columns: approve, deny. Then, when one is selected, I "should" be able to listen to that event then turn the other value off? /fingers-crossed

  3. #2
    Sencha User
    Join Date
    May 2010
    Location
    Dallas, TX
    Posts
    68
    Vote Rating
    1
    Answers
    6
    rkanemeier is on a distinguished road

      0  

    Default


    Ok, so I may have found a potential solution using /example/ux/checkcolumn.js. However, it does not render a checkbox.

    Code:
    <script type="text/javascript" src="/extjs4/examples/ux/checkcolumn.js"></script>
    
    ...
    
        var myGrid = Ext.create('Ext.grid.Panel', {
            region: 'center',
            title: 'My Grid',
            store: myStore,
            autoScroll: true,
            loadMask: true,
            stripeRows: true,
            columns: [{
    .....
                xtype: 'checkcolumn',
                //header: "<b>Approval</b>",
                text: "<b>Approval</b>",
                flex: 1,
                sortable: false,
                draggable: false,
                width: 75,
                dataIndex: 'MYAPPROVE'
            }],
    This code does not seem to add an actual checkbox. The grid does respond by putting the red triangle in the upper left hand corner of the cell when you click on it. Any ideas?

  4. #3
    Sencha User
    Join Date
    May 2010
    Location
    Dallas, TX
    Posts
    68
    Vote Rating
    1
    Answers
    6
    rkanemeier is on a distinguished road

      0  

    Default


    Ok,

    I'm actually getting better at researching ExtJS stuff. I forgot to include the css link:

    Code:
    <link rel="stylesheet" type="text/css" href="/extjs4/examples/ux/css/CheckHeader.css" />
    Now I can code 2 columns: approve, deny. Then, when one is selected, I "should" be able to listen to that event then turn the other value off? /fingers-crossed