表单中报表块的跑马灯每次刷新后,隐藏滚动条就会失效,出现滚动条。5月13日,报表块使用官方JS跑马灯效果+定时刷新控件,刷新后依然出现滚动条各位看看问题出在哪里?求指导。JS如下,var supplierNumber = this.options.form.getWidgetByName("supplierNumber").getValue()var firstSupplierNumber = parseInt(supplierNumber);setTimeout(function() { //隐藏报表块report0_c的滚动条(此报表块名为report0_c,根据具体情况修改) $("div").find(".frozen-north").style.overflow = "hidden"; $("div").find(".frozen-center").style.overflow = "hidden"; }, 1000); window.flag = true; //鼠标悬停,滚动停止 setTimeout(function() { var old = -1; var interval = setInterval(function() { if(window.flag) { currentpos = $("div").find(".frozen-center").scrollTop; if(currentpos == old) { $("div").find(".frozen-center").scrollTop = 0; } else { old = currentpos; //以25ms的速度每次滚动1PX $("div").find(".frozen-center").scrollTop = currentpos + 1; } } }, 25); }, 1000);var form = this.options.form; setInterval(function() { form.getWidgetByName('REPORT0').gotoPage(1,"{}",true);$("div").find(".frozen-north").style.overflow = "hidden";$("div").find(".frozen-center").style.overflow = "hidden"; var lastSupplierNumber = parseInt(_g().options.form.getWidgetByName("report0").element.find("td").text());if (lastSupplierNumber != firstSupplierNumber) {location.reload();}}, 10000); //刷新报表块report0 10s刷新一次-------------------------------------------------------------5.13var supplierNumber = this.options.form.getWidgetByName("supplierNumber").getValue()var firstSupplierNumber = parseInt(supplierNumber);setTimeout(function() { //隐藏报表块report0_c的滚动条(此报表块名为report0_c,根据具体情况修改) $("div").find(".frozen-north").style.overflow = "hidden"; $("div").find(".frozen-center").style.overflow = "hidden"; console.log(1)}, 1000); window.flag = true; //鼠标悬停,滚动停止 setTimeout(function() { var old = -1; var interval = setInterval(function() { if(window.flag) { currentpos = $("div").find(".frozen-center").scrollTop; if(currentpos == old) { console.log(2) $("div").find(".frozen-center").scrollTop = 0; } else { old = currentpos; //以25ms的速度每次滚动1.5PX $("div").find(".frozen-center").scrollTop = currentpos + 1; } } }, 25); }, 1000);var form = this.options.form; setInterval(function() { setTimeout(function() { $("div").find(".frozen-north").style.overflow = "hidden"; $("div").find(".frozen-center").style.overflow = "hidden"; form.getWidgetByName('REPORT0').gotoPage(1,"{}",true); console.log(3)}, 50);var lastSupplierNumber = parseInt(_g().options.form.getWidgetByName("report0").element.find("td").text());if (lastSupplierNumber != firstSupplierNumber) {console.log(4)location.reload();}}, 10000); //刷新报表块report0 5s刷新一次