Ebay for "according to description"

Tries to view the item description valid at the date of purchase

当前为 2022-01-14 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name Ebay for "according to description"
  3. // @description Tries to view the item description valid at the date of purchase
  4. // @author Werve
  5. // @match https://order.ebay.it/ord/*
  6. // @icon https://icons.duckduckgo.com/ip2/ebay.it.ico
  7. // @grant none
  8. // @create 2022-01-13
  9. // @lastmodified 2022-01-13
  10. // @version 0.1
  11. // @namespace https://greasyfork.org/users/669237
  12. // @homepageURL https://greasyfork.org/scripts/438499
  13. // @require https://code.jquery.com/jquery-3.6.0.min.js
  14. // @license CC BY 4.0
  15. // @copyright 2022 Werve
  16. // @run-at document-end
  17. // ==/UserScript==
  18.  
  19. (function() {
  20. 'use strict';
  21.  
  22. $.noConflict(true);
  23. $(".top-region").append("<div id='try_old_desc'> <button id='old_desc'> View item description valid at the date of purchase </button></div></br>");
  24. $("#old_desc").click(URL_desc);
  25. })();
  26.  
  27. function URL_desc(){
  28. let URL = location.href;
  29. let productId = URL.match(/.*itemid=(\d+)/)[1];
  30. let transactionId = URL.match(/.*transId=(\d+)/)[1];
  31. location.href = "https://ebay.it/ipp/"+ productId +"?transactionId="+ transactionId;
  32. }