This commit is contained in:
make
2025-04-21 17:49:17 +08:00
parent 7ef217c1b9
commit 2337ab4f7d
942 changed files with 209166 additions and 0 deletions

View File

@@ -0,0 +1,52 @@
import {
checkIsLoginFn,
hideCctvDomByEquipmentClass,
intiHistoryHref,
init,
isSearchValid,
pageJumpFn
} from './commonFun.js';
import CommonCctv from '../cctv/common.js';
/**
* 所有页面调用的js
*/
const commonJs = function(){
document.addEventListener('DOMContentLoaded', function () {
hideCctvDomByEquipmentClass()
intiHistoryHref()
init()
CommonCctv.init()
// 格式化轮播广告和 顶部导航的间隙
function getHeaderHeight() {
if(document.getElementById('header') && document.querySelector('.j-booth-elements-header')){
var intHeaderHeight = document.getElementById('header').offsetHeight;
document.querySelector('.j-booth-elements-header').style.height = intHeaderHeight + 'px';
}
}
// 当窗口大小改变时调整高度
window.onresize = getHeaderHeight();
// 页面加载时调整高度
window.onload = getHeaderHeight();
})
}()
/**
* 会员 板块初始化
*/
const MenBerPublicJs = function () {
const selectors = [
".bill-web",".bind-web", ".buy-web", ".capital-flow-web", ".charge-web",".member-info-web",
".recfeedback-web", ".setting-web",
".withdrawal-funds-web", ".my-promotion-web",
".withdrawal-records-web"
];
if (selectors.some(selector => document.querySelector(selector))) {
window.addEventListener('load', checkIsLoginFn);
}
}()