IPoint.java 2.75 KB
package com.dituhui.pea.gis;

import com.dituhui.pea.pojo.PointRequest;
import com.dituhui.pea.pojo.WebResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@FeignClient(value = "gis")
public interface IPoint {

    @RequestMapping(value = "/gis/point/test", method = RequestMethod.GET)
    public WebResult<String> test();

    /**
     * 添加点
     * @param point
     * @return
     */
    @PostMapping("/gis/point/add")
    public WebResult<String> add(@RequestBody PointRequest point);

    /**
     * 根据用户自定义id修改
     * @param point
     * @return
     */
    @PostMapping("/gis/point/updateByCustomId")
    public WebResult<Boolean> updateByCustomId(@RequestBody PointRequest point);

    /**
     * 根据id修改
     * @param point
     * @return
     */
    @PostMapping("/gis/point/updateById")
    public WebResult<Boolean> updateById(@RequestBody PointRequest point);

    /**
     * 根据用户自定义id删除
     * @return
     */
    @PostMapping("/gis/point/delByCustomId")
    public WebResult<Boolean> delByCustomId(@RequestParam boolean contract, @RequestParam String teamId, @RequestParam String mapId,
                                            @RequestParam String layerCode, @RequestParam String customId);

    /**
     * 根据id删除
     * @return
     */
    @PostMapping("/gis/point/delById")
    public WebResult<Boolean> delById(@RequestParam boolean contract, @RequestParam String teamId, @RequestParam String id);

    /**
     * 根据用户自定义id获取点
     * @return
     */
    @GetMapping("/gis/point/getByCustomId")
    public WebResult getByCustomId(@RequestParam boolean contract, @RequestParam String teamId, @RequestParam String mapId,
                                   @RequestParam String layerCode, @RequestParam String customId);

    /**
     * 根据id获取面
     * @return
     */
    @GetMapping("/gis/point/getById")
    public WebResult getById(@RequestParam boolean contract, @RequestParam String teamId, @RequestParam String mapId,
                             @RequestParam(required = false) String layerCode, @RequestParam String id);

    @GetMapping("/gis/point/search")
    public WebResult search(@RequestParam boolean contract, @RequestParam String teamId, @RequestParam String mapId,
                            @RequestParam(defaultValue = "0") int pageNum, @RequestParam(defaultValue = "0") int pageSize, @RequestParam(required = false) String layerCode,
                            @RequestParam(required = false) String customQuerys, @RequestParam(defaultValue = "And") String compositeType,
                            @RequestParam(required = false) List<String> fieldNames, @RequestParam(required = false) String orders);
}