Commit 02a6f052 authored by Quxl's avatar Quxl

x

parent 149d9216
......@@ -13,6 +13,6 @@ public interface CinemaService {
void setTmpData(Integer showtimeId);
List<Map<String, Object>> queryShowtimeList();
List<Map<String, Object>> queryShowtimeList(Integer cinemaId);
}
......@@ -63,10 +63,10 @@ public class CinemaServiceImpl implements CinemaService {
}
@Override
public List<Map<String, Object>> queryShowtimeList() {
public List<Map<String, Object>> queryShowtimeList(Integer cinemaId) {
Date dodayStart = DateUtil.start(new Date());
String sql = "select * from fc_cinema_showtime where show_date >= ?";
return jdbcTemplate.queryForList(sql, dodayStart);
String sql = "select * from fc_cinema_showtime where show_date >= ? and cinema_id = ?";
return jdbcTemplate.queryForList(sql, dodayStart, cinemaId);
}
}
......@@ -111,8 +111,11 @@ public class CinemaController {
@ResponseBody
@PostMapping("updateShowtime")
@ApiOperation("编辑场次")
public Object getShowtimeList() {
List<Map<String, Object>> list = service.queryShowtimeList();
@ApiImplicitParams({
@ApiImplicitParam(paramType="query", name="cinema_id", value="影院放映厅ID"),
})
public Object getShowtimeList(Integer cinema_id) {
List<Map<String, Object>> list = service.queryShowtimeList(cinema_id);
List<String> dates = new ArrayList<String>();
List<String> times = new ArrayList<String>();
for(Map<String, Object> map : list) {
......
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