Sha256: 3ebba150523aa261eaa798f05430e1777d2e27042327daaf837ee7ad2192b715

Contents?: true

Size: 1.67 KB

Versions: 3

Compression:

Stored size: 1.67 KB

Contents

section.query
  .page-header
    h1
      = query.name
      .pull-right
        = link_to [:edit, query], class: 'btn btn-default btn-sm' do
          i.fa.fa-pencil.fa-pad-r
          | Edit
      .pull-right
        = link_to 'Delete', query, class: 'btn btn-default btn-sm', :method => :delete, data: { confirm: 'Are you sure?' }
      .clearfix
      small= "Updated at #{l(query.updated_at, format: :short)}"
  p.description= query.description

  css:
    #{Rouge::Themes::Github.render(scope: '.highlight')}

  = raw query.query_with_highlight

  section.new-execution
    h2 Create report
    = form_for [query, query.executions.build], html: {role: 'form'} do |f|
      .form-inline.form-group.report_format
        = f.label  :report_format
        = f.select :report_format, f.object.supported_formats, {}, class: 'form-control'
      - if query.parameters.present?
        h4 Query parameters
        .form-group.query_parameters
          - query.parameters.each do |param_name|
            .form-inline.query_parameter
              = label_tag "parameters_#{param_name}", "#{param_name}"
              = query_parameter_field(param_name)
      .form-group
        = f.submit 'Create report', class: 'btn btn-default'

  section.past-executions
    h2 Reports
    table.executions.table.table-striped.table-hover
      thead
        tr
          th.wip  
          th.created_at= human(Adhoq::Execution, :created_at)
          th.status=     human(Adhoq::Execution, :status)
          th.report
      tbody
        - query.executions.recent_first.preload(:report).each do |exec|
          - next if exec.report.try(:on_the_fly?)
          = render 'execution', query: query, exec: exec

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
adhoq-0.5.0 app/views/adhoq/queries/_query.html.slim
adhoq-0.5.0.beta1 app/views/adhoq/queries/_query.html.slim
adhoq-0.4.0 app/views/adhoq/queries/_query.html.slim