public ActionResult Create(SalesProductServiceDocument salesproductservicedocument)
 {
     if (ModelState.IsValid) {
         salesproductservicedocumentRepository.InsertOrUpdate(salesproductservicedocument);
         salesproductservicedocumentRepository.Save();
         return RedirectToAction("Index");
     } else {
         ViewBag.PossibleSalesProductServiceCatelogs = salesproductservicecatelogRepository.All;
         return View(salesproductservicedocument);
     }
 }
 public void InsertOrUpdate(SalesProductServiceDocument salesproductservicedocument)
 {
     if (salesproductservicedocument.SalesProductServiceDocumentID == default(int)) {
         // New entity
         context.SalesProductServiceDocument.Add(salesproductservicedocument);
     } else {
         // Existing entity
         context.Entry(salesproductservicedocument).State = EntityState.Modified;
     }
 }
 public ActionResult Create()
 {
     SalesProductServiceDocument salesproductservicedocument = new SalesProductServiceDocument();
     ViewBag.PossibleSalesProductServiceCatelogs = salesproductservicecatelogRepository.All;
     return View(salesproductservicedocument);
 }
 public ViewResult Search(SalesProductServiceDocument searchSalesProductServiceDocument)
 {
     if(searchSalesProductServiceDocument!=null)
     {
                     }
                 return View("Index",salesproductservicedocumentRepository.AllIncluding(salesproductservicedocument => salesproductservicedocument.SalesProductServiceCatelog));
 }