summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2015-03-26 08:56:00 -0700
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2015-03-26 08:56:00 -0700
commitb8164321fedfd17479ce7ac0b4961bf1e5929da0 (patch)
tree73031698255cc7665e4bf80d4252a9b21e526244 /app
parenta80733e25494a9b8d31b33454a9fb3f5b4be2dfb (diff)
parent7842a815693328614c77f636b3b413d260739fcf (diff)
downloadgitlab-ce-b8164321fedfd17479ce7ac0b4961bf1e5929da0.tar.gz
Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce
Diffstat (limited to 'app')
-rw-r--r--app/assets/javascripts/calendar.js.coffee2
-rw-r--r--app/helpers/diff_helper.rb4
-rw-r--r--app/views/users/calendar.html.haml2
3 files changed, 6 insertions, 2 deletions
diff --git a/app/assets/javascripts/calendar.js.coffee b/app/assets/javascripts/calendar.js.coffee
index d08ef9361a6..37b7ba2cc10 100644
--- a/app/assets/javascripts/calendar.js.coffee
+++ b/app/assets/javascripts/calendar.js.coffee
@@ -1,4 +1,4 @@
-class @calendar
+class @Calendar
options =
month: "short"
day: "numeric"
diff --git a/app/helpers/diff_helper.rb b/app/helpers/diff_helper.rb
index f81504991d3..b56f21c7a18 100644
--- a/app/helpers/diff_helper.rb
+++ b/app/helpers/diff_helper.rb
@@ -121,6 +121,8 @@ module DiffHelper
def inline_diff_btn
params_copy = params.dup
params_copy[:view] = 'inline'
+ # Always use HTML to handle case where JSON diff rendered this button
+ params_copy.delete(:format)
link_to url_for(params_copy), id: "commit-diff-viewtype", class: (params[:view] != 'parallel' ? 'btn btn-sm active' : 'btn btn-sm') do
'Inline'
@@ -130,6 +132,8 @@ module DiffHelper
def parallel_diff_btn
params_copy = params.dup
params_copy[:view] = 'parallel'
+ # Always use HTML to handle case where JSON diff rendered this button
+ params_copy.delete(:format)
link_to url_for(params_copy), id: "commit-diff-viewtype", class: (params[:view] == 'parallel' ? 'btn active btn-sm' : 'btn btn-sm') do
'Side-by-side'
diff --git a/app/views/users/calendar.html.haml b/app/views/users/calendar.html.haml
index 488f49267c7..922b0c6cebf 100644
--- a/app/views/users/calendar.html.haml
+++ b/app/views/users/calendar.html.haml
@@ -4,7 +4,7 @@
%small Issues, merge requests and push events
#cal-heatmap.calendar
:javascript
- new calendar(
+ new Calendar(
#{@timestamps.to_json},
#{@starting_year},
#{@starting_month},