Exemplo n.º 1
0
		public IncomeItemEntity(IncomeItemEntity original)
		{
			Id = original.Id;
			Date = original.Date;
			Category = original.Category;
			Amount = original.Amount;
			Details = original.Details;
		}
Exemplo n.º 2
0
		public AddIncomeViewModel(ShellViewModel parentVM)
		{
			this.parentVM = parentVM;
			entityPrototype = new IncomeItemEntity { Id = 0, Date = DateTime.Today, Category = parentVM.IncomeCategories.FirstOrDefault(), Amount = 0, Details = string.Empty };
		}
Exemplo n.º 3
0
		private void ExecuteAddNewCommand()
		{
			var newItem = new IncomeItemEntity(entityPrototype);

			Id = 0;
			Amount = 0;
			Details = string.Empty;

			parentVM.Items.Add(newItem);
		}