diff --git a/src/components/basis/flight/plan/FlightPlanAreaDetailForm.js b/src/components/basis/flight/plan/FlightPlanAreaDetailForm.js index 64d466e..02a2cfa 100644 --- a/src/components/basis/flight/plan/FlightPlanAreaDetailForm.js +++ b/src/components/basis/flight/plan/FlightPlanAreaDetailForm.js @@ -10,11 +10,17 @@ import { Button } from 'reactstrap'; -const FlightPlanAreaDetailForm = ({ handleSave, handleClose, handleChange, handleBufferList, data }) => { +const FlightPlanAreaDetailForm = ({ handleSave, handleClose, handleChange, handleBufferList, data, mapControl }) => { const coordList = data ? data[0].coordList : null; + useEffect(() => { + console.log("상현",mapControl.drawType); + }, [coordList]) + // console.log("성횬"+props.data[0]); + return ( + @@ -67,6 +73,7 @@ const FlightPlanAreaDetailForm = ({ handleSave, handleClose, handleChange, handl placeholdeer='' readOnly /> + } @@ -85,22 +92,27 @@ const FlightPlanAreaDetailForm = ({ handleSave, handleClose, handleChange, handl
- + { + const {name, value} = e.target; + + handleChange({ name, value }) }} - /> + />
handleBufferList()} + disabled={coordList[0].lat && (mapControl.drawType===("LINE") || mapControl.drawType===("CIRCLE")) ? false : true } + > 적용 diff --git a/src/components/basis/flight/plan/FlightPlanAreaMap.js b/src/components/basis/flight/plan/FlightPlanAreaMap.js index 30c14d5..554f52b 100644 --- a/src/components/basis/flight/plan/FlightPlanAreaMap.js +++ b/src/components/basis/flight/plan/FlightPlanAreaMap.js @@ -50,6 +50,7 @@ const FlightPlanAreaMap = (props) => { const ModeInit = () => { setMode(mapControl.drawType) + } const NaverMapInit = () => { diff --git a/src/containers/basis/flight/plan/FlightPlanAreaDetailContainer.js b/src/containers/basis/flight/plan/FlightPlanAreaDetailContainer.js index c6e5443..b1126df 100644 --- a/src/containers/basis/flight/plan/FlightPlanAreaDetailContainer.js +++ b/src/containers/basis/flight/plan/FlightPlanAreaDetailContainer.js @@ -9,6 +9,8 @@ import {initFlightBas} from '../../../../modules/basis/flight/models/basisFlight const FlightPlanAreaDetailContainer = ({ handleModal }) => { const dispatch = useDispatch(); + const mapControl = useSelector(state => state.controlMapReducer); + const { areaCoordList, detail } = useSelector(state => state.flightState); const [areaDetail, setAreaDetail] = useState(initFlightBas.initDetail.areaList); @@ -76,6 +78,7 @@ const FlightPlanAreaDetailContainer = ({ handleModal }) => { handleBufferList={handleBufferList} areaCoordList={areaCoordList} data={areaDetail} + mapControl={mapControl} />