BigW Consortium Gitlab

_show.html.haml 855 Bytes
Newer Older
1 2 3 4 5 6 7 8
- if @merge_request.open?
  = render 'projects/merge_requests/widget/open'
- elsif @merge_request.merged?
  = render 'projects/merge_requests/widget/merged'
- elsif @merge_request.closed?
  = render 'projects/merge_requests/widget/closed'
- elsif @merge_request.locked?
  = render 'projects/merge_requests/widget/locked'
9 10 11 12 13

:javascript
  var merge_request_widget;

  merge_request_widget = new MergeRequestWidget({
14
    url_to_automerge_check: "#{merge_check_namespace_project_merge_request_path(@project.namespace, @project, @merge_request)}",
15 16 17
    check_enable: #{@merge_request.unchecked? ? "true" : "false"},
    url_to_ci_check: "#{ci_status_namespace_project_merge_request_path(@project.namespace, @project, @merge_request)}",
    ci_enable: #{@project.ci_service ? "true" : "false"},
18
    current_status: "#{@merge_request.gitlab_merge_status}",
19 20
  });