Пример #1
0
 public String addHistory() {
   history.setDriver(dm.getDriver(driverId));
   history.setBus(bm.getBus(busId));
   history.setRoute(rm.getRoute(routeId));
   history.setDate(date);
   hm.addHistory(history);
   history = new History();
   driverId = 0L;
   busId = 0L;
   routeId = 0L;
   historiesForDate = hm.getHistoryByDate(date);
   return "showLines?faces-redirect=true";
 }
Пример #2
0
 public String deleteHistory() {
   History historyToDelete = histories.getRowData();
   hm.deleteHistory(historyToDelete);
   return null;
 }
Пример #3
0
 public ListDataModel<History> getAllHistories() {
   histories.setWrappedData(hm.getAllHistory());
   return histories;
 }
Пример #4
0
 public void setDate(Date date) {
   historiesForDate = hm.getHistoryByDate(date);
   this.date = date;
 }