Mercurial > lada > lada-client
comparison app/model/Zusatzwert.js @ 106:b91d5376db19
Load Zusatzwerte from server
author | Torsten Irländer <torsten.irlaender@intevation.de> |
---|---|
date | Tue, 18 Jun 2013 14:02:48 +0200 |
parents | |
children | 189a93e31be9 |
comparison
equal
deleted
inserted
replaced
105:7ad96e3d70c1 | 106:b91d5376db19 |
---|---|
1 Ext.define('Lada.model.Zusatzwert', { | |
2 extend: 'Ext.data.Model', | |
3 fields: [ | |
4 {name: "id"}, | |
5 {name: "convertedId", convert:buildId}, | |
6 {name: "probeId"}, | |
7 {name: "messwertNwg"}, | |
8 {name: "messwertPzs"}, | |
9 {name: "messfehler"}, | |
10 {name: "mehId"}, | |
11 {name: "letzteAenderung"}, | |
12 {name: "sprobenZusatz"}, | |
13 {name: "pzsId"}, | |
14 {name: "beschreibung"}, | |
15 {name: "zusatzwert"}, | |
16 {name: "eudfKeyword"} | |
17 ], | |
18 idProperty: "convertedId", | |
19 proxy: { | |
20 type: 'rest', | |
21 appendId: true, //default | |
22 url: 'server/rest/zusatzwert', | |
23 reader: { | |
24 type: 'json', | |
25 root: 'data' | |
26 } | |
27 } | |
28 }); | |
29 | |
30 function buildId(v, record){ | |
31 return record.get('probeId') + record.get('pzsId'); | |
32 } |