凯氏卫星定位监控系统日期字段同步

屏蔽凯氏卫星历史记录日期输入框的日期选择控件,并对两个日期框做数据同步

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name         凯氏卫星定位监控系统日期字段同步
// @namespace    https://penicillin.github.io/
// @version      0.2.1
// @description  屏蔽凯氏卫星历史记录日期输入框的日期选择控件,并对两个日期框做数据同步
// @author       静夜轻风
// @match        http://www.fzksgps.com/Main/Index.html
// @grant        none
// @license MIT
// ==/UserScript==

(function() {
    var interval = setInterval(function(){
        try{
            document.getElementsByTagName('iframe')[1].contentWindow.document.getElementById("function").contentWindow.document.getElementsByTagName('iframe')[3].style.display='none';
            var iframeDocument=document.getElementsByTagName('iframe')[1].contentWindow.document.getElementById("function").contentWindow.document.getElementById("search").contentWindow.document;
            clearInterval(interval);
            console.log('OK....');
            setInterval(function(){ clock(); }, 3000);
            function clock()
            {
                var leftText=iframeDocument.getElementById("tb_F");
                var rightText=iframeDocument.getElementById("tb_G");
                if (leftText && rightText !== null){
                    rightText.value=leftText.value.substring(0,10)+" 20:00:00";
                }
            }
        }catch(err){
            console.log('Waitting....');
        }
    }
                               , 2000);}
)();