Unverified Commit bc71c1e7 authored by bitsoko's avatar bitsoko Committed by GitHub

Update rewards.js

parent 7a4c7c01
......@@ -166,30 +166,39 @@ paySwits[i].onchange=function(){
var pCls=this.getAttribute("class").replace(' switch','');
switch (pCls) {
case 'doPayEth-switch':
if(document.querySelector('.'+e.target.getAttribute("class").replace('-switch','')).checked){
if(document.querySelector('.'+pCls.replace('-switch','')).checked){
doTradeCola.open(1);
doTradeCola.open(0);
document.querySelector('.'+pCls.replace('-switch','')).style["pointer-events"] = "all";
}else{
doTradeCola.close(1);
doTradeCola.close(0);
document.querySelector('.'+pCls.replace('-switch','')).style["pointer-events"] = "none";
}
break;
case 'doPayMM-switch':
if(document.querySelector('.'+e.target.getAttribute("class").replace('-switch','')).checked){
if(document.querySelector('.'+pCls.replace('-switch','')).checked){
doTradeCola.open(2);
doTradeCola.open(1);
document.querySelector('.'+pCls.replace('-switch','')).style["pointer-events"] = "all";
}else{
doTradeCola.close(2);
doTradeCola.close(1);
document.querySelector('.'+pCls.replace('-switch','')).style["pointer-events"] = "none";
}
break;
case 'doPaycard-switch':
if(document.querySelector('.'+e.target.getAttribute("class").replace('-switch','')).checked){
if(document.querySelector('.'+pCls.replace('-switch','')).checked){
doTradeCola.open(3);
doTradeCola.open(2);
document.querySelector('.'+pCls.replace('-switch','')).style["pointer-events"] = "all";
}else{
doTradeCola.close(3);
doTradeCola.close(2);
document.querySelector('.'+pCls.replace('-switch','')).style["pointer-events"] = "none";
}
break;
default:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment