Greasy Fork is available in English.
京东搜索商品时自动勾选京东自营
当前为
// ==UserScript==
// @name 京东自营自动检测器
// @description 京东搜索商品时自动勾选京东自营
// @version 0.04
// @author Vanilla
// @license MIT
// @match http://search.jd.com/*
// @grant none
// @run-at document-body
// @require http://libs.baidu.com/jquery/1.9.0/jquery.js
// @namespace http://greasyfork.icu/users/14035
// ==/UserScript==
$(function(){
var $dom = $('#J_feature a[data-field="wtype"]');
var isClick = $dom.hasClass('selected');
if(!isClick) {
var myInterval = window.setInterval(function(){
var isLoaded = typeof window.searchlog === 'function';
if(isLoaded) {
$dom.trigger('click');
window.clearInterval(myInterval);
}
}, 200);
}
});