mirror of
https://github.com/TracksApp/tracks.git
synced 2026-02-14 03:14:22 +01:00
Remove deprecations printed out in the test suite
This commit is contained in:
parent
d3c9975606
commit
f2647e3f94
5 changed files with 10 additions and 10 deletions
|
|
@ -1,6 +1,6 @@
|
|||
class Context < ApplicationRecord
|
||||
|
||||
has_many :todos, -> { order("todos.due IS NULL, todos.due ASC, todos.created_at ASC").includes(:project) }, :dependent => :delete_all
|
||||
has_many :todos, -> { order(Arel.sql("todos.due IS NULL, todos.due ASC, todos.created_at ASC")).includes(:project) }, :dependent => :delete_all
|
||||
has_many :recurring_todos, :dependent => :delete_all
|
||||
belongs_to :user
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
class Project < ApplicationRecord
|
||||
has_many :todos, -> {order("todos.due IS NULL, todos.due ASC, todos.created_at ASC")}, dependent: :delete_all
|
||||
has_many :todos, -> {order(Arel.sql("todos.due IS NULL, todos.due ASC, todos.created_at ASC"))}, dependent: :delete_all
|
||||
has_many :notes, -> {order "created_at DESC"}, dependent: :delete_all
|
||||
has_many :recurring_todos
|
||||
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@ module Search
|
|||
@user.todos.
|
||||
where("(todos.description LIKE ? OR todos.notes LIKE ?) AND todos.completed_at IS NULL", terms, terms).
|
||||
includes(Todo::DEFAULT_INCLUDES).
|
||||
reorder("todos.due IS NULL, todos.due ASC, todos.created_at ASC")
|
||||
reorder(Arel.sql("todos.due IS NULL, todos.due ASC, todos.created_at ASC"))
|
||||
end
|
||||
|
||||
def complete_todos(terms)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue