mirror of
https://github.com/TracksApp/tracks.git
synced 2026-02-04 23:11:47 +01:00
update query for Postgresql
exchanging double quote with single quote in sql. Thanks Walter
This commit is contained in:
parent
841eb1cb76
commit
e31b05a697
1 changed files with 2 additions and 2 deletions
|
|
@ -53,8 +53,8 @@ class User < ActiveRecord::Base
|
|||
end
|
||||
def actionize(user_id, scope_conditions = {})
|
||||
@state = scope_conditions[:state]
|
||||
query_state = ''
|
||||
query_state = 'AND project.state = "' + @state +'" 'if @state
|
||||
query_state = ""
|
||||
query_state = "AND project.state = '" + @state +"' "if @state
|
||||
projects = Project.find_by_sql([
|
||||
"SELECT project.id, count(todo.id) as p_count " +
|
||||
"FROM projects as project " +
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue