Hybrid View

  1. #1
    Sencha User
    Join Date
    Feb 2011
    Posts
    6
    Vote Rating
    0
    nferreira is on a distinguished road

      0  

    Default Answered: Ext.data.proxy.Ajax issue

    Answered: Ext.data.proxy.Ajax issue


    Hi All,

    I have a Model and I have configured a Ajax proxy to handle its remote operations.

    Code fragment from the model:

    Code:
    ...
        proxy: {
            type: 'ajax',
            url: 'services/timeband.php?action=delete',
            reader: {
                    root: 'timebands',
                    totalProperty: 'total'
            },
            api: {
                create: 'services/timeband.php?action=create',
                read: 'services/timeband.php?action=read',
                update: 'services/timeband.php?action=update',
                delete: 'services/timeband.php?action=delete',
            }
        },
    ...
    Initially, I have not used a url property as I wanted to define specific url for all specific APIs.

    The create, read and update work just fine, but when I try to delete a record, it raises an error stating that I can not do it without defining the url property.

    Therefore, I have set the url just to handle the delete operation.

    What is wrong?

    Regards
    Nad

  2. Delete is a keyword in JS, we use "destroy" for that parameter.

    See: http://docs.sencha.com/ext-js/4-1/#!...Server-cfg-api

  3. #2
    Sencha - Ext JS Dev Team evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    16,103
    Answers
    343
    Vote Rating
    500
    evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute

      1  

    Default


    Delete is a keyword in JS, we use "destroy" for that parameter.

    See: http://docs.sencha.com/ext-js/4-1/#!...Server-cfg-api
    Evan Trimboli
    Sencha Developer
    Twitter - @evantrimboli
    Don't be afraid of the source code!

  4. #3
    Sencha User
    Join Date
    Feb 2011
    Posts
    6
    Vote Rating
    0
    nferreira is on a distinguished road

      0  

    Default


    Ops! Sorry, my mistake! Now it is working.

    Thanks,
    Nad

Thread Participants: 1

Tags for this Thread

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar