PeopleCarPlanController.java 2.37 KB
package com.bsth.controller.schedule;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import com.bsth.service.realcontrol.ScheduleRealInfoService;
import com.bsth.service.schedule.PeopleCarPlanService;

@RestController
@RequestMapping("pcpc")
public class PeopleCarPlanController {

	@Autowired
    private PeopleCarPlanService peopleCarPlanService;
	
	@RequestMapping(value = "/queryPeopleCar", method = RequestMethod.GET)
	public List<Map<String,Object>> queryPeopleCar(@RequestParam String line, @RequestParam String date, @RequestParam String type){
		return peopleCarPlanService.queryPeopleCar(line, date, type);
	}

	@RequestMapping(value="/workDaily", method = RequestMethod.GET)
	public List<Map<String,Object>> workDaily(@RequestParam String line, @RequestParam String date, @RequestParam String type){
		return peopleCarPlanService.workDaily(line, date, type);
	}
	
	@RequestMapping(value="/scheduleAnaly", method = RequestMethod.GET)
	public Map<String, Object> scheduleAnaly(@RequestParam String page, @RequestParam String line, @RequestParam String startDate, @RequestParam String endDate, @RequestParam String model, @RequestParam String type){
		return peopleCarPlanService.scheduleAnaly(page, line, startDate, endDate, model, type);
	}
	
	@RequestMapping(value="/getModel", method = RequestMethod.GET)
	public List<Map<String,Object>> getModel(@RequestParam String line, @RequestParam String startDate, @RequestParam String endDate){
		return peopleCarPlanService.getModel(line, startDate, endDate);
	}
	
	@RequestMapping(value="/firstAndLastBus", method = RequestMethod.GET)
	public List<Map<String,Object>> firstAndLastBus(@RequestParam String line, @RequestParam String date, @RequestParam String type){
		return peopleCarPlanService.firstAndLastBus(line, date, type);
	}
	
	@RequestMapping(value="/commandState", method = RequestMethod.GET)
	public List<Map<String,Object>> commandState(@RequestParam String line, @RequestParam String date, @RequestParam String code){
		return peopleCarPlanService.commandState(line, date, code);
	}
	
}