Update models with more functionality
This is a small commit that aims to add some more descriptive functionality to the models. Guest now has more creditcard information such as CCV and an expiration date to bring it in-line with what would be expected. Reservation implemented a very loose cancellation function, this may be moved out. Transaction has a few more tweaks that follows the same goal as guest, however this functionality may be migrated as well.
This commit is contained in:
@@ -48,14 +48,16 @@ namespace Ophelias.Models
|
||||
CheckOut = null;
|
||||
DateChanged = null;
|
||||
}
|
||||
internal void ChangeReservation(ReservationType type)
|
||||
internal void ChangeReservation(ReservationType type, Transaction t, BaseRate b)
|
||||
{
|
||||
Status = ReservationStatus.Changed;
|
||||
Type = type;
|
||||
t.Penalize(this, b.Rate);
|
||||
}
|
||||
internal void CancelReservation()
|
||||
internal void CancelReservation(Transaction t)
|
||||
{
|
||||
Status = ReservationStatus.Cancelled;
|
||||
t.Penalize(this);
|
||||
}
|
||||
}
|
||||
internal enum ReservationStatus
|
||||
|
||||
Reference in New Issue
Block a user