Esempio n. 1
0
        // GET: Sales/Create
        public async Task <IActionResult> Create()
        {
            var clients = (await _clientService.ListAsync()).Data;

            var products = (await _productService.ListAsync()).Data;

            var saleViewModel = new SaleViewModel(clients, products);

            return(View(saleViewModel));
        }
Esempio n. 2
0
 // GET: Sales
 public async Task <IActionResult> Index()
 {
     return(View((await _service.ListAsync()).Data));
 }