comparison app/model/MKommentar.js @ 179:f1f0351b6e2f

Show List of Messungskommentare
author Torsten Irländer <torsten.irlaender@intevation.de>
date Thu, 04 Jul 2013 12:21:25 +0200
parents 0b635b836903
children 8970cbad6cae
comparison
equal deleted inserted replaced
178:c53f3110852e 179:f1f0351b6e2f
1 Ext.define('Lada.model.MKommentar', { 1 Ext.define('Lada.model.MKommentar', {
2 extend: 'Ext.data.Model', 2 extend: 'Ext.data.Model',
3 fields: [ 3 fields: [
4 {name: "kId"}, 4 {name: "id"},
5 {name: "messungsId"}, 5 {name: "messungsId"},
6 {name: "probeId"}, 6 {name: "probeId"},
7 {name: "erzeuger"}, 7 {name: "erzeuger"},
8 {name: "kdatum", type: 'date', convert: ts2date, defaultValue: new Date()}, 8 {name: "kdatum", type: 'date', convert: ts2date, defaultValue: new Date()},
9 {name: "ktext"} 9 {name: "ktext"}
10 ], 10 ],
11 idProperty: "kId", 11 idProperty: "id",
12 proxy: { 12 proxy: {
13 type: 'rest', 13 type: 'rest',
14 appendId: true, //default 14 appendId: true, //default
15 url: 'server/rest/messkommentare', 15 url: 'server/rest/messkommentare',
16 reader: { 16 reader: {
17 type: 'json', 17 type: 'json',
18 root: 'data' 18 root: 'data'
19 } 19 }
20 }, 20 },
21 getEidi: function() { 21 getEidi: function() {
22 var kid = this.get('kId'); 22 var kid = this.get('id.kid');
23 var messId = this.get('messungsId'); 23 var messId = this.get('messungsId');
24 var probeId = this.get('probeId'); 24 var probeId = this.get('probeId');
25 return "/" + kid + "/" + messId + "/" + probeId; 25 return "/" + kid + "/" + messId + "/" + probeId;
26 } 26 }
27 }); 27 });

http://lada.wald.intevation.org