# HG changeset patch # User Raimund Renkert # Date 1456476099 -3600 # Node ID 39b16274977870f640b2b3c366482fef1a13572e # Parent d859fbfc8a53bc424460346d2ddd4ba24440718c# Parent 3ef492b5240b1a886d1e27fc14a9622a38ff46cb merged. diff -r 3ef492b5240b -r 39b162749778 app/controller/Filter.js --- a/app/controller/Filter.js Wed Feb 24 18:24:25 2016 +0100 +++ b/app/controller/Filter.js Fri Feb 26 09:41:39 2016 +0100 @@ -86,11 +86,12 @@ var filters = element.up('panel[name=main]').down('panel[name=filtervariables]'); var filterValues = element.up('panel[name=main]').down('panel[name=filtervalues]'); + var desc = element.up('fieldset').down('displayfield[name=description]'); if (!record[0]) { + desc.setValue(''); return; } // Set "Filter Auswahl" Description - var desc = element.up('fieldset').down('displayfield[name=description]'); desc.setValue(record[0].data.description); this.displayFields = record[0].data.results; @@ -452,6 +453,12 @@ return true; } }); + if (entries.getCount() === 0) { + fav.setValue(false); + entries = store.queryBy(function() { + return true; + }); + } } else { entries = store.queryBy(function() { @@ -473,7 +480,7 @@ var qId = search.getValue(); var query = search.store.getById(qId); var ndx = 0; - for (var i = filters.items.length - 1; i >= 0; i--) { + for (var i = filters.items.items.length - 1; i >= 0; i--) { var filter = filters.items.items[i]; var filterId = filter.filterId; var value = filter.getValue(); @@ -495,7 +502,7 @@ break; } } - if (ndx < filter.items.length - 1) { + if (ndx < filters.items.items.length - 1) { return; } if (query.get('type') === 'probe') { diff -r 3ef492b5240b -r 39b162749778 app/controller/grid/Status.js --- a/app/controller/grid/Status.js Wed Feb 24 18:24:25 2016 +0100 +++ b/app/controller/grid/Status.js Fri Feb 26 09:41:39 2016 +0100 @@ -136,6 +136,9 @@ var record = Ext.create('Lada.model.Status', { messungsId: button.up('statusgrid').recordId }); + if (Ext.data.StoreManager.get('messstellenFiltered').count() === 1) { + record.set('erzeuger', Ext.data.StoreManager.get('messstellenFiltered').getAt(0).get('id')); + } } //Set the Date diff -r 3ef492b5240b -r 39b162749778 app/view/grid/DatensatzErzeuger.js --- a/app/view/grid/DatensatzErzeuger.js Wed Feb 24 18:24:25 2016 +0100 +++ b/app/view/grid/DatensatzErzeuger.js Fri Feb 26 09:41:39 2016 +0100 @@ -120,6 +120,8 @@ } }, { header: i18n.getMsg('letzteAenderung'), + xtype: 'datecolumn', + format: 'd.m.Y H:i', dataIndex: 'letzteAenderung' }]; this.listeners = { diff -r 3ef492b5240b -r 39b162749778 app/view/grid/MessprogrammKategorie.js --- a/app/view/grid/MessprogrammKategorie.js Wed Feb 24 18:24:25 2016 +0100 +++ b/app/view/grid/MessprogrammKategorie.js Fri Feb 26 09:41:39 2016 +0100 @@ -99,6 +99,8 @@ } }, { header: i18n.getMsg('letzteAenderung'), + xtype: 'datecolumn', + format: 'd.m.Y H:i', dataIndex: 'letzteAenderung' }]; this.listeners = { diff -r 3ef492b5240b -r 39b162749778 app/view/grid/Probenehmer.js --- a/app/view/grid/Probenehmer.js Wed Feb 24 18:24:25 2016 +0100 +++ b/app/view/grid/Probenehmer.js Fri Feb 26 09:41:39 2016 +0100 @@ -151,6 +151,8 @@ } }, { header: i18n.getMsg('letzteAenderung'), + xtype: 'datecolumn', + format: 'd.m.Y H:i', dataIndex: 'letzteAenderung' }]; this.listeners = { diff -r 3ef492b5240b -r 39b162749778 app/view/grid/Status.js --- a/app/view/grid/Status.js Wed Feb 24 18:24:25 2016 +0100 +++ b/app/view/grid/Status.js Fri Feb 26 09:41:39 2016 +0100 @@ -104,13 +104,8 @@ displayField: 'messStelle', valueField: 'id', allowBlank: false, - editable: false, - afterRender: function() { - this.superclass.afterRender.apply(this, arguments); - if (this.store.count() === 1) { - this.setValue(this.store.getAt(0)); - } - } + queryMode: 'local', + editable: false }, sortable: false }, {