hedera-web/forms/account/address/address.js

29 lines
626 B
JavaScript
Raw Normal View History

2018-05-16 15:21:15 +00:00
Hedera.Address = new Class({
Extends: Hedera.Form,
2018-05-16 15:21:15 +00:00
activate: function() {
this.$('model').setInfo('a', 'myAddress', 'hedera', ['id'], 'id');
this.$('model').setDefault('clientFk', 'a',
new Sql.Function({schema: 'account', name: 'myUserGetId'}));
},
2018-05-16 15:21:15 +00:00
onStatusChange: function(form) {
2015-07-10 12:30:08 +00:00
if (form.ready && this.$('address').value == 0)
2018-05-16 15:21:15 +00:00
form.insertRow();
},
2018-05-16 15:21:15 +00:00
onOperationsDone: function() {
Htk.Toast.showMessage(_('AddressChangedSuccessfully'));
this.onReturnClick();
},
2018-05-16 15:21:15 +00:00
onAcceptClick: function() {
this.$('iter').performOperations();
},
2018-05-16 15:21:15 +00:00
onReturnClick: function() {
window.history.back();
}
});