// ==UserScript== // @author code:Tamozhnya1; style: sw.East; modifications: Alena17 // @collaborator style: sw.East // @collaborator modifications: Alena17 // @name Salary Style Mod // @name:ru Подсчет зарплаты HWM // @description Показывает зарплату на предприятии с учетом и отображением коэффициента ГР // @icon http://i.imgur.com/GScgZzY.jpg // @version 1.1.4 // @encoding utf-8 // @include *//*heroeswm.*/home.php // @include *//*heroeswm.*/object-info.php* // @include *//178.248.235.15/home.php // @include *//178.248.235.15/object-info.php* // @include *//*lordswm.*/home.php // @include *//*lordswm.*/object-info.php* // @grant GM_addStyle // @grant GM_xmlhttpRequest // @grant GM_info // @grant GM_getMetadata // @grant GM_getValue // @grant GM_setValue // @grant GM_deleteValue // @grant GM_registerMenuCommand // @homeURL https://openuserjs.org/scripts/chesheerk/Salary_Style_Mod // @copyright 2014-15, code:Tamozhnya1; style: sw.East; modifications: Alena17 // @license MIT // @namespace https://greasyfork.org/users/3065 // @downloadURL https://update.greasyfork.icu/scripts/16377/Salary%20Style%20Mod.user.js // @updateURL https://update.greasyfork.icu/scripts/16377/Salary%20Style%20Mod.meta.js // ==/UserScript== main(); function main() { setK(); if(/object-info.php/.test(location.href)) { var strSalary = ustring("Зарплата: "); var tds = document.getElementsByTagName("td"); for (var i = 0; i < tds.length; i++) { var td = tds[i]; if(td.innerHTML == strSalary) { var tdSalary = td; break; } } var b = tdSalary.nextSibling.firstChild.firstChild.firstChild.firstChild.lastChild.firstChild; var salary = ""; salary = parseInt(b.innerHTML); var k = parseFloat(GM_getValue(getNick(), "1.0")); /* Style */ var cssStyle = ""; cssStyle += "body > center:nth-child(2) > table:nth-child(2) > tbody:nth-child(1) > tr:nth-child(1) > td:nth-child(1) > table:nth-child(1) > tbody:nth-child(1) > tr:nth-child(1) > td:nth-child(1) > table:nth-child(3) > tbody:nth-child(1) > tr:nth-child(1) > td:nth-child(1) > table:nth-child(11) > tbody:nth-child(1) > tr:nth-child(1) > td:nth-child(3){display: none;}.salary{display:inline-block;text-align:center;padding:3px 6px;margin:0;font-size:11px;font-weight:bold;line-height:14px;color:#fff;vertical-align:baseline;white-space:nowrap;background-color:#666;border:1px solid #fff;text-decoration:none;box-shadow:1px 1px 2px rgba(0,0,0,.1);}.salary:hover,.salary:focus{color:#fff;opacity:.85;text-decoration:none;cursor:help;}.salary-light_blue{background-color:#719DAB;}.salary-blue{background-color:#7189AB;}.tt-wrapper{padding:0;width:435px;height:20px;margin:0 auto 0 auto;}ul.tt-wrapper{list-style:none !important;}.tt-wrapper li{float:left;}.tt-wrapper li a{display:block;width:24px;height:14.5px;margin:0;outline:none;position:relative;z-index:2;}.tt-wrapper li a span{width:115px;height:auto;padding:5px;left:50%;margin-left:-32px;font-family:Georgia, serif;font-weight:400;font-style:italic;font-size:14px;color:#fff;text-shadow:1px 1px 1px rgba(0, 0, 0, .1);text-align:center;border:4px solid #fff;background:rgba(113,156,171,.85);text-indent:0;position:absolute;pointer-events:none;bottom:30px;opacity:0;box-shadow:0 3px 8px rgba(0,0,0,.2);-webkit-transition:all .3s ease-in-out;-moz-transition:all .3s ease-in-out;-o-transition:all .3s ease-in-out;-ms-transition:all .3s ease-in-out;transition:all .3s ease-in-out;-webkit-transform:rotate(0deg) scale(.2);-moz-transform:rotate(0deg) scale(.2);-o-transform:rotate(0deg) scale(.2);-ms-transform:rotate(0deg) scale(.2);transform:rotate(0deg) scale(.2);}.tt-wrapper li a:hover span{opacity:.9;bottom:55px;-webkit-transform:rotate(-45deg) scale(1);-moz-transform:rotate(-45deg) scale(1);-o-transform:rotate(-45deg) scale(1);-ms-transform:rotate(-45deg) scale(1);transform:rotate(-45deg) scale(1);}.tt-wrapper li a:hover span.tt-blue{background-color:#7189AB;}"; GM_addStyle(cssStyle); /* Style End */ b.innerHTML = "