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
Boxiang Sun
gitlab-ce
Commits
ce884ad3
Commit
ce884ad3
authored
Sep 08, 2017
by
kushalpandya
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove confidential toggle checkbox and related code as no longer necessary
parent
ce14fae5
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
0 additions
and
62 deletions
+0
-62
app/assets/javascripts/issue_show/components/app.vue
app/assets/javascripts/issue_show/components/app.vue
+0
-7
app/assets/javascripts/issue_show/components/fields/confidential_checkbox.vue
...ts/issue_show/components/fields/confidential_checkbox.vue
+0
-23
app/assets/javascripts/issue_show/components/form.vue
app/assets/javascripts/issue_show/components/form.vue
+0
-4
app/assets/javascripts/issue_show/index.js
app/assets/javascripts/issue_show/index.js
+0
-1
app/assets/javascripts/issue_show/stores/index.js
app/assets/javascripts/issue_show/stores/index.js
+0
-1
app/helpers/issuables_helper.rb
app/helpers/issuables_helper.rb
+0
-1
spec/javascripts/issue_show/components/app_spec.js
spec/javascripts/issue_show/components/app_spec.js
+0
-25
No files found.
app/assets/javascripts/issue_show/components/app.vue
View file @
ce884ad3
...
@@ -72,10 +72,6 @@ export default {
...
@@ -72,10 +72,6 @@ export default {
required
:
false
,
required
:
false
,
default
:
()
=>
[],
default
:
()
=>
[],
},
},
isConfidential
:
{
type
:
Boolean
,
required
:
true
,
},
markdownPreviewPath
:
{
markdownPreviewPath
:
{
type
:
String
,
type
:
String
,
required
:
true
,
required
:
true
,
...
@@ -131,7 +127,6 @@ export default {
...
@@ -131,7 +127,6 @@ export default {
this
.
showForm
=
true
;
this
.
showForm
=
true
;
this
.
store
.
setFormState
({
this
.
store
.
setFormState
({
title
:
this
.
state
.
titleText
,
title
:
this
.
state
.
titleText
,
confidential
:
this
.
isConfidential
,
description
:
this
.
state
.
descriptionText
,
description
:
this
.
state
.
descriptionText
,
lockedWarningVisible
:
false
,
lockedWarningVisible
:
false
,
updateLoading
:
false
,
updateLoading
:
false
,
...
@@ -147,8 +142,6 @@ export default {
...
@@ -147,8 +142,6 @@ export default {
.
then
((
data
)
=>
{
.
then
((
data
)
=>
{
if
(
location
.
pathname
!==
data
.
web_url
)
{
if
(
location
.
pathname
!==
data
.
web_url
)
{
gl
.
utils
.
visitUrl
(
data
.
web_url
);
gl
.
utils
.
visitUrl
(
data
.
web_url
);
}
else
if
(
data
.
confidential
!==
this
.
isConfidential
)
{
gl
.
utils
.
visitUrl
(
location
.
pathname
);
}
}
return
this
.
service
.
getData
();
return
this
.
service
.
getData
();
...
...
app/assets/javascripts/issue_show/components/fields/confidential_checkbox.vue
deleted
100644 → 0
View file @
ce14fae5
<
script
>
export
default
{
props
:
{
formState
:
{
type
:
Object
,
required
:
true
,
},
},
};
</
script
>
<
template
>
<fieldset
class=
"checkbox"
>
<label
for=
"issue-confidential"
>
<input
type=
"checkbox"
value=
"1"
id=
"issue-confidential"
v-model=
"formState.confidential"
/>
This issue is confidential and should only be visible to team members with at least Reporter access.
</label>
</fieldset>
</
template
>
app/assets/javascripts/issue_show/components/form.vue
View file @
ce884ad3
...
@@ -4,7 +4,6 @@
...
@@ -4,7 +4,6 @@
import
descriptionField
from
'
./fields/description.vue
'
;
import
descriptionField
from
'
./fields/description.vue
'
;
import
editActions
from
'
./edit_actions.vue
'
;
import
editActions
from
'
./edit_actions.vue
'
;
import
descriptionTemplate
from
'
./fields/description_template.vue
'
;
import
descriptionTemplate
from
'
./fields/description_template.vue
'
;
import
confidentialCheckbox
from
'
./fields/confidential_checkbox.vue
'
;
export
default
{
export
default
{
props
:
{
props
:
{
...
@@ -44,7 +43,6 @@
...
@@ -44,7 +43,6 @@
descriptionField
,
descriptionField
,
descriptionTemplate
,
descriptionTemplate
,
editActions
,
editActions
,
confidentialCheckbox
,
},
},
computed
:
{
computed
:
{
hasIssuableTemplates
()
{
hasIssuableTemplates
()
{
...
@@ -81,8 +79,6 @@
...
@@ -81,8 +79,6 @@
:form-state=
"formState"
:form-state=
"formState"
:markdown-preview-path=
"markdownPreviewPath"
:markdown-preview-path=
"markdownPreviewPath"
:markdown-docs-path=
"markdownDocsPath"
/>
:markdown-docs-path=
"markdownDocsPath"
/>
<confidential-checkbox
:form-state=
"formState"
/>
<edit-actions
<edit-actions
:form-state=
"formState"
:form-state=
"formState"
:can-destroy=
"canDestroy"
/>
:can-destroy=
"canDestroy"
/>
...
...
app/assets/javascripts/issue_show/index.js
View file @
ce884ad3
...
@@ -35,7 +35,6 @@ document.addEventListener('DOMContentLoaded', () => {
...
@@ -35,7 +35,6 @@ document.addEventListener('DOMContentLoaded', () => {
initialDescriptionHtml
:
this
.
initialDescriptionHtml
,
initialDescriptionHtml
:
this
.
initialDescriptionHtml
,
initialDescriptionText
:
this
.
initialDescriptionText
,
initialDescriptionText
:
this
.
initialDescriptionText
,
issuableTemplates
:
this
.
issuableTemplates
,
issuableTemplates
:
this
.
issuableTemplates
,
isConfidential
:
this
.
isConfidential
,
markdownPreviewPath
:
this
.
markdownPreviewPath
,
markdownPreviewPath
:
this
.
markdownPreviewPath
,
markdownDocsPath
:
this
.
markdownDocsPath
,
markdownDocsPath
:
this
.
markdownDocsPath
,
projectPath
:
this
.
projectPath
,
projectPath
:
this
.
projectPath
,
...
...
app/assets/javascripts/issue_show/stores/index.js
View file @
ce884ad3
...
@@ -3,7 +3,6 @@ export default class Store {
...
@@ -3,7 +3,6 @@ export default class Store {
this
.
state
=
initialState
;
this
.
state
=
initialState
;
this
.
formState
=
{
this
.
formState
=
{
title
:
''
,
title
:
''
,
confidential
:
false
,
description
:
''
,
description
:
''
,
lockedWarningVisible
:
false
,
lockedWarningVisible
:
false
,
updateLoading
:
false
,
updateLoading
:
false
,
...
...
app/helpers/issuables_helper.rb
View file @
ce884ad3
...
@@ -213,7 +213,6 @@ module IssuablesHelper
...
@@ -213,7 +213,6 @@ module IssuablesHelper
canUpdate:
can?
(
current_user
,
:update_issue
,
issuable
),
canUpdate:
can?
(
current_user
,
:update_issue
,
issuable
),
canDestroy:
can?
(
current_user
,
:destroy_issue
,
issuable
),
canDestroy:
can?
(
current_user
,
:destroy_issue
,
issuable
),
issuableRef:
issuable
.
to_reference
,
issuableRef:
issuable
.
to_reference
,
isConfidential:
issuable
.
confidential
,
markdownPreviewPath:
preview_markdown_path
(
@project
),
markdownPreviewPath:
preview_markdown_path
(
@project
),
markdownDocsPath:
help_page_path
(
'user/markdown'
),
markdownDocsPath:
help_page_path
(
'user/markdown'
),
issuableTemplates:
issuable_templates
(
issuable
),
issuableTemplates:
issuable_templates
(
issuable
),
...
...
spec/javascripts/issue_show/components/app_spec.js
View file @
ce884ad3
...
@@ -42,7 +42,6 @@ describe('Issuable output', () => {
...
@@ -42,7 +42,6 @@ describe('Issuable output', () => {
initialDescriptionText
:
''
,
initialDescriptionText
:
''
,
markdownPreviewPath
:
'
/
'
,
markdownPreviewPath
:
'
/
'
,
markdownDocsPath
:
'
/
'
,
markdownDocsPath
:
'
/
'
,
isConfidential
:
false
,
projectNamespace
:
'
/
'
,
projectNamespace
:
'
/
'
,
projectPath
:
'
/
'
,
projectPath
:
'
/
'
,
},
},
...
@@ -157,30 +156,6 @@ describe('Issuable output', () => {
...
@@ -157,30 +156,6 @@ describe('Issuable output', () => {
});
});
});
});
it
(
'
reloads the page if the confidential status has changed
'
,
(
done
)
=>
{
spyOn
(
gl
.
utils
,
'
visitUrl
'
);
spyOn
(
vm
.
service
,
'
updateIssuable
'
).
and
.
callFake
(()
=>
new
Promise
((
resolve
)
=>
{
resolve
({
json
()
{
return
{
confidential
:
true
,
web_url
:
location
.
pathname
,
};
},
});
}));
vm
.
updateIssuable
();
setTimeout
(()
=>
{
expect
(
gl
.
utils
.
visitUrl
,
).
toHaveBeenCalledWith
(
location
.
pathname
);
done
();
});
});
it
(
'
correctly updates issuable data
'
,
(
done
)
=>
{
it
(
'
correctly updates issuable data
'
,
(
done
)
=>
{
spyOn
(
vm
.
service
,
'
updateIssuable
'
).
and
.
callFake
(()
=>
new
Promise
((
resolve
)
=>
{
spyOn
(
vm
.
service
,
'
updateIssuable
'
).
and
.
callFake
(()
=>
new
Promise
((
resolve
)
=>
{
resolve
();
resolve
();
...
...
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