From 4ae412afcf9ba9d1952381d726117ef9987dfc56 Mon Sep 17 00:00:00 2001 From: Marc Englund Date: Wed, 29 Aug 2007 13:35:23 +0000 Subject: [PATCH] Successful reservation message. svn changeset:2152/svn branch:trunk --- .../toolkit/demo/reservation/ReservationApplication.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/com/itmill/toolkit/demo/reservation/ReservationApplication.java b/src/com/itmill/toolkit/demo/reservation/ReservationApplication.java index 07226794e9..af98930b72 100644 --- a/src/com/itmill/toolkit/demo/reservation/ReservationApplication.java +++ b/src/com/itmill/toolkit/demo/reservation/ReservationApplication.java @@ -130,6 +130,9 @@ public class ReservationApplication extends Application { db.addReservation(resource, 0, (Date) reservedFrom.getValue(), (Date) reservedTo.getValue(), (String) description .getValue()); + statusLabel.setCaption("Success!"); + statusLabel + .setValue("You have reserved the resource for the selected period."); } } catch (ResourceNotAvailableException e) { statusLabel.setCaption("Reservation failed"); @@ -183,7 +186,7 @@ public class ReservationApplication extends Application { SampleDB.Resource.PROPERTY_ID_NAME).getValue()); reservationButton.setEnabled(true); } - + } private void initCalendarFieldPropertyIds(CalendarField cal) { @@ -193,7 +196,7 @@ public class ReservationApplication extends Application { cal .setItemTitlePropertyId(SampleDB.Reservation.PROPERTY_ID_DESCRIPTION); } - + private void resetStatus() { statusLabel.setCaption(null); statusLabel.setValue(null); @@ -204,6 +207,5 @@ public class ReservationApplication extends Application { refreshReservations(); resetStatus(); } - } -- 2.39.5