Commit 270a9e15 by 焦凯

提供场站和购砂单位用的场站获取接口

parent 55f23aea
package com.xyst.dinas.biz.web;
import java.util.UUID;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;
import com.beecode.bcp.type.KObject;
import com.beecode.inz.basis.team.pojo.ResponseObj;
import com.xyst.dinas.biz.service.StationService;
/**
* @author Joker
*/
@RestController()
public class Station2Controller {
// private static final Logger logger = LoggerFactory.getLogger(Station2Controller.class);
@Autowired
private StationService stationService;
/**
* 根据id获取场站
* @param id
* @return
*/
@SuppressWarnings("rawtypes")
@GetMapping("/warehouse/api/{id}")
public ResponseObj getByIdStation(@PathVariable("id") UUID id){
if(id == null){
return ResponseObj.error(400,"'id' must be not null!");
}
KObject station = stationService.getById(id);
return ResponseObj.success("获取成功",station);
}
/**
* 根据id获取场站
* @param id
* @return
*/
@SuppressWarnings("rawtypes")
@GetMapping("/sand/user/{id}")
public ResponseObj getByIdCompany(@PathVariable("id") UUID id){
if(id == null){
return ResponseObj.error(400,"'id' must be not null!");
}
KObject station = stationService.getById(id);
return ResponseObj.success("获取成功",station);
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment