Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Tatuya Kamada
gitlab-ce
Commits
3ea3d9ef
Commit
3ea3d9ef
authored
Dec 21, 2015
by
Jacob Schatz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
changes `issue-box` to `status-box` since html was changed as well
parent
45347914
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
9 deletions
+9
-9
app/assets/javascripts/issue.js.coffee
app/assets/javascripts/issue.js.coffee
+9
-9
No files found.
app/assets/javascripts/issue.js.coffee
View file @
3ea3d9ef
...
@@ -6,7 +6,7 @@ class @Issue
...
@@ -6,7 +6,7 @@ class @Issue
# Prevent duplicate event bindings
# Prevent duplicate event bindings
@
disableTaskList
()
@
disableTaskList
()
if
$
(
"a.btn-close"
).
length
if
$
(
'a.btn-close'
).
length
@
initTaskList
()
@
initTaskList
()
@
initIssueBtnEventListeners
()
@
initIssueBtnEventListeners
()
...
@@ -15,32 +15,32 @@ class @Issue
...
@@ -15,32 +15,32 @@ class @Issue
$
(
document
).
on
'tasklist:changed'
,
'.detail-page-description .js-task-list-container'
,
@
updateTaskList
$
(
document
).
on
'tasklist:changed'
,
'.detail-page-description .js-task-list-container'
,
@
updateTaskList
initIssueBtnEventListeners
:
->
initIssueBtnEventListeners
:
->
$
(
"a.btn-close, a.btn-reopen"
).
on
"click"
,
(
e
)
->
$
(
'a.btn-close, a.btn-reopen'
).
on
'click'
,
(
e
)
->
e
.
preventDefault
()
e
.
preventDefault
()
e
.
stopImmediatePropagation
()
e
.
stopImmediatePropagation
()
$this
=
$
(
this
)
$this
=
$
(
this
)
isClose
=
$this
.
hasClass
(
'btn-close'
)
isClose
=
$this
.
hasClass
(
'btn-close'
)
$this
.
prop
(
"disabled"
,
true
)
$this
.
prop
(
'disabled'
,
true
)
url
=
$this
.
attr
(
'href'
)
url
=
$this
.
attr
(
'href'
)
$
.
ajax
$
.
ajax
type
:
'PUT'
type
:
'PUT'
url
:
url
,
url
:
url
,
error
:
(
jqXHR
,
textStatus
,
errorThrown
)
->
error
:
(
jqXHR
,
textStatus
,
errorThrown
)
->
issueStatus
=
if
isClose
then
'close'
else
'open'
issueStatus
=
if
isClose
then
'close'
else
'open'
new
Flash
(
"Issues update failed"
,
'alert'
)
new
Flash
(
'Issues update failed'
,
'alert'
)
success
:
(
data
,
textStatus
,
jqXHR
)
->
success
:
(
data
,
textStatus
,
jqXHR
)
->
if
data
.
saved
if
data
.
saved
$this
.
addClass
(
'hidden'
)
$this
.
addClass
(
'hidden'
)
if
isClose
if
isClose
$
(
'a.btn-reopen'
).
removeClass
(
'hidden'
)
$
(
'a.btn-reopen'
).
removeClass
(
'hidden'
)
$
(
'div.
issue
-box-closed'
).
removeClass
(
'hidden'
)
$
(
'div.
status
-box-closed'
).
removeClass
(
'hidden'
)
$
(
'div.
issue
-box-open'
).
addClass
(
'hidden'
)
$
(
'div.
status
-box-open'
).
addClass
(
'hidden'
)
else
else
$
(
'a.btn-close'
).
removeClass
(
'hidden'
)
$
(
'a.btn-close'
).
removeClass
(
'hidden'
)
$
(
'div.
issue
-box-closed'
).
addClass
(
'hidden'
)
$
(
'div.
status
-box-closed'
).
addClass
(
'hidden'
)
$
(
'div.
issue
-box-open'
).
removeClass
(
'hidden'
)
$
(
'div.
status
-box-open'
).
removeClass
(
'hidden'
)
else
else
new
Flash
(
"Issues update failed"
,
'alert'
)
new
Flash
(
'Issues update failed'
,
'alert'
)
$this
.
prop
(
'disabled'
,
false
)
$this
.
prop
(
'disabled'
,
false
)
disableTaskList
:
->
disableTaskList
:
->
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment