1. 그리드 제목 가운데정렬되도록 수정

2. 브라우저별 가로스크롤 높이에 따른 스크롤이벤트 수정
main
이범준 1 year ago
parent cb9cf32a81
commit dd0a7e0d0a

@ -313,7 +313,8 @@ $(document).ready(function(){
if(el.scrollTop() == 0){
return;
}
if((el[0].scrollHeight - el.scrollTop() + 15) == el.outerHeight()){
if((el[0].scrollHeight - el.scrollTop() + VERTICAL_SCROLL_HEIGHT) == el.outerHeight()){
$P.scrollCrdnList();
}
});
@ -336,4 +337,5 @@ $(document).ready(function(){
}
});
</script>

@ -229,7 +229,7 @@ $(document).ready(function(){
{ header: '위반일시', name: 'CRDN_YMD_TM', width: 120, className: 'text-center' },
{ header: '차량번호', name: 'VHRNO', width: 80, className: 'text-center' },
{ header: '법정동', name: 'CRDN_STDG_NM', width: 80, className: 'text-center' },
{ header: '신고/단속자', name: 'CVLCPT_APLCNT_NM000', width: 80, className: 'text-center' },
{ header: '신고/단속자', name: 'APLCNT_CRDN_NM', width: 80, className: 'text-center' },
{ header: '잔액', name: 'UNKNOWN2', width: 80, className: 'text-end' },
{ header: '영상매체', name: 'UNKNOWN3', width: 80, className: 'text-center' },
{ header: '사진건수', name: 'ATCH_FILE_CNT', width: 40, className: 'text-center' },
@ -273,7 +273,7 @@ $(document).ready(function(){
if(el.scrollTop() == 0){
return;
}
if((el[0].scrollHeight - el.scrollTop() + 15) == el.outerHeight()){
if((el[0].scrollHeight - el.scrollTop() + VERTICAL_SCROLL_HEIGHT) == el.outerHeight()){
$P.scrollCrdnList();
}
});

@ -292,7 +292,7 @@ $(document).ready(function(){
if(el.scrollTop() == 0){
return;
}
if((el[0].scrollHeight - el.scrollTop() + 15) == el.outerHeight()){
if((el[0].scrollHeight - el.scrollTop() + VERTICAL_SCROLL_HEIGHT) == el.outerHeight()){
$P.scrollCrdnList();
}
});

@ -42,6 +42,36 @@
<script>
let pageObject = {};
function getBrowserName() {
var agent = navigator.userAgent.toUpperCase();
if (agent.indexOf('TRIDENT') >= 0) {
return 'IE';
} else if (agent.indexOf('FIREFOX') >= 0) {
return 'FIREFOX';
} else if (agent.indexOf('EDG') >= 0) {
return 'EDGE';
} else if (agent.indexOf('SAFARI') >= 0) {
return 'SAFARI';
} else if (agent.indexOf('CHROME') >= 0) {
return 'CHROME';
} else {
return '';
}
}
const BROWSER_NAME = getBrowserName();
const VERTICAL_SCROLL_HEIGHT = 15;
switch(BROWSER_NAME){
case "EDGE" :
VERTICAL_SCROLL_HEIGHT = 15;
break;
case "FIREFOX" :
VERTICAL_SCROLL_HEIGHT = 17;
break;
case "CHROME" :
VERTICAL_SCROLL_HEIGHT = 17;
break;
}
${functions}
${topScript}

@ -40,6 +40,7 @@ var initGrid = (gridOptions) => {
if(!gClass){
gClass = "";
}
var thClass = gClass.replace("text-start","").replace("texter-center","").replace("text-end","");
var titleClickEvent = ``;
@ -59,7 +60,7 @@ var initGrid = (gridOptions) => {
}
strThs += `<th
tabindex="0" rowspan="1" colspan="1" class="sorting ${gClass}"
tabindex="0" rowspan="1" colspan="1" class="sorting text-center ${thClass}"
style="width: ${gWidth};"
${gHidden}
onclick="${titleClickEvent}"

Loading…
Cancel
Save