diff --git a/egovframe-template-simple-react-contribution/src/css/component.css b/egovframe-template-simple-react-contribution/src/css/component.css index 058c969..af823cc 100644 --- a/egovframe-template-simple-react-contribution/src/css/component.css +++ b/egovframe-template-simple-react-contribution/src/css/component.css @@ -32,9 +32,11 @@ /* Board */ .board_list {border-top: 2px solid #222;} .board_list .head {display: table; table-layout: fixed; width: 100%;} -.board_list .head > span {display: table-cell; padding: 25px 0 27px 0; border-bottom: 1px solid #888; font-size: 16px; font-weight: 500px; text-align: center;} +/* changed by lim padding: 25px 0 27px 0; */ +.board_list .head > span {display: table-cell; padding: 10px 0 10px 0; border-bottom: 1px solid #888; font-size: 16px; font-weight: 500px; text-align: center;} .board_list .result .list_item {display: table; width: 100%; table-layout: fixed;} -.board_list .result .list_item > div {display: table-cell; padding: 18px 0 20px 0; border-bottom: 1px solid #dde2e5; color: #666; font-size: 16px; text-align: center; vertical-align: middle;} +/* changed by lim padding: 18px 0 20px 0; */ +.board_list .result .list_item > div {display: table-cell; padding: 7px 0 7px 0; border-bottom: 1px solid #dde2e5; color: #666; font-size: 16px; text-align: center; vertical-align: middle;} .board_list .result .list_item > div.al {padding: 18px 30px 20px 30px; text-align: left;} .board_list .result .list_item > div.reply {position: relative; padding: 18px 30px 20px 52px;} .board_list .result .list_item > div.reply::before {content: ""; display: block; position: absolute; left: 27px; top: 24px; width: 22px; height: 14px; background: url(css/images/ico_reply.png) no-repeat;} @@ -245,7 +247,7 @@ select::-ms-expand {display:none;} /* Title */ -.tit_1 {position: relative; padding-bottom: 50px; color: #222; font-size: 48px; font-weight: 500; letter-spacing: -2px; line-height: 48px;} +.tit_1 {position: relative; padding-bottom: 20px; color: #222; font-size: 38px; font-weight: 500; letter-spacing: -2px; line-height: 48px;} /* changed by lim padding-bottom: 50px; font-size: 48px;*/ .tit_1::after {content: ""; display: block; position: absolute; left: 0; bottom: 0; width: 30px; height: 2px; background: #0465be;} .tit_2 {font-size: 30px; font-weight: 700;} diff --git a/egovframe-template-simple-react-contribution/src/pages/admin/logs/PrivacyLogs.jsx b/egovframe-template-simple-react-contribution/src/pages/admin/logs/PrivacyLogs.jsx index cad6625..d3a9a6b 100644 --- a/egovframe-template-simple-react-contribution/src/pages/admin/logs/PrivacyLogs.jsx +++ b/egovframe-template-simple-react-contribution/src/pages/admin/logs/PrivacyLogs.jsx @@ -1,13 +1,147 @@ -import React from 'react'; +import React, { useState, useEffect, useCallback, useRef } from 'react'; +import { Link, useLocation } from 'react-router-dom'; +import * as EgovNet from 'api/egovFetch'; +import URL from 'constants/url'; -function UserConnections(props) { +import { default as EgovLeftNav } from 'components/leftmenu/EgovLeftNavAdmin'; +import EgovPaging from 'components/EgovPaging'; + +import { itemIdxByPage } from 'utils/calc'; + +function PrivacyConnections(props) { + // console.group("EgovAdminPrivacyList"); + // console.log("[Start] EgovAdminPrivacyList ------------------------------"); + // console.log("EgovAdminPrivacyList [props] : ", props); + + const location = useLocation(); + // console.log("EgovAdminPrivacyList [location] : ", location); + + // const cndRef = useRef(); + // const wrdRef = useRef(); + + // eslint-disable-next-line no-unused-vars + const [searchCondition, setSearchCondition] = useState(location.state?.searchCondition || { pageIndex: 1, searchCnd: '0', searchWrd: '' });// 기존 조회에서 접근 했을 시 || 신규로 접근 했을 시 + const [paginationInfo, setPaginationInfo] = useState({}); + + const [listTag, setListTag] = useState([]); + + const retrieveList = useCallback((srchCnd) => { + // console.groupCollapsed("EgovAdminUsageList.retrieveList()"); + + const retrieveListURL = '/admin/logs/privacy'; + + const requestOptions = { + method: "POST", + headers: { + 'Content-type': 'application/json', + }, + body: JSON.stringify(srchCnd) + } + + EgovNet.requestFetch(retrieveListURL, + requestOptions, + (resp) => { + setPaginationInfo(resp.result.paginationInfo); + + let mutListTag = []; + listTag.push(
데이터가 없습니다.
); // 게시판 목록 초기값 + + const resultCnt = parseInt(resp.result.resultCnt); + const currentPageNo = resp.result.paginationInfo.currentPageNo; + const pageSize = resp.result.paginationInfo.pageSize; + + const startIndex = (currentPageNo - 1) * pageSize; + const endIndex = Math.min(startIndex + pageSize, resultCnt); + + // 리스트 항목 구성 + for (let index = startIndex; index < endIndex; index++) { + const listIdx = itemIdxByPage(resultCnt, currentPageNo, 0, index); // pageSize 로 넣으면 listIdx값이 2배씩 줄어서 0으로 수정 + const item = resp.result.resultList[index]; + + mutListTag.push( +