mmmturkeybacon Disable Gift Card Withdrawal

Unchecks and disables the Amazon Gift Card withdrawal radio button on Amazon Payments.

目前为 2015-03-20 提交的版本,查看 最新版本

// ==UserScript==
// @name        mmmturkeybacon Disable Gift Card Withdrawal
// @author      mmmturkeybacon
// @description Unchecks and disables the Amazon Gift Card withdrawal radio button on Amazon Payments.
// @namespace   http://userscripts.org/users/523367
// @match       https://www.mturk.com/mturk/transferearnings
// @match       https://payments.amazon.com/withdraw*
// @require     https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js
// @version     1.03
// @grant       none
// ==/UserScript==

$(document).ready(function ()
{
    // An unknown person posted a different version of this script with the following line added.
    // I don't know where it comes from. PM me if you know.
    //$('input[id="AmazonPayments"][value="AmazonPayments"][name="withdrawTo"][type="radio"]').attr('enabled', 'true');

    $('input[name="selectedExecutorTypeName"][value="AmazonPayments"][type="radio"]').attr('checked', 'true');
    $('input[name="selectedExecutorTypeName"][value="GCSharp"][type="radio"]').attr('disabled', 'true');
    $('input[name="selectedExecutorTypeName"][value="GCSharp"][type="radio"]').attr('checked', null);

    // https://payments.amazon.com/withdraw
    // This form doesn't exist anymore.
    $('input[id="purchaseGC"][value="purchaseGC"][name="withdrawTo"][type="radio"]').attr('disabled', 'true');
});