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
b6e1df7a
Commit
b6e1df7a
authored
Jan 16, 2016
by
Robert Speicher
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'abuse-autofill-message' into 'master'
Autofill abuse message text with user url. Closes #2838 See merge request !2396
parents
5cd2f777
2d3655cd
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
4 additions
and
2 deletions
+4
-2
CHANGELOG
CHANGELOG
+1
-0
abuse_reports_controller.rb
app/controllers/abuse_reports_controller.rb
+1
-0
new.html.haml
app/views/abuse_reports/new.html.haml
+1
-1
show.html.haml
app/views/users/show.html.haml
+1
-1
No files found.
CHANGELOG
View file @
b6e1df7a
...
...
@@ -57,6 +57,7 @@ v 8.4.0 (unreleased)
- Autosize Markdown textareas
- Import GitHub wiki into GitLab
- Add reporters ability to download and browse build artifacts (Andrew Johnson)
- Autofill referring url in message box when reporting user abuse. (Josh Frye)
v 8.3.4
- Use gitlab-workhorse 0.5.4 (fixes API routing bug)
...
...
app/controllers/abuse_reports_controller.rb
View file @
b6e1df7a
...
...
@@ -2,6 +2,7 @@ class AbuseReportsController < ApplicationController
def
new
@abuse_report
=
AbuseReport
.
new
@abuse_report
.
user_id
=
params
[
:user_id
]
@ref_url
=
params
.
fetch
(
:ref_url
,
''
)
end
def
create
...
...
app/views/abuse_reports/new.html.haml
View file @
b6e1df7a
...
...
@@ -16,7 +16,7 @@
.form-group
=
f
.
label
:message
,
class:
'control-label'
.col-sm-10
=
f
.
text_area
:message
,
class:
"form-control js-quick-submit"
,
rows:
2
,
required:
true
=
f
.
text_area
:message
,
class:
"form-control js-quick-submit"
,
rows:
2
,
required:
true
,
value:
sanitize
(
@ref_url
)
.help-block
Explain the problem with this user. If appropriate, provide a link to the relevant issue or comment.
...
...
app/views/users/show.html.haml
View file @
b6e1df7a
...
...
@@ -20,7 +20,7 @@
data:
{
toggle:
'tooltip'
,
placement:
'left'
,
container:
'body'
}}
=
icon
(
'exclamation-circle'
)
-
else
=
link_to
new_abuse_report_path
(
user_id:
@user
.
id
),
class:
'btn btn-gray'
,
=
link_to
new_abuse_report_path
(
user_id:
@user
.
id
,
ref_url:
request
.
referrer
),
class:
'btn btn-gray'
,
title:
'Report abuse'
,
data:
{
toggle:
'tooltip'
,
placement:
'left'
,
container:
'body'
}
do
=
icon
(
'exclamation-circle'
)
-
if
current_user
...
...
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