ZSMTurker's Piotr Script

Automatically selects the first two options and adds hotkey shortcuts.

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @author      ZSMTurker
// @name        ZSMTurker's Piotr Script
// @namespace   https://greasyfork.org/users/2291
// @description Automatically selects the first two options and adds hotkey shortcuts.
// @require     http://code.jquery.com/jquery-latest.min.js
// @match       https://www.deyde.com/*
// @version     0.1
// ==/UserScript==

$( document ).ready( function() {
    $( 'button[name="cancel"]' ).eq( 0 ).css('float','right');
    $( 'button[name="check"]' ).eq( 0 ).css('float', 'left');
    $('#priceCluster-1').click();
    $('#offerCluster-1').click();
    document.addEventListener( "keydown", elPiotr, false );
} );

function elPiotr( i ) {
    if ( i.keyCode == 49 ) { //1
        $( 'button[name="check"]' ).eq( 0 ).css('background-color', '#ffffff');
        $( 'button[name="check"]' ).eq( 0 ).click();
    }
    if ( i.keyCode == 50 ) { //2
        $( 'button[name="cancel"]' ).eq( 0 ).css('background-color', '#ffffff');
        $( 'button[name="cancel"]' ).eq( 0 ).click();
    }
    if ( i.keyCode == 191 && i.shiftKey ) { //? Key - Shows Keys
        piotrCount++;
        alert(' 1 - Approve \n 2 - Reject');
    }
}