Пример #1
0
        public AjaxContinuation AddTodoCommand(TodoAddModel input)
        {
            var todo = new Todo()
            {
                Description = input.Description, Title = input.Title
            };
            bool successful = todoService.addTodo(input.Username, todo);

            return(new AjaxContinuation()
            {
                ShouldRefresh = successful, Success = successful, Message = successful?"Todo added!":"Todo not added.."
            });
        }
Пример #2
0
 public AjaxContinuation AddTodoCommand(TodoAddModel input)
 {
     var todo = new Todo() { Description = input.Description, Title = input.Title };
     bool successful = todoService.addTodo(input.Username, todo);
     return new AjaxContinuation() { ShouldRefresh = successful, Success = successful, Message = successful?"Todo added!":"Todo not added.." };
 }