Browse Source

Conditional Native button enable/disable in add coin dialog box

master
Satinder Grewal 8 years ago
parent
commit
1d7b607ea2
  1. 16
      assets/scripts/dashboard.js
  2. 9
      assets/scripts/login.js

16
assets/scripts/dashboard.js

@ -305,9 +305,19 @@ var Dashboard = function() {
} }
var handleWalletWidgetBtns = function() { var handleWalletWidgetBtns = function() {
$('.mdl_addcoin_done_btn').click(function(){ $('#addcoin_mdl_native_mode').prop('disabled', true);
ExecuteAddCoinFn();
}); $('.mdl_addcoin_done_btn').click(function(){
ExecuteAddCoinFn();
});
$( "#addcoin_select_coin_mdl_options" ).change(function() {
if ($('#addcoin_select_coin_mdl_options').val() == 'KMD') {
$('#addcoin_mdl_native_mode').prop('disabled', false);
} else {
$('#addcoin_mdl_native_mode').prop('disabled', true);
}
});
} }

9
assets/scripts/login.js

@ -748,11 +748,20 @@ var Login = function() {
}; };
var handleAddCoinLoginBtn = function() { var handleAddCoinLoginBtn = function() {
$('#addcoin_mdl_native_mode_login').prop('disabled', true);
$('.mdl_addcoin_done_btn-login').click(function(){ $('.mdl_addcoin_done_btn-login').click(function(){
ExecuteAddCoinLoginFn(); ExecuteAddCoinLoginFn();
}); });
$( "#addcoin_select_coin_mdl_options-login" ).change(function() {
if ($('#addcoin_select_coin_mdl_options-login').val() == 'KMD') {
$('#addcoin_mdl_native_mode_login').prop('disabled', false);
} else {
$('#addcoin_mdl_native_mode_login').prop('disabled', true);
}
});
} }

Loading…
Cancel
Save