comparison app/model/Zusatzwert.js @ 142:dee9da79f055

Added function to model with return the beschreibung of the messeinheit of a given Probenzusatzwert by pzsId.
author Torsten Irländer <torsten.irlaender@intevation.de>
date Fri, 28 Jun 2013 11:15:39 +0200
parents 4287f29b5b81
children 51897f9a6bbb
comparison
equal deleted inserted replaced
141:1fb79e16149f 142:dee9da79f055
24 }, 24 },
25 getEidi: function () { 25 getEidi: function () {
26 var pzsId = this.get('pzsId'); 26 var pzsId = this.get('pzsId');
27 var probeId = this.get('probeId'); 27 var probeId = this.get('probeId');
28 return "/" + pzsId + "/" + probeId; 28 return "/" + pzsId + "/" + probeId;
29 },
30 getMesseinheit: function(pzsId) {
31 var zstore = Ext.getStore('Probenzusatzwerte');
32 var mstore = Ext.getStore('Messeinheit');
33 var mehId = zstore.getById(pzsId).get('mehId');
34 var record = mstore.findRecord('mehId', mehId);
35 return record.get('einheit');
29 } 36 }
30 }); 37 });
31 38
32 function buildId(v, record){ 39 function buildId(v, record){
33 return record.get('probeId') + ',' + record.get('pzsId'); 40 return record.get('probeId') + ',' + record.get('pzsId');

http://lada.wald.intevation.org