rain
2024-03-28 a83ae77a98e235cdca07a1bb167a9a43479a2c9a
src/main/java/com/dji/sample/patches/controller/ShpToDataSourceController.java
@@ -1,6 +1,7 @@
package com.dji.sample.patches.controller;
import com.dji.sample.common.model.ResponseResult;
import com.dji.sample.patches.model.entity.LotInfo;
import com.dji.sample.patches.service.impl.ShpToDataSourceServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
@@ -8,6 +9,7 @@
import java.io.IOException;
import java.util.List;
@RestController
@RequestMapping("${url.patches.prefix}${url.patches.version}")
@@ -15,9 +17,9 @@
    @Autowired
    private ShpToDataSourceServiceImpl shpToDataSourceServiceImpl;
    @PostMapping("/getGeo")
    public ResponseResult getGeo (@RequestParam("file") MultipartFile file) throws IOException {
        shpToDataSourceServiceImpl.insertGeo(file);
        return  ResponseResult.success();
    public ResponseResult<List<LotInfo>> getGeo (@RequestParam("file") MultipartFile file) throws IOException {
        List<LotInfo> list=shpToDataSourceServiceImpl.insertGeo(file);
        return  ResponseResult.success(list);
    }