//获取url地址
var hrefs = location.href.split('/');
var func1 = function() {
var ahref = document.querySelectorAll("#table_1 tr > td > a");
var tab = document.querySelector("#elementor-tab-title-1751");
var tab2 = document.querySelector("#elementor-tab-title-1752");
var tab3 = document.querySelector("#elementor-tab-title-1753");
var tab4 = document.querySelector("#elementor-tab-title-1754");
var tab5 = document.querySelector("#elementor-tab-title-1755");
// 分页点击
var fen = document.querySelectorAll("#table_1_paginate a");
var fen2 = document.querySelectorAll("#table_3_paginate a");
var fen3 = document.querySelectorAll("#table_5_paginate a");
var fen4 = document.querySelectorAll("#table_7_paginate a");
var fen5 = document.querySelectorAll("#table_9_paginate a");
clearInterval(homes)
// 第一次渲染
var arr = [];
for (var hrefs in ahref) {
arr.push(ahref[hrefs].href)
}
// 截取当前href值
var arrs =[]
for (var i =0; i <arr.length; i++) {
if (arr[i]) {
arrs.push(arr[i].split('/')[arr[i].split('/').length -1])
}
}
//赋值当前href值
for ( tabs in arrs) {
ahref[tabs].href = 'http://zbqy.updis.haomo-tech.com/wp-admin/admin.php?page=gf_entries&view=entry&id=3&lid='+ arrs[tabs] +'&order=ASC&filter&paged=1&pos=0&field_id&operator'
}
function fen_homes() {
var homes1 = setInterval(()=>{
var ahref1 = document.querySelectorAll("#table_1 tr > td > a");
clearInterval(homes1)
var arr = [];
for (var hrefs in ahref1) {
arr.push(ahref1[hrefs].href)
}
// 截取当前href值
var arrs =[]
for (var i =0; i <arr.length; i++) {
if (arr[i]) {
arrs.push(arr[i].split('/')[arr[i].split('/').length -1])
}
}
//赋值当前href值
for ( tabs in arrs) {
ahref1[tabs].href = 'http://zbqy.updis.haomo-tech.com/wp-admin/admin.php?page=gf_entries&view=entry&id=3&lid='+ arrs[tabs] +'&order=ASC&filter&paged=1&pos=0&field_id&operator'
}
},1200)
}
//分页1
for (var j = 0; j< fen.length; j++) {
//第一个分页
fen[j].onclick = function () {
var fens_set = setTimeout(() =>{
fen_homes();
homes = setInterval(func1,500)
},500)
}
}
//点击第一个渲染
tab.onclick = function () {
fen_homes();
}
//分页函数定义2
function fen_homes2() {
var homes2 = setInterval(()=>{
var ahref2 = document.querySelectorAll("#elementor-tab-content-1752 td > a");
clearInterval(homes2)
var arr = [];
for (var hrefs in ahref2) {
arr.push(ahref2[hrefs].href)
}
// 截取当前href值
var arrs =[]
for (var i =0; i <arr.length; i++) {
if (arr[i]) {
arrs.push(arr[i].split('/')[arr[i].split('/').length -1])
}
}
//赋值当前href值
for ( tabs in arrs) {
ahref2[tabs].href = 'http://zbqy.updis.haomo-tech.com/wp-admin/admin.php?page=gf_entries&view=entry&id=6&lid='+ arrs[tabs] +'&order=ASC&filter&paged=1&pos=0&field_id&operator'
}
},200)
}
//分页2
for (var f = 0; f< fen2.length; f++) {
//第二个分页
fen2[f].onclick = function () {
var fens_set2 = setTimeout(() =>{
fen_homes2();
homes = setInterval(func1,500)
},500)
}
}
//点击第二个渲染
tab2.onclick = function () {
fen_homes2()
}
//第三个表格函数
function fen_homes3() {
var homes3 = setInterval(()=>{
var ahref3 = document.querySelectorAll("#elementor-tab-content-1753 td > a");
clearInterval(homes3)
var arr = [];
for (var hrefs in ahref3) {
arr.push(ahref3[hrefs].href)
}
// 截取当前href值
var arrs =[]
for (var i =0; i <arr.length; i++) {
if (arr[i]) {
arrs.push(arr[i].split('/')[arr[i].split('/').length -1])
}
}
//赋值当前href值
for ( tabs in arrs) {
ahref3[tabs].href = 'http://zbqy.updis.haomo-tech.com/wp-admin/admin.php?page=gf_entries&view=entry&id=8&lid='+ arrs[tabs] +'&order=ASC&filter&paged=1&pos=0&field_id&operator'
}
},200)
}
//第三个分页
for (var s = 0; s< fen3.length; s++) {
fen3[s].onclick = function () {
var fens_set3 = setTimeout(() =>{
fen_homes3();
homes = setInterval(func1,500)
},500)
}
}
//点击第三个渲染
tab3.onclick = function () {
fen_homes3()
}
//第四个表格函数
function fen_homes4() {
var homes4 = setInterval(()=>{
var ahref4 = document.querySelectorAll("#elementor-tab-content-1754 td > a");
clearInterval(homes4)
var arr = [];
for (var hrefs in ahref4) {
arr.push(ahref4[hrefs].href)
}
// 截取当前href值
var arrs =[]
for (var i =0; i <arr.length; i++) {
if (arr[i]) {
arrs.push(arr[i].split('/')[arr[i].split('/').length -1])
}
}
//赋值当前href值
for ( tabs in arrs) {
ahref4[tabs].href = 'http://zbqy.updis.haomo-tech.com/wp-admin/admin.php?page=gf_entries&view=entry&id=4&lid='+ arrs[tabs] +'&order=ASC&filter&paged=1&pos=0&field_id&operator'
}
},200)
}
//点击第四个渲染
tab4.onclick = function () {
fen_homes4()
}
//分页4
for (var t = 0; t< fen4.length; t++) {
//第四个分页
fen4[t].onclick = function () {
var fens_set4 = setTimeout(() =>{
fen_homes4();
homes = setInterval(func1,500)
},500)
}
}
//第五个表格函数
function fen_homes5() {
var homes5 = setInterval(()=>{
var ahref5 = document.querySelectorAll("#elementor-tab-content-1755 td > a");
clearInterval(homes5)
var arr = [];
for (var hrefs in ahref5) {
arr.push(ahref5[hrefs].href)
}
// 截取当前href值
var arrs =[]
for (var i =0; i <arr.length; i++) {
if (arr[i]) {
arrs.push(arr[i].split('/')[arr[i].split('/').length -1])
}
}
//赋值当前href值
for ( tabs in arrs) {
ahref5[tabs].href = 'http://zbqy.updis.haomo-tech.com/wp-admin/admin.php?page=gf_entries&view=entry&id=5&lid='+ arrs[tabs] +'&order=ASC&filter&paged=1&pos=0&field_id&operator'
}
},200)
}
//第五个分页
for (var y = 0; y< fen5.length; y++) {
fen5[y].onclick = function () {
var fens_set5 = setTimeout(() =>{
fen_homes5();
homes = setInterval(func1,500)
},500)
}
}
//点击第五个渲染
tab5.onclick = function () {
fen_homes5()
}
}
var homes = setInterval(func1,2000)
网友评论