퍼블 업뎃
parent
9cd309c4db
commit
6849850039
|
|
@ -1,6 +1,6 @@
|
|||
import React from 'react';
|
||||
|
||||
import { NavLink } from 'react-router-dom';
|
||||
import {NavLink, useLocation} from 'react-router-dom';
|
||||
import {Accordion} from "react-bootstrap";
|
||||
|
||||
import Row from 'react-bootstrap/Row';
|
||||
|
|
@ -10,10 +10,28 @@ import Button from 'react-bootstrap/Button';
|
|||
import URL from 'constants/url';
|
||||
|
||||
function EgovLeftNavIntro() {
|
||||
// 활성화 임시키 (상황에 맞게 사용하세요)
|
||||
let activeKey = 0;
|
||||
const location = useLocation();
|
||||
const getLastFolder = (url) => { // 중간 폴더를 가져오는 로직 추가
|
||||
const parts = url.split('/').filter(Boolean); // '/'로 분할하고 빈 문자열을 필터링
|
||||
if (parts.length >= 2) {
|
||||
return parts[2]; // 3번째 폴더 반환
|
||||
}
|
||||
return null;
|
||||
};
|
||||
const activeFolder = getLastFolder(location.pathname);
|
||||
|
||||
return (
|
||||
let activeKey;
|
||||
if (activeFolder === "3") {
|
||||
activeKey = 1;
|
||||
} else if (activeFolder === "4") {
|
||||
activeKey = 2;
|
||||
} else if (activeFolder === "5") {
|
||||
activeKey = 3;
|
||||
} else {
|
||||
activeKey = 0;
|
||||
}
|
||||
|
||||
return (
|
||||
<div className="nav2">
|
||||
<div className="inner">
|
||||
<Row className={"pt-4 pb-2 mb-1"}>
|
||||
|
|
|
|||
|
|
@ -56,7 +56,8 @@ const URL = {
|
|||
STANDARD_CODE_INFO : "/standardCode/info", //건설기준코드/건설기준코드 안내
|
||||
STANDARD_CODE_TERM : "/standardCode/term", //건설기준코드/건설기준코드 용어
|
||||
STANDARD_CODE_ENG : "/standardCode/eng", //건설기준코드/영문 건설기준코드
|
||||
STANDARD_CODE_OLD : "/standardCode/old", //건설기준코드/(구)건설기준코드
|
||||
STANDARD_CODE_OLD : "/standardCode/old/:Code", //건설기준코드/(구)건설기준코드
|
||||
STANDARD_CODE_OLD_NOCODE : "/standardCode/old", //건설기준코드/(구)건설기준코드
|
||||
STANDARD_CODE_LIST : "/standardCode/list", //건설기준코드/리스트
|
||||
STANDARD_CODE_LIST_LINK : "/standardCode/list/:listCode", //건설기준코드/리스트
|
||||
STANDARD_CODE_DETAIL : "/standardCode/detail", //건설기준코드/리스트
|
||||
|
|
|
|||
|
|
@ -103,7 +103,7 @@ body {min-width: 1400px;}
|
|||
.c_wrap .layout .nav2 ul li a.cur {color: #222; font-weight: 700; }
|
||||
|
||||
.c_wrap .layout .contents .border-secondary {border : 1px solid #6c757d;}
|
||||
.c_wrap .layout .contents .border-secondary-no_top {border-left: 1px solid #6c757d; border-right: 1px solid #6c757d; border-bottom: 1px solid #6c757d; height: 400px; overflow-y: scroll;}
|
||||
.c_wrap .layout .contents .border-secondary-no_top {border-left: 1px solid #6c757d; border-right: 1px solid #6c757d; border-bottom: 1px solid #6c757d; height: 500px; overflow-y: scroll;}
|
||||
|
||||
.c_wrap .layout .contents {display: table-cell; width: auto; vertical-align: top; padding-left: 30px;}
|
||||
|
||||
|
|
|
|||
|
|
@ -274,7 +274,7 @@ function EgovMain(props) {
|
|||
</Row>
|
||||
<Row>
|
||||
<Col>
|
||||
<Link to={URL.STANDARD_CODE_OLD} className="link-wrapper">
|
||||
<Link to={URL.STANDARD_CODE_OLD_NOCODE+'/5'} className="link-wrapper">
|
||||
<div className={"topbox_13"}><img src="/assets/images/ico-landing5.png" /></div>
|
||||
<div className={"topbox_14"}>훈령/예규/지침</div>
|
||||
</Link>
|
||||
|
|
|
|||
|
|
@ -10,8 +10,6 @@ import Button from 'react-bootstrap/Button';
|
|||
|
||||
function CodeOld(){
|
||||
|
||||
|
||||
|
||||
return (
|
||||
<div className="container">
|
||||
<div className="c_wrap">
|
||||
|
|
|
|||
Loading…
Reference in New Issue