using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Input;
using Prism.Commands;
using Valg.EVA.Skanning.Contracts.CommonEnums;
using Valg.EVA.Skanning.Resources.Language;
using Valg.EVA.Skanning.ServicesModel.ServiceContracts.Box.Read;
using Valg.EVA.Skanning.UserInterfaceElements;

namespace Valg.EVA.Skanning.Scan.Presentation.Sample
{
    public class SelectCountingViewModel : ViewModelBase
    {
        public string ModalDialogDescriptionText => SampleLanguageString.ModalDialog_MultipleCountings_Description;
        private Action<CountingMetaData> onComplete;
        public ICommand SelectedCountingCommand { get; set; }
        public ObservableCollection<CountingMetaData> BoxCountings { get; private set; } = new ObservableCollection<CountingMetaData>();
        public SelectCountingViewModel(IEnumerable<CountingMetaData> countings, Action<CountingMetaData> onComplete)
        {

            this.onComplete = onComplete;
            BoxCountings.AddRange(countings);
            this.SelectedCountingCommand = new DelegateCommand<CountingMetaData>(onComplete);
        }

    }
}

