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
a2912074
Commit
a2912074
authored
Nov 19, 2015
by
Valery Sizov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
satisfy rubocop
parent
fa2ed94f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
8 deletions
+8
-8
app/controllers/projects/notes_controller.rb
app/controllers/projects/notes_controller.rb
+2
-2
db/schema.rb
db/schema.rb
+1
-3
lib/award_emoji.rb
lib/award_emoji.rb
+5
-3
No files found.
app/controllers/projects/notes_controller.rb
View file @
a2912074
...
@@ -3,7 +3,7 @@ class Projects::NotesController < Projects::ApplicationController
...
@@ -3,7 +3,7 @@ class Projects::NotesController < Projects::ApplicationController
before_action
:authorize_read_note!
before_action
:authorize_read_note!
before_action
:authorize_create_note!
,
only:
[
:create
]
before_action
:authorize_create_note!
,
only:
[
:create
]
before_action
:authorize_admin_note!
,
only:
[
:update
,
:destroy
]
before_action
:authorize_admin_note!
,
only:
[
:update
,
:destroy
]
before_action
:find_current_user_notes
,
except:
[
:destroy
,
:delete_attachment
,
:award_toggle
]
]
before_action
:find_current_user_notes
,
except:
[
:destroy
,
:delete_attachment
,
:award_toggle
]
def
index
def
index
current_fetched_at
=
Time
.
now
.
to_i
current_fetched_at
=
Time
.
now
.
to_i
...
@@ -76,7 +76,7 @@ class Projects::NotesController < Projects::ApplicationController
...
@@ -76,7 +76,7 @@ class Projects::NotesController < Projects::ApplicationController
project
.
notes
.
create
(
data
)
project
.
notes
.
create
(
data
)
end
end
render
json:
{
ok:
true
}
render
json:
{
ok:
true
}
end
end
private
private
...
...
db/schema.rb
View file @
a2912074
...
@@ -642,9 +642,7 @@ ActiveRecord::Schema.define(version: 20151116144118) do
...
@@ -642,9 +642,7 @@ ActiveRecord::Schema.define(version: 20151116144118) do
t
.
integer
"star_count"
,
default:
0
,
null:
false
t
.
integer
"star_count"
,
default:
0
,
null:
false
t
.
string
"import_type"
t
.
string
"import_type"
t
.
string
"import_source"
t
.
string
"import_source"
t
.
integer
"commit_count"
,
default:
0
t
.
integer
"commit_count"
,
default:
0
t
.
boolean
"merge_requests_ff_only_enabled"
,
default:
false
t
.
text
"issues_template"
t
.
text
"import_error"
t
.
text
"import_error"
end
end
...
...
lib/award_emoji.rb
View file @
a2912074
class
AwardEmoji
class
AwardEmoji
EMOJI_LIST
=
[
"+1"
,
"-1"
,
"100"
,
"blush"
,
"heart"
,
"smile"
,
"rage"
,
EMOJI_LIST
=
[
"+1"
,
"-1"
,
"100"
,
"blush"
,
"heart"
,
"smile"
,
"rage"
,
"beers"
,
"disappointed"
,
"ok_hand"
,
"beers"
,
"disappointed"
,
"ok_hand"
,
"helicopter"
,
"shit"
,
"airplane"
,
"alarm_clock"
,
"helicopter"
,
"shit"
,
"airplane"
,
"alarm_clock"
,
"ambulance"
,
"anguished"
,
"two_hearts"
,
"wink"
]
"ambulance"
,
"anguished"
,
"two_hearts"
,
"wink"
]
def
self
.
path_to_emoji_image
(
name
)
def
self
.
path_to_emoji_image
(
name
)
"emoji/
#{
Emoji
.
emoji_filename
(
name
)
}
.png"
"emoji/
#{
Emoji
.
emoji_filename
(
name
)
}
.png"
end
end
end
end
\ No newline at end of file
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