Add basic tables and graphs for various tables.
Add basic tables and graphs for viewing things like uploads over time, new users over time, comments over time, etc. Located at https://betabooru.donmai.us/reports. The graphing uses Apache ECharts: https://echarts.apache.org/en/index.html.
This commit is contained in:
13
app/components/time_series_component.rb
Normal file
13
app/components/time_series_component.rb
Normal file
@@ -0,0 +1,13 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
class TimeSeriesComponent < ApplicationComponent
|
||||
delegate :current_page_path, :search_params, to: :helpers
|
||||
|
||||
attr_reader :results, :columns, :mode
|
||||
|
||||
def initialize(results, columns, mode: :table)
|
||||
@results = results
|
||||
@columns = columns
|
||||
@mode = mode.to_sym
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user