Exemple #1
0
 public Event CreateEvent(string title, string description, int numOfParticipants, double priceFrom, double priceTo, string location, DateTime datetime, bool isPublic, User admin)
 {
     try
     {
         Event        e = eCtrl.CreateEvent(title, description, numOfParticipants, priceFrom, priceTo, location, datetime, isPublic, admin);
         Registration r = rCtrl.CreateRegistration(e.Admin, e);
         uCtrl.AddRegistration(e.Admin, r);
         return(e);
     }
     catch (ArgumentException ae)
     {
         throw new FaultException(ae.Message);
     }
     catch (DateInPastException dipe)
     {
         throw new FaultException(dipe.Message);
     }
 }