Exemplo n.º 1
0
        public override async Task LoadAsync(int id)
        {
            Id = id;
            BrowseItems.Clear();

            var lookupItems = await lookupService.GetCustomerLookupAsync();

            foreach (var item in lookupItems)
            {
                BrowseItems.Add(new BrowseItem(
                                    item.Id,
                                    item.DisplayMember,
                                    EventAggregator,
                                    nameof(CustomerDetailVM)
                                    ));
            }
        }
Exemplo n.º 2
0
        private void RefreshItems()
        {
            var capturesDir = Windows.Media.Capture.AppCaptureManager.GetCurrentSettings().AppCaptureDestinationFolder.Path;
            var files       = Directory.GetFiles(capturesDir, "*.png").Concat(Directory.GetFiles(capturesDir, "*.mp4"));
            List <BrowseItemViewModel> items = new List <BrowseItemViewModel>();

            foreach (var file in files)
            {
                items.Add(new BrowseItemViewModel(file));
            }

            BrowseItems.Clear();

            foreach (var item in items.OrderByDescending(x => x.CreationTime))
            {
                BrowseItems.Add(item);
            }
        }
Exemplo n.º 3
0
        private void browse_Click(object sender, RoutedEventArgs e)
        {
            BrowseItems m = new BrowseItems();

            NavigationService.Navigate(m);
        }