using Microsoft.AspNetCore.Mvc; using Nirvana.Common; using System.Collections.Generic; using System.Threading.Tasks; using YBDevice.Application; using YBDevice.Application.ViewInfo; using YBDevice.Entity; namespace YBDevice.NWeb.Pages.OutProduct { public class IndexModel : BaseModel { public List businesslist = new List(); public List types = new List(); private IBusinessService _businessService; private IViewEngineService _viewEngineService; private IDeviceService _deviceService; public ViewS2SDto viewdata = new ViewS2SDto(); public IndexModel(IBusinessService businessService, IViewEngineService viewEngineService,IDeviceService deviceService) { _businessService = businessService; _viewEngineService = viewEngineService; _deviceService = deviceService; } public async Task OnGetAsync() { businesslist = await _businessService.GetAllListAsync(1); types = await _deviceService.GetTypeListAsync(); viewdata = await _viewEngineService.GetBtnListAsync(); } } }