Browse Source

비행계획서 반경,적용(활성화,비활성화)

pull/2/head
sanguu 2 years ago
parent
commit
bf835e03cc
  1. 5
      src/components/basis/flight/plan/FlightPlanAreaDetailForm.js
  2. 2
      src/containers/basis/flight/plan/FlightPlanAreaDetailContainer.js

5
src/components/basis/flight/plan/FlightPlanAreaDetailForm.js

@ -10,7 +10,7 @@ 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;
@ -91,6 +91,8 @@ const FlightPlanAreaDetailForm = ({ handleSave, handleClose, handleChange, handl
id='bufferZone'
name='bufferZone'
bsSize='sm'
readOnly={coordList[0].lat && (mapControl.drawType===("LINE") || mapControl.drawType===("CIRCLE")) ? false : true }
placeholder='반경'
value={data ? data[0].bufferZone : ''}
onChange={(e) => {
@ -107,6 +109,7 @@ const FlightPlanAreaDetailForm = ({ handleSave, handleClose, handleChange, handl
className='mr-1'
color='primary'
size='sm'
disabled={coordList[0].lat && (mapControl.drawType===("LINE") || mapControl.drawType===("CIRCLE")) ? false : true }
onClick={() => handleBufferList()}
>
적용

2
src/containers/basis/flight/plan/FlightPlanAreaDetailContainer.js

@ -8,6 +8,7 @@ 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 +77,7 @@ const FlightPlanAreaDetailContainer = ({ handleModal }) => {
handleBufferList={handleBufferList}
areaCoordList={areaCoordList}
data={areaDetail}
mapControl={mapControl}
/>
</Col>
</Row>

Loading…
Cancel
Save