1. #11

  2. #12
    Sencha User
    Join Date
    Mar 2007
    Posts
    186
    Vote Rating
    0
    Nullity is on a distinguished road

      0  

    Default


    Quote Originally Posted by JorisA View Post
    I've been looking into this for part of my morning, and I'm not sure there's going to be a real easy way to do it. Adding and expanding the necessary methods in the base Field class is easy enough, but then some of the other classes like TextField, TextArea, and ComboBox override some of those. So, I'd have to override them a second time with the inline stuff.

    So If you can think of a better way, I'd love to hear it; I like this idea too.

  3. #13
    Ext User
    Join Date
    Jul 2007
    Location
    Florida
    Posts
    9,996
    Vote Rating
    6
    mjlecomte will become famous soon enough mjlecomte will become famous soon enough

      0  

    Default


    I'm very new to ext so please excuse me. The sample text editing is excellent. I like that it supports tabbing to get to the next editable text area as well.
    Not knowing exactly what is going on with the request to Escape or having to hit enter to save I would hope that could be made an optional argument for the user to decide. For me, I like the Escape feature to cancel the edit, but instead of Enter to accept I would have preferred "tab". Which leads to my inquiry if this example has or can be incorporated into an editable grid.
    I saw that ext has a nice grid, and that's it's being expanded for ext 2.0. It would be nice if that grid coupled this editing feature such that you could tab through the grid and edit 'grids'. This would almost be like working with Excel.
    I'm not sure how difficult it would be, but would be nice to configure the tabbing order (whether the next tab goes horizontally in the grid row or vertically in the grid column).

  4. #14
    Ext User
    Join Date
    Jun 2007
    Posts
    19
    Vote Rating
    0
    justCharlie is on a distinguished road

      0  

    Default


    I'm very new to JS and Ext, this may be a very n00bish questions, but could anyone give an example how to use this InlineTextField.


    -charlie

  5. #15
    Ext User
    Join Date
    Jun 2007
    Location
    Christchurch, New Zealand
    Posts
    50
    Vote Rating
    0
    sintax.era is on a distinguished road

      0  

    Default


    is there any way to add more parameters to the ajax send?
    for example, id like to send the contact ID of the field im updating...

  6. #16
    Ext User
    Join Date
    Jun 2007
    Location
    Christchurch, New Zealand
    Posts
    50
    Vote Rating
    0
    sintax.era is on a distinguished road

      0  

    Default


    oh ok I just figured it out after trying something i thought id already tried

    contactDisplayFirstName = new Ext.form.InlineTextField({
    autoSave: {url:'test.html',table:'contact',id:100,params:{another:'param'}},
    id: 'firstname',
    fieldLabel:'First Name'
    });

    posts :
    firstname sintax
    another param

  7. #17
    Ext User
    Join Date
    Jun 2007
    Location
    Christchurch, New Zealand
    Posts
    50
    Vote Rating
    0
    sintax.era is on a distinguished road

      0  

    Default


    ive been trying to get a callback function to work for the last day...
    has anyone succeeded in making it go? or am I just still stupid :P

  8. #18
    Sencha User
    Join Date
    Mar 2007
    Posts
    186
    Vote Rating
    0
    Nullity is on a distinguished road

      0  

    Default


    Quote Originally Posted by sintax.era View Post
    ive been trying to get a callback function to work for the last day...
    has anyone succeeded in making it go? or am I just still stupid :P
    It worked for me in testing. Please post the relevant parts of your code.

  9. #19
    Ext User
    Join Date
    Jun 2007
    Location
    Christchurch, New Zealand
    Posts
    50
    Vote Rating
    0
    sintax.era is on a distinguished road

      0  

    Default


    Code:
                        AutoSaveCallBack:function(){
                         console.log('test');
                        }
                        ,
                        DisplayForm:function(){
                        console.log('->ContactDisplay.DisplayForm<-');
                            rec = PMS.dsContact.getById(cid);
     
                            contactDisplayFirstName = new Ext.form.InlineTextField({
                                autoSave:  {
                                url:'php/update.php',
                                callback:PMS.ContactDisplay.AutoSaveCallBack,
                                id:cid,params:{
                                    id:cid,
                                    table:'contact'
                                }},
                                id: 'firstname',
                                fieldLabel:'First Name',
                                value:rec.get('firstname')
                            });
                            form.column({width:'280'},contactDisplayFirstName);
                            form.render('ContactDisplayFormId');
                        }

  10. #20
    Sencha User
    Join Date
    Mar 2007
    Posts
    186
    Vote Rating
    0
    Nullity is on a distinguished road

      0  

    Default


    First post updated to version 1.2 (along with details). sintax.era, this may fix the callback issues you were having.