var apshow = 0; var reshow = 0; var miscshow = 0; function fktcreatePDF(lid){ var url = "https://registar.online/include/createPDF.php?lid="+lid; var w = window.innerWidth; var h = window.innerHeight; var a = window.navigator.standalone; if (a === true){ if ($("#dialog").length>0){$("#dialog").remove();} $("#top").append("
x
"); $("#pdfdiv_content").load(url,function(){ var url = $("#pdfdiv_content").html(); var docname = $("#"+lid).html(); var pdfhtml = "






Download PDF

"+docname+"





Hinweis:

Nach Öffnen des Dokuments muss die APP gestartet werden.

"; //var pdfhtml = ""; //var pdfhtml = ""; //var pdfhtml = ""; //var pdfhtml = "

Your browser does not support PDFs.Download PDF.

"; $("#pdfdiv_content").html(pdfhtml); $('#dialog').click(function(){ setTimeout(function(){ $('#dialog').fadeOut(200, function(){ $('#dialog').remove(); }); },100); }); }); $('#pdfframe').click(function(){ $('#dialog').fadeOut(200, function(){ $('#dialog').remove(); }); }); } else { url = url+"&show=1"; window.open(url,"_blank"); } } function fktauditPDF(lid){ var url = "https://registar.online/include/audit_pdfreport.php?lid="+lid; window.open(url,"_blank"); } function fktShowAtt(e,url,dn){ var w = window.innerWidth; var h = window.innerHeight; var a = window.navigator.standalone; a=true; if (a === true){ if ($("#dialog").length>0){$("#dialog").remove();} $("#top").append("
x
"); var pdfhtml = "






Download PDF

"+dn+"





Hinweis:

Nach Öffnen des Dokuments muss die APP gestartet werden.

"; $("#pdfdiv_content").html(pdfhtml); $(window).scrollTop(0); $('#dialog').click(function(){ setTimeout(function(){ $('#dialog').fadeOut(200, function(){ $('#dialog').remove(); }); },100); }); } else { window.open(url,"_blank"); } } function fktDaybwd(){ var d = $("#TLdate").val(); $("#TLinfo").load("https://registar.online/include/TLinfo.php?dat="+d+"&dbwd=1", function(){ fktActUbers(); }); } function fktDayfwd(){ var d = $("#TLdate").val(); $("#TLinfo").load("https://registar.online/include/TLinfo.php?dat="+d+"&dfwd=1", function(){ var t = $("#TIC3").html(); fktActUbers(); }); } function fktActUbers(){ $("#TI1").css("background-color","rgba(240,130,130, 0.7)"); if ($("#TIC1").html()=="1"){ $("#TID1").html("Neuer Lead"); } else { $("#TID1").html("Neue Leads"); } $("#TI2").css("background-color","rgba(250,250,160, 0.7)"); if ($("#TIC2").html()=="1"){ $("#TID2").html("Offener Lead"); } else { $("#TID2").html("Offene Leads"); } $("#TI3").css("background-color","rgba(150,240,150, 0.7)"); if ($("#TIC3").html()=="1"){ $("#TID3").html("Termin"); } else { $("#TID3").html("Termine"); } $("#TI4").css("background-color","rgba(250,250,160, 0.7)"); if ($("#TIC4").html()=="1"){ $("#TID4").html("Absage"); } else { $("#TID4").html("Absagen"); } } function fktOpenCat(e){ var block = ""; switch (e) { case "NewCar": block = "car"; break; case "NewOp": block = "event"; break; } if ($("#"+block).is(':hidden')){ $("#"+block).show(200); } else { $("#"+block).hide(200); } } function fktLList(e){ for (x=1; x<=5; x++){ $("#LB"+x).removeClass("focus"); } $("#LB"+e).addClass("focus"); window.setTimeout(function(){ $("#leadreport").load("https://registar.online/include/Leadlist.php?art="+e); },500); } $(window).scroll(function(){ // This is the function used to detect if the element is scrolled into view function elementScrolled(elem){ var docViewTop = $(window).scrollTop(); var docViewBottom = docViewTop + $(window).height(); if ($(elem).length){ var elemTop = $(elem).offset().top; return ((elemTop <= docViewBottom) && (elemTop >= docViewTop)); } else { return false; } } // This is where we use the function to detect if "elem" is scrolled into view, and when it is add the class ".animated" to the

child element if (elementScrolled('#leads')){ var h = $("#leadreport").html().length; if (h==0){ $("#leadreport").load("https://registar.online/include/Leadlist.php"); } } if (elementScrolled('#reports')){ if (reshow!=1){ $("#report1").load("https://registar.online/include/Leadreport.php?Report=1",function(){ reshow=1; }); //$("#appreport").load("https://registar.online/include/Event_report.php"); if ($("#tcmreport").length){ $("#tcmreport").load("https://registar.online/include/TCM_report.php"); } } } if (elementScrolled('#actions')){ if (apshow!=1){ $("#aplan").load("https://registar.online/include/Actionplan.php",function(){ apshow=1; }); } } if (elementScrolled('#miscellaneous')){ if (miscshow!=1){ $('#miscellaneous').load('https://registar.online/include/miscellaneous.php',function(){ miscshow=1; }); } } }); function fktGraph(){ var w = window.innerWidth; var h = window.innerHeight; var top = 0; if (w>800){ $("#start").css("height","100vh"); $("#graph").css("display","block"); $("#graph").css("top",top+"px"); $("#graph").css("margin-left","-20%"); $("#graph1").load("https://registar.online/include/Leadreport.php",function(){ $("#graph").css("width","40%"); }); } else { if (h>w){ $("#start").css("height","120vh"); $("#graph").css("display","block"); var top = 220; $("#graph").css("top",top+"px"); $("#graph").css("margin-left","-45%"); $("#graph1").load("https://registar.online/include/Leadreport.php",function(){ $("#graph").css("width","90%"); }); } else { $("#graph").css("display","none"); } } var wi = $( window ).width(); var ht = $( window ).height(); if (ht>=768 && wi>=768 && wi<1240){ $(".msghole").css("width","220px"); $(".msghole").css("height","220px"); $(".TIleft").css("margin-top","3.3vh"); $(".TIleft").css("line-height","2em"); $(".TIright").css("margin-top","3.3vh"); $(".TIright").css("line-height","2em"); $(".msghole h1").css("font-size","40px"); $("#TID1").css("font-size","1em"); $("#TID2").css("font-size","1em"); $("#TID3").css("font-size","1em"); $("#TID4").css("font-size","1em"); } if (ht<768 || (wi<=767 && wi>400)){ $(".msghole").css("width","150px"); $(".msghole").css("height","150px"); $(".TIleft").css("margin-top","2.2vh"); $(".TIleft").css("line-height","1.2em"); $(".TIright").css("margin-top","2.2vh"); $(".TIright").css("line-height","1.2em"); $(".msghole h1").css("font-size","35px"); $("#TI1").css("padding-top","0em"); $("#TI2").css("padding-top","0em"); $("#TI3").css("padding-top","0em"); $("#TI4").css("padding-top","0em"); $("#TID1").css("font-size","0.7em"); $("#TID2").css("font-size","0.7em"); $("#TID3").css("font-size","0.7em"); $("#TID4").css("font-size","0.7em"); } if (ht<600 || wi<=400){ $(".msghole").css("width","100px"); $(".msghole").css("height","100px"); $(".TIleft").css("margin-top","1.7vh"); $(".TIleft").css("line-height","0.2em"); $(".TIright").css("margin-top","1.7vh"); $(".TIright").css("line-height","0.2em"); $(".msghole h1").css("font-size","25px"); $("#TI1").css("padding-top","2em"); $("#TI2").css("padding-top","2em"); $("#TI3").css("padding-top","2em"); $("#TI4").css("padding-top","2em"); $("#TID1").css("font-size","0.8em"); $("#TID2").css("font-size","0.8em"); $("#TID3").css("font-size","0.8em"); $("#TID4").css("font-size","0.8em"); } } $(window).resize(function(){ }); var myVar; function fktReload(){ myVar = setTimeout(function(){ location.href="https://registar.online/index.php"; },300000); } $(document).ready(function() { if ($("#leadreport").length){ fktGraph(); fktReload(); $(window).scroll(function () { if (myVar){clearTimeout(myVar);} var a = $(this).scrollTop(); if (a==0){ fktReload(); } }); } });