엑셀 팝업에서 메모 열 제거하고 간격 맞춤
This commit is contained in:
parent
a8e7f62a6d
commit
18f472db16
@ -27,18 +27,17 @@ $(document).ready(function(){
|
||||
clipboardPasteAction:"insert", // insert, update, replace
|
||||
placeholder:"Excel 파일을 업로드 해주세요.", //fit columns to width of table (optional)
|
||||
columns:[ //Define Table Columns
|
||||
{formatter:"rowSelection", titleFormatter:"rowSelection",clipboard:false, hozAlign:"center", headerSort:false, cellClick:function(e, cell){
|
||||
{formatter:"rowSelection", titleFormatter:"rowSelection",clipboard:false, headerHozAlign:"center", hozAlign:"center", headerSort:false, cellClick:function(e, cell){
|
||||
cell.getRow().toggleSelect();
|
||||
}
|
||||
},
|
||||
{formatter:"rownum", align:"center" ,title:"No", hozAlign:"center", headerHozAlign:"center", width:40},
|
||||
{title:"A", field:"A", hozAlign:"center", headerHozAlign: "center", width:125, validator:["maxLength:100", "string"]},
|
||||
{title:"B", field:"B", hozAlign:"center", headerHozAlign: "center", width:125, validator:["maxLength:100", "string"]},
|
||||
{title:"C", field:"C", hozAlign:"center", headerHozAlign: "center", width:125, validator:["maxLength:100", "string"]},
|
||||
{title:"D", field:"D", hozAlign:"center", headerHozAlign: "center", width:125, validator:["maxLength:100", "string"]},
|
||||
{title:"E", field:"E", hozAlign:"center", headerHozAlign: "center", width:125, validator:["maxLength:100", "string"]},
|
||||
{title:"F", field:"F", hozAlign:"center", headerHozAlign: "center", width:125, validator:["maxLength:100", "string"]},
|
||||
{title:"G", field:"G", hozAlign:"center", headerHozAlign: "center", width:125, validator:["maxLength:100", "string"]}
|
||||
{formatter:"rownum", align:"center" ,title:"No", hozAlign:"center", headerHozAlign:"center", width:60},
|
||||
{title:"A", field:"A", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]},
|
||||
{title:"B", field:"B", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]},
|
||||
{title:"C", field:"C", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]},
|
||||
{title:"D", field:"D", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]},
|
||||
{title:"E", field:"E", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]},
|
||||
{title:"F", field:"F", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]}
|
||||
],
|
||||
validationFailed:function(cell, value, parameters){ // 유효성 체크 함수
|
||||
var valid = cell.isValid();
|
||||
@ -235,7 +234,6 @@ $(document).ready(function(){
|
||||
|
||||
}
|
||||
|
||||
console.log('$tableExcel : ' ,$tableExcel);
|
||||
var addrData = $tableExcel.getData().map((row, index) => ({
|
||||
name: row.addrNm,
|
||||
phone: removeDash(row.addrPhoneNo),
|
||||
@ -378,19 +376,19 @@ function processTextData(text) {
|
||||
|
||||
//공통 테이블 업데이트 함수
|
||||
function updateTable(tableData) {
|
||||
$tableExcel.setColumns([ // 열 정의를 다시 설정
|
||||
{formatter: "rowSelection", titleFormatter: "rowSelection", clipboard: false, hozAlign: "center", headerHozAlign: "center", headerSort: false, cellClick: function(e, cell) {
|
||||
cell.getRow().toggleSelect();
|
||||
}},
|
||||
{formatter:"rownum", align:"center" ,title:"No", hozAlign:"center", headerHozAlign:"center", width:40},
|
||||
{title: "A", field: "A", hozAlign: "center", headerHozAlign: "center", width: 125, validator: ["maxLength:100", "string"]},
|
||||
{title: "B", field: "B", hozAlign: "center", headerHozAlign: "center", width: 125, validator: ["maxLength:100", "string"]},
|
||||
{title: "C", field: "C", hozAlign: "center", headerHozAlign: "center", width: 125, validator: ["maxLength:100", "string"]},
|
||||
{title: "D", field: "D", hozAlign: "center", headerHozAlign: "center", width: 125, validator: ["maxLength:100", "string"]},
|
||||
{title: "E", field: "E", hozAlign: "center", headerHozAlign: "center", width: 125, validator: ["maxLength:100", "string"]},
|
||||
{title: "F", field: "F", hozAlign: "center", headerHozAlign: "center", width: 125, validator: ["maxLength:100", "string"]},
|
||||
{title: "G", field: "G", hozAlign: "center", headerHozAlign: "center", width: 125, validator: ["maxLength:100", "string"]}
|
||||
]);
|
||||
$tableExcel.setColumns([ //Define Table Columns
|
||||
{formatter:"rowSelection", titleFormatter:"rowSelection",clipboard:false, headerHozAlign:"center", hozAlign:"center", headerSort:false, cellClick:function(e, cell){
|
||||
cell.getRow().toggleSelect();
|
||||
}
|
||||
},
|
||||
{formatter:"rownum", align:"center" ,title:"No", hozAlign:"center", headerHozAlign:"center", width:60},
|
||||
{title:"A", field:"A", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]},
|
||||
{title:"B", field:"B", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]},
|
||||
{title:"C", field:"C", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]},
|
||||
{title:"D", field:"D", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]},
|
||||
{title:"E", field:"E", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]},
|
||||
{title:"F", field:"F", hozAlign:"center", headerHozAlign: "center", width:140, validator:["maxLength:100", "string"]}
|
||||
]);
|
||||
|
||||
$tableExcel.setData(tableData).then(() => {
|
||||
// excelRowTotCnt 업데이트
|
||||
@ -412,7 +410,7 @@ function updateTableFields($objTabul) {
|
||||
{formatter: "rowSelection", titleFormatter: "rowSelection", clipboard: false, hozAlign: "center", headerHozAlign: "center", headerSort: false, cellClick: function(e, cell) {
|
||||
cell.getRow().toggleSelect();
|
||||
}}
|
||||
,{formatter:"rownum", align:"center", title:"No", hozAlign:"center", headerHozAlign:"center", width:40}
|
||||
,{formatter:"rownum", align:"center", title:"No", hozAlign:"center", headerHozAlign:"center", width:60}
|
||||
];
|
||||
|
||||
var fieldMapping = [];
|
||||
@ -428,7 +426,7 @@ function updateTableFields($objTabul) {
|
||||
, headerHozAlign: "center"
|
||||
// , editor: "input"
|
||||
, editor: false
|
||||
, width: 125
|
||||
, width: 140
|
||||
, validator: ["maxLength:100", "string"]
|
||||
});
|
||||
fieldMapping.push(selectedField);
|
||||
@ -440,7 +438,7 @@ function updateTableFields($objTabul) {
|
||||
, headerHozAlign: "center"
|
||||
, editor: false
|
||||
// , editor: "input"
|
||||
, width: 125
|
||||
, width: 140
|
||||
, validator: ["maxLength:100", "string"]
|
||||
});
|
||||
fieldMapping.push(field);
|
||||
@ -678,8 +676,8 @@ function popMore(e){
|
||||
<div class="adr_excel" style="margin-top: 13px;">
|
||||
<!-- thead -->
|
||||
<div class="adr_hd select_adr_hd" data-group="tableExcel">
|
||||
<div style="width: 80px;"></div>
|
||||
<div style="width: 125px;">
|
||||
<div style="width: 100px;"></div>
|
||||
<div style="width: 140px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
@ -689,10 +687,75 @@ function popMore(e){
|
||||
<option value="addrInfo2">[*2*]</option>
|
||||
<option value="addrInfo3">[*3*]</option>
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<option value="addrComment">메모</option>
|
||||
<!-- <option value="addrComment">메모</option> -->
|
||||
</select>
|
||||
</div>
|
||||
<div style="width: 125px;">
|
||||
<div style="width: 140px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
<option value="addrNm">이름</option>
|
||||
<option value="addrPhoneNo">휴대폰</option>
|
||||
<option value="addrInfo1">[*1*]</option>
|
||||
<option value="addrInfo2">[*2*]</option>
|
||||
<option value="addrInfo3">[*3*]</option>
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<!-- <option value="addrComment">메모</option> -->
|
||||
</select>
|
||||
</div>
|
||||
<div style="width: 140px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
<option value="addrNm">이름</option>
|
||||
<option value="addrPhoneNo">휴대폰</option>
|
||||
<option value="addrInfo1">[*1*]</option>
|
||||
<option value="addrInfo2">[*2*]</option>
|
||||
<option value="addrInfo3">[*3*]</option>
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<!-- <option value="addrComment">메모</option> -->
|
||||
</select>
|
||||
</div>
|
||||
<div style="width: 140px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
<option value="addrNm">이름</option>
|
||||
<option value="addrPhoneNo">휴대폰</option>
|
||||
<option value="addrInfo1">[*1*]</option>
|
||||
<option value="addrInfo2">[*2*]</option>
|
||||
<option value="addrInfo3">[*3*]</option>
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<!-- <option value="addrComment">메모</option> -->
|
||||
</select>
|
||||
</div>
|
||||
<div style="width: 140px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
<option value="addrNm">이름</option>
|
||||
<option value="addrPhoneNo">휴대폰</option>
|
||||
<option value="addrInfo1">[*1*]</option>
|
||||
<option value="addrInfo2">[*2*]</option>
|
||||
<option value="addrInfo3">[*3*]</option>
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<!-- <option value="addrComment">메모</option> -->
|
||||
</select>
|
||||
</div>
|
||||
<div style="width: 140px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
<option value="addrNm">이름</option>
|
||||
<option value="addrPhoneNo">휴대폰</option>
|
||||
<option value="addrInfo1">[*1*]</option>
|
||||
<option value="addrInfo2">[*2*]</option>
|
||||
<option value="addrInfo3">[*3*]</option>
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<!-- <option value="addrComment">메모</option> -->
|
||||
</select>
|
||||
</div>
|
||||
<!-- <div style="width: 125px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
@ -704,72 +767,7 @@ function popMore(e){
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<option value="addrComment">메모</option>
|
||||
</select>
|
||||
</div>
|
||||
<div style="width: 125px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
<option value="addrNm">이름</option>
|
||||
<option value="addrPhoneNo">휴대폰</option>
|
||||
<option value="addrInfo1">[*1*]</option>
|
||||
<option value="addrInfo2">[*2*]</option>
|
||||
<option value="addrInfo3">[*3*]</option>
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<option value="addrComment">메모</option>
|
||||
</select>
|
||||
</div>
|
||||
<div style="width: 125px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
<option value="addrNm">이름</option>
|
||||
<option value="addrPhoneNo">휴대폰</option>
|
||||
<option value="addrInfo1">[*1*]</option>
|
||||
<option value="addrInfo2">[*2*]</option>
|
||||
<option value="addrInfo3">[*3*]</option>
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<option value="addrComment">메모</option>
|
||||
</select>
|
||||
</div>
|
||||
<div style="width: 125px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
<option value="addrNm">이름</option>
|
||||
<option value="addrPhoneNo">휴대폰</option>
|
||||
<option value="addrInfo1">[*1*]</option>
|
||||
<option value="addrInfo2">[*2*]</option>
|
||||
<option value="addrInfo3">[*3*]</option>
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<option value="addrComment">메모</option>
|
||||
</select>
|
||||
</div>
|
||||
<div style="width: 125px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
<option value="addrNm">이름</option>
|
||||
<option value="addrPhoneNo">휴대폰</option>
|
||||
<option value="addrInfo1">[*1*]</option>
|
||||
<option value="addrInfo2">[*2*]</option>
|
||||
<option value="addrInfo3">[*3*]</option>
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<option value="addrComment">메모</option>
|
||||
</select>
|
||||
</div>
|
||||
<div style="width: 125px;">
|
||||
<label for="" class="label"></label>
|
||||
<select class="field-selector">
|
||||
<option value="">선택하기</option>
|
||||
<option value="addrNm">이름</option>
|
||||
<option value="addrPhoneNo">휴대폰</option>
|
||||
<option value="addrInfo1">[*1*]</option>
|
||||
<option value="addrInfo2">[*2*]</option>
|
||||
<option value="addrInfo3">[*3*]</option>
|
||||
<option value="addrInfo4">[*4*]</option>
|
||||
<option value="addrComment">메모</option>
|
||||
</select>
|
||||
</div>
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user