Merge remote-tracking branch 'origin/master'

This commit is contained in:
KNKIM 2021-08-06 16:54:58 +09:00
commit 3022eb82e8
3 changed files with 10 additions and 69 deletions

View File

@ -90,38 +90,24 @@ window.onload = function() {
return data.promise(); return data.promise();
} // loadData } // loadData
}, },
rowClick: function(args) { // 행 클릭 시, 실행되는 이벤트 함수
// 클릭된 행의 자료 객체
var getData = args.item;
// 추출할 컬럼의 데이터 가져오기
var articleNo = getData["articleNo"];
// 상세 내용 보기
fn_view_detail(articleNo);
},
//====================================== //======================================
// 그리드 컬럼 정의 (각 요청에 맞게 조정) // 그리드 컬럼 정의 (각 요청에 맞게 조정)
//====================================== //======================================
fields: [ fields: [
{ title:"번호", name: "articleNo" , type: "number" , width: 50, align: "center"}, { width: 80, align: "center" , itemTemplate: function (_, item) {
{ title:"자료명", name: "rentItem", type: "text" , width: 200, align: "center" }, var btn = $("<input type='checkbox'>").click(function (e) {
{ title:"관리번호", name: "ctrlNum", type: "number", width: 50, align: "center" }, alert("chk");
{ title:"저자", name: "author", type: "text", width: 100, align: "center"},
{ title:"출판사", name: "publisher", type: "text", width: 100, align: "center"},
{ title:"대여일", name: "rentDate", type: "text", width: 100, align: "center"},
{ title:"반납예정일", name: "retDueDate", type: "text", width: 100, align: "center"},
{ title:"대출연장", name: "loanExtension", type: "text", width: 80, align: "center" , itemTemplate: function (_, item) {
var btn = $("<button type='button'>").text("연장").click(function (e) {
alert("Clicked!");
e.stopPropagation(); e.stopPropagation();
}); });
return $("<div>").append(item.loanExtension).append("&nbsp;&nbsp;&nbsp;").append(btn); return $("<div>").append(item.loanExtension).append("&nbsp;&nbsp;&nbsp;").append(btn);
} }
} },
{ title:"번호", name: "articleNo" , type: "number" , width: 50, align: "center"},
{ title:"자료명", name: "rentItem", type: "text" , width: 200, align: "center" },
{ title:"관리번호", name: "ctrlNum", type: "number", width: 50, align: "center" },
{ title:"저자", name: "author", type: "text", width: 100, align: "center"},
{ title:"출판사", name: "publisher", type: "text", width: 100, align: "center"}
] ]
}); });
@ -141,13 +127,6 @@ window.onload = function() {
}; // window.onload }; // window.onload
// 선택한 게시글 상세 보기로 이동
function fn_view_detail(articleNo) {
$("#articleNo").val(articleNo);
$("#articleForm").attr("action", "${pageContext.request.contextPath}/board/selectQnA.do");
$("#articleForm").submit();
}
// 그리드 데이터 조회 호출 // 그리드 데이터 조회 호출
function fn_search_article(pageSize, pageIndex) { function fn_search_article(pageSize, pageIndex) {
$("#jsGrid").jsGrid("search" $("#jsGrid").jsGrid("search"

View File

@ -91,17 +91,6 @@ window.onload = function() {
} // loadData } // loadData
}, },
rowClick: function(args) { // 행 클릭 시, 실행되는 이벤트 함수
// 클릭된 행의 자료 객체
var getData = args.item;
// 추출할 컬럼의 데이터 가져오기
var articleNo = getData["articleNo"];
// 상세 내용 보기
fn_view_detail(articleNo);
},
//====================================== //======================================
// 그리드 컬럼 정의 (각 요청에 맞게 조정) // 그리드 컬럼 정의 (각 요청에 맞게 조정)
@ -112,8 +101,7 @@ window.onload = function() {
{ title:"관리번호", name: "ctrlNum", type: "number", width: 50, align: "center" }, { title:"관리번호", name: "ctrlNum", type: "number", width: 50, align: "center" },
{ title:"저자", name: "author", type: "text", width: 100, align: "center"}, { title:"저자", name: "author", type: "text", width: 100, align: "center"},
{ title:"출판사", name: "publisher", type: "text", width: 100, align: "center"}, { title:"출판사", name: "publisher", type: "text", width: 100, align: "center"},
{ title:"대여일", name: "rentDate", type: "text", width: 100, align: "center"}, { title:"취소일자", name: "rentDate", type: "text", width: 100, align: "center"}
{ title:"반납예정일", name: "retDueDate", type: "text", width: 100, align: "center"}
] ]
}); });
@ -132,14 +120,6 @@ window.onload = function() {
}; // window.onload }; // window.onload
// 선택한 게시글 상세 보기로 이동
function fn_view_detail(articleNo) {
$("#articleNo").val(articleNo);
$("#articleForm").attr("action", "${pageContext.request.contextPath}/board/selectQnA.do");
$("#articleForm").submit();
}
// 그리드 데이터 조회 호출 // 그리드 데이터 조회 호출
function fn_search_article(pageSize, pageIndex) { function fn_search_article(pageSize, pageIndex) {
$("#jsGrid").jsGrid("search" $("#jsGrid").jsGrid("search"

View File

@ -91,18 +91,6 @@ window.onload = function() {
} // loadData } // loadData
}, },
rowClick: function(args) { // 행 클릭 시, 실행되는 이벤트 함수
// 클릭된 행의 자료 객체
var getData = args.item;
// 추출할 컬럼의 데이터 가져오기
var articleNo = getData["articleNo"];
// 상세 내용 보기
fn_view_detail(articleNo);
},
//====================================== //======================================
// 그리드 컬럼 정의 (각 요청에 맞게 조정) // 그리드 컬럼 정의 (각 요청에 맞게 조정)
//====================================== //======================================
@ -141,12 +129,6 @@ window.onload = function() {
}; // window.onload }; // window.onload
// 선택한 게시글 상세 보기로 이동
function fn_view_detail(articleNo) {
$("#articleNo").val(articleNo);
$("#articleForm").attr("action", "${pageContext.request.contextPath}/board/selectQnA.do");
$("#articleForm").submit();
}
// 그리드 데이터 조회 호출 // 그리드 데이터 조회 호출
function fn_search_article(pageSize, pageIndex) { function fn_search_article(pageSize, pageIndex) {