锘?(function () { basicShow(); NewsType(); GroupMembersName(); //鍥炲埌闋傞儴 $(window).scroll(function () { //鍙绐楀彛婊氬姩,灏辫Е鍙戜笅闈唬鐮 var scrollt = document.documentElement.scrollTop + document.body.scrollTop; //鑾峰彇婊氬姩鍚庣殑楂樺害 if (scrollt > 200) { //鍒ゆ柇婊氬姩鍚庨珮搴﹁秴杩?00px,灏辨樉绀 $("#back_top").fadeIn(400); //娣″叆 } else { $("#back_top").stop().fadeOut(400); //濡傛灉杩斿洖鎴栬€呮病鏈夎秴杩?灏辨贰鍑?蹇呴』鍔犱笂stop()鍋滄涔嬪墠鍔ㄧ敾,鍚﹀垯浼氬嚭鐜伴棯鍔 } }); $("#back_top").click(function () { //褰撶偣鍑绘爣绛剧殑鏃跺€?浣跨敤animate鍦?00姣鐨勬椂闂村唴,婊氬埌椤堕儴 $("html,body").animate({ scrollTop: "0px" }, 200); }); //GA var hm1 = document.createElement("script"); hm1.src = "https://www.googletagmanager.com/gtag/js?id=UA-127488743-1"; var s1 = document.getElementsByTagName("script")[0]; s1.parentNode.insertBefore(hm1, s1); console.log(111); window.dataLayer = window.dataLayer || []; function gtag() { dataLayer.push(arguments); } gtag('js', new Date()); gtag('config', 'UA-127488743-1'); //QQ73 var _hmt = _hmt || []; var hm2 = document.createElement("script"); hm2.src = "https://hm.baidu.com/hm.js?aa507d031177fe20a161fee3282aeeb4"; var s2 = document.getElementsByTagName("script")[0]; s2.parentNode.insertBefore(hm2, s2); console.log(222); //var _hmt = _hmt || []; //shvip var hm = document.createElement("script"); hm.src = "https://hm.baidu.com/hm.js?47b9841342068855c7053b718fe9f289"; var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(hm, s); console.log(333); }) function basicShow() { var basic = BasicShow(); console.log(basic); if (basic.success) { var data = basic.data; $("#LogoPic img").attr("src", PathHttp() + data.BCompanyLogo); $("#Hotline").html(data.BHotline) $("#FootTel").html(data.BHotline) $("#address").html("鍦板潃锛? + data.BCompanyAddress) //$("#copyright").html("漏锔 鐗堟潈鎵€鏈夛細" + data.BCompanyName) $("#copyright").html("漏锔 鐗堟潈鎵€鏈夛細涓婃捣瀹夎氨瀹為獙绉戞妧鑲′唤鏈夐檺鍏徃 娌狪CP澶 08012727鍙 - 2 ") } } //鏂伴椈绫诲瀷 function NewsType() { var result = NewsTypeList(); console.log("鏂伴椈绫诲瀷") console.log(result) if (result.success) { var data = result.data; var num = 0 var htmlNew = ""; var Num1 = Math.ceil(data.length / 4) var Num2 = Math.ceil(data.length / Num1) console.log("绗竴娆″惊鐜細" + Num1) console.log("绗簩娆″惊鐜細" + Num2) for (var i = 0; i < Num1; i++) { htmlNew += "
"; //if (Num1 - 1 == i) { // if (data.length % 2 != 0) { // Num2 = Num2 - 1; // } //} for (var j = 0; j < Num2; j++) { if (num < data.length) { htmlNew += "

" + data[num].NewsTypeName + "

"; num++; } } htmlNew += "
"; htmlNew += "
"; } $("#NewListShow").html(htmlNew) //document.getElementById("NewListShow").innerHTML = NewListShowtmpText(data); } } //瀹夎氨缃戠兢 function GroupMembersName() { var result = GroupMembers(); console.log("鏂伴椈绫诲瀷") console.log(result) if (result.success) { var data = result.data; var num = 0 var htmlNew = ""; var Num1 = Math.ceil(data.length / 5) var Num2 = Math.ceil(data.length / Num1) for (var i = 0; i < Num1; i++) { htmlNew += "
"; //if (i == 0) { // htmlNew += "

鑱旂郴鎴戜滑

"; //} for (var j = 0; j < Num2; j++) { if (num < data.length) { htmlNew += "

" + data[num].Name + "

"; //htmlNew += "

" + data[num].Name + "

"; num++; } } htmlNew += "
"; htmlNew += "
"; } $("#Group_Members_Name").html(htmlNew) //document.getElementById("NewListShow").innerHTML = NewListShowtmpText(data); } } function JumpGroup(link) { console.log("linkkkkkkkkkkkkkkkkkkkk"); console.log(link); if (link != null && link != "null" && link != "") { window.open(link) console.log(1111111111111); } else { console.log(2222222222); if (window.location.pathname == "/GroupMembers.html") { //鍒ゆ柇鏄鍦ㄥ畨璋辩綉缇ら〉闈 $(window).scrollTop(2035); } else { location.href = "GroupMembers.html#Group"; } } } //鎼滅储 function SubmitSearch() { var SearchName = $("#QuerySearchName").val() console.log("SearchNameSearchNameSearchNameSearchNameSearchName鐐瑰嚮:" + SearchName); if (SearchName.trim() != "") { console.log("SearchName:" + SearchName); window.location.href = "CommWholeStation.html?SearchName=" + SearchName } } function On_KeyDow() { if (window.event.keyCode == 13) { var SearchName = $("#QuerySearchName").val() console.log("SearchNameSearchNameSearchNameSearchNameSearchName鍥炶溅:" + SearchName); if (SearchName.trim() != "") { console.log("SearchName:" + SearchName); window.location.href = "CommWholeStation.html?SearchName=" + SearchName } } } function LoopInfoRemovePic(Info) { if (Info != null) { //console.log("杩涙潵浜嗗悧111111:" + Info) if (Info.indexOf("img src") > 0) { var Jies = Info.match(//)[1]; var PingJie = "" Info = Info.replace(PingJie, "") return LoopInfoRemovePic(Info) } else if (Info.indexOf("img alt") > 0) { //console.log("杩涙潵浜嗗悧333333:" + Info) var Jies = Info.match(//)[1]; //console.log("杩涙潵浜嗗悧Jies333333:" + Jies) var PingJie = "" Info = Info.replace(PingJie, "") return LoopInfoRemovePic(Info) } else { //console.log("InfoInfoInfoInfo:" + Info) return Info } } } function LoopInfoPath(Info) { console.log(Info) if (Info != "" && Info != null) { if (Info.indexOf("/UpFile/Admin") > 0 && Info.indexOf(PathHttp() + "/UpFile/Admin") < 0) { Info = Info.replace(/\/UpFile\/Admin/g, PathHttp() + "/UpFile/Admin") } else if (Info.indexOf("/uploads/") > 0 && Info.indexOf(PathHttp() + "/uploads/") < 0) { Info = Info.replace(/\/uploads\//g, PathHttp() + "/uploads/") } else { console.log("InfoInfoInfoInfo:" + Info) return Info } return LoopInfoPath(Info) } } //瀹夎氨浜戝晢閾炬帴 $(".fr .btns a:first").attr("href", "http://www.labsci.com.cn?utm_source=rukou") //head澶撮儴璧嬪€ function TdkAssignment(title, Key, description) { if (title != null) { document.title = title; } if (Key != null) { document.getElementsByName("keywords")[0].content = Key; } if (description != null && description != "") { document.getElementsByName("description")[0].content = description.replace(/\s*/g, "").replace(/[\r\n]/g, ""); } } //鎴彇 function intercept(ConInfo) { if (ConInfo != "" && ConInfo != null) { if (ConInfo.length >= 110) { ConInfo = ConInfo.substring(0, 109).trim().replace(/\s*/g, "").replace(/[\r\n]/g, ""); return ConInfo; } return ConInfo.trim().replace(/\s*/g, "").replace(/[\r\n]/g, ""); } }