Esempio n. 1
0
        // GET: Transaction/Create
        public ActionResult Create()
        {
            var transactionEditVM = new TransactionEditVM
            {
                Date             = DateTime.Today,
                ToolSelectList   = new SelectList(toolManager.AllTool(), "Id", "Name"),
                PersonBuyerList  = new SelectList(personManager.AllPerson(), "Id", "Name"),
                PersonSellerList = new SelectList(personManager.AllPerson(), "Id", "Name")
            };

            return(View(transactionEditVM));
        }
Esempio n. 2
0
        // GET: Tool
        public ActionResult Index()
        {
            var toolVM = toolManager.AllTool().Select(p => new ToolVM {
                Id = p.Id, Name = p.Name
            });

            return(View(toolVM));
        }