예제 #1
0
        public PetViewModel(IPetsData petsData, IPetDescription petDescription, IMapper mapper) : base(petsData, mapper)
        {
            SaveCommand        = new DelegateCommand(SaveCommandExecute);
            EditCommand        = new DelegateCommand(Edit);
            CancelCommand      = new DelegateCommand(Cancel);
            ChangeImageCommand = new DelegateCommand <EventArgs>(ChangeImage);

            ValidateName();
            this.petDescription = petDescription;
        }
예제 #2
0
        public HomeViewModel(IRegionManager regionManager, IPetsData petsData, IPetDescription petDescription, IDialogService dialogService)
        {
            AddCommand          = new DelegateCommand(Add);
            OpenCommand         = new DelegateCommand(Open);
            DeleteCommand       = new DelegateCommand(Delete);
            this.regionManager  = regionManager;
            this.petsData       = petsData;
            this.petDescription = petDescription;
            this.dialogService  = dialogService;
            Pets = new ObservableCollection <IPetDescription>();

            LoadData();
        }
예제 #3
0
        public VisitsViewModel(IPetsData petsData, IPetDescription petDescription, IDialogService dialogService, IMapper mapper)
        {
            AddCommand    = new DelegateCommand(Add);
            DeleteCommand = new DelegateCommand <int?>(Delete);
            EditCommand   = new DelegateCommand <int?>(Edit);

            this.petsData       = petsData;
            this.petDescription = petDescription;
            this.dialogService  = dialogService;
            this.mapper         = mapper;
            Visits = new ObservableCollection <IVisitViewModel>();

            LoadData();
        }
예제 #4
0
        public NotesViewModel(IPetsData petsData, IPetDescription petDescription, IDialogService dialogService, IMapper mapper)
        {
            AddCommand    = new DelegateCommand(Add);
            DeleteCommand = new DelegateCommand <int?>(Delete);
            EditCommand   = new DelegateCommand <int?>(Edit);
            SaveCommand   = new DelegateCommand <int?>(Save);
            CancelCommand = new DelegateCommand <int?>(Cancel);

            this.petsData       = petsData;
            this.petDescription = petDescription;
            this.dialogService  = dialogService;
            this.mapper         = mapper;
            Notes = new ObservableCollection <INoteViewModel>();
            LoadData();
        }
예제 #5
0
        public WeightsViewModel(IPetsData petsData, IPetDescription petDescription, IDialogService dialogService, IMapper mapper)
        {
            AddCommand  = new DelegateCommand(Add);
            EditCommand = new DelegateCommand(Edit);

            this.petsData       = petsData;
            this.petDescription = petDescription;
            this.dialogService  = dialogService;
            this.mapper         = mapper;
            Weights             = new ObservableCollection <IWeightViewModel>();

            InitializeWeight();
            InitializedWeight.PropertyChanged += InitializedWeight_PropertyChanged;

            LoadData();
        }
예제 #6
0
 public WeightViewModel(IPetsData petsData, IMapper mapper)
     : base(petsData, mapper)
 {
 }
예제 #7
0
 public VisitViewModel(IPetsData petsData, IMapper mapper)
     : base(petsData, mapper)
 {
 }
예제 #8
0
 public SingleViewModel(IPetsData petsData, IMapper mapper)
 {
     this.petsData = petsData;
     this.mapper   = mapper;
     originValues  = new Dictionary <string, object>();
 }
예제 #9
0
 public NoteViewModel(IPetsData petsData, IMapper mapper)
     : base(petsData, mapper)
 {
 }
예제 #10
0
 public VaccinationViewModel(IPetsData petsData, IMapper mapper) : base(petsData, mapper)
 {
 }