File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -1428,7 +1428,6 @@ export class WebMap extends Observable {
14281428 if ( data . type === "JSON" || data . type === "GEOJSON" ) {
14291429 data . content = data . content . type ? data . content : JSON . parse ( data . content ) ;
14301430 features = that . geojsonToFeature ( data . content , layer ) ;
1431-
14321431 } else if ( data . type === 'EXCEL' || data . type === 'CSV' ) {
14331432 if ( layer . dataSource && layer . dataSource . administrativeInfo ) {
14341433 //行政规划信息
@@ -1439,6 +1438,10 @@ export class WebMap extends Observable {
14391438 } else {
14401439 features = await that . excelData2Feature ( data . content , layer ) ;
14411440 }
1441+ } else if ( data . type === 'SHP' ) {
1442+ let content = JSON . parse ( data . content ) ;
1443+ data . content = content . layers [ 0 ] ;
1444+ features = that . geojsonToFeature ( data . content , layer ) ;
14421445 }
14431446 that . addLayer ( layer , features , layerIndex ) ;
14441447 that . layerAdded ++ ;
You can’t perform that action at this time.
0 commit comments