public ActionResult CreateEdit(int?AccountMasterId, int?CollectionId)
        {
            Collection collection = new Collection();

            if (AccountMasterId != null)
            {
                collection.AccountMasterId = Convert.ToInt32(AccountMasterId);
            }
            if (CollectionId != null)
            {
                collection = CollectionDataLayer.Find(CollectionId);
            }


            ViewBag.AccountMasterId = new SelectList(AccountDataLayer.ToList(), "AccountMasterId", "AccountName", collection.AccountMasterId);
            return(View(collection));
        }
示例#2
0
 // GET: AccountMasters
 public ActionResult Index()
 {
     return(View(accountDataLayer.ToList()));
 }