게시판관리 최종수정일, 사용여부 표시
parent
0d338b97b1
commit
274ade0af0
|
|
@ -53,6 +53,8 @@ function EgovAdminBoardList(props) {
|
|||
// 리스트 항목 구성
|
||||
resp.result.boardList.forEach(function (item, index) {
|
||||
if (index === 0) mutListTag = []; // 목록 초기화
|
||||
const finalModifiedDate = item.lastChgDt ? item.lastChgDt : item.frstCrtDt;
|
||||
const formattedDate = finalModifiedDate ? format(finalModifiedDate, "yyyy-MM-dd HH:mm") : "";
|
||||
|
||||
mutListTag.push(
|
||||
<div className="list_item">
|
||||
|
|
@ -60,8 +62,8 @@ function EgovAdminBoardList(props) {
|
|||
<div>{item.bbsId}</div>
|
||||
<div>{item.bbsTitle}</div>
|
||||
<div>{item.frstCrtId}</div>
|
||||
<div>{item.frstCrtDt ? format(item.frstCrtDt, "yyyy-MM-dd HH:mm") : ""}</div>
|
||||
<div>{item.lastChgDt ? format(item.lastChgDt, "yyyy-MM-dd HH:mm") : ""}</div>
|
||||
<div>{formattedDate}</div>
|
||||
<div>{item.useYn}</div>
|
||||
<div><button className={"btn btn_blue_h31 px-1"} onClick={()=>{editBoard(item)}}>수정</button></div>
|
||||
</div>
|
||||
);
|
||||
|
|
@ -79,7 +81,6 @@ function EgovAdminBoardList(props) {
|
|||
|
||||
useEffect(() => {
|
||||
retrieveList(searchCondition);
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
}, []);
|
||||
|
||||
function editBoard(item){
|
||||
|
|
@ -118,44 +119,6 @@ function EgovAdminBoardList(props) {
|
|||
<h1 className="tit_1">게시판 관리</h1>
|
||||
</div>
|
||||
|
||||
|
||||
{/* <!-- 검색조건 --> */}
|
||||
{/*<div className="condition">
|
||||
<ul>
|
||||
<li className="third_1 L">
|
||||
<span className="lb">검색유형선택</span>
|
||||
<label className="f_select" htmlFor="searchCnd">
|
||||
<select id="searchCnd" name="searchCnd" title="검색유형선택" ref={cndRef}
|
||||
onChange={e => {
|
||||
cndRef.current.value = e.target.value;
|
||||
}}
|
||||
>
|
||||
<option value="0">게시판명</option>
|
||||
<option value="1">게시판유형</option>
|
||||
</select>
|
||||
</label>
|
||||
</li>
|
||||
<li className="third_2 R">
|
||||
<span className="lb">검색어</span>
|
||||
<span className="f_search w_400">
|
||||
<input type="text" name="" defaultValue={searchCondition && searchCondition.searchWrd} placeholder="" ref={wrdRef}
|
||||
onChange={e => {
|
||||
wrdRef.current.value = e.target.value;
|
||||
}}
|
||||
/>
|
||||
<button type="button"
|
||||
onClick={() => {
|
||||
retrieveList({ ...searchCondition, pageIndex: 1, searchCnd: cndRef.current.value, searchWrd: wrdRef.current.value });
|
||||
}}>조회</button>
|
||||
</span>
|
||||
</li>
|
||||
<li>
|
||||
<Link to={URL.ADMIN_BOARD_CREATE} className="btn btn_blue_h46 pd35">등록</Link>
|
||||
</li>
|
||||
</ul>
|
||||
</div>*/}
|
||||
{/* <!--// 검색조건 --> */}
|
||||
|
||||
{/* <!-- 게시판목록 --> */}
|
||||
<div className="board_list BRD006">
|
||||
<div className="head">
|
||||
|
|
@ -163,8 +126,8 @@ function EgovAdminBoardList(props) {
|
|||
<span>아이디</span>
|
||||
<span>제목</span>
|
||||
<span>작성자</span>
|
||||
<span>작성일</span>
|
||||
<span>수정일</span>
|
||||
<span>최종수정일</span>
|
||||
<span>사용여부</span>
|
||||
<span><button className={"btn btn_blue_h31 px-1"} onClick={()=>{editBoard(undefined)}}>추가</button></span>
|
||||
</div>
|
||||
<div className="result">
|
||||
|
|
@ -174,11 +137,6 @@ function EgovAdminBoardList(props) {
|
|||
{/* <!--// 게시판목록 --> */}
|
||||
|
||||
<div className="board_bot">
|
||||
{/* <!-- Paging --> */}
|
||||
{/*<EgovPaging pagination={paginationInfo} moveToPage={passedPage => {
|
||||
retrieveList({ ...searchCondition, pageIndex: passedPage, searchCnd: cndRef.current.value, searchWrd: wrdRef.current.value })
|
||||
}} />*/}
|
||||
{/* <!--/ Paging --> */}
|
||||
</div>
|
||||
|
||||
{/* <!--// 본문 --> */}
|
||||
|
|
|
|||
Loading…
Reference in New Issue