houston-core 0.6.3 → 0.7.0.beta
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/Gemfile.lock +53 -63
- data/app/adapters/houston/adapters/error_tracker/errbit_adapter.rb +2 -2
- data/app/adapters/houston/adapters/ticket_tracker/github_adapter.rb +1 -1
- data/app/adapters/houston/adapters/ticket_tracker/unfuddle_adapter.rb +5 -5
- data/app/adapters/houston/adapters/version_control/git_adapter.rb +4 -4
- data/app/assets/javascripts/{app → houston/app}/boot.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/emoji.coffee.erb +0 -0
- data/app/assets/javascripts/{app → houston/app}/infinite_scroll.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/models/commit.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/models/release.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/models/task.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/models/tester.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/models/testing_note.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/models/ticket.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/models/user.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/mousetrap-bind-scoped.js +0 -0
- data/app/assets/javascripts/{app → houston/app}/releases.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/table_row_expander.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/ticket_tracker_refresh.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/_show_sprint_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/_tickets_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/all_tickets_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/commit_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/edit_sprint_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/edit_ticket_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/find_or_create_ticket_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/keyboard_shortcuts_modal.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/new_ticket_modal.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/new_ticket_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/problems_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/testing_note_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/testing_report_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/testing_ticket_view.coffee +0 -0
- data/app/assets/javascripts/{app → houston/app}/views/ticket_modal_view.coffee +0 -0
- data/app/assets/javascripts/{application.js → houston/application.js} +1 -1
- data/app/assets/javascripts/{core → houston/core}/app.coffee +0 -0
- data/app/assets/javascripts/{core → houston/core}/burndown_chart.coffee +0 -0
- data/app/assets/javascripts/{core → houston/core}/core_ext/array.coffee +0 -0
- data/app/assets/javascripts/{core → houston/core}/core_ext/date.coffee +0 -0
- data/app/assets/javascripts/{core → houston/core}/core_ext/number.coffee +0 -0
- data/app/assets/javascripts/{core → houston/core}/errors.coffee +1 -1
- data/app/assets/javascripts/{core → houston/core}/handlebars_helpers.coffee +0 -0
- data/app/assets/javascripts/{core → houston/core}/helpers.coffee +0 -0
- data/app/assets/javascripts/{core → houston/core}/jquery_extensions.coffee +5 -3
- data/app/assets/javascripts/{core → houston/core}/stacked_area_graph.coffee +0 -0
- data/app/assets/javascripts/{core → houston/core}/stacked_bar_graph.coffee +0 -0
- data/app/assets/javascripts/{dashboard.js → houston/dashboard.js} +1 -1
- data/app/assets/javascripts/{dashboard → houston/dashboard}/refresher.coffee +0 -0
- data/app/assets/javascripts/{vendor.js → houston/vendor.js} +0 -0
- data/app/assets/stylesheets/{application.css → houston/application.css} +0 -0
- data/app/assets/stylesheets/{application → houston/application}/ansi.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/commit.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/emoji.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/exceptions.scss +1 -1
- data/app/assets/stylesheets/{application → houston/application}/find_or_create_ticket.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/follow_up.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/forms.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/freight_train.css.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/full_screen.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/github_repos.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/infinite_scroll.scss +0 -0
- data/app/assets/stylesheets/houston/application/jobs.scss +5 -0
- data/app/assets/stylesheets/{application → houston/application}/keyboard_shortcuts.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/markdown.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/mobile.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/modals.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/navigation.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/new_ticket_view.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/omnibar.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/project_banner_buttons.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/project_tiles.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/projects.css.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/pull_requests.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/queue.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/release_form.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/releases.scss +1 -1
- data/app/assets/stylesheets/{application → houston/application}/sortable_table.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/sprint.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/tables.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/test.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/test_run.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/testing_report.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/ticket.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/ticket_modal.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/tickets.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/timeline.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/tips.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/typeahead.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/uploading.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/user_wall.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/users.scss +0 -0
- data/app/assets/stylesheets/{application → houston/application}/welcome.scss +0 -0
- data/app/assets/stylesheets/{core → houston/core}/alerts.scss +0 -0
- data/app/assets/stylesheets/{core → houston/core}/avatars.scss +0 -0
- data/app/assets/stylesheets/{core → houston/core}/burndown_chart.scss +0 -0
- data/app/assets/stylesheets/{core → houston/core}/colors.scss.erb +0 -0
- data/app/assets/stylesheets/{core → houston/core}/misc.scss +3 -0
- data/app/assets/stylesheets/{core → houston/core}/octicons-icons.scss +0 -0
- data/app/assets/stylesheets/{core → houston/core}/octicons.scss.erb +0 -0
- data/app/assets/stylesheets/{core → houston/core}/overrides.scss +0 -0
- data/app/assets/stylesheets/{core → houston/core}/roboto.scss.erb +0 -0
- data/app/assets/stylesheets/{core → houston/core}/scores.scss +0 -0
- data/app/assets/stylesheets/{dashboard.css → houston/dashboard.css} +0 -0
- data/app/assets/stylesheets/{dashboard → houston/dashboard}/dashboard.scss +0 -0
- data/app/assets/stylesheets/{print.css.scss → houston/print.css.scss} +0 -0
- data/app/assets/stylesheets/{variables.scss → houston/variables.scss} +0 -0
- data/app/assets/stylesheets/{vendor.css → houston/vendor.css} +0 -0
- data/app/concerns/houston/props.rb +96 -0
- data/app/concerns/project_adapter.rb +1 -1
- data/app/controllers/api/v1/measurements_controller.rb +32 -0
- data/app/controllers/application_controller.rb +1 -1
- data/app/controllers/authorizations_controller.rb +61 -0
- data/app/controllers/github/pulls_controller.rb +1 -1
- data/app/controllers/jobs_controller.rb +30 -1
- data/app/controllers/oauth/providers_controller.rb +45 -0
- data/app/controllers/project_options_controller.rb +2 -2
- data/app/controllers/projects_controller.rb +3 -3
- data/app/controllers/releases_controller.rb +3 -3
- data/app/controllers/user_options_controller.rb +2 -2
- data/app/controllers/users_controller.rb +1 -2
- data/app/helpers/application_helper.rb +49 -3
- data/app/helpers/email_helper.rb +19 -1
- data/app/helpers/release_helper.rb +1 -1
- data/app/helpers/ticket_helper.rb +0 -32
- data/app/interactors/cache_key_dependencies.rb +3 -8
- data/app/mailers/view_mailer.rb +8 -8
- data/app/models/authorization.rb +54 -0
- data/app/models/commit.rb +1 -1
- data/app/models/error.rb +14 -0
- data/app/models/github/comment_event.rb +4 -4
- data/app/models/github/pull_request.rb +39 -17
- data/app/models/github/pull_request_event.rb +1 -7
- data/app/models/job.rb +81 -0
- data/app/models/measurement.rb +2 -1
- data/app/models/oauth/provider.rb +35 -0
- data/app/models/project.rb +12 -3
- data/app/models/slackdown.rb +1 -1
- data/app/models/user.rb +28 -35
- data/app/presenters/measurements_presenter.rb +26 -0
- data/app/presenters/project_presenter.rb +1 -1
- data/app/views/authorizations/_form.html.erb +33 -0
- data/app/views/authorizations/edit.html.erb +7 -0
- data/app/views/authorizations/granted.html.erb +7 -0
- data/app/views/authorizations/index.html.erb +47 -0
- data/app/views/authorizations/new.html.erb +7 -0
- data/app/views/configuration_error/_no_ticket_tracker.html.erb +1 -1
- data/app/views/github/pulls/index.html.erb +5 -1
- data/app/views/jobs/index.html.erb +72 -0
- data/app/views/jobs/show.html.erb +25 -32
- data/app/views/layouts/_navigation.html.erb +1 -1
- data/app/views/layouts/application.html.erb +14 -15
- data/app/views/layouts/dashboard.html.erb +9 -10
- data/app/views/layouts/minimal.html.erb +14 -15
- data/app/views/layouts/naked.html.erb +52 -0
- data/app/views/layouts/naked_dashboard.html.erb +9 -10
- data/app/views/oauth/providers/_form.html.erb +54 -0
- data/app/views/oauth/providers/edit.html.erb +7 -0
- data/app/views/oauth/providers/index.html.erb +41 -0
- data/app/views/oauth/providers/new.html.erb +7 -0
- data/app/views/projects/_form.html.erb +8 -9
- data/app/views/projects/index.html.erb +1 -1
- data/app/views/users/_form.html.erb +20 -19
- data/bin/rails +1 -1
- data/config/application.rb +11 -10
- data/config/boot.rb +1 -2
- data/config/environments/development.rb +8 -6
- data/config/environments/production.rb +11 -16
- data/config/environments/test.rb +5 -5
- data/config/initializers/assets.rb +17 -7
- data/config/initializers/cookies_serializer.rb +1 -1
- data/config/initializers/houston_async.rb +22 -4
- data/config/initializers/houston_report_exception.rb +16 -11
- data/config/initializers/houston_scheduler.rb +1 -1
- data/config/initializers/houston_try.rb +12 -0
- data/config/routes.rb +29 -19
- data/db/fixtures/projects.yml +2 -2
- data/db/migrate/20160317140151_remove_limit_from_users_invitation_token.rb +9 -0
- data/db/migrate/20160419230411_create_oauth_providers.rb +14 -0
- data/db/migrate/20160420000616_create_authorizations.rb +16 -0
- data/db/migrate/20160507135209_create_jobs.rb +14 -0
- data/db/migrate/20160507135846_create_errors_2.rb +12 -0
- data/db/migrate/20160510233329_add_closed_at_and_merged_at_to_pull_requests.rb +7 -0
- data/db/migrate/20160625203412_convert_user_view_options_to_props.rb +21 -0
- data/db/migrate/20160625221840_convert_project_extended_attributes_to_props.rb +32 -0
- data/db/migrate/20160625230420_move_users_unfuddle_id_to_props.rb +14 -0
- data/db/structure.sql +247 -4
- data/{houston.gemspec → houston-core.gemspec} +8 -9
- data/lib/configuration.rb +15 -43
- data/lib/houston/version.rb +1 -1
- data/lib/houston_observer.rb +2 -7
- data/lib/parallel_enumerable.rb +2 -8
- data/templates/new-instance/app/assets/javascripts/.keep +0 -0
- data/templates/new-instance/app/assets/javascripts/application.js +13 -0
- data/templates/new-instance/app/assets/stylesheets/.keep +0 -0
- data/templates/new-instance/app/assets/stylesheets/application.css +13 -0
- data/templates/new-instance/app/controllers/.keep +0 -0
- data/templates/new-instance/app/models/.keep +0 -0
- data/templates/new-instance/app/views/.keep +0 -0
- data/templates/new-instance/config/alerts/errs.rb +1 -1
- data/templates/new-instance/config/jobs/purge_jobs.rb +3 -0
- data/templates/new-instance/config/main.rb +1 -0
- data/templates/new-instance/config/routes.rb +5 -0
- data/templates/new-instance/config/triggers/github/publish_comments_on_slack.rb +3 -3
- data/templates/new-instance/lib/houston/engine.rb +25 -0
- data/test/acceptance/creating_a_release_test.rb +1 -1
- data/test/integration/ci_integration_test.rb +2 -2
- data/test/integration/commits_api_test.rb +1 -1
- data/test/unit/controllers/hooks_controller_test.rb +1 -6
- data/test/unit/controllers/project_options_controller_test.rb +11 -11
- data/test/unit/controllers/user_options_controller_test.rb +13 -13
- data/test/unit/models/code_climate_coverage_report_test.rb +1 -1
- data/test/unit/models/commit_test.rb +4 -2
- data/test/unit/models/project_test.rb +5 -5
- data/test/unit/models/props_test.rb +57 -0
- data/test/unit/models/pull_request_test.rb +2 -2
- data/test/unit/models/test_run_test.rb +1 -1
- metadata +166 -151
- data/app/assets/javascripts/app/views/reports_view.coffee +0 -51
- data/app/controllers/oauth_consumers_controller.rb +0 -68
- data/app/controllers/reports_controller.rb +0 -215
- data/app/models/consumer_token.rb +0 -13
- data/app/models/github_token.rb +0 -8
- data/app/views/oauth_consumers/error.html.erb +0 -5
- data/app/views/oauth_consumers/index.html.erb +0 -29
- data/app/views/oauth_consumers/show.html.erb +0 -7
- data/app/views/reports/index.html.erb +0 -9
- data/app/views/reports/sprint.html.erb +0 -21
- data/app/views/reports/velocity.html.erb +0 -104
- data/config/initializers/oauth_consumers.rb +0 -18
- data/lib/patches/sprockets_output_path_for_assets.rb +0 -29
@@ -0,0 +1,26 @@
|
|
1
|
+
class MeasurementsPresenter
|
2
|
+
attr_reader :measurements
|
3
|
+
|
4
|
+
def initialize(measurements)
|
5
|
+
@measurements = measurements
|
6
|
+
end
|
7
|
+
|
8
|
+
def to_json(*args)
|
9
|
+
Houston.benchmark "[#{self.class.name.underscore}] Render JSON" do
|
10
|
+
MultiJson.dump(as_json(*args))
|
11
|
+
end
|
12
|
+
end
|
13
|
+
|
14
|
+
def as_json(*args)
|
15
|
+
Houston.benchmark "[#{self.class.name.underscore}] Prepare JSON" do
|
16
|
+
measurements.pluck(:name, :taken_at, :value, :subject_type, :subject_id)
|
17
|
+
.map do |name, timestamp, value, subject_type, subject_id|
|
18
|
+
{ timestamp: timestamp,
|
19
|
+
name: name,
|
20
|
+
value: value,
|
21
|
+
subject: { type: subject_type, id: subject_id } }
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
25
|
+
|
26
|
+
end
|
@@ -0,0 +1,33 @@
|
|
1
|
+
<%= form_for @authorization, html: {class: "form-horizontal"} do |f| %>
|
2
|
+
<fieldset>
|
3
|
+
<div class="control-group">
|
4
|
+
<%= f.label :name, class: "control-label" %>
|
5
|
+
<div class="controls">
|
6
|
+
<%= f.text_field :name, class: "text_field" %>
|
7
|
+
</div>
|
8
|
+
</div>
|
9
|
+
</fieldset>
|
10
|
+
|
11
|
+
<hr />
|
12
|
+
|
13
|
+
<fieldset>
|
14
|
+
<div class="control-group">
|
15
|
+
<%= f.label :provider_id, class: "control-label" %>
|
16
|
+
<div class="controls">
|
17
|
+
<%= f.collection_select :provider_id, Oauth::Provider.all, :id, :name %>
|
18
|
+
</div>
|
19
|
+
</div>
|
20
|
+
|
21
|
+
<div class="control-group">
|
22
|
+
<%= f.label :scope, class: "control-label" %>
|
23
|
+
<div class="controls">
|
24
|
+
<%= f.text_field :scope, class: "text_field" %>
|
25
|
+
</div>
|
26
|
+
</div>
|
27
|
+
</fieldset>
|
28
|
+
|
29
|
+
<div class="form-actions">
|
30
|
+
<%= f.submit nil, class: "btn btn-primary" %>
|
31
|
+
<%= link_to "Cancel", authorizations_path, class: "btn" %>
|
32
|
+
</div>
|
33
|
+
<% end %>
|
@@ -0,0 +1,47 @@
|
|
1
|
+
<% content_for :title do %>
|
2
|
+
<h1 class="project-banner space-below">
|
3
|
+
Authorizations
|
4
|
+
|
5
|
+
<%= link_to "New Authorization", new_authorization_path, class: "btn btn-primary" if can?(:create, Authorization) %>
|
6
|
+
</h1>
|
7
|
+
<% end %>
|
8
|
+
|
9
|
+
<div class="nomargin">
|
10
|
+
<table id="authorizations" class="table table-sortable table-striped">
|
11
|
+
<thead>
|
12
|
+
<tr>
|
13
|
+
<td class="table-margin"></td>
|
14
|
+
<th class="authorization-name">Name</th>
|
15
|
+
<th class="authorization-name">Provider</th>
|
16
|
+
<th class="authorization-status">Satus</th>
|
17
|
+
<td class="table-margin"></td>
|
18
|
+
</tr>
|
19
|
+
</thead>
|
20
|
+
<tbody>
|
21
|
+
<% @authorizations.each do |authorization| %>
|
22
|
+
<tr class="authorization">
|
23
|
+
<td class="table-margin"></td>
|
24
|
+
<td class="authorization-name"><%= link_to authorization.name, edit_authorization_path(authorization) %></td>
|
25
|
+
<td class="authorization-provider"><%= authorization.provider.name %></td>
|
26
|
+
<td class="authorization-status">
|
27
|
+
<% if authorization.granted? %>
|
28
|
+
Granted
|
29
|
+
<% else %>
|
30
|
+
<%= link_to "Grant", grant_authorization_path(authorization), class: "btn btn-primary" %>
|
31
|
+
<% end %>
|
32
|
+
</td>
|
33
|
+
<td class="table-margin"></td>
|
34
|
+
</tr>
|
35
|
+
<% end %>
|
36
|
+
</tbody>
|
37
|
+
</table>
|
38
|
+
</div>
|
39
|
+
|
40
|
+
|
41
|
+
<% content_for :javascripts do %>
|
42
|
+
<script type="text/javascript">
|
43
|
+
$(function() {
|
44
|
+
$('#authorizations').tablesorter();
|
45
|
+
});
|
46
|
+
</script>
|
47
|
+
<% end %>
|
@@ -2,6 +2,6 @@
|
|
2
2
|
<div class="controls">
|
3
3
|
<h3 style="margin-bottom: 0.25em;">No Ticket Tracker specified for this project.</h3>
|
4
4
|
<p><%= message %></p>
|
5
|
-
<p><%= link_to "OK. Let me enter that now.", edit_project_path(@project, anchor: "ticket_tracker") %></p>
|
5
|
+
<p><%= link_to "OK. Let me enter that now.", main_app.edit_project_path(@project, anchor: "ticket_tracker") %></p>
|
6
6
|
</div>
|
7
7
|
</div>
|
@@ -38,7 +38,11 @@
|
|
38
38
|
<% end %>
|
39
39
|
</td>
|
40
40
|
<td class="pull-request-project">
|
41
|
-
|
41
|
+
<% if pull.project.repo.respond_to?(:pulls_url) %>
|
42
|
+
<%= link_to pull.project.slug, pull.project.repo.pulls_url, class: "label #{pull.project.color}", target: "_blank" %>
|
43
|
+
<% else %>
|
44
|
+
<span class="label <%= pull.project.color %>"><%= pull.project.slug %></span>
|
45
|
+
<% end %>
|
42
46
|
</td>
|
43
47
|
<td class="pull-request-title">
|
44
48
|
<%= link_to emojify(pull.title), pull.url, target: "_blank" %>
|
@@ -0,0 +1,72 @@
|
|
1
|
+
<% content_for :title do %>
|
2
|
+
<h1 class="project-banner space-below">
|
3
|
+
Jobs
|
4
|
+
</h1>
|
5
|
+
<% end %>
|
6
|
+
|
7
|
+
<% if $scheduler %>
|
8
|
+
<p><b>Status:</b> <%= $scheduler.up? ? "Up (Started #{format_time $scheduler.started_at})".html_safe : "Down" %></p>
|
9
|
+
|
10
|
+
<div class="nomargin">
|
11
|
+
<table id="jobs" class="table table-sortable table-striped">
|
12
|
+
<thead>
|
13
|
+
<tr>
|
14
|
+
<td class="table-margin"></td>
|
15
|
+
<th class="scheduler-job-name">Name</th>
|
16
|
+
<td class="scheduler-job-schedule">Schedule</td>
|
17
|
+
<th class="scheduler-job-last">Last Run</th>
|
18
|
+
<th class="scheduler-job-reliability">Reliability</th>
|
19
|
+
<th class="scheduler-job-duration">Duration</th>
|
20
|
+
<td class="scheduler-job-run-now"></td>
|
21
|
+
<td class="table-margin"></td>
|
22
|
+
</tr>
|
23
|
+
</thead>
|
24
|
+
<tbody>
|
25
|
+
<% @jobs.each do |job| %>
|
26
|
+
<tr class="scheduler-job">
|
27
|
+
<td class="table-margin"></td>
|
28
|
+
<td class="scheduler-job-name"><%= link_to job[:name], job_path(slug: job[:name]) %></td>
|
29
|
+
<td class="scheduler-job-schedule"><%= job[:schedule] %></td>
|
30
|
+
<% if job[:last] %>
|
31
|
+
<td class="scheduler-job-last" data-timestamp="<%= job[:last].started_at.iso8601 %>">
|
32
|
+
<%= format_time job[:last].started_at, today: false %>
|
33
|
+
<%= format_job_state job[:last] %>
|
34
|
+
</td>
|
35
|
+
<td class="scheduler-job-reliability">
|
36
|
+
<%= number_to_percentage 100.0 * job[:successful_runs].to_f / job[:runs], precision: 1 %>
|
37
|
+
<span class="scheduler-job-success-rate">/<%= job[:runs] %></span>
|
38
|
+
</td>
|
39
|
+
<td class="scheduler-job-duration" data-position="<%= job[:avg_duration] %>"><%= format_duration job[:avg_duration] %></td>
|
40
|
+
<% else %>
|
41
|
+
<td class="scheduler-job-last">—</td>
|
42
|
+
<td class="scheduler-job-reliability">—</td>
|
43
|
+
<td class="scheduler-job-duration">—</td>
|
44
|
+
<% end %>
|
45
|
+
<td class="scheduler-job-run-now">
|
46
|
+
<%= button_to "Run now", run_job_path(slug: job[:name]), :class => "btn btn-default" %>
|
47
|
+
</td>
|
48
|
+
<td class="table-margin"></td>
|
49
|
+
</tr>
|
50
|
+
<% end %>
|
51
|
+
</tbody>
|
52
|
+
</table>
|
53
|
+
</div>
|
54
|
+
|
55
|
+
<% else %>
|
56
|
+
<p><b>Status:</b> Unavailable</p>
|
57
|
+
<% end %>
|
58
|
+
|
59
|
+
|
60
|
+
<% content_for :javascripts do %>
|
61
|
+
<script type="text/javascript">
|
62
|
+
$(function() {
|
63
|
+
$('#jobs').tablesorter({
|
64
|
+
headers: {
|
65
|
+
3: { sorter: 'timestamp' },
|
66
|
+
4: { sorter: 'percent' },
|
67
|
+
5: { sorter: 'property' }
|
68
|
+
}
|
69
|
+
});
|
70
|
+
});
|
71
|
+
</script>
|
72
|
+
<% end %>
|
@@ -1,43 +1,36 @@
|
|
1
1
|
<% content_for :title do %>
|
2
2
|
<h1 class="project-banner space-below">
|
3
|
-
Jobs
|
3
|
+
<%= link_to "Jobs", jobs_path %>
|
4
|
+
<small><%= @job_name %></small>
|
4
5
|
</h1>
|
5
6
|
<% end %>
|
6
7
|
|
7
|
-
|
8
|
-
<
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
<
|
8
|
+
<div class="nomargin">
|
9
|
+
<table id="jobs" class="table table-sortable table-striped">
|
10
|
+
<thead>
|
11
|
+
<tr>
|
12
|
+
<td class="table-margin"></td>
|
13
|
+
<th class="scheduler-job-time">Time</th>
|
14
|
+
<th class="scheduler-job-succeded">Succeeded</th>
|
15
|
+
<th class="scheduler-job-duration">Duration</th>
|
16
|
+
<th class="scheduler-job-exception">Exception</th>
|
17
|
+
<td class="table-margin"></td>
|
18
|
+
</tr>
|
19
|
+
</thead>
|
20
|
+
<tbody>
|
21
|
+
<% @jobs.each do |job| %>
|
22
|
+
<tr class="scheduler-job">
|
14
23
|
<td class="table-margin"></td>
|
15
|
-
<
|
16
|
-
<
|
17
|
-
<
|
24
|
+
<td class="scheduler-job-time"><%= format_time job.started_at %></td>
|
25
|
+
<td class="scheduler-job-succeded"><%= format_job_state job %></td>
|
26
|
+
<td class="scheduler-job-duration"><%= format_duration job.duration %></td>
|
27
|
+
<td class="scheduler-job-exception"><%= job.error.message if job.error %><td>
|
18
28
|
<td class="table-margin"></td>
|
19
29
|
</tr>
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
<td class="table-margin"></td>
|
25
|
-
<td class="scheduler-job-name"><%= job.tags.first %></td>
|
26
|
-
<td class="scheduler-job-schedule"><%= job.original %></td>
|
27
|
-
<td class="scheduler-job-run-now">
|
28
|
-
<%= button_to "Run now", run_job_path(slug: job.tags.first), :class => "btn btn-default" %>
|
29
|
-
</td>
|
30
|
-
<td class="table-margin"></td>
|
31
|
-
</tr>
|
32
|
-
<% end %>
|
33
|
-
</tbody>
|
34
|
-
</table>
|
35
|
-
</div>
|
36
|
-
|
37
|
-
<% else %>
|
38
|
-
<p><b>Status:</b> Unavailable</p>
|
39
|
-
<% end %>
|
40
|
-
|
30
|
+
<% end %>
|
31
|
+
</tbody>
|
32
|
+
</table>
|
33
|
+
</div>
|
41
34
|
|
42
35
|
<% content_for :javascripts do %>
|
43
36
|
<script type="text/javascript">
|
@@ -38,7 +38,7 @@
|
|
38
38
|
</div>
|
39
39
|
|
40
40
|
<% if current_user -%>
|
41
|
-
<div class="navbar project-navbar <%= current_project.color %>">
|
41
|
+
<div class="navbar project-navbar <%= current_project && current_project.color %>">
|
42
42
|
<ul class="nav">
|
43
43
|
|
44
44
|
<li class="dropdown current-project <%= current_project && current_project.color %>">
|
@@ -19,18 +19,17 @@
|
|
19
19
|
<![endif]-->
|
20
20
|
|
21
21
|
<!-- Le styles -->
|
22
|
-
<%= stylesheet_link_tag
|
23
|
-
<%= stylesheet_link_tag
|
24
|
-
<%= stylesheet_link_tag
|
22
|
+
<%= stylesheet_link_tag "houston/vendor", media: "all" %>
|
23
|
+
<%= stylesheet_link_tag "houston/application", media: "all" %>
|
24
|
+
<%= stylesheet_link_tag "houston/print", media: "print" %>
|
25
25
|
<link href="//maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css" rel="stylesheet">
|
26
|
-
|
26
|
+
|
27
27
|
<%= yield :stylesheets %><%# so that Engines can hook in and add styles %>
|
28
28
|
|
29
29
|
<!-- Le fav and touch icons -->
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
<link href="images/apple-touch-icon-114x114.png" rel="apple-touch-icon" sizes="114x114">
|
30
|
+
<% unless unfurling? %>
|
31
|
+
<link rel="icon" type="image/x-icon" href="<%= ENV['RAILS_RELATIVE_URL_ROOT'] %>/favicon.png" />
|
32
|
+
<% end %>
|
34
33
|
</head>
|
35
34
|
<body>
|
36
35
|
|
@@ -51,23 +50,23 @@
|
|
51
50
|
|
52
51
|
<%= render partial: "layouts/tester_bar" if Rails.env.development? -%>
|
53
52
|
</div> <!-- /container -->
|
54
|
-
|
53
|
+
|
55
54
|
<!-- Le javascript
|
56
55
|
================================================== -->
|
57
56
|
<!-- Placed at the end of the document so the pages load faster -->
|
58
|
-
<%= javascript_include_tag "https://
|
57
|
+
<%= javascript_include_tag "https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js" %>
|
59
58
|
<%# javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/2.3.2/js/bootstrap.min.js" %>
|
60
59
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.5.1/underscore-min.js" %>
|
61
60
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/backbone.js/1.0.0/backbone-min.js" %>
|
62
61
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/handlebars.js/4.0.2/handlebars.min.js" %>
|
63
62
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/d3/3.4.1/d3.min.js" %>
|
64
63
|
<%# javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/dropzone/4.0.1/min/dropzone.min.js" %>
|
65
|
-
<%= javascript_include_tag
|
66
|
-
<%= javascript_include_tag
|
64
|
+
<%= javascript_include_tag "houston/vendor" %>
|
65
|
+
<%= javascript_include_tag "houston/application" %>
|
67
66
|
<script type="text/javascript">
|
68
67
|
$(function(){
|
69
68
|
window.testers = new Testers(<%= raw TesterPresenter.new(User.testers.unretired).to_json %>);
|
70
|
-
|
69
|
+
|
71
70
|
<% if flash[:alert] %>
|
72
71
|
alertify.log(<%=raw flash[:alert].to_json %>);
|
73
72
|
<% end %>
|
@@ -77,7 +76,7 @@
|
|
77
76
|
<% if flash[:error] %>
|
78
77
|
alertify.error(<%=raw flash[:error].to_json %>);
|
79
78
|
<% end %>
|
80
|
-
|
79
|
+
|
81
80
|
<% if current_user %>
|
82
81
|
window.userId = <%= current_user.id %>;
|
83
82
|
window.user = new User(<%= raw({
|
@@ -90,6 +89,6 @@
|
|
90
89
|
<% end %>
|
91
90
|
});
|
92
91
|
</script>
|
93
|
-
<%= yield :javascripts %>
|
92
|
+
<%= yield :javascripts %><%# so that Engines can hook in and add scripts %>
|
94
93
|
</body>
|
95
94
|
</html>
|
@@ -15,16 +15,15 @@
|
|
15
15
|
<![endif]-->
|
16
16
|
|
17
17
|
<!-- Le styles -->
|
18
|
-
<%= stylesheet_link_tag
|
19
|
-
<%= stylesheet_link_tag
|
18
|
+
<%= stylesheet_link_tag "houston/vendor", media: "all" %>
|
19
|
+
<%= stylesheet_link_tag "houston/dashboard", media: "all" %>
|
20
20
|
<link href="//maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css" rel="stylesheet">
|
21
21
|
<%= yield :stylesheets %><%# so that Engines can hook in and add styles %>
|
22
22
|
|
23
23
|
<!-- Le fav and touch icons -->
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
<link href="images/apple-touch-icon-114x114.png" rel="apple-touch-icon" sizes="114x114">
|
24
|
+
<% unless unfurling? %>
|
25
|
+
<link rel="icon" type="image/x-icon" href="<%= ENV['RAILS_RELATIVE_URL_ROOT'] %>/favicon.png" />
|
26
|
+
<% end %>
|
28
27
|
</head>
|
29
28
|
<body class="dashboard">
|
30
29
|
<div id="container" <% if params[:zoom].to_f > 0 %> style="transform: scale(<%= params[:zoom].to_f %>); transform-origin: 50% 0; -webkit-transform: scale(<%= params[:zoom].to_f %>); -webkit-transform-origin: 50% 0; -moz-transform: scale(<%= params[:zoom].to_f %>); -moz-transform-origin: 50% 0; width: <%= (1 / params[:zoom].to_f) * 100 %>%; height: <%= (1 / params[:zoom].to_f) * 100 %>%;" <% end %>>
|
@@ -34,15 +33,15 @@
|
|
34
33
|
<!-- Le javascript
|
35
34
|
================================================== -->
|
36
35
|
<!-- Placed at the end of the document so the pages load faster -->
|
37
|
-
<%= javascript_include_tag "https://
|
36
|
+
<%= javascript_include_tag "https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js" %>
|
38
37
|
<%# javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/2.3.2/js/bootstrap.min.js" %>
|
39
38
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.5.1/underscore-min.js" %>
|
40
39
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/backbone.js/1.0.0/backbone-min.js" %>
|
41
40
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/handlebars.js/4.0.2/handlebars.min.js" %>
|
42
41
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/d3/3.4.1/d3.min.js" %>
|
43
42
|
<%# javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/dropzone/4.0.1/min/dropzone.min.js" %>
|
44
|
-
<%= javascript_include_tag
|
45
|
-
<%= javascript_include_tag
|
46
|
-
<%= yield :javascripts %>
|
43
|
+
<%= javascript_include_tag "houston/vendor" %>
|
44
|
+
<%= javascript_include_tag "houston/dashboard" %>
|
45
|
+
<%= yield :javascripts %><%# so that Engines can hook in and add scripts %>
|
47
46
|
</body>
|
48
47
|
</html>
|
@@ -16,40 +16,39 @@
|
|
16
16
|
<![endif]-->
|
17
17
|
|
18
18
|
<!-- Le styles -->
|
19
|
-
<%= stylesheet_link_tag
|
20
|
-
<%= stylesheet_link_tag
|
21
|
-
<%= stylesheet_link_tag
|
19
|
+
<%= stylesheet_link_tag "houston/vendor", media: "all" %>
|
20
|
+
<%= stylesheet_link_tag "houston/application", media: "all" %>
|
21
|
+
<%= stylesheet_link_tag "houston/print", media: "print" %>
|
22
22
|
<link href="//maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css" rel="stylesheet">
|
23
23
|
<%= yield :stylesheets %><%# so that Engines can hook in and add styles %>
|
24
24
|
|
25
25
|
<!-- Le fav and touch icons -->
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
<link href="images/apple-touch-icon-114x114.png" rel="apple-touch-icon" sizes="114x114">
|
26
|
+
<% unless unfurling? %>
|
27
|
+
<link rel="icon" type="image/x-icon" href="<%= ENV['RAILS_RELATIVE_URL_ROOT'] %>/favicon.png" />
|
28
|
+
<% end %>
|
30
29
|
</head>
|
31
30
|
<body>
|
32
|
-
|
31
|
+
|
33
32
|
<%= render "layouts/navigation" %>
|
34
|
-
|
33
|
+
|
35
34
|
<div class="container">
|
36
35
|
<%= yield -%>
|
37
|
-
|
36
|
+
|
38
37
|
<%= render partial: "layouts/tester_bar" if Rails.env.development? -%>
|
39
38
|
</div> <!-- /container -->
|
40
|
-
|
39
|
+
|
41
40
|
<!-- Le javascript
|
42
41
|
================================================== -->
|
43
42
|
<!-- Placed at the end of the document so the pages load faster -->
|
44
|
-
<%= javascript_include_tag "https://
|
43
|
+
<%= javascript_include_tag "https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js" %>
|
45
44
|
<%# javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/2.3.2/js/bootstrap.min.js" %>
|
46
45
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.5.1/underscore-min.js" %>
|
47
46
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/backbone.js/1.0.0/backbone-min.js" %>
|
48
47
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/handlebars.js/4.0.2/handlebars.min.js" %>
|
49
48
|
<%= javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/d3/3.4.1/d3.min.js" %>
|
50
49
|
<%# javascript_include_tag "https://cdnjs.cloudflare.com/ajax/libs/dropzone/4.0.1/min/dropzone.min.js" %>
|
51
|
-
<%= javascript_include_tag
|
52
|
-
<%= javascript_include_tag
|
53
|
-
<%= yield :javascripts %>
|
50
|
+
<%= javascript_include_tag "houston/vendor" %>
|
51
|
+
<%= javascript_include_tag "houston/application" %>
|
52
|
+
<%= yield :javascripts %><%# so that Engines can hook in and add scripts %>
|
54
53
|
</body>
|
55
54
|
</html>
|