2024/01/16 table caption script 추가
This commit is contained in:
parent
b20d9fc5ea
commit
7ecdaded3f
@ -8,7 +8,9 @@
|
||||
var chxChecked = $(this).prop("checked");
|
||||
if (chxChecked == true) {
|
||||
$(this).next("label").after("<span class='chx_label'>" + chxLabel + ' 체크됨' + "</span>");
|
||||
} else {$(this).next("label").after("<span class='chx_label'>"+chxLabel+"</span>");}
|
||||
} else {
|
||||
$(this).next("label").after("<span class='chx_label'>" + chxLabel + "</span>");
|
||||
}
|
||||
} else {}
|
||||
});
|
||||
|
||||
@ -132,6 +134,7 @@ function birthSelectBoxDraw(){
|
||||
dayDraw($(this));
|
||||
});
|
||||
}
|
||||
|
||||
function dayDraw(obj) {
|
||||
var selectValue = $(obj).attr('selectValue');
|
||||
var selectMonth = $(obj).prev().prev('select.birthMonth').val();
|
||||
@ -262,8 +265,7 @@ function date_mask(objValue){
|
||||
if (v.match(/^\d{2}$/) !== null) {
|
||||
if (event.keyCode == "8") {
|
||||
// 백스페이스 키를 누를 때 '-' 안생기게
|
||||
}
|
||||
else{
|
||||
} else {
|
||||
v = v + ':';
|
||||
}
|
||||
}
|
||||
@ -273,6 +275,7 @@ function date_mask(objValue){
|
||||
|
||||
var timeInputHouBak = 0,
|
||||
timeInputMinBak = 0;
|
||||
|
||||
function timeInput() {
|
||||
|
||||
/*$('.table_time_wrap .time_wrap').find(".time").change(function(){
|
||||
@ -576,7 +579,13 @@ function addEduClassCopy(target) {
|
||||
}
|
||||
var cloneObj = tr.clone(true);
|
||||
cloneObj.find("input[name=eduHopeDt]").closest("th,td").empty().append($('<div/>').addClass('calendar_wrap').append(
|
||||
$('<input/>').addClass('calendar').css({'width' : '80%'}).attr({'size' : '8', 'type' : 'text', 'name' : 'eduHopeDt'})
|
||||
$('<input/>').addClass('calendar').css({
|
||||
'width': '80%'
|
||||
}).attr({
|
||||
'size': '8',
|
||||
'type': 'text',
|
||||
'name': 'eduHopeDt'
|
||||
})
|
||||
));
|
||||
/* 청소년 */
|
||||
cloneObj.find('.ampm_select,.hours_select,.min_select').off("change");
|
||||
@ -861,15 +870,13 @@ function dateSetting(objValue) {
|
||||
if (v.match(/^\d{4}$/) !== null) {
|
||||
if (event.keyCode == "8") {
|
||||
// 백스페이스 키를 누를 때 '.' 안생기게
|
||||
}
|
||||
else{
|
||||
} else {
|
||||
v = v + '.';
|
||||
}
|
||||
} else if (v.match(/^\d{4}\.\d{2}$/) !== null) {
|
||||
if (event.keyCode == "8") {
|
||||
// 백스페이스 키를 누를 때 '.' 안생기게
|
||||
}
|
||||
else{
|
||||
} else {
|
||||
v = v + '.';
|
||||
}
|
||||
}
|
||||
@ -1071,10 +1078,10 @@ $(function(){
|
||||
|
||||
boardCaptionToggle();
|
||||
boardCaptionToggle02();
|
||||
|
||||
boardCaptionToggle03();
|
||||
});
|
||||
|
||||
function boardCaptionToggle() {
|
||||
/*function boardCaptionToggle() {
|
||||
var bdWid = $("body").width();
|
||||
var thLength = $(".tb_type01 th").length;
|
||||
if (bdWid > 640) {
|
||||
@ -1083,7 +1090,7 @@ $(function(){
|
||||
$(".tb_type01 th").each(function (index, item) {
|
||||
itmText += $(item).text();
|
||||
if (index === thLength - 1) {
|
||||
/* 마지막 th일 경우 - ,가 들어가면 안됨. */
|
||||
마지막 th일 경우 - ,가 들어가면 안됨.
|
||||
itmText;
|
||||
} else {
|
||||
itmText += ", ";
|
||||
@ -1105,4 +1112,94 @@ $(function(){
|
||||
} else {
|
||||
$(".tb_type01 caption").remove();
|
||||
}
|
||||
} */
|
||||
|
||||
|
||||
function boardCaptionToggle() {
|
||||
var thLength = $(".tb_type01 th").length;
|
||||
$(".tb_type01").each(function (idx, itm) {
|
||||
var subTit = $(itm).prev(".tb_tit01").find(".tb_tit01_left p").text();
|
||||
var thText = "";
|
||||
$(itm).find("th").each(function (index, item) {
|
||||
thText += $(item).text();
|
||||
if (index === thLength - 1) {
|
||||
//마지막 th일 경우 - ,가 들어가면 안됨.
|
||||
thText;
|
||||
} else {
|
||||
thText += ", ";
|
||||
}
|
||||
|
||||
})
|
||||
if ($(".tb_type01 caption").length == 0) {
|
||||
if($(itm).is(".tb_input")){
|
||||
$(itm).find("table").prepend("<caption>" + subTit + " : " + thText + "등의 정보입력 </caption>");
|
||||
}else{
|
||||
$(itm).find("table").prepend("<caption>" + subTit + " : " + thText + "등의 정보제공 </caption>");
|
||||
}
|
||||
|
||||
} else {
|
||||
$(itm).find("caption").remove();
|
||||
if($(itm).is(".tb_input")){
|
||||
$(itm).find("table").prepend("<caption>" + subTit + " : " + thText + "등의 정보입력 </caption>");
|
||||
}else{
|
||||
$(itm).find("table").prepend("<caption>" + subTit + " : " + thText + "등의 정보제공 </caption>");
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
function boardCaptionToggle02() {
|
||||
var thLength = $(".tb_list01 th").length;
|
||||
$(".tb_list01").each(function (idx, itm) {
|
||||
var subTit = $(itm).siblings(".cont_tit").find("h2").text()
|
||||
var thText = "";
|
||||
$(itm).find("th").each(function (index, item) {
|
||||
thText += $(item).text();
|
||||
if (index === thLength - 1) {
|
||||
//마지막 th일 경우 - ,가 들어가면 안됨.
|
||||
thText;
|
||||
} else {
|
||||
thText += ", ";
|
||||
}
|
||||
|
||||
})
|
||||
if ($(".tb_list01 caption").length == 0) {
|
||||
$(itm).find("table").prepend("<caption>" + subTit + " : " + thText + "등의 정보제공 </caption>");
|
||||
} else {
|
||||
$(itm).find("caption").remove();
|
||||
$(itm).find("table").prepend("<caption>" + subTit + " : " + thText + "등의 정보제공 </caption>");
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
function boardCaptionToggle03() {
|
||||
var thLength = $(".tb_type02 thead th").length;
|
||||
$(".tb_type02").each(function (idx, itm) {
|
||||
var subTit = $(itm).prev(".tb_tit01").find(".tb_tit01_left p").text();
|
||||
var thText = "";
|
||||
$(itm).find("thead th").each(function (index, item) {
|
||||
thText += $(item).text();
|
||||
if (index === thLength - 1) {
|
||||
//마지막 th일 경우 - ,가 들어가면 안됨.
|
||||
thText;
|
||||
} else {
|
||||
thText += ", ";
|
||||
}
|
||||
|
||||
})
|
||||
if ($(".tb_type02 caption").length == 0) {
|
||||
if($(itm).is(".tb_type02_write")){
|
||||
$(itm).find("table").prepend("<caption>" + subTit + " : " + thText + "등의 정보입력 </caption>");
|
||||
}else{
|
||||
$(itm).find("table").prepend("<caption>" + subTit + " : " + thText + "등의 정보제공 </caption>");
|
||||
}
|
||||
|
||||
} else {
|
||||
$(itm).find("caption").remove();
|
||||
if($(itm).is(".tb_type02_write")){
|
||||
$(itm).find("table").prepend("<caption>" + subTit + " : " + thText + "등의 정보입력 </caption>");
|
||||
}else{
|
||||
$(itm).find("table").prepend("<caption>" + subTit + " : " + thText + "등의 정보제공 </caption>");
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user