Last active
May 26, 2016 08:48
-
-
Save r-k-b/cd061d055581cba5d808d5e36a726ddd to your computer and use it in GitHub Desktop.
Set Payment Method to 11
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Set Payment Method to 11 | |
// @namespace https://gist.github.com/r-k-b/ | |
// @version 1.0.1 | |
// @description DESCRIPTIONGOESHERE | |
// @author Robert K. Bell | |
// @homepage https://gist.github.com/673e9c53d0b0da4994b48d2d7423ff8d | |
// @downloadURL https://gist.github.com/robert-bosweb/673e9c53d0b0da4994b48d2d7423ff8d/raw/set-BC-paymentmethodtype-to-11.user.js | |
// @match * | |
// @grant none | |
// @run-at context-menu | |
// ==/UserScript== | |
/* jshint esnext: true */ | |
(() => { | |
'use strict'; | |
let pms = $('[name=PaymentMethodType]'); | |
let oldVal = pms.val(); | |
pms | |
.val('11') | |
.change(); | |
console.groupCollapsed('Changed paymentMethodType from', oldVal, 'to 11'); | |
console.log('Target:', pms); | |
console.groupEnd(); | |
})(jQuery); | |
// todo: handle multiple targets |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment