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

43 lines
687 B
JavaScript
Raw Normal View History

2015-07-23 15:58:48 +00:00
Vn.AddressList = new Class
({
Extends: Vn.Form
2015-07-23 15:58:48 +00:00
,activate: function ()
{
this.$('user-model').setInfo ('c', 'customer_view', 'hedera');
this.$('addresses').setInfo ('a', 'address_view', 'hedera');
}
,onAddAddressClick: function ()
{
this.hash.set ({
'form': 'account/address',
'address': 0
});
}
,onReturnClick: function ()
{
window.history.back();
}
,onRemoveAddressClick: function (button, form)
{
if (confirm (_('AreYouSureDeleteAddress')))
{
form.set ('active', false);
form.refresh ();
}
}
,onEditAddressClick: function (button, form)
{
this.hash.set ({
'form': 'account/address',
'address': form.get ('id')
});
}
});