Esempio n. 1
0
 private void LoadGrid()
 {
     portsGridView = locations
                     .SelectMany(p => p.Ports)
                     .Select(p => PortDetailsGridView.FromPort(p))
                     .ToArray();
 }
Esempio n. 2
0
        protected async Task SaveLocation()
        {
            Db.PortDetails.Add(portForm.ToPortDetails());

            await Db.SaveChangesAsync();

            locations = await Db.Locations.ToArrayAsync();

            portsGridView = locations
                            .SelectMany(p => p.Ports)
                            .Where(AreValidRecords)
                            .Select(p => PortDetailsGridView.FromPort(p))
                            .ToArray();

            portForm = new PortDetailsForm();

            await EditorPanel.HideAsync();

            await SuccessNotification.Show();
        }
Esempio n. 3
0
 private async Task LoadGrid()
 {
     portsGridView = await Db.PortDetails.Select(p => PortDetailsGridView.FromPort(p)).ToArrayAsync();
 }
Esempio n. 4
0
 protected async Task <PortDetailsGridView[]> LoadPortsViewModel() =>
 await Db.PortDetails.Include(p => p.Location)
 .Select(p => PortDetailsGridView.FromPort(p))
 .ToArrayAsync();
Esempio n. 5
0
        protected override async Task OnInitializedAsync()
        {
            locations = await Db.Locations.ToArrayAsync();

            portsGridView = locations.SelectMany(p => p.Ports).Select(p => PortDetailsGridView.FromPort(p)).ToArray();
        }