summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Schatz <jacobschatz@Jacobs-MBP.fios-router.home>2015-12-21 17:10:27 -0500
committerJacob Schatz <jacobschatz@Jacobs-MBP.fios-router.home>2015-12-21 17:10:27 -0500
commit3ea3d9ef284fcfaaa1b631e98926df7dae4129c9 (patch)
tree49b245e9b33b62a45ddf65e87b540723632d41af
parent453479143dd4784d7284b2e6f98694ff8fc18ce8 (diff)
downloadgitlab-ce-3ea3d9ef284fcfaaa1b631e98926df7dae4129c9.tar.gz
changes `issue-box` to `status-box` since html was changed as well
-rw-r--r--app/assets/javascripts/issue.js.coffee18
1 files changed, 9 insertions, 9 deletions
diff --git a/app/assets/javascripts/issue.js.coffee b/app/assets/javascripts/issue.js.coffee
index 2e0ef99a587..1a9e03e4ee3 100644
--- a/app/assets/javascripts/issue.js.coffee
+++ b/app/assets/javascripts/issue.js.coffee
@@ -6,7 +6,7 @@ class @Issue
# Prevent duplicate event bindings
@disableTaskList()
- if $("a.btn-close").length
+ if $('a.btn-close').length
@initTaskList()
@initIssueBtnEventListeners()
@@ -15,32 +15,32 @@ class @Issue
$(document).on 'tasklist:changed', '.detail-page-description .js-task-list-container', @updateTaskList
initIssueBtnEventListeners: ->
- $("a.btn-close, a.btn-reopen").on "click", (e) ->
+ $('a.btn-close, a.btn-reopen').on 'click', (e) ->
e.preventDefault()
e.stopImmediatePropagation()
$this = $(this)
isClose = $this.hasClass('btn-close')
- $this.prop("disabled", true)
+ $this.prop('disabled', true)
url = $this.attr('href')
$.ajax
type: 'PUT'
url: url,
error: (jqXHR, textStatus, errorThrown) ->
issueStatus = if isClose then 'close' else 'open'
- new Flash("Issues update failed", 'alert')
+ new Flash('Issues update failed', 'alert')
success: (data, textStatus, jqXHR) ->
if data.saved
$this.addClass('hidden')
if isClose
$('a.btn-reopen').removeClass('hidden')
- $('div.issue-box-closed').removeClass('hidden')
- $('div.issue-box-open').addClass('hidden')
+ $('div.status-box-closed').removeClass('hidden')
+ $('div.status-box-open').addClass('hidden')
else
$('a.btn-close').removeClass('hidden')
- $('div.issue-box-closed').addClass('hidden')
- $('div.issue-box-open').removeClass('hidden')
+ $('div.status-box-closed').addClass('hidden')
+ $('div.status-box-open').removeClass('hidden')
else
- new Flash("Issues update failed", 'alert')
+ new Flash('Issues update failed', 'alert')
$this.prop('disabled', false)
disableTaskList: ->