基于chrome的京东自动签到领京豆脚本

技术百科 码拜 4年前 (2020-02-11) 6409次浏览 0个评论

基于chrome京东自动签到京豆脚本

基于chrome的京东自动签到领京豆脚本

脚本详情:

// ==UserScript==
// @author codebye.com
// @name 京东自动签到京豆
// @description 京东店铺签到抽奖+京东游戏签到
// @include *//bean.jd.com/myJingBean/list/*
// @include *//mall.jd.com/*
// @include *//*.jd.com/*
// @version 0.9
// @connect-src www.jd.com
// @namespace https://greasyfork.org/users/443454
// ==/UserScript==

(function() {
'use strict';
if(top.location.hostname=='bean.jd.com'){
setTimeout(function(){
window.open("http://huan.jd.com");
},3000);

setTimeout(function(){
var btn = document.getElementsByClassName('s-btn');
for(var i = 0;i<btn.length;i++){ (function(i){ setTimeout(function (){ btn[i].click(); },i*3000); })(i); } },3000); } 
//进店签到京豆 
if(/\w*\.jd\.com/.test(top.location.hostname)&&document.getElementById('JSHOP_CHANNEL_FLAG')){ 
setInterval(function(){ if(document.getElementsByClassName('unsigned').length>=1){
document.getElementsByClassName('unsigned')[0].click();
}else if(document.getElementsByClassName('signed').length>=1){
window.location.href="about:blank";
window.close();
}
},3000);
setInterval(function(){
if(window.location.href.indexOf('shopSign')>=0){
window.location.href="about:blank";
window.close();
}
},3000);
//延时未加载页面即刷新
setTimeout(function(){
window.location.reload();
},10000);
}
//京东游戏特权点数
if(top.location.hostname=='huan.jd.com'){
setTimeout(function(){
if(document.getElementsByClassName('sign-status').length==0){
document.getElementById('signin-btn').click();
};
},2000);
setInterval(function(){
if(document.getElementsByClassName('thickclose').length>0){
window.location.href="about:blank";
window.close();
}
},2000);
}
})();


CodeBye 版权所有丨如未注明 , 均为原创丨本网站采用BY-NC-SA协议进行授权 , 转载请注明基于chrome的京东自动签到领京豆脚本
喜欢 (2)
[1034331897@qq.com]
分享 (0)

文章评论已关闭!