mirror of
https://github.com/MarshalX/telegram-crawler.git
synced 2024-12-01 12:42:07 +01:00
Update content of files
This commit is contained in:
parent
e3d4c1bfbc
commit
8cd5de35b6
1 changed files with 0 additions and 10 deletions
|
@ -1302,13 +1302,11 @@ var Random = {
|
||||||
var LoginCodes = {
|
var LoginCodes = {
|
||||||
init: function() {
|
init: function() {
|
||||||
Aj.onLoad(function(state) {
|
Aj.onLoad(function(state) {
|
||||||
$('.js-toggle-receive').on('change', LoginCodes.eToggleReceive);
|
|
||||||
state.needUpdate = true;
|
state.needUpdate = true;
|
||||||
state.updLastReq = +Date.now();
|
state.updLastReq = +Date.now();
|
||||||
state.updStateTo = setTimeout(LoginCodes.updateState, Main.UPDATE_PERIOD);
|
state.updStateTo = setTimeout(LoginCodes.updateState, Main.UPDATE_PERIOD);
|
||||||
});
|
});
|
||||||
Aj.onUnload(function(state) {
|
Aj.onUnload(function(state) {
|
||||||
$('.js-toggle-receive').off('change', LoginCodes.eToggleReceive);
|
|
||||||
clearTimeout(state.updStateTo);
|
clearTimeout(state.updStateTo);
|
||||||
state.needUpdate = false;
|
state.needUpdate = false;
|
||||||
});
|
});
|
||||||
|
@ -1339,14 +1337,6 @@ var LoginCodes = {
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
},
|
|
||||||
eToggleReceive: function() {
|
|
||||||
var can_receive = $(this).prop('checked');
|
|
||||||
$('.js-codes-main').toggleClass('codes-disabled', !can_receive);
|
|
||||||
Aj.apiRequest('toggleLoginCodes', {
|
|
||||||
number: Aj.state.number,
|
|
||||||
can_receive: can_receive ? 1 : 0
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue