Mercurial > lada > lada-client
comparison app/view/widgets/LadaForm.js @ 74:5c58c0e8936b
Add function which translates the errorcodes returned from the server.
author | Torsten Irländer <torsten.irlaender@intevation.de> |
---|---|
date | Wed, 05 Jun 2013 18:04:07 +0200 |
parents | fcb63271d1bd |
children | 4a82e28dfcc4 |
comparison
equal
deleted
inserted
replaced
73:7661f09466cc | 74:5c58c0e8936b |
---|---|
84 this.fireEvent('loadsuccess', this, record, operation); | 84 this.fireEvent('loadsuccess', this, record, operation); |
85 }, | 85 }, |
86 | 86 |
87 onModelLoadFailure: function(record, operation) { | 87 onModelLoadFailure: function(record, operation) { |
88 this.fireEvent('loadfailure', this, record, operation); | 88 this.fireEvent('loadfailure', this, record, operation); |
89 }, | |
90 | |
91 translateReturnCodes: function(codes) { | |
92 var translated = {}; | |
93 for (var k in codes) { | |
94 translated[k] = Lada.getApplication().bundle.getMsg(codes[k]); | |
95 } | |
96 return translated; | |
89 } | 97 } |
90 | 98 |
91 }); | 99 }); |