comparison app/controller/grid/MKommentar.js @ 970:f4eb53ba63fc

Setting Timestamps the correct way. Before this commit the times of the instatiation of the model were used as default values, which led to wrong dates.
author Dustin Demuth <dustin@intevation.de>
date Mon, 16 Nov 2015 11:48:15 +0100
parents 1f1467713c3f
children
comparison
equal deleted inserted replaced
969:d4603049cd42 970:f4eb53ba63fc
76 /** 76 /**
77 * This function adds a new row to add a MKommentar 77 * This function adds a new row to add a MKommentar
78 */ 78 */
79 add: function(button) { 79 add: function(button) {
80 var record = Ext.create('Lada.model.MKommentar'); 80 var record = Ext.create('Lada.model.MKommentar');
81 record.data.datum = new Date();
81 record.set('messungsId', button.up('mkommentargrid').recordId); 82 record.set('messungsId', button.up('mkommentargrid').recordId);
82 button.up('mkommentargrid').store.insert(0, record); 83 button.up('mkommentargrid').store.insert(0, record);
83 button.up('mkommentargrid').rowEditing.startEdit(0, 1); 84 button.up('mkommentargrid').rowEditing.startEdit(0, 1);
84 }, 85 },
85 86

http://lada.wald.intevation.org