# HG changeset patch # User Dustin Demuth # Date 1437138630 -7200 # Node ID 13c0e64e1873bb11c1becbac0cb9a57f6573cdb9 # Parent 031b4431b1b8d9f9a5f52bd08a0916a9c32822cb Applied Patch which was presented in the Workshop: Title of a Messung-Window contains more details diff -r 031b4431b1b8 -r 13c0e64e1873 app/view/window/MessungCreate.js --- a/app/view/window/MessungCreate.js Fri Jul 17 15:05:37 2015 +0200 +++ b/app/view/window/MessungCreate.js Fri Jul 17 15:10:30 2015 +0200 @@ -7,7 +7,7 @@ */ /* - * Window to edit a Messung + * Window to create a Messung */ Ext.define('Lada.view.window.MessungCreate', { extend: 'Ext.window.Window', @@ -24,11 +24,26 @@ layout: 'fit', constrain: true, + probe: null, record: null, grid: null, initComponent: function() { - this.title = 'Messung'; + this.probe = this.record; + if (this.probe === null) { + Ext.Msg.alert('Zu der Messung existiert keine Probe!'); + this.callParent(arguments); + return; + } + + var messstelle = Ext.data.StoreManager.get('messstellen') + .getById(this.probe.get('mstId')); + + this.title = 'Neue Messung zu Probe: ' + + this.probe.get('probeIdAlt') + + ' Mst: ' + messstelle.get('messStelle') + + ' hinzufügen.'; + this.buttons = [{ text: 'Schließen', scope: this, diff -r 031b4431b1b8 -r 13c0e64e1873 app/view/window/MessungEdit.js --- a/app/view/window/MessungEdit.js Fri Jul 17 15:05:37 2015 +0200 +++ b/app/view/window/MessungEdit.js Fri Jul 17 15:10:30 2015 +0200 @@ -43,7 +43,16 @@ this.callParent(arguments); return; } - this.title = 'Messung ' + this.record.get('nebenprobenNr'); + + var messstelle = Ext.data.StoreManager.get('messstellen') + .getById(this.probe.get('mstId')); + + this.title = 'Messung: ' + this.record.get('nebenprobenNr') + + ' zu Probe: ' + this.probe.get('probeIdAlt') + + ' Mst: ' + messstelle.get('messStelle') + + ' editieren.'; + + this.buttons = [{ text: 'Schließen', scope: this,