Commit 149d9216 authored by Quxl's avatar Quxl

x

parent 386c3e5b
......@@ -113,9 +113,15 @@ public class CinemaController {
@ApiOperation("编辑场次")
public Object getShowtimeList() {
List<Map<String, Object>> list = service.queryShowtimeList();
List<String> dates = new ArrayList<String>();
List<String> times = new ArrayList<String>();
for(Map<String, Object> map : list) {
Date date = (Date)map.get("show_date");
map.put("show_date", DateUtil.format(date, "yyyy-MM-dd"));
String show_date = DateUtil.format(date, "yyyy-MM-dd");
map.put("show_date", show_date);
String show_time = (String)map.get("show_time");
dates.add(show_date);
times.add(show_time);
}
Map<String, List<Map<String, Object>>> datas = Util.listToML(list, "show_date");
for(String key : datas.keySet()) {
......@@ -129,6 +135,6 @@ public class CinemaController {
}
});
}
return Rjx.jsonOk().setData(new TreeMap<String, List<Map<String, Object>>>(datas));
return Rjx.jsonOk().set("dates", dates).set("times", times).setData(new TreeMap<String, List<Map<String, Object>>>(datas));
}
}
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