view app/model/Deskriptor.js @ 970:f4eb53ba63fc

Setting Timestamps the correct way. Before this commit the times of the instatiation of the model were used as default values, which led to wrong dates.
author Dustin Demuth <dustin@intevation.de>
date Mon, 16 Nov 2015 11:48:15 +0100
parents 274a843caf44
children f73ca04d73a7
line wrap: on
line source
/**
 *
 */
Ext.define('Lada.model.Deskriptor', {
    extend: 'Ext.data.Model',

    /**
     * Fields are:
     *  - ...
     */
    fields: [{
        name: 'bedeutung'
    }, {
        name: 'beschreibung'
    }, {
        name: 'ebene'
    }, {
        name: 'id'
    }, {
        name: 'sn'
    }, {
        name: 'sXx'
    }],

    idProperty: 'id',

    proxy: {
        type: 'rest',
        url: 'lada-server/deskriptor',
        reader: {
            type: 'json',
            root: 'data',
            totalProperty: 'totalCount'
        }
    }
});

http://lada.wald.intevation.org