From 027f2b8cc39a46834374fec37e40764d464e7252 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?junh=5Feee=28=EC=9D=B4=EC=A4=80=ED=9D=AC=29?= Date: Thu, 14 Dec 2023 16:12:17 +0900 Subject: [PATCH] =?UTF-8?q?=EB=93=9C=EB=A1=A0=EA=B5=90=ED=86=B5=EA=B4=80?= =?UTF-8?q?=EB=A6=AC=20uam=EB=85=B8=EC=84=A0=20=EB=B0=8F=20=EC=86=A1?= =?UTF-8?q?=EC=A0=84=EC=84=A0=EB=A1=9C=20=ED=91=9C=EC=B6=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/assets/images/transmission_tower_icon.png | Bin 0 -> 1913 bytes src/components/map/geojson/uamRouteArea.json | 639 ++++++++++ src/components/map/geojson/uamTowerArea.json | 1076 +++++++++++++++++ .../map/mapbox/feature/FeatureAirZone.js | 137 ++- .../basis/flight/actions/basisFlightAction.ts | 19 +- .../basis/flight/apis/basisFlightApi.ts | 5 + .../basis/flight/models/basisFlightModel.ts | 19 +- .../flight/reducers/basisFlightReducer.ts | 8 +- .../basis/flight/sagas/basisFlightSaga.ts | 26 + 9 files changed, 1923 insertions(+), 6 deletions(-) create mode 100644 src/assets/images/transmission_tower_icon.png create mode 100644 src/components/map/geojson/uamRouteArea.json create mode 100644 src/components/map/geojson/uamTowerArea.json diff --git a/src/assets/images/transmission_tower_icon.png b/src/assets/images/transmission_tower_icon.png new file mode 100644 index 0000000000000000000000000000000000000000..2b1ad2fb1f062897218592d2dab45470734be4b0 GIT binary patch literal 1913 zcmaJ?dsNeQ7%e*MDC*>)7DWgJ1Y77MP@%<63n{j0fz?j%0hqQa1W41hffhP-0;0%E z=RCs=x7mS;GLU&Dq9~xExCuk%3lRry_+WEbCp(C`Ep?*%V=O1h?{V(E-}n8#o0Edr z=p|EWvuP9xWvWaHDabLv{=7*g-$j2O!^pv%ki-)!a4lhi4G2Z7!Bq$#!{B5@fxw!q z_bwm{DU^xxP-Q$3FJCTH;}{#ZW7uX)PqHbLg^SF3Se=FtfC@=Qbt1;li6#bsYDA1U zzML!9M&9Fxh!HU+bBLo$aa5C}M2kOP82BqGR|r6XW-kk05c zrT`&EwE@)=D6RwSim(dLAVdr@*?+3Q^si)f#+N5Wo*Bms>p46&*Iv~aP%i&}D2Ba4 z8wmySI^X{kHY&692uFb!@eG5S?48!f9!f8aG$1g6812DAA< zKpd*m;3nhz7X-OnDAO4USf@s0kcdG_uu)Va6br(_#M}^QK`1Yj$CF3|kRT$8%a4c( zju7(&5@?JI;pz+w(Gg=@&1?n4XLbAqF%P(L@<=40utq5FJ04h;j8^ay8@U z5;-oHLngzqclKYM9@`@AW1qgVF1dJRendw)-auO0TRk_Q{9^9QAhFVX<6>EwR4H~l zKZNyGw_7iVEMq0DzbEdFk|`et73H-Z@O`Rao(%f-t>L;afG%3j+Zvo^k#>ETZF#O2 zJyOoeb6^SNaO2J<)mp}s?6&(gi$hN|6&HG^pLG-`c@~vhksP3yy3aN0wqM;Y`UFw% zahC__4F68ntf=x<+Ny@WSXImK%#~|Q?vWm6DvHl0SS83a(`|R#)S+^3)i5{REjd2C zZsurfXM^k2diMtdkSmcs{N*$FI#Z%_^9E14S-SVT{L)O1}urLvy`JwhkFwX9hy1=?gje@6V_b5ldmnxS{4|)TYb36n#HtHcAjb( zJX%$R12xXy+d7<1mNcP|<2-n$pSYm$Y-qnpIdT1xBwgl zK9Q(eru{tsaRTI@xv8N8vYuNr5o?Pp?faEckhf{hrOZ9FK>gq)wnV?Rf@*yBJ2EM) zZrjRTyx@lmKd@bq&UIcpmtOnm)Hk&PO|kg$(wh-|7a7*Q8@Ht1_1TseTjk|To#t8a z{gW_fVeD5AtL9y}CZnQ_D)33cUH|lsFp_;W zb%&n5V`<|O%h!Ei>!Ul0$Nto=W_}w|ef(4n_*=;PUETqi87Hq)_9yrs{3JI=inX?P zOlVquCakx$c~2!fu|G%C>S)UinB`&Iw-~a49$AM9ESEOddu2m+?pAG2_D4_GZk72ddDK?(Obvqx`MrQH2Q=; zt2U;C-xc@iln(_11wseS>+%{xg(GqM@3Ibvb_n*{ArS literal 0 HcmV?d00001 diff --git a/src/components/map/geojson/uamRouteArea.json b/src/components/map/geojson/uamRouteArea.json new file mode 100644 index 0000000..a89624b --- /dev/null +++ b/src/components/map/geojson/uamRouteArea.json @@ -0,0 +1,639 @@ +{ + "type": "FeatureCollection", + "features": [ + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.6243464, 37.5642352], + [126.627865, 37.57291277777778], + [126.63130833333331, 37.574488333333335], + [126.64792694444445, 37.57170861111112], + [126.66070861111113, 37.57284000000001], + [126.71217305555557, 37.571181388888895], + [126.72323666666666, 37.55760305555555], + [126.74221777777778, 37.551310277777766], + [126.75231583333333, 37.552930555555555], + [126.75556138888886, 37.5517675], + [126.76711666666668, 37.53592416666667], + [126.76253555555556, 37.53282305555555], + [126.74099055555556, 37.54691583333333], + [126.7212813888889, 37.55372722222222], + [126.71090916666664, 37.57002333333334], + [126.66086972222223, 37.57148361111111], + [126.64985499999999, 37.57053277777778], + [126.63398138888893, 37.55547861111111], + [126.62887638888888, 37.55600555555555], + [126.6243464, 37.5642352] + ] + }, + "properties": { + "type": "routeLine", + "name": "AR", + "description": "UAM 아라뱃길 노선" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6243464, 37.5642352] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "드론시험 인증센터" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.627865, 37.57291277777778] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "001" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.63130833333331, 37.574488333333335] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "002" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.64792694444445, 37.57170861111112] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "003" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.66070861111113, 37.57284000000001] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "004" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.71217305555557, 37.571181388888895] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "005" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.72323666666666, 37.55760305555555] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "006" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.74221777777778, 37.551310277777766] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "007" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.75231583333333, 37.552930555555555] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "008" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.75556138888886, 37.5517675] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "009" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.76711666666668, 37.53592416666667] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "010" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.76253555555556, 37.53282305555555] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "011" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.74099055555556, 37.54691583333333] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "012" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.7212813888889, 37.55372722222222] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "013" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.71090916666664, 37.57002333333334] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "014" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.66086972222223, 37.57148361111111] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "015" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.64985499999999, 37.57053277777778] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "016" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.63398138888893, 37.55547861111111] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "017" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.62887638888888, 37.55600555555555] + }, + "properties": { + "type": "routePoint", + "name": "AR", + "description": "018" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.72420416666667, 37.66822861111111], + [126.72130583333335, 37.66335111111111], + [126.79702611111112, 37.61767361111111], + [126.74079222222223, 37.65721194444444], + [126.72420416666667, 37.66822861111111] + ] + }, + "properties": { + "type": "routeLine", + "name": "HG", + "description": "UAM 한강 노선1" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.72420416666667, 37.66822861111111] + }, + "properties": { + "type": "routePoint", + "name": "HG", + "description": "001" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.72130583333335, 37.66335111111111] + }, + "properties": { + "type": "routePoint", + "name": "HG", + "description": "002" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.79702611111112, 37.61767361111111] + }, + "properties": { + "type": "routePoint", + "name": "HG", + "description": "003" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.74079222222223, 37.65721194444444] + }, + "properties": { + "type": "routePoint", + "name": "HG", + "description": "004" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.79702611111112, 37.61767361111111], + [126.80453805555555, 37.572388333333336], + [126.80991500000003, 37.555640555555556], + [126.81530555555557, 37.554041388888876], + [126.91214388888889, 37.52405611111111] + ] + }, + "properties": { + "type": "routeLine", + "name": "HG", + "description": "UAM 한강 노선2" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.80453805555555, 37.572388333333336] + }, + "properties": { + "type": "routePoint", + "name": "HG", + "description": "005" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.80991500000003, 37.555640555555556] + }, + "properties": { + "type": "routePoint", + "name": "HG", + "description": "006" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.81530555555557, 37.554041388888876] + }, + "properties": { + "type": "routePoint", + "name": "HG", + "description": "007" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.92951111111113, 37.535757499999995], + [126.93060138888889, 37.53156861111111], + [126.91713111111112, 37.52255194444444], + [126.91214388888889, 37.52405611111111], + [126.92951111111113, 37.535757499999995] + ] + }, + "properties": { + "type": "routeLine", + "name": "HG", + "description": "UAM 한강 노선3" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.92951111111113, 37.535757499999995] + }, + "properties": { + "type": "routePoint", + "name": "HG", + "description": "008" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.93060138888889, 37.53156861111111] + }, + "properties": { + "type": "routePoint", + "name": "HG", + "description": "009" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.91214388888889, 37.52405611111111] + }, + "properties": { + "type": "routePoint", + "name": "HG", + "description": "010" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.91713111111112, 37.52255194444444] + }, + "properties": { + "type": "routePoint", + "name": "HG", + "description": "011" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [127.08605444444446, 37.519884166666664], + [127.0841361111111, 37.51934638888889], + [127.07263527777779, 37.51935388888888], + [127.05694444444444, 37.53], + [127.06211527777776, 37.53232277777778], + [127.0720008333333, 37.50237972222222], + [127.09528527777779, 37.49509166666667], + [127.09718083333335, 37.49339055555556], + [127.09813527777777, 37.490587777777776], + [127.1054336111111, 37.48388333333334], + [127.10976999999998, 37.48730472222222], + [127.10070555555555, 37.494905555555555], + [127.07244999999999, 37.50371194444445] + ] + }, + "properties": { + "type": "routeLine", + "name": "TC", + "description": "UAM 탄천 노선" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.08605444444446, 37.519884166666664] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "001" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.0841361111111, 37.51934638888889] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "002" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.07263527777779, 37.51935388888888] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "003" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.05694444444444, 37.53] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "004" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.06211527777776, 37.53232277777778] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "005" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.0720008333333, 37.50237972222222] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "006" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.09528527777779, 37.49509166666667] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "007" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.09718083333335, 37.49339055555556] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "008" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.09813527777777, 37.490587777777776] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "009" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.1054336111111, 37.48388333333334] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "010" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.10976999999998, 37.48730472222222] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "011" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.10070555555555, 37.494905555555555] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "012" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.07244999999999, 37.50371194444445] + }, + "properties": { + "type": "routePoint", + "name": "TC", + "description": "013" + } + } + ] +} diff --git a/src/components/map/geojson/uamTowerArea.json b/src/components/map/geojson/uamTowerArea.json new file mode 100644 index 0000000..f116ccb --- /dev/null +++ b/src/components/map/geojson/uamTowerArea.json @@ -0,0 +1,1076 @@ +{ + "type": "FeatureCollection", + "features": [ + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.6037885, 37.5799164], + [126.6030589, 37.5826372], + [126.6032735, 37.58563], + [126.6056339, 37.5873303], + [126.6117708, 37.5870923], + [126.6133586, 37.585732], + [126.6230146, 37.585766] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 01" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6037885, 37.5799164] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "01" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6230146, 37.585766] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "02" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.6656841, 37.5574589], + [126.6679157, 37.562902], + [126.6689456, 37.5646029], + [126.6691602, 37.5682937], + [126.6732934, 37.5786285], + [126.6699245, 37.5875347], + [126.651707, 37.5929586], + [126.6470292, 37.5971325], + [126.6463211, 37.5999207], + [126.6459563, 37.6000397], + [126.6398838, 37.6042048], + [126.6278246, 37.612122], + [126.6216877, 37.6087223], + [126.6184261, 37.6141957], + [126.6132334, 37.6156914], + [126.6024616, 37.6231358], + [126.6010883, 37.6251752] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 02" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6656841, 37.5574589] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "03" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6699245, 37.5875347] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "04" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6459563, 37.6000397] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "05" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6216877, 37.6087223] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "06" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6010883, 37.6251752] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "07" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.6897596, 37.6121102], + [126.6908754, 37.6126542], + [126.6930211, 37.6088466], + [126.6954244, 37.6073507], + [126.697141, 37.6040868], + [126.6947377, 37.6031349], + [126.6952527, 37.6010948], + [126.694051, 37.5994288], + [126.6911328, 37.5981707], + [126.6886008, 37.5955695], + [126.6889012, 37.5928152], + [126.6907465, 37.5886665], + [126.6922057, 37.5852657], + [126.6901457, 37.5833953], + [126.6903603, 37.5810486], + [126.6872704, 37.5797222], + [126.6856805, 37.5762871], + [126.6867652, 37.5636071], + [126.6903228, 37.5598311], + [126.6968675, 37.5584703], + [126.700129, 37.5553743], + [126.7064376, 37.5550681], + [126.7134328, 37.5549661], + [126.7173421, 37.5545815], + [126.7222733, 37.5530546], + [126.7281527, 37.5530742], + [126.7356629, 37.5505904] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 03" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6897596, 37.6121102] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "08" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6907465, 37.5886665] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "09" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.7064376, 37.5550681] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "10" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.7356629, 37.5505904] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "11" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.7064376, 37.5550681], + [126.7031052, 37.5514421], + [126.7009165, 37.5475633], + [126.7000797, 37.5450794], + [126.7008092, 37.540826], + [126.7054012, 37.5372869], + [126.6945007, 37.5289321], + [126.6865828, 37.5274856], + [126.6850164, 37.527877], + [126.6829135, 37.5284216], + [126.6783001, 37.5276898], + [126.6728713, 37.5292044], + [126.6604903, 37.5276218], + [126.644397, 37.523027], + [126.6325524, 37.519419], + [126.626673, 37.5164917], + [126.6248276, 37.5135302], + [126.6189911, 37.5119643], + [126.6152146, 37.5112494], + [126.6111805, 37.5122026], + [126.6131546, 37.4975974], + [126.6264155, 37.4976655], + [126.6339686, 37.4929326], + [126.6384318, 37.4845558] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 04" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.7054012, 37.5372869] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "12" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6850164, 37.527877] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "13" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.644397, 37.523027] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "14" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6111805, 37.5122026] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "15" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6131546, 37.4975974] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "16" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6384318, 37.4845558] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "17" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.6850164, 37.527877], + [126.6874636, 37.5261447], + [126.687807, 37.5241195], + [126.6850711, 37.5187672], + [126.6840411, 37.5152271], + [126.6846634, 37.5097294], + [126.6914011, 37.497422], + [126.6947271, 37.4926977], + [126.6969158, 37.4905525], + [126.6933323, 37.4885519], + [126.7041041, 37.4865769], + [126.7039324, 37.4843464], + [126.7074515, 37.4814347], + [126.7097689, 37.4817582], + [126.7149831, 37.4783526], + [126.7213775, 37.4726308], + [126.7280723, 37.4706213], + [126.7300249, 37.4706213], + [126.7377685, 37.4685478], + [126.7432831, 37.4635066], + [126.7445276, 37.4622121], + [126.7533253, 37.4605089], + [126.7930649, 37.4563188], + [126.7958544, 37.4572726], + [126.8000816, 37.455416], + [126.8174194, 37.446081], + [126.8224405, 37.4384145], + [126.8224405, 37.4384145], + [126.822279, 37.4409741], + [126.8232813, 37.4441509], + [126.8260064, 37.4466551], + [126.8387093, 37.4519701], + [126.8372349, 37.4628634], + [126.835411, 37.4774925], + [126.8356041, 37.482022], + [126.8364991, 37.484601], + [126.8343963, 37.4862696], + [126.8233241, 37.4898451] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 05" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.6933323, 37.4885519] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "18" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.7213775, 37.4726308] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "19" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.7533253, 37.4605089] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "20" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.7958544, 37.4572726] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "21" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8224405, 37.4384145] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "22" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8387093, 37.4519701] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "23" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8233241, 37.4898451] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "24" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.8372349, 37.4628634], + [126.8439244, 37.4620384], + [126.8469928, 37.4613827], + [126.847143, 37.4605566], + [126.8498091, 37.4603735], + [126.8560909, 37.4597433], + [126.8587302, 37.4588917], + [126.8629037, 37.4563452], + [126.8632685, 37.4558002], + [126.8695234, 37.4481687], + [126.8750058, 37.4459115], + [126.8803488, 37.4433561], + [126.8848763, 37.445213] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 06" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.847143, 37.4605566] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "25" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8848763, 37.445213] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "26" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.7514947, 37.5207621], + [126.7558291, 37.5264462], + [126.7584041, 37.5276034], + [126.7617085, 37.5309727], + [126.7640689, 37.5310408], + [126.7717936, 37.5339675], + [126.797972, 37.5357031], + [126.8061688, 37.5350225] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 07" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.7514947, 37.5207621] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "27" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.7617085, 37.5309727] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "28" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8061688, 37.5350225] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "29" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.7986841, 37.6489505], + [126.8007869, 37.649732], + [126.8034906, 37.6495111], + [126.8049283, 37.6496471], + [126.8080182, 37.6503606], + [126.8112368, 37.6506324], + [126.8133826, 37.6507683], + [126.8137474, 37.6515838], + [126.8258066, 37.6482454], + [126.8289716, 37.648152] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 08" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8007869, 37.649732] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "30" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.8112368, 37.6506324], + [126.8122292, 37.6516709], + [126.8236125, 37.6625005], + [126.8250717, 37.6653881], + [126.8306077, 37.6682417], + [126.8323244, 37.6704497], + [126.8342985, 37.6695325], + [126.8365301, 37.6689211], + [126.8389762, 37.6698043], + [126.848718, 37.669023], + [126.8508638, 37.6694646], + [126.8547691, 37.6659996], + [126.8597902, 37.6600544], + [126.8651975, 37.6585256], + [126.8673004, 37.6567929], + [126.8633307, 37.6499295], + [126.8803466, 37.6212971], + [126.8975405, 37.5890471], + [126.8996327, 37.5892257], + [126.8819881, 37.5738041], + [126.8792845, 37.571321], + [126.8693281, 37.558573], + [126.8679012, 37.5563532] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 09" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8250717, 37.6653881] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "31" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8508638, 37.6694646] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "32" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8633307, 37.6499295] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "33" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8803466, 37.6212971] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "34" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8996327, 37.5892257] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "35" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8819881, 37.5738041] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "36" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.8679012, 37.5563532] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "37" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.8996327, 37.5892257], + [126.8992317, 37.6122825], + [126.9063556, 37.6225655], + [126.9067848, 37.6288536], + [126.905905, 37.63057], + [126.907965, 37.6386585], + [126.9099391, 37.6437899], + [126.9307101, 37.6580607], + [126.9391429, 37.650382], + [126.9400871, 37.6459307], + [126.9413745, 37.6443421], + [126.9417393, 37.6431358], + [126.943059, 37.6383867], + [126.9418868, 37.634839], + [126.9407281, 37.6315933], + [126.9416723, 37.6292142], + [126.9430456, 37.6274298], + [126.9496894, 37.6137103], + [126.9485307, 37.6084749], + [126.9444966, 37.606741], + [126.938746, 37.6075229], + [126.937201, 37.6092568] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 10" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.9063556, 37.6225655] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "38" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.9307101, 37.6580607] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "39" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.9407281, 37.6315933] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "40" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.937201, 37.6092568] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "41" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.9307101, 37.6580607], + [126.9296094, 37.6640606], + [126.9292231, 37.6667783], + [126.9283648, 37.6766632], + [126.9301244, 37.6826749], + [126.9440289, 37.6714529], + [126.9479772, 37.6707188], + [126.9487496, 37.6732664], + [126.9502517, 37.6813843], + [126.9607632, 37.6767348], + [126.9649153, 37.6737457], + [126.9925447, 37.670549], + [127.0101829, 37.6741156], + [127.0138308, 37.6681711], + [127.0164915, 37.6663027], + [127.0163628, 37.6645362], + [127.020547, 37.6563485], + [127.0234652, 37.6547177], + [127.03016, 37.654174] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 11" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.9607632, 37.6767348] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "42" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.0101829, 37.6741156] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "43" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.03016, 37.654174] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "44" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [127.0629085, 37.6781009], + [127.0504201, 37.669558], + [127.0551945, 37.6549659], + [127.0552052, 37.6513898], + [127.0569862, 37.6448828], + [127.0562566, 37.6413997], + [127.0592607, 37.6384863], + [127.0590676, 37.6307206], + [127.05984, 37.6284944], + [127.0590032, 37.6273388], + [127.058102, 37.6270839] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 12" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.0629085, 37.6781009] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "45" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.0504201, 37.669558] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "46" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.058102, 37.6270839] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "47" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [127.1012587, 37.5435093], + [127.0988984, 37.5475925], + [127.0999284, 37.5493278], + [127.1019454, 37.549702], + [127.1025462, 37.5509609], + [127.1036191, 37.5538529], + [127.1011595, 37.5577436], + [127.098134, 37.5609244], + [127.0936922, 37.5645644], + [127.0917932, 37.5645814], + [127.0915518, 37.5655254], + [127.0998345, 37.5700155], + [127.1068082, 37.5741823], + [127.1100912, 37.5780426], + [127.1124516, 37.579165], + [127.1169108, 37.5803875], + [127.1224683, 37.5790611], + [127.1245068, 37.5777687] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 13" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.1012587, 37.5435093] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "48" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.0917932, 37.5645814] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "49" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.1169108, 37.5803875] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "50" + } + }, + + { + "type": "Feature", + "geometry": { + "type": "LineString", + "coordinates": [ + [126.9851177, 37.4752895], + [126.9861692, 37.4747276], + [126.9865554, 37.4741656], + [126.9868773, 37.4722924], + [126.9948166, 37.4683754], + [126.9970267, 37.4682902], + [127.0015972, 37.4708278], + [127.0040005, 37.4725648], + [127.0060819, 37.4740805], + [127.0077341, 37.4740464], + [127.0109957, 37.4756812], + [127.0127552, 37.475562], + [127.0190852, 37.4765838], + [127.0190423, 37.4770095] + ] + }, + "properties": { + "type": "towerLine", + "name": "송전선", + "description": "송전선 15" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [126.9851177, 37.4752895] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "51" + } + }, + { + "type": "Feature", + "geometry": { + "type": "Point", + "coordinates": [127.0190423, 37.4770095] + }, + "properties": { + "type": "towerPoint", + "name": "송전탑", + "description": "52" + } + } + ] +} diff --git a/src/components/map/mapbox/feature/FeatureAirZone.js b/src/components/map/mapbox/feature/FeatureAirZone.js index 8093055..478ca0a 100644 --- a/src/components/map/mapbox/feature/FeatureAirZone.js +++ b/src/components/map/mapbox/feature/FeatureAirZone.js @@ -1,7 +1,12 @@ -import { useEffect } from 'react'; +import { useEffect, useState } from 'react'; import * as turf from '@turf/turf'; -import geoJson from '../../../../components/map/geojson/airArea.json'; +import geoJson from '../../geojson/airArea.json'; +import uamRouteArea from '../../geojson/uamRouteArea.json'; +import uamTowerArea from '../../geojson/uamTowerArea.json'; import '../../../../assets/css/custom.css'; +import { useDispatch, useSelector } from 'react-redux'; +import { FLIGHT_UAM_BUFFER_LIST } from '../../../../modules/basis/flight/actions/basisFlightAction'; +import towerImg from '../../../../assets/images/transmission_tower_icon.png'; // 격자 공역 Source const airPort = [ @@ -26,12 +31,52 @@ const airPort = [ ]; export const FeatureAirZone = props => { + const dispatch = useDispatch(); + const { uamBufferList } = useSelector(state => state.flightState); + + const [uamGeoJson, setUamGeoJson] = useState({ + ...uamRouteArea, + ...uamTowerArea, + features: [...uamRouteArea.features, ...uamTowerArea.features] + }); + const [number, setNumber] = useState(0); + let popup; useEffect(() => { featureAirZoneInit(); + uamAirAreaInit(); }, []); + // 얻은 버퍼 좌표로 버퍼 도형 생성 후 지도에 반영 + useEffect(() => { + if (uamBufferList.length > 0) { + const paths = []; + uamBufferList.map(buffer => { + const path = [buffer.x, buffer.y]; + paths.push(path); + }); + + const bufferObj = { + type: 'Feature', + geometry: { + type: 'LineString', + coordinates: paths + }, + properties: { + type: 'routeBuffer' + } + }; + + const obj = { + ...uamGeoJson, + features: [...uamGeoJson.features, bufferObj] + }; + setUamGeoJson(obj); + props.map.getSource('uam').setData(obj); + } + }, [uamBufferList]); + // 공역 정보 표출 window 생성 const infowindowOpen = data => { const content = @@ -318,5 +363,93 @@ export const FeatureAirZone = props => { }); }; + // uam 셋팅 함수 + const uamAirAreaInit = () => { + if (number === 0) { + const routeFeatures = uamRouteArea.features; + const routeLine = routeFeatures + .filter(route => route.geometry.type === 'LineString') + .map(line => { + return line.geometry.coordinates.map(p => { + return { x: p[0], y: p[1] }; + }); + }); + + // uam노선 버퍼 좌표 요청 + routeLine.forEach(coords => { + dispatch( + FLIGHT_UAM_BUFFER_LIST.request({ + buffer: 50, + coordinates: coords + }) + ); + }); + + props.map.addSource('uam', { + type: 'geojson', + data: uamGeoJson + }); + props.map.addLayer({ + id: 'routeLine', + type: 'line', + source: 'uam', + layout: { + 'line-cap': 'butt', + 'line-join': 'round' + }, + paint: { + 'line-color': '#FF1493', + 'line-width': 3, + 'line-dasharray': [1, 1] + }, + filter: ['==', ['get', 'type'], 'routeLine'] + }); + props.map.addLayer({ + id: 'routeBuffer', + type: 'line', + source: 'uam', + layout: { + 'line-cap': 'round', + 'line-join': 'round' + }, + paint: { + 'line-color': '#000000', + 'line-width': 1, + 'line-dasharray': [3, 3] + }, + filter: ['==', ['get', 'type'], 'routeBuffer'] + }); + props.map.addLayer({ + id: 'routePoint', + type: 'circle', + source: 'uam', + paint: { + 'circle-radius': 5, + 'circle-color': '#ffffff', + 'circle-stroke-color': '#000000', + 'circle-stroke-width': 1 + }, + filter: ['==', ['get', 'type'], 'routePoint'] + }); + props.map.addLayer({ + id: 'towerLine', + type: 'line', + source: 'uam', + layout: { + 'line-cap': 'round', + 'line-join': 'round' + }, + paint: { + 'line-color': '#960018', + 'line-width': 1, + 'line-dasharray': [5, 5] + }, + filter: ['==', ['get', 'type'], 'towerLine'] + }); + } + + setNumber(number + 1); + }; + return null; }; diff --git a/src/modules/basis/flight/actions/basisFlightAction.ts b/src/modules/basis/flight/actions/basisFlightAction.ts index 23708d0..440b744 100644 --- a/src/modules/basis/flight/actions/basisFlightAction.ts +++ b/src/modules/basis/flight/actions/basisFlightAction.ts @@ -13,7 +13,9 @@ import { BasFlightAprovData, BasFlightScheduleList, weatherData, - resweatherData + resweatherData, + FlightUamBufferRq, + FlightUamBufferList } from '../models/basisFlightModel'; // 공역 조회 @@ -134,6 +136,11 @@ const FLIGHT_SCHEDULE_SUCCESS = const FLIGHT_SCHEDULE_FAILURE = 'basis/flight/schedule/list/FLIGHT_SCHEDULE_FAILURE'; +// 버퍼 좌표 가져오기 +const UAM_BUFFER_LIST_REQUEST = 'basis/flight/adex/BUFFER_LIST_REQUEST'; +const UAM_BUFFER_LIST_SUCCESS = 'basis/flight/adex/BUFFER_LIST_SUCCESS'; +const UAM_BUFFER_LIST_FAILURE = 'basis/flight/adex/BUFFER_LIST_FAILURE'; + export const SEARCH_AREA = createAsyncAction( FLIGHT_SEARCH_AREA_REQUEST, FLIGHT_SEARCH_AREA_SUCCESS, @@ -292,6 +299,13 @@ export const FlightweatherAction = createAsyncAction( FLIGHT_WEATHER_FAILURE )(); +// UAM 버퍼 좌표 가져오기 +export const FLIGHT_UAM_BUFFER_LIST = createAsyncAction( + UAM_BUFFER_LIST_REQUEST, + UAM_BUFFER_LIST_SUCCESS, + UAM_BUFFER_LIST_FAILURE +)(); + const actions = { PUBLIC_AREA_LIST, // FLIGHT_PLAN_AREA, @@ -318,7 +332,8 @@ const actions = { SEARCH_AREA, FLIGHT_SCHEDULE_LIST, FlightweatherAction, - FLIGHT_PLAN_AREA_INAIRAREA + FLIGHT_PLAN_AREA_INAIRAREA, + FLIGHT_UAM_BUFFER_LIST }; export type FlightAction = ActionType; diff --git a/src/modules/basis/flight/apis/basisFlightApi.ts b/src/modules/basis/flight/apis/basisFlightApi.ts index dc4d5c0..c437361 100644 --- a/src/modules/basis/flight/apis/basisFlightApi.ts +++ b/src/modules/basis/flight/apis/basisFlightApi.ts @@ -6,6 +6,7 @@ import { FlightPlanAreaDataList, FlightPlanData, FlightPlanListRqData, + FlightUamBufferRq, weatherData } from '../models/basisFlightModel'; @@ -87,5 +88,9 @@ export const flightPlanAPI = { inAirArea: async (data: FlightPlanAreaDataList) => { const res = await axios.post(`api/bas/flight/airspace/contains`, data); return res.data.result; + }, + + uamBufferList: async (data: FlightUamBufferRq) => { + return await axios.post('/api/bas/flight/adex/buffer', data); } }; diff --git a/src/modules/basis/flight/models/basisFlightModel.ts b/src/modules/basis/flight/models/basisFlightModel.ts index bc30cc0..b663795 100644 --- a/src/modules/basis/flight/models/basisFlightModel.ts +++ b/src/modules/basis/flight/models/basisFlightModel.ts @@ -22,6 +22,7 @@ export interface FlightState { listSelect: ListGroupData | undefined; aprvSelect: ListGroupData | undefined; inAirArea: boolean | undefined; + uamBufferList: FlightUamBufferList[] | undefined; } export interface weatherData { serviceKey: string; @@ -244,6 +245,21 @@ export interface BasFlightScheduleData { list: [BasFlightScheduleList]; } +export interface FlightUamBufferRq { + buffer: number; + coordinates: { + x: number; + y: number; + }[]; +} + +export interface FlightUamBufferList { + x: number; + y: number; + m: number | string; + z: number | string; +} + export const initFlight = { weather: undefined, page: 1, @@ -389,7 +405,8 @@ export const initFlight = { areaList: undefined, aprvList: undefined, aprvProc: undefined, - scheduleList: [] + scheduleList: [], + uamBufferList: [] }; export const initFlightBas = { diff --git a/src/modules/basis/flight/reducers/basisFlightReducer.ts b/src/modules/basis/flight/reducers/basisFlightReducer.ts index 55391bb..a305b47 100644 --- a/src/modules/basis/flight/reducers/basisFlightReducer.ts +++ b/src/modules/basis/flight/reducers/basisFlightReducer.ts @@ -164,11 +164,17 @@ export const flightReducer = createReducer( draft.scheduleList = data; }) ) - // 관제권 포함 유무 .handleAction(Actions.FLIGHT_PLAN_AREA_INAIRAREA.success, (state, action) => produce(state, draft => { const data = action.payload; draft.inAirArea = data; }) + ) + // uam 노선 버퍼 영역 조회 + .handleAction(Actions.FLIGHT_UAM_BUFFER_LIST.success, (state, action) => + produce(state, draft => { + const data = action.payload; + draft.uamBufferList = data; + }) ); diff --git a/src/modules/basis/flight/sagas/basisFlightSaga.ts b/src/modules/basis/flight/sagas/basisFlightSaga.ts index 4a665ca..5c5737f 100644 --- a/src/modules/basis/flight/sagas/basisFlightSaga.ts +++ b/src/modules/basis/flight/sagas/basisFlightSaga.ts @@ -446,6 +446,31 @@ function* inAirAreaSaga( } } +// get uam buffer list +function* uamBufferListSaga( + action: ActionType +) { + try { + const data = action.payload; + const response = yield call(Apis.flightPlanAPI.uamBufferList, data); + if (response.errorCode) { + yield put( + MessageActions.IS_ERROR({ + errorCode: response.errorCode, + errorMessage: response.errorMessage, + isHistoryBack: false, + isRefresh: false + }) + ); + return; + } + + yield put(Actions.FLIGHT_UAM_BUFFER_LIST.success(response)); + } catch (error: any) { + yield put(Actions.FLIGHT_UAM_BUFFER_LIST.failure(error)); + } +} + export function* flightSaga() { yield takeEvery(Actions.PUBLIC_AREA_LIST.request, listAreaSaga); // yield takeEvery(Actions.FLIGHT_PLAN_AREA.request, createFlightPlanArea); @@ -463,4 +488,5 @@ export function* flightSaga() { yield takeEvery(Actions.FLIGHT_SCHEDULE_LIST.request, scheduleListSaga); yield takeEvery(Actions.FlightweatherAction.request, WeatherSaga); yield takeEvery(Actions.FLIGHT_PLAN_AREA_INAIRAREA.request, inAirAreaSaga); + yield takeEvery(Actions.FLIGHT_UAM_BUFFER_LIST.request, uamBufferListSaga); }