|
|
@ -300,15 +300,6 @@ module Report::Controller |
|
|
|
"(is_public = #{val ? report_engine.reporting_connection.quoted_true : report_engine.reporting_connection.quoted_false})" |
|
|
|
"(is_public = #{val ? report_engine.reporting_connection.quoted_true : report_engine.reporting_connection.quoted_false})" |
|
|
|
end |
|
|
|
end |
|
|
|
|
|
|
|
|
|
|
|
## |
|
|
|
|
|
|
|
# Fallback: @current_user needs to be set for the engine |
|
|
|
|
|
|
|
def current_user |
|
|
|
|
|
|
|
if @current_user.nil? |
|
|
|
|
|
|
|
raise NotImplementedError, "The #{self.class} should have set @current_user before this request" |
|
|
|
|
|
|
|
end |
|
|
|
|
|
|
|
@current_user |
|
|
|
|
|
|
|
end |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
## |
|
|
|
## |
|
|
|
# Abstract: Implementation required in application |
|
|
|
# Abstract: Implementation required in application |
|
|
|
def allowed_to?(action, subject, user = current_user) |
|
|
|
def allowed_to?(action, subject, user = current_user) |
|
|
|