-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove references to aggregation attribute on Workflows (#4339)
* Ignore aggregation column on workflows * Remove everywhere else * Hound * Hound cleanup * Short circuit scopes & specs for private aggs * Deprecate AggregationsController * Spec removal
- Loading branch information
Showing
12 changed files
with
70 additions
and
280 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,12 @@ | ||
class Api::V1::AggregationsController < Api::ApiController | ||
include JsonApiController::PunditPolicy | ||
# include JsonApiController::PunditPolicy | ||
|
||
require_authentication :create, :update, scopes: [:project] | ||
resource_actions :create, :update, :show, :index | ||
schema_type :json_schema | ||
before_action :filter_by_subject_set, only: :index | ||
# THIS FUNCTIONALITY IS BEING DEPRECATED EFFECTIVE IMMEDIATELY | ||
# A REPLACEMENT IS FORTHCOMING. | ||
|
||
private | ||
# require_authentication :create, :update, scopes: [:project] | ||
# resource_actions :create, :update, :show, :index | ||
# schema_type :json_schema | ||
# before_action :filter_by_subject_set, only: :index | ||
|
||
def filter_by_subject_set | ||
subject_set_ids = params.delete(:subject_set_id).try(:split, ',') | ||
unless subject_set_ids.blank? | ||
@controlled_resources = controlled_resources | ||
.joins(workflow: :subject_sets) | ||
.where(workflows: { subject_set_id: subject_set_ids } ) | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
169 changes: 0 additions & 169 deletions
169
spec/controllers/api/v1/aggregations_controller_spec.rb
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.