예제 #1
0
        public static ActivityViewModel ConvertToActivityModel(OnboardActivity onboardactivity)
        {
            var activity = new ActivityViewModel();

            activity.OnboardActivityID = onboardactivity.ID;
            activity.Type  = onboardactivity.Type;
            activity.Title = onboardactivity.Name;
            return(activity);
        }
예제 #2
0
 public ActionResult _CreateActivity(OnboardActivity activity)
 {
     if (ModelState.IsValid)
     {
         db.OnboardActivities.Add(activity);
         db.SaveChanges();
     }
     return(View());
 }
예제 #3
0
        public ActionResult _CreateActivity()
        {
            var activity = new OnboardActivity();

            return(View());
        }