getCellDefs 수정

main
이범준 5 months ago
parent 82b3991be0
commit 19854711a9

@ -355,27 +355,28 @@ function isEmail(str) {
/**************************************************************************
* 엑셀 파일 작성 정보 생성
**************************************************************************/
function getCellDefs($th, $td){
function getCellDefs($ths, $tds, fieldGetterOption){
var cellDefs = [];
for(var i=0; i < $th.length; i++){
for(var i=0; i < $ths.length; i++){
var label = $th.eq(i).text();
var label = $ths.eq(i).text();
label = label.replace("\n", "");
label = label.replace("\t", "");
label = label.replace(" ", "");
if(label != ""){
var width = $th.eq(i).outerWidth();
var width = $ths.eq(i).outerWidth();
width = Math.ceil(width/10) + 2;
var field = "";
if($td.eq(i).hasClass("privacy-cell")){
field = $td.eq(i).find("span:eq(0)").text();
if(fieldGetterOption != null){
field = fieldGetterOption($tds.eq(i));
} else {
field = $td.eq(i).text();
field = $tds.eq(i).text();
}
field = field.replace("{", "");
field = field.replace("}", "");
field = field.replace("\n", "");

Loading…
Cancel
Save