mirror of
https://github.com/TracksApp/tracks.git
synced 2026-02-07 08:21:47 +01:00
add validation to catch empty descriptions
This commit is contained in:
parent
6e5057138d
commit
abf4524679
6 changed files with 56 additions and 5 deletions
|
|
@ -169,7 +169,13 @@ class TodosController < ApplicationController
|
|||
@projects = current_user.projects.find(:all) if @new_project_created
|
||||
@initial_context_name = params['default_context_name']
|
||||
@initial_project_name = params['default_project_name']
|
||||
@default_tags = @todos[0].project.default_tags unless @todos[0].project.nil?
|
||||
if @todos.size > 0
|
||||
@default_tags = @todos[0].project.default_tags unless @todos[0].project.nil?
|
||||
else
|
||||
@multiple_error = "You need to submit at least one next action"
|
||||
@saved = false;
|
||||
@default_tags = current_user.projects.find_by_name(@initial_project_name).default_tags unless @initial_project_name.blank?
|
||||
end
|
||||
render :action => 'create_multiple'
|
||||
end
|
||||
format.xml do
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue