This commit is contained in:
hylee 2024-09-11 17:44:13 +09:00
commit 3b093dcdb1
2 changed files with 47 additions and 48 deletions

View File

@ -451,7 +451,7 @@ function GetAddrMassDupli() {
<div class="adr_excel" style="margin-top: 13px;">
<div class="adr_excel" style="margin-top: 13px; overflow-x: auto;">
<!-- thead -->
<div class="adr_hd select_adr_hd" data-group="tableClip">
<div style="width: 80px;"></div>

View File

@ -152,6 +152,52 @@ $(document).ready(function(){
fn_selfmakeTable()
// 타뷸레이터 width값 변경 시 위에 select width 값 변경
var titleArray = ["A","B","C","D","E","F","G"];
$tableExcel.on("columnWidth",function(column){
var titleIndex = titleArray.indexOf(column._column.definition.title);
titleIndex += 1;
console.log(titleIndex)
if(titleIndex != 0){
$('.tableExcel .select_adr_hd>div').eq(titleIndex).css('width', column._column.width);
}else{
$('.tableExcel .select_adr_hd>div').eq(0).css('width', column._column.width + 40);
}
});
$tableExcel.on("scrollHorizontal",function(left){
$(".tableExcel .adr_excel").scrollLeft(left);
})
$(".tableExcel .adr_excel").on("scroll",function(){
$(".tableExcel .tabulator-tableholder").scrollLeft($(this).scrollLeft());
});
$tableClip.on("columnWidth",function(column){
var titleIndex = titleArray.indexOf(column._column.definition.title);
titleIndex += 1;
console.log(titleIndex)
if(titleIndex != 0){
$('.tableClip .select_adr_hd>div').eq(titleIndex).css('width', column._column.width);
}else{
$('.tableClip .select_adr_hd>div').eq(0).css('width', column._column.width + 40);
}
});
$tableClip.on("scrollHorizontal",function(left){
$(".tableClip .adr_excel").scrollLeft(left);
})
$(".tableClip .adr_excel").on("scroll",function(){
$(".tableClip .tabulator-tableholder").scrollLeft($(this).scrollLeft());
});
});
@ -217,51 +263,4 @@ function fn_selfmakeTable(){
// 타뷸레이터 width값 변경 시 위에 select width 값 변경
var titleArray = ["A","B","C","D","E","F","G"];
$tableExcel.on("columnWidth",function(column){
var titleIndex = titleArray.indexOf(column._column.definition.title);
titleIndex += 1;
console.log(titleIndex)
if(titleIndex != 0){
$('.tableExcel .select_adr_hd>div').eq(titleIndex).css('width', column._column.width);
console.log("d")
}else{
console.log("a")
$('.tableExcel .select_adr_hd>div').eq(0).css('width', column._column.width + 40);
}
});
$tableExcel.on("scrollHorizontal",function(left){
$(".tableExcel .adr_excel").scrollLeft(left);
})
$(".tableExcel .adr_excel").on("scroll",function(){
$(".tableExcel .tabulator-tableholder").scrollLeft($(this).scrollLeft());
});
$tableClip.on("columnWidth",function(column){
var titleIndex = titleArray.indexOf(column._column.definition.title);
titleIndex += 1;
console.log(titleIndex)
if(titleIndex != 0){
$('.tableClip .select_adr_hd>div').eq(titleIndex).css('width', column._column.width);
console.log("d")
}else{
console.log("a")
$('.tableClip .select_adr_hd>div').eq(0).css('width', column._column.width + 40);
}
});
$tableClip.on("scrollHorizontal",function(left){
$(".tableClip .adr_excel").scrollLeft(left);
})
$(".tableClip .adr_excel").on("scroll",function(){
$(".tableClip .tabulator-tableholder").scrollLeft($(this).scrollLeft());
});