Files
codeocean/app/views/statistics/activity_history.html.slim
Sebastian Serth d223abfb5e Update from webpacker v5 to shakapacker v6.0.0.rc13
Using a two-step process is recommended:
332e25186a/docs/v6_upgrade.md
2022-08-12 10:22:55 +02:00

26 lines
1.1 KiB
Plaintext

- content_for :head do
// Force a full page reload, see https://github.com/turbolinks/turbolinks/issues/326.
Otherwise, the global variable `vis` might be uninitialized in the assets (race condition)
meta name='turbolinks-visit-control' content='reload'
- append_javascript_pack_tag('vis')
- append_stylesheet_pack_tag('vis')
.group
.title
h1 = t("statistics.graphs.#{resource}_activity")
.spinner
.graph id="#{resource}-activity-history"
form
.form-group
label for="from-date" = t('.from')
input type="date" class="form-control" id="from-date" name="from" value=(params[:from] || DateTime.new(2016).to_date)
.form-group
label for="to-date" = t('.to')
input type="date" class="form-control" id="to-date" name="to" value=(params[:to] || DateTime.now.to_date)
.form-group
label for="interval" = t('.interval')
select class="form-control" id="interval" name="interval"
= [:year, :quarter, :month, :day, :hour, :minute, :second].each do | key |
option selected=(key.to_s == params[:interval]) = key
button type="submit" class="btn btn-primary" = t('.update')