barcode(바코드) 렌더링

해당 컬럼의 데이터를 html로 편집하여 셀에 보여주기 위해서는 큐셀 프로퍼티에서 {..., type : "html", options: {html : {data: fnBarcodeRendering}}}이라고 넣어 렌더링 함수를 등록하고 원하는 편집을 하는 함수를 구현하면 됩니다.
즉, 동적으로 셀을 하나씩 만들때 바코드 값을 가지고 하나씩 html code를 넣어주는 방식으로 동적으로 생성하는 것입니다.
jQuery barcode generator 라이브러리를 로딩하여 사용하였습니다. 다른 것을 사용하려면 해당 라이브러리의 가이드를 참조하여 개발하시면 됩니다.
<script type="text/javascript" src="./js/jquery-barcode.min.js"></script>
<script type="text/javascript" src="./js/jquery-barcode.js"></script>


function fnBarcodeRendering(id, row, col, val, obj){
  var stid = 'subcell_'+row+'_'+col, tid = '#cell_'+row+'_'+col;
  html = '<div id="'+stid+'" class="rt-qc-barcode" style="height: 60px; " ></div>';

setTimeout(function(){
    $('#'+stid).barcode(val, "ean13", settings);
}, 100);

return html;
};