comparison app/controller/grid/PKommentar.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 0a233865a9c3
children
comparison
equal deleted inserted replaced
969:d4603049cd42 970:f4eb53ba63fc
77 /** 77 /**
78 * This function adds a new row to add a PKommentar 78 * This function adds a new row to add a PKommentar
79 */ 79 */
80 add: function(button) { 80 add: function(button) {
81 var record = Ext.create('Lada.model.PKommentar'); 81 var record = Ext.create('Lada.model.PKommentar');
82 record.data.datum = new Date();
82 record.set('probeId', button.up('pkommentargrid').recordId); 83 record.set('probeId', button.up('pkommentargrid').recordId);
83 button.up('pkommentargrid').store.insert(0, record); 84 button.up('pkommentargrid').store.insert(0, record);
84 button.up('pkommentargrid').rowEditing.startEdit(0, 1); 85 button.up('pkommentargrid').rowEditing.startEdit(0, 1);
85 }, 86 },
86 87

http://lada.wald.intevation.org