Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
6000_case_study:0400_configuration:0700_operations:1300_cancel_reservation [2022/08/21 22:47] – removed - external edit (Unknown date) 127.0.0.16000_case_study:0400_configuration:0700_operations:1300_cancel_reservation [2026/08/13 00:55] (current) – ↷ Links adapted because of a move operation localdev
Line 1: Line 1:
 +[<10>]
 +======  "Cancel Reservation" operation ======
 +
 +To cancel a reservation users would need to navigate to the corresponding reservation and then click on the "Cancel" button. Users can navigate to the reservation either from the form of a member who made the reservation or from the form of the item (this is similar to the "[[6000_case_study:0400_configuration:0700_operations:1000_renew_loan|Renew Loan]]" operation).
 +
 +To cancel a reservation the system would need to change the status of the reservation to "Cancelled" and the rest will be taken care by the business rules of the ''[[6000_case_study:0400_configuration:0600_business_rules:0400_reservation_object|Reservation]]'' object. In order to do this we would need to define the process called ''CancelReservation'' that requires the ''Reservation'' object as its input and which has the single action defined:
 +
 +<code aim>Reservation.Status = 'Cancelled' </code>
 +
 +We will also ask the user to confirm cancellation of the Reservation and check that he replied "Yes" before changing status of the reservation. The whole process will look like so:
 +
 +<code aim>DISPLAY QUESTION 'Do you want to cancel the reservation?'
 +IF Question.Reply='Yes' THEN 
 + Reservation.Status='Cancelled' </code>