Results 1 to 4 of 4

Thread: Proxy appendId adds duplicate / double id

  1. #1
    Sencha Premium User
    Join Date
    Jun 2012
    Posts
    212
    Answers
    13
    Vote Rating
    3
      0  

    Default Proxy appendId adds duplicate / double id

    To add parameters to an API query, I use the url path as well as the query string. Url only would be

    /cust/prod/123?_dc=123456789

    As soon as I add extraParams in the proxy config, I get something like this

    /cust/prod/123?_dc=123456789&someparam=sth&id=123

    Is the duplicate id in there something avoidable or desirable?

    Thanks!

  2. #2
    Sencha User mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    40,026
    Answers
    3976
    Vote Rating
    1367
      0  

    Default

    It's two different things. The Rest proxy will add the id and not look at the params.
    Mitchell Simoens @LikelyMitch
    Modus Create, Senior Frontend Engineer
    ________________
    Need any sort of Ext JS help? Modus Create is here to help!

    Check out my GitHub:
    https://github.com/mitchellsimoens

  3. #3
    Sencha Premium User
    Join Date
    Jun 2012
    Posts
    212
    Answers
    13
    Vote Rating
    3
      0  

    Default

    Sorry, I don't properly understand what you mean.
    With two Ids in there, my API controller can grab the same value from two different variables and I guess this redundancy is not intended by design.

    With appendId = true, if I don't set the extraParams, the id is added to the URL path only. As soon as I add any extraParams, I have it in the URL path and the query string at the same time. Both ids are added automatically.
    With appendId = false, there is no id appended.

    Does that make sense?

  4. #4
    Sencha Premium User
    Join Date
    Jun 2012
    Posts
    212
    Answers
    13
    Vote Rating
    3
      0  

    Default

    Maybe I better change my question:

    Can I avoid that the id is added to the params string when I have it already in the URL path?

Posting Permissions

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