Results 1 to 3 of 3

Thread: writer example. Which Json response is needed?

  1. #1
    Sencha User
    Join Date
    Jul 2011
    Posts
    29
    Vote Rating
    0
      0  

    Default writer example. Which Json response is needed?

    Hi

    let us consider the http://dev.sencha.com/deploy/ext-4.0...er/writer.html example.

    When I update a cell (say under the column 'last'), I see that the POST data is
    Object { last="new text", id=2}, and the response Json is the entire row
    Code:
    {"success":true,"message":"Updated record","data":{"id":2,"first":"Wilma","last":"new text","email":"wilma@flintstone.com"}}
    .

    I wish to use a similar script (grid+panel), and I am asking how to modify it as to make it possibile to respond just the id+'last' values. On my server side that would be somehow easier.

    If I try, what I get is a empty row, but the two id+'last' values.

    I guess I am asking something trivial, still I need some help
    thks
    mario

  2. #2
    Sencha - Sr Software Engineer mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    39,551
    Vote Rating
    1271
      0  

    Default

    So you only want to respond with the ids?
    Mitchell Simoens @LikelyMitch
    Sencha Inc, Senior Software Engineer
    ________________
    Learn BBCode and use it! Checkout the CODE tag!

    Check out my GitHub, lots of nice things for Ext JS and Sencha Touch
    https://github.com/mitchellsimoens

  3. #3
    Sencha User
    Join Date
    Jul 2011
    Posts
    29
    Vote Rating
    0
      0  

    Default just

    Hi,

    thanks for the reply.

    Let me explain myself better.
    In the case above, I would like to respond just:

    Code:
    {"success":true,"message":"Updated record","data":{"id":2, "last":"new text"}}
    and see the entire row. I am not able to get that.

    thks
    mario


    ps. otherwise it seems I need to do an extra SELECT query -server side-, to get the entire row data again.

Posting Permissions

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