getTaobaoDetails

try to take over the world!

Bu betiği kurabilmeniz için Tampermonkey, Greasemonkey ya da Violentmonkey gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

Bu betiği kurabilmeniz için Tampermonkey ya da Violentmonkey gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

Bu betiği kurabilmeniz için Tampermonkey ya da Violentmonkey gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

Bu betiği kurabilmeniz için Tampermonkey ya da Userscripts gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

You will need to install an extension such as Tampermonkey to install this script.

Bu komut dosyasını yüklemek için bir kullanıcı komut dosyası yöneticisi uzantısı yüklemeniz gerekecek.

(Zaten bir kullanıcı komut dosyası yöneticim var, kurmama izin verin!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(Zateb bir user-style yöneticim var, yükleyeyim!)

// ==UserScript==
// @name         getTaobaoDetails
// @namespace    http://tampermonkey.net/
// @version      0.1
// @description  try to take over the world!
// @author       You
// @match        https://*.taobao.com/trace/*
// @grant        none
// @resource     customCSS https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css
// @require      https://greasyfork.org/scripts/27254-clipboard-js/code/clipboardjs.js?version=174357
// @require      https://cdn.jsdelivr.net/npm/[email protected]/dist/jquery.slim.min.js
// @require      https://cdn.jsdelivr.net/npm/vue
// ==/UserScript==

(function() {
    'use strict';
    var delivery_no = $(".order-row .em").html();
    delivery_no = delivery_no.replace(/\s{2,}/g, ' ');
    delivery_no = delivery_no.replace(/\t/g, ' ');
    delivery_no = delivery_no.toString().trim().replace(/(\r\n|\n|\r)/g,"");
    var description = $(".order-list img:first").attr("alt");
    var maxLength = 13; //最长宝贝描述字数
    if (description.length > maxLength) {
        description = description.slice(description.length-maxLength,description.length);
        //alert(description);
    }
    var clipbard_text = delivery_no + '	'
                        + description;
    var clipboard = new Clipboard('.btn');
    var infoHTML = ' <button style="font-size:13px;" class="btn" data-clipboard-text="' + clipbard_text + '"> 点我复制 delivery_no / description </button>';
    $(".indent").append(infoHTML);
    // Your code here...
})();