Commit 4240613529d298a0b4fc6b6d98a472ab6f2e5a88
1 parent
a0b75618
Exists in
staging
and in
4 other branches
pass the correct search task parameters
Showing
1 changed file
with
3 additions
and
3 deletions
Show diff stats
app/controllers/my_profile/tasks_controller.rb
@@ -90,9 +90,9 @@ class TasksController < MyProfileController | @@ -90,9 +90,9 @@ class TasksController < MyProfileController | ||
90 | end | 90 | end |
91 | 91 | ||
92 | def search_tasks | 92 | def search_tasks |
93 | - | ||
94 | - params[:filter_type] = params[:filter_type].blank? ? nil : params[:filter_type] | ||
95 | - result = Task.pending_all(profile,params) | 93 | + filter_type = params[:filter_type].presence |
94 | + filter_text = params[:filter_text].presence | ||
95 | + result = Task.pending_all(profile,filter_type, filter_text) | ||
96 | 96 | ||
97 | render :json => result.map { |task| {:label => task.data[:name], :value => task.data[:name]} } | 97 | render :json => result.map { |task| {:label => task.data[:name], :value => task.data[:name]} } |
98 | end | 98 | end |