view app/model/Staat.js @ 255:82118c01bc52

#57: Open Edit-Dialog after creating a new Probe.
author Torsten Irländer <torsten.irlaender@intevation.de>
date Wed, 24 Jul 2013 19:14:02 +0200
parents e9fb4814153a
children 5f373d9d55cd
line wrap: on
line source
Ext.define('Lada.model.Staat', {
    extend: 'Ext.data.Model',
    fields: [
        {name: "staatId", type: 'int'},
        {name: "staat"},
        {name: "staatIso"},
        {name: "staatKurz"}
    ],
    idProperty: "staatId",
    proxy: {
        type: 'rest',
        appendId: true, //default
        url: 'server/rest/staat',
        api: {
        },
        reader: {
            type: 'json',
            root: 'data'
        }
    }
});

function ts2date(v, record){
    // Converts a timestamp into a date object.
    return new Date(v);
}

http://lada.wald.intevation.org