CSFD porovnání hodnocení

Show your own ratings on other users ratings list

当前为 2021-04-14 提交的版本,查看 最新版本

// ==UserScript==
// @name         CSFD porovnání hodnocení
// @namespace    csfd.cz
// @version      0.1
// @description  Show your own ratings on other users ratings list
// @author       SonGokussj4
// @match        http://csfd.cz/*
// @include      *csfd.cz/uzivatel/*
// @icon         http://img.csfd.cz/assets/b1733/images/apple_touch_icon.png
// @grant        none
// @require      http://code.jquery.com/jquery-3.4.1.min.js
// ==/UserScript==


(function() {
    'use strict';
    /* globals jQuery, $, waitForKeyElements */

    // Get Logged-in user
    var loggedInUserHref = document.querySelector('.logged ul.first li h3 a').href;
    var loggedInUserName = loggedInUserHref.split('/')[loggedInUserHref.split('/').length - 2];
    console.log("Logged-in user:", loggedInUserName);

    // Add column to table header
    $(".ui-table-list thead tr th:nth-child(2)").after('<th>Moje</th>');

    // Add column to table body
    var tblData = $('.ui-table-list tbody');
    tblData.find('tr').each( function() {
        var tblRow = $(this);
        tblRow.find('td').eq(1).after('<td>Mé budoucí hodnoceni</td>');
    });

})();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址