public ActionResult Create(Configuration configuration)
        {
            try
            {
                if (ModelState.IsValid)
                {
                    //configuration.ProjectId = ViewBag.ProjectId;

                    session.Insert(configuration);

                    return RedirectToAction("Details", "Project", new { id = configuration.ProjectId });
                }
                return View(configuration);
            }
            catch
            {
                return View(configuration);
            }
        }
        //
        // GET: /Configuration/Create
        public ActionResult Create(ObjectId projectId)
        {
            //ViewBag.ProjectId = projectId;
            var configuration = new Configuration { ProjectId = projectId };
            var items = new List<SelectListItem>
                            {
                                new SelectListItem
                                    {
                                        Text = BuildConfiguration.Debug.ToString(),
                                        Value = BuildConfiguration.Debug.ToString()
                                    },
                                new SelectListItem
                                    {
                                        Text = BuildConfiguration.Release.ToString(),
                                        Value = BuildConfiguration.Release.ToString()
                                    }
                            };

            ViewBag.BuildConfigurations = items;
            return View(configuration);
        }
        public ActionResult Edit(Configuration configuration)
        {
            try
            {
                if (ModelState.IsValid)
                {
                    session.Update(configuration);

                    return RedirectToAction("Details", "Project", new { id = configuration.ProjectId });
                }
                return View(configuration);
            }
            catch
            {
                return View(configuration);
            }
        }