BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
245be4ce
Commit
245be4ce
authored
Jun 22, 2017
by
Phil Hughes
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '33904-edit-issue-warning' into 'master'
don't show "Someone edited the issue" warning when saving issue Closes #33904 See merge request !12371
parents
270ca89d
54168362
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
10 deletions
+6
-10
app.vue
app/assets/javascripts/issue_show/components/app.vue
+0
-6
index.js
app/assets/javascripts/issue_show/stores/index.js
+6
-4
No files found.
app/assets/javascripts/issue_show/components/app.vue
View file @
245be4ce
...
...
@@ -204,13 +204,7 @@ export default {
method
:
'getData'
,
successCallback
:
(
res
)
=>
{
const
data
=
res
.
json
();
const
shouldUpdate
=
this
.
store
.
stateShouldUpdate
(
data
);
this
.
store
.
updateState
(
data
);
if
(
this
.
showForm
&&
(
shouldUpdate
.
title
||
shouldUpdate
.
description
))
{
this
.
store
.
formState
.
lockedWarningVisible
=
true
;
}
},
errorCallback
(
err
)
{
throw
new
Error
(
err
);
...
...
app/assets/javascripts/issue_show/stores/index.js
View file @
245be4ce
...
...
@@ -12,6 +12,10 @@ export default class Store {
}
updateState
(
data
)
{
if
(
this
.
stateShouldUpdate
(
data
))
{
this
.
formState
.
lockedWarningVisible
=
true
;
}
this
.
state
.
titleHtml
=
data
.
title
;
this
.
state
.
titleText
=
data
.
title_text
;
this
.
state
.
descriptionHtml
=
data
.
description
;
...
...
@@ -23,10 +27,8 @@ export default class Store {
}
stateShouldUpdate
(
data
)
{
return
{
title
:
this
.
state
.
titleText
!==
data
.
title_text
,
description
:
this
.
state
.
descriptionText
!==
data
.
description_text
,
};
return
this
.
state
.
titleText
!==
data
.
title_text
||
this
.
state
.
descriptionText
!==
data
.
description_text
;
}
setFormState
(
state
)
{
...
...
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