|
@@ -63,18 +63,25 @@ public class StationController {
|
|
|
return gson.toJson(resultData);
|
|
|
}
|
|
|
/**
|
|
|
- * 获取油站列表信息
|
|
|
+ * 根据公众号appId获取油站列表信息
|
|
|
*/
|
|
|
- @RequestMapping(value = "/getStationList", method = RequestMethod.GET)
|
|
|
+ @RequestMapping(value = "/getGzhStationList", method = RequestMethod.GET)
|
|
|
@ResponseBody
|
|
|
- public String getStationList(@RequestParam StationRequest request){
|
|
|
+ public String getStationList(@RequestParam String appId){
|
|
|
Gson gson =new Gson();
|
|
|
- StationInfo stationInfo =new StationInfo();
|
|
|
- List<StationInfo> stationInfoList = stationService.getStationList(stationInfo);
|
|
|
- return gson.toJson(stationInfoList);
|
|
|
+ ResultData resultData=null;
|
|
|
+ if(appId !=null){
|
|
|
+ StationInfo stationInfo =new StationInfo();
|
|
|
+ stationInfo.setGzhAppId(appId);
|
|
|
+ List<StationInfo> stationInfoList = stationService.getStationList(stationInfo);
|
|
|
+ resultData = ResultData.success(stationInfoList);
|
|
|
+ }else {
|
|
|
+ resultData=ResultData.error(CodeMsg.REQUEST_FAIL);
|
|
|
+ }
|
|
|
+ return gson.toJson(resultData);
|
|
|
}
|
|
|
/**
|
|
|
- * 获取油站列表信息
|
|
|
+ * 添加油站信息
|
|
|
*/
|
|
|
@RequestMapping(value = "/addStationInfo", method = RequestMethod.POST)
|
|
|
@ResponseBody
|