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
Léo-Paul Géneau
gitlab-ce
Commits
6ade6e2b
Commit
6ade6e2b
authored
Feb 15, 2018
by
James Lopez
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix specs
parent
50ccc6dc
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
app/helpers/blob_helper.rb
app/helpers/blob_helper.rb
+6
-5
No files found.
app/helpers/blob_helper.rb
View file @
6ade6e2b
...
...
@@ -84,7 +84,7 @@ module BlobHelper
elsif
can_modify_blob?
(
blob
,
project
,
ref
)
button_tag
label
,
class:
"
#{
common_classes
}
"
,
'data-target'
=>
"#modal-
#{
modal_type
}
-blob"
,
'data-toggle'
=>
'modal'
elsif
can?
(
current_user
,
:fork_project
,
project
)
edit_fork_button_tag
(
common_classes
,
project
,
label
,
edit_modify_file_fork_params
(
action
))
edit_fork_button_tag
(
common_classes
,
project
,
label
,
edit_modify_file_fork_params
(
action
)
,
action
)
end
end
...
...
@@ -331,16 +331,17 @@ module BlobHelper
{
to:
request
.
fullpath
,
notice:
edit_in_new_fork_notice_action
(
action
),
notice_now:
edit_in_new_fork_notice_now
notice_now:
edit_in_new_fork_notice_now
,
action:
action
}
end
def
edit_fork_button_tag
(
common_classes
,
project
,
label
,
params
)
def
edit_fork_button_tag
(
common_classes
,
project
,
label
,
params
,
action
=
'edit'
)
fork_path
=
project_forks_path
(
project
,
namespace_key:
current_user
.
namespace
.
id
,
continue:
params
)
button_tag
edit_text
,
button_tag
label
,
class:
"
#{
common_classes
}
js-edit-blob-link-fork-toggler"
,
data:
{
action:
'edit'
,
fork_path:
fork_path
}
data:
{
action:
action
,
fork_path:
fork_path
}
end
def
edit_button_tag
(
button_text
,
common_classes
)
...
...
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