diff --git a/BookAStar/BookAStar/ViewModels/BillingLineViewModel.cs b/BookAStar/BookAStar/ViewModels/BillingLineViewModel.cs index 1512b559..da39a0a0 100644 --- a/BookAStar/BookAStar/ViewModels/BillingLineViewModel.cs +++ b/BookAStar/BookAStar/ViewModels/BillingLineViewModel.cs @@ -1,16 +1,11 @@ using BookAStar.Interfaces; using BookAStar.Model.Workflow; using System; -using System.Collections.Generic; -using System.Diagnostics; -using System.Linq; -using System.Text; -using System.Threading.Tasks; using XLabs.Forms.Mvvm; namespace BookAStar.ViewModels { - class BillingLineViewModel : ViewModel, IBillingLine + public class BillingLineViewModel : ViewModel, IBillingLine { public BillingLineViewModel(BillingLine data) { diff --git a/BookAStar/BookAStar/ViewModels/BookQueriesViewModel.cs b/BookAStar/BookAStar/ViewModels/BookQueriesViewModel.cs index 744a4c25..5c22076f 100644 --- a/BookAStar/BookAStar/ViewModels/BookQueriesViewModel.cs +++ b/BookAStar/BookAStar/ViewModels/BookQueriesViewModel.cs @@ -6,11 +6,17 @@ using System.Collections.ObjectModel; using System.Linq; using System.Text; using System.Threading.Tasks; +using System.Windows.Input; namespace BookAStar.ViewModels { - class BookQueriesViewModel : XLabs.Forms.Mvvm.ViewModel + public class BookQueriesViewModel : XLabs.Forms.Mvvm.ViewModel { + public BookQueriesViewModel() + { + + } + public ObservableCollection Queries { get @@ -18,5 +24,10 @@ namespace BookAStar.ViewModels return DataManager.Current.BookQueries; } } + + public ICommand RefreshQueries + { + get { return DataManager.Current.BookQueries; } + } } } diff --git a/BookAStar/BookAStar/ViewModels/EstimateViewModel.cs b/BookAStar/BookAStar/ViewModels/EstimateViewModel.cs index ef2a5162..51e42836 100644 --- a/BookAStar/BookAStar/ViewModels/EstimateViewModel.cs +++ b/BookAStar/BookAStar/ViewModels/EstimateViewModel.cs @@ -1,9 +1,4 @@ -using BookAStar.Model.Interfaces; -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; +using System.Collections.Generic; using XLabs.Forms.Mvvm; using BookAStar.Model.Workflow; using System.Collections.ObjectModel; @@ -11,11 +6,15 @@ using BookAStar.Model; namespace BookAStar.ViewModels { - class EstimateViewModel : ViewModel + public class EstimateViewModel : ViewModel { public EstimateViewModel(Estimate data) { estimate = data; + + if (data.AttachedFiles == null) data.AttachedFiles = new List(); + if (data.AttachedGraphicList == null) data.AttachedGraphicList = new List(); + if (data.Bill == null) data.Bill = new List(); AttachedFiles = new ObservableCollection(data.AttachedFiles); AttachedGraphicList = new ObservableCollection(data.AttachedGraphicList); Bill = new ObservableCollection(data.Bill);