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
Tatuya Kamada
gitlab-ce
Commits
a0aa0212
Commit
a0aa0212
authored
Nov 29, 2012
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Removed feature: comments on wiki
parent
df03275e
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
1 addition
and
59 deletions
+1
-59
app/contexts/notes/load_context.rb
app/contexts/notes/load_context.rb
+0
-2
app/mailers/notify.rb
app/mailers/notify.rb
+1
-9
app/models/project.rb
app/models/project.rb
+0
-4
app/views/notify/note_wiki_email.html.haml
app/views/notify/note_wiki_email.html.haml
+0
-23
app/views/wikis/show.html.haml
app/views/wikis/show.html.haml
+0
-3
features/project/wiki.feature
features/project/wiki.feature
+0
-6
spec/requests/gitlab_flavored_markdown_spec.rb
spec/requests/gitlab_flavored_markdown_spec.rb
+0
-12
No files found.
app/contexts/notes/load_context.rb
View file @
a0aa0212
...
@@ -19,8 +19,6 @@ module Notes
...
@@ -19,8 +19,6 @@ module Notes
when
"wall"
when
"wall"
# this is the only case, where the order is DESC
# this is the only case, where the order is DESC
project
.
common_notes
.
order
(
"created_at DESC, id DESC"
).
limit
(
50
)
project
.
common_notes
.
order
(
"created_at DESC, id DESC"
).
limit
(
50
)
when
"wiki"
project
.
wiki_notes
.
limit
(
20
)
end
end
@notes
=
if
after_id
@notes
=
if
after_id
...
...
app/mailers/notify.rb
View file @
a0aa0212
...
@@ -89,14 +89,6 @@ class Notify < ActionMailer::Base
...
@@ -89,14 +89,6 @@ class Notify < ActionMailer::Base
mail
(
to:
recipient
(
recipient_id
),
subject:
subject
)
mail
(
to:
recipient
(
recipient_id
),
subject:
subject
)
end
end
def
note_wiki_email
(
recipient_id
,
note_id
)
@note
=
Note
.
find
(
note_id
)
@wiki
=
@note
.
noteable
@project
=
@note
.
project
mail
(
to:
recipient
(
recipient_id
),
subject:
subject
(
"note for wiki"
))
end
#
#
# Project
# Project
...
...
app/models/project.rb
View file @
a0aa0212
...
@@ -216,10 +216,6 @@ class Project < ActiveRecord::Base
...
@@ -216,10 +216,6 @@ class Project < ActiveRecord::Base
last_event
.
try
(
:created_at
)
||
updated_at
last_event
.
try
(
:created_at
)
||
updated_at
end
end
def
wiki_notes
Note
.
where
(
noteable_id:
wikis
.
pluck
(
:id
),
noteable_type:
'Wiki'
,
project_id:
self
.
id
)
end
def
project_id
def
project_id
self
.
id
self
.
id
end
end
...
...
app/views/notify/note_wiki_email.html.haml
deleted
100644 → 0
View file @
df03275e
%td
.content
{
align:
"left"
,
style:
"font-family: Helvetica, Arial, sans-serif; padding: 20px 0 0;"
,
valign:
"top"
,
width:
"600"
}
%table
{
border:
"0"
,
cellpadding:
"0"
,
cellspacing:
"0"
,
style:
"color: #717171; font: normal 11px Helvetica, Arial, sans-serif; margin: 0; padding: 0;"
,
width:
"600"
}
%tr
%td
{
style:
"font-size: 1px; line-height: 1px;"
,
width:
"21"
}
%td
{
align:
"left"
,
style:
"padding: 20px 0 0;"
}
%h2
{
style:
"color:#646464 !important; font-weight: bold; margin: 0; padding: 0; line-height: 26px; font-size: 18px; font-family: Helvetica, Arial, sans-serif; "
}
New comment for Wiki page
=
link_to_gfm
@wiki
.
title
,
project_wiki_url
(
@wiki
.
project
,
@wiki
,
anchor:
"note_
#{
@note
.
id
}
"
)
%td
{
style:
"font-size: 1px; line-height: 1px;"
,
width:
"21"
}
%tr
%td
{
style:
"font-size: 1px; line-height: 1px;"
,
width:
"21"
}
%td
{
style:
"padding: 15px 0 15px;"
,
valign:
"top"
}
%p
{
style:
"color:#767676; font-weight: normal; margin: 0; padding: 0; line-height: 20px; font-size: 12px;font-family: Helvetica, Arial, sans-serif; "
}
%a
{
href:
"#"
,
style:
"color: #0eb6ce; text-decoration: none;"
}
#{
@note
.
author_name
}
commented on Wiki page:
%br
%table
{
border:
"0"
,
cellpadding:
"0"
,
cellspacing:
"0"
,
width:
"558"
}
%tr
%td
{
valign:
"top"
}
%div
{
style:
"background:#f5f5f5; padding:20px;border:1px solid #ddd"
}
=
markdown
(
@note
.
note
)
%td
{
style:
"font-size: 1px; line-height: 1px;"
,
width:
"21"
}
app/views/wikis/show.html.haml
View file @
a0aa0212
...
@@ -19,6 +19,3 @@
...
@@ -19,6 +19,3 @@
-
if
can?
current_user
,
:admin_wiki
,
@project
-
if
can?
current_user
,
:admin_wiki
,
@project
=
link_to
project_wiki_path
(
@project
,
@wiki
),
confirm:
"Are you sure you want to delete this page?"
,
method: :delete
do
=
link_to
project_wiki_path
(
@project
,
@wiki
),
confirm:
"Are you sure you want to delete this page?"
,
method: :delete
do
Delete this page
Delete this page
%hr
.wiki_notes
#notes
=
render
"notes/notes_with_form"
,
tid:
@wiki
.
id
,
tt:
"wiki"
features/project/wiki.feature
View file @
a0aa0212
...
@@ -7,9 +7,3 @@ Feature: Project Wiki
...
@@ -7,9 +7,3 @@ Feature: Project Wiki
Scenario
:
Add new page
Scenario
:
Add new page
Given
I create Wiki page
Given
I create Wiki page
Then
I should see newly created wiki page
Then
I should see newly created wiki page
@javascript
Scenario
:
I
comment wiki page
Given
I create Wiki page
And
I leave a comment like
"XML attached"
Then
I should see comment
"XML attached"
spec/requests/gitlab_flavored_markdown_spec.rb
View file @
a0aa0212
...
@@ -197,18 +197,6 @@ describe "Gitlab Flavored Markdown" do
...
@@ -197,18 +197,6 @@ describe "Gitlab Flavored Markdown" do
page
.
should
have_link
(
"#
#{
issue
.
id
}
"
)
page
.
should
have_link
(
"#
#{
issue
.
id
}
"
)
end
end
it
"should render in wikis#index"
,
js:
true
do
visit
project_wiki_path
(
project
,
:index
)
fill_in
"Title"
,
with:
'Test title'
fill_in
"Content"
,
with:
'[link test](test)'
click_on
"Save"
fill_in
"note_note"
,
with:
"see #
#{
issue
.
id
}
"
click_button
"Add Comment"
page
.
should
have_link
(
"#
#{
issue
.
id
}
"
)
end
end
end
...
...
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