Class: Graphql::Dashboard::DetailedTraces::TracesController
- Inherits:
-
ApplicationController
- Object
- ActionController::Base
- ApplicationController
- Graphql::Dashboard::DetailedTraces::TracesController
- Includes:
- Installable
- Defined in:
- lib/graphql/dashboard/detailed_traces.rb
Instance Method Summary collapse
Methods included from Installable
Methods inherited from ApplicationController
Instance Method Details
#delete_all ⇒ Object
26 27 28 29 30 |
# File 'lib/graphql/dashboard/detailed_traces.rb', line 26 def delete_all schema_class.detailed_trace.delete_all_traces flash[:success] = "Deleted all traces." head :no_content end |
#destroy ⇒ Object
20 21 22 23 24 |
# File 'lib/graphql/dashboard/detailed_traces.rb', line 20 def destroy schema_class.detailed_trace.delete_trace(params[:id]) flash[:success] = "Trace deleted." head :no_content end |
#index ⇒ Object
9 10 11 12 13 |
# File 'lib/graphql/dashboard/detailed_traces.rb', line 9 def index @last = params[:last]&.to_i || 50 @before = params[:before]&.to_i @traces = schema_class.detailed_trace.traces(last: @last, before: @before) end |
#show ⇒ Object
15 16 17 18 |
# File 'lib/graphql/dashboard/detailed_traces.rb', line 15 def show trace = schema_class.detailed_trace.find_trace(params[:id].to_i) send_data(trace.trace_data) end |