3
active_admin 및 acts_As_taggable_on을 사용하고 있는데 필터를 만들려고합니다. 여기activeadmin 및 acts_as_taggable_on이 ambiguous_column_name 오류를 생성합니다.
class Person < ApplicationRecord
acts_as_taggable_on :expertise, :industry
end
필터입니다 : 다음은 모델 코드는
filter :industry, as: :select, collection: Person.industry_counts.pluck(:name, :name)
여기 필터 제출할 때 내가 오류입니다 :이 어떻게 해결합니까
SQLite3::SQLException: ambiguous column name: created_at: SELECT COUNT(DISTINCT "people"."id") FROM "people" LEFT OUTER JOIN "taggings" ON "taggings"."taggable_id" = "people"."id" AND "taggings"."context" = ? AND "taggings"."taggable_type" = ? WHERE "taggings"."tag_id" = 0 AND (created_at > '2017-01-17 00:22:53.923894')
를?
는 문제가있다 나는이 작품을 만들기 위해 모델에서 사용자 정의 "ransackers"를했습니다 'created_at> '2017-01-17 00 : 22 : 53.923894' 'created_at'이'taggings'와'people' 둘 모두에 존재합니다. – TheRealMrCrowley
전화를 걸면 어디 코드를 게시 할 수 있습니까? 뭔가 빠진 것처럼 보인다. – TheRealMrCrowley