package com.yh.saas.plugin.yiliangyiyun.controller;


import com.yh.saas.plugin.yiliangyiyun.entity.TrackDetailInfo;
import com.yh.saas.plugin.yiliangyiyun.service.ITrackDetailInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * <p>
 * 记录轨迹明细 前端控制器
 * </p>
 *
 * @author Gdc
 * @since 2022-06-29
 */
@RestController
@RequestMapping("/trackDetailInfo")
public class TrackDetailInfoController {
    @Autowired
    private ITrackDetailInfoService trackDetailInfoService;
    /**
     * 添加轨迹
     *
     * @param trackDetailInfo
     * @return
     */
    @PostMapping("/api/addTrackDetail")
    public String addTrackDetail(@RequestBody TrackDetailInfo trackDetailInfo) {
        return trackDetailInfoService.addTrackDetail(trackDetailInfo);
    }
    /**
     * 查看轨迹
     *
     * @param trackDetailInfo
     * @return
     */
    @GetMapping("/getTrack")
    public TrackDetailInfo getTrack(@RequestParam TrackDetailInfo trackDetailInfo) {
        return trackDetailInfoService.getTrack(trackDetailInfo);
    }
}

