comparison app/controller/form/Messung.js @ 693:817524db4017

Readonly was missing
author Dustin Demuth <dustin@intevation.de>
date Thu, 26 Mar 2015 15:54:50 +0100
parents aedf0709af92
children d6ef146e1a9f
comparison
equal deleted inserted replaced
692:c31644b3d445 693:817524db4017
55 button.up('toolbar').down('button[action=discard]') 55 button.up('toolbar').down('button[action=discard]')
56 .setDisabled(true); 56 .setDisabled(true);
57 formPanel.getForm().loadRecord(formPanel.getForm().getRecord()); 57 formPanel.getForm().loadRecord(formPanel.getForm().getRecord());
58 var json = response.request.scope.reader.jsonData; 58 var json = response.request.scope.reader.jsonData;
59 if (json) { 59 if (json) {
60 formPanel.setMessages(json.errors, json.warnings); 60 if(json.errors.totalCount > 0 || json.warnings.totalCount > 0) {
61 formPanel.setMessages(json.errors, json.warnings);
62 }
63
64 if(json.message){
65 Ext.Msg.alert(Lada.getApplication().bundle.getMsg('errmsgtitle'), Lada.getApplication().bundle.getMsg(json.message));
66 }
61 } 67 }
62 } 68 }
63 }); 69 });
64 console.log('save');
65 }, 70 },
66 71
67 discard: function(button) { 72 discard: function(button) {
68 var formPanel = button.up('form'); 73 var formPanel = button.up('form');
69 formPanel.getForm().loadRecord(formPanel.getForm().getRecord()); 74 formPanel.getForm().loadRecord(formPanel.getForm().getRecord());

http://lada.wald.intevation.org