public ActionResult ManageTourMap(MstTourPackageMapModel model) { model.MstTourPackageMap.PackageID = model.MstTourPackage.PackageID; if (ModelState.IsValid) { TempData["ErrMsg"] = dbMap.Save(model.MstTourPackageMap); return(RedirectToAction("CompleteTourPackage", new { id = model.MstTourPackage.PackageID })); } model.MstTourPackage = dbTour.GetTourPackageDetailsByID(model.MstTourPackage.PackageID); return(View("ManageTourMap", model)); }
public ActionResult ManageTourMap(long id) { utblMstTourPackagePic pic = dbPhoto.GetDefaultPhoto(id); if (pic == null) { TempData["ErrMsg"] = 6; return(RedirectToAction("ManageTourPhotos", new { id = id })); } MstTourPackageMapModel obj = new MstTourPackageMapModel(); obj.MstTourPackage = dbTour.GetTourPackageDetailsByID(id); obj.MstTourPackageMap = dbMap.GetTourMapByID(id); return(View("ManageTourMap", obj)); }