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
Jérome Perrin
gitlab-ce
Commits
40347b78
Commit
40347b78
authored
Aug 06, 2017
by
Jacob Schatz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Change name to user feature helper.
parent
417ec302
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
5 deletions
+6
-5
app/assets/javascripts/dispatcher.js
app/assets/javascripts/dispatcher.js
+3
-3
app/assets/javascripts/helpers/user_feature_helper.js
app/assets/javascripts/helpers/user_feature_helper.js
+2
-2
app/assets/javascripts/repo/helpers/repo_helper.js
app/assets/javascripts/repo/helpers/repo_helper.js
+1
-0
No files found.
app/assets/javascripts/dispatcher.js
View file @
40347b78
...
...
@@ -76,7 +76,7 @@ import initNotes from './init_notes';
import
initLegacyFilters
from
'
./init_legacy_filters
'
;
import
initIssuableSidebar
from
'
./init_issuable_sidebar
'
;
import
GpgBadges
from
'
./gpg_badges
'
;
import
FeatureHelper
from
'
./helpers/
feature_helper
'
;
import
UserFeatureHelper
from
'
./helpers/user_
feature_helper
'
;
(
function
()
{
var
Dispatcher
;
...
...
@@ -413,7 +413,7 @@ import FeatureHelper from './helpers/feature_helper';
case
'
projects:tree:show
'
:
shortcut_handler
=
new
ShortcutsNavigation
();
if
(
FeatureHelper
.
isNewRepo
())
break
;
if
(
User
FeatureHelper
.
isNewRepo
())
break
;
new
TreeView
();
new
BlobViewer
();
...
...
@@ -433,7 +433,7 @@ import FeatureHelper from './helpers/feature_helper';
shortcut_handler
=
true
;
break
;
case
'
projects:blob:show
'
:
if
(
FeatureHelper
.
isNewRepo
())
break
;
if
(
User
FeatureHelper
.
isNewRepo
())
break
;
new
BlobViewer
();
initBlob
();
break
;
...
...
app/assets/javascripts/helpers/feature_helper.js
→
app/assets/javascripts/helpers/
user_
feature_helper.js
View file @
40347b78
...
...
@@ -4,8 +4,8 @@ function isNewRepo() {
return
Cookies
.
get
(
'
new_repo
'
)
===
'
true
'
;
}
const
FeatureHelper
=
{
const
User
FeatureHelper
=
{
isNewRepo
,
};
export
default
FeatureHelper
;
export
default
User
FeatureHelper
;
app/assets/javascripts/repo/helpers/repo_helper.js
View file @
40347b78
...
...
@@ -216,6 +216,7 @@ const RepoHelper = {
serializeRepoEntity
(
type
,
entity
)
{
const
{
url
,
name
,
icon
,
last_commit
}
=
entity
;
console
.
log
(
'
entity
'
,
JSON
.
stringify
(
entity
));
return
{
type
,
name
,
...
...
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