1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- using System;
- using System.Runtime.CompilerServices;
- using System.Threading.Tasks;
- using Comal.Classes;
- using CommunityToolkit.Mvvm.ComponentModel;
- using CommunityToolkit.Mvvm.Input;
- using InABox.Avalonia;
- using InABox.Core;
- using PRS.Avalonia.Components;
- namespace PRS.Avalonia.Modules;
- public partial class DeliveryListViewModel : ModuleViewModel
- {
- public override string Title => "Delivery List";
- [ObservableProperty]
- private DeliveryModel _deliveries;
- public DeliveryListViewModel()
- {
- Deliveries = new DeliveryModel(
- DataAccess,
- () => new Filter<Delivery>().All(),
- () => DefaultCacheFileName<DeliveryShell>()
- );
- }
-
- protected override async Task<TimeSpan> OnRefresh()
- {
- await Deliveries.RefreshAsync(false);
- return TimeSpan.Zero;
- }
- [RelayCommand]
- private void SelectDelivery(DeliveryShell shell)
- {
-
- }
-
- }
|