import React, { useState, useEffect, useCallback } from 'react'; import { Link, useLocation } from 'react-router-dom'; import * as EgovNet from 'api/egovFetch'; import URL from 'constants/url'; import { default as EgovLeftNav } from 'components/leftmenu/EgovLeftNavAdmin'; import CODE from "constants/code"; import Modal from "react-bootstrap/Modal"; import AboutSiteModal from "./aboutSiteMgt/AboutSiteModal"; import {Image} from "react-bootstrap"; import {SERVER_URL} from "config"; function StandardCodeMgt(props) { const location = useLocation(); const [searchCondition, setSearchCondition] = useState(location.state?.searchCondition || { pageIndex: 1, searchCnd: '0', searchWrd: '' });// 기존 조회에서 접근 했을 시 || 신규로 접근 했을 시 const [paginationInfo, setPaginationInfo] = useState({}); const [listTag, setListTag] = useState([]); const [show, setShow] = useState(false); const [modalBody, setModalBody] = useState(); const handleClose = () => setShow(false); const handleShow = () => setShow(true); const retrieveList = useCallback(() => { handleClose(); console.groupCollapsed("AdminPartnerSiteList.retrieveList()"); const retrieveListURL = '/admin/config/about-site-mgt/list'; const requestOptions = { method: "GET", headers: { 'Content-type': 'application/json', }, body: JSON.stringify() } EgovNet.requestFetch(retrieveListURL, requestOptions, (resp) => { let mutListTag = []; listTag.push(

검색된 결과가 없습니다.

); // 게시판 목록 초기값 // 리스트 항목 구성 resp.result.partnerSiteList.forEach(function (item, index) { if (index === 0) mutListTag = []; // 목록 초기화 mutListTag.push(
{item.siteTitle}
{item.siteUrl}
이미지 window.open(e.target.src)} width={"150"}/>
{item.siteOrder}
{item.useYn}
); }); setListTag(mutListTag); console.log("@@@ resp : "); }, function (resp) { console.log("err response : ", resp); } ); console.groupEnd("EgovAdminBoardList.retrieveList()"); },[]); useEffect(() => { retrieveList(searchCondition); // eslint-disable-next-line react-hooks/exhaustive-deps }, []); function editPartnerSite(item){ handleShow(); if(item != undefined) { item.mode = CODE.MODE_MODIFY; } setModalBody() } return (
{/* */}
  • Home
  • 사이트관리
  • 환경설정
  • 관련사이트 관리
{/* */}
{/* */} {/* */}

관련사이트 관리

{/* */} {/*
  • 검색유형선택
  • 검색어 { wrdRef.current.value = e.target.value; }} />
  • 등록
*/} {/* */} {/* */}
사이트명 URL 배너이미지 정렬순서 사용여부
{listTag}
{/* */}
{/* */} {/* { retrieveList({ ...searchCondition, pageIndex: passedPage, searchCnd: cndRef.current.value, searchWrd: wrdRef.current.value }) }} />*/} {/* */}
{/* */}
{modalBody}
); } export default StandardCodeMgt;