1. #1
    Sencha - Community Support Team jsakalos's Avatar
    Join Date
    Apr 2007
    Location
    Slovakia
    Posts
    27,509
    Vote Rating
    374
    jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future

      0  

    Default Grid CellActions Plugin

    Grid CellActions Plugin


    Following the Grid RowActions plugin I turned out first version of CellActions.

    To clarify:

    RowActions should be used when we need to operate on a whole grid record.
    CellActions should be used when we need to operate on a single grid cell.

    You can use one, another or both of them in one grid.

    Demo: http://cellactions.extjs.eu

    Note: Code is really beta in this case, not fully documented and not for general production use. I'll give it some lifetime here and then I'll polish it.
    Code is fully documented and well commented now.

    Enjoy!
    Jozef Sakalos, aka Saki

    Education, extensions and services for developers at new http://extjs.eu
    News: Grid Search Plugin, ExtJS 5 Complex Data Binding using MVVM


  2. #2
    Sencha User
    Join Date
    Mar 2007
    Posts
    754
    Vote Rating
    1
    franklt69 is on a distinguished road

      0  

    Default


    Saki I am watching the demo, and work ok but a doubt, will be possible to have for instance a inside the column email (icon + emai@domain.com for each row)?, the idea is the user can watch the email, url or phone to do search ect, but when it click on cell to show a dialog.

    regards
    Frank

  3. #3
    Sencha - Community Support Team jsakalos's Avatar
    Join Date
    Apr 2007
    Location
    Slovakia
    Posts
    27,509
    Vote Rating
    374
    jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future

      0  

    Default


    Yes, it is designed that way. If you click the icon, the handler gets value as one of the arguments. So if you have field with value email@domain.com and email icon beside it and you click the email icon, the handler gets the value email.domain.com and you can do whatever you want with it.
    Jozef Sakalos, aka Saki

    Education, extensions and services for developers at new http://extjs.eu
    News: Grid Search Plugin, ExtJS 5 Complex Data Binding using MVVM


  4. #4
    Sencha - Community Support Team jsakalos's Avatar
    Join Date
    Apr 2007
    Location
    Slovakia
    Posts
    27,509
    Vote Rating
    374
    jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future

      0  

    Default


    Or you mean to place icon(s) to the left of text?
    Jozef Sakalos, aka Saki

    Education, extensions and services for developers at new http://extjs.eu
    News: Grid Search Plugin, ExtJS 5 Complex Data Binding using MVVM


  5. #5
    Sencha User
    Join Date
    Mar 2007
    Posts
    754
    Vote Rating
    1
    franklt69 is on a distinguished road

      0  

    Default


    Yes I want to said to place the icon(s) to the left of text, the reason Saki is the user can browse the (email, phone, url and watch it) if the user want to do send a email click in this cell and appear the mail app, the same with the phone, ect, I have doubt now if is better only to show the email, phone url ect with a link in the cell email@domain.com, maybe is more expense to show the icon + link in the cell, what do you think, could be it optional?

    regards
    Frank

  6. #6
    Sencha - Community Support Team jsakalos's Avatar
    Join Date
    Apr 2007
    Location
    Slovakia
    Posts
    27,509
    Vote Rating
    374
    jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future

      0  

    Default


    If you want only link, then you don't need CellActions a custom renderer is sufficient. E.g.:
    PHP Code:
    renderer = function(val) {
        return 
    '<a href="mailto:' val '">' val '</a>';

    or something like that.

    CellActions are designed to be lightweight so the performance penalty of using it shouldn't be big. Placing icons at the left of text is not implemented yet, do you want it?
    Jozef Sakalos, aka Saki

    Education, extensions and services for developers at new http://extjs.eu
    News: Grid Search Plugin, ExtJS 5 Complex Data Binding using MVVM


  7. #7
    Sencha User
    Join Date
    Mar 2007
    Posts
    754
    Vote Rating
    1
    franklt69 is on a distinguished road

      0  

    Default


    Saki using
    PHP Code:
    renderer = function(val) {
        return 
    '<a href="mailto:' val '">' val '</a>';

    open the default mail client, when click on this cell, but remember it could be a web phone voice ip or an map app to fields like address, (dialog or app done with ext) so here cellAction will be very useful, I think the better will be have the options to show:
    icon + text (and the text formated) the developer decide if only want icon or text ect inside the cell.

    regards
    Frank

  8. #8
    Sencha - Community Support Team jsakalos's Avatar
    Join Date
    Apr 2007
    Location
    Slovakia
    Posts
    27,509
    Vote Rating
    374
    jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future jsakalos has a brilliant future

      0  

    Default


    Frank, take a look at the demo now. Icons are (temporarily, only for you ) at the left sice of cells. Is that what you want?
    Jozef Sakalos, aka Saki

    Education, extensions and services for developers at new http://extjs.eu
    News: Grid Search Plugin, ExtJS 5 Complex Data Binding using MVVM


  9. #9
    Ext User
    Join Date
    Apr 2007
    Location
    London, UK
    Posts
    50
    Vote Rating
    0
    Lucian is on a distinguished road

      0  

    Default Thanks

    Thanks


    Quote Originally Posted by jsakalos View Post
    Frank, take a look at the demo now. Icons are (temporarily, only for you ) at the left sice of cells. Is that what you want?
    Lucian here...this is what I want, thank you very much. I also added support for mouseover/mouseout events by modifying the main file. Anybody interested?...

  10. #10
    Sencha User
    Join Date
    Mar 2007
    Posts
    754
    Vote Rating
    1
    franklt69 is on a distinguished road

      0  

    Default


    Saki this is what I want, thanks again

    regards
    Frank