summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Lepp <jlepp@arcresources.com>2010-10-19 14:47:57 -0600
committerJason Lepp <jlepp@arcresources.com>2010-10-19 14:47:57 -0600
commitb0799fe494875d76c0b15c9c0a46f1f8a2619531 (patch)
tree9bb69f8549b080c5da21c66dd81466faed8f6820
parentdece0e4e51351c28e8546c5fc8107aa61f87c9f6 (diff)
Change order of TodoItemViewModel
-rw-r--r--src/MVPtoMVVM.mvvm/viewmodels/ToDoItemViewModel.cs26
1 files changed, 6 insertions, 20 deletions
diff --git a/src/MVPtoMVVM.mvvm/viewmodels/ToDoItemViewModel.cs b/src/MVPtoMVVM.mvvm/viewmodels/ToDoItemViewModel.cs
index 4cce350..a33b9b4 100644
--- a/src/MVPtoMVVM.mvvm/viewmodels/ToDoItemViewModel.cs
+++ b/src/MVPtoMVVM.mvvm/viewmodels/ToDoItemViewModel.cs
@@ -1,7 +1,6 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
-using System.Text;
using MVPtoMVVM.domain;
using MVPtoMVVM.repositories;
using System.Linq;
@@ -12,6 +11,11 @@ namespace MVPtoMVVM.mvvm.viewmodels
{
private readonly ITodoItemRepository todoItemRepository;
private Synchronizer<TodoItemViewModel> synchronizer;
+ public event PropertyChangedEventHandler PropertyChanged = (o, e) => { };
+ public int Id { get; set; }
+ public IObservableCommand SaveCommand { get; set; }
+ public IObservableCommand DeleteCommand { get; set; }
+ public MainWindowViewModel Parent { get; set; }
public TodoItemViewModel(ITodoItemRepository todoItemRepository)
{
@@ -45,8 +49,6 @@ namespace MVPtoMVVM.mvvm.viewmodels
todoItemRepository.Save(todoItem);
}
- public event PropertyChangedEventHandler PropertyChanged = (o,e)=> { };
- public int Id { get; set; }
private string description;
public string Description
{
@@ -74,9 +76,6 @@ namespace MVPtoMVVM.mvvm.viewmodels
}
}
- public IObservableCommand SaveCommand { get; set; }
- public IObservableCommand DeleteCommand { get; set; }
- public MainWindowViewModel Parent { get; set; }
public bool ShowDueSoonAlert
{
get
@@ -96,20 +95,7 @@ namespace MVPtoMVVM.mvvm.viewmodels
public string Error
{
- get { return BuildErrors(); }
- }
-
- private string BuildErrors()
- {
- var builder = new StringBuilder();
- foreach (var validation in validations.Values)
- {
- if(!validation.IsValid)
- {
- builder.AppendLine(validation.Message);
- }
- }
- return builder.ToString();
+ get { return string.Empty; }
}
}
} \ No newline at end of file