Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
李少辉-开发者
gitlab-foss
提交
8786aff2
G
gitlab-foss
项目概览
李少辉-开发者
/
gitlab-foss
通知
15
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
gitlab-foss
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
8786aff2
编写于
11月 12, 2011
作者:
D
Dmitriy Zaporozhets
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
project avtivity page
上级
4dd5d9c8
变更
6
显示空白变更内容
内联
并排
Showing
6 changed file
with
45 addition
and
67 deletion
+45
-67
app/assets/stylesheets/projects.css.scss
app/assets/stylesheets/projects.css.scss
+21
-1
app/views/projects/_feed.html.haml
app/views/projects/_feed.html.haml
+15
-0
app/views/projects/_recent_commits.html.haml
app/views/projects/_recent_commits.html.haml
+0
-34
app/views/projects/_recent_messages.html.haml
app/views/projects/_recent_messages.html.haml
+0
-27
app/views/projects/show.html.haml
app/views/projects/show.html.haml
+8
-4
spec/requests/projects_spec.rb
spec/requests/projects_spec.rb
+1
-1
未找到文件。
app/assets/stylesheets/projects.css.scss
浏览文件 @
8786aff2
...
...
@@ -344,12 +344,32 @@ body.project-page table .commit {
background
:
#2c5c66
;
color
:white
;
}
&
.note
{
background
:
#2c5c66
;
color
:white
;
}
&
.issue
{
background
:
#D12F19
;
color
:white
;
}
&
.commit
{
background
:
#
2c5c66
;
background
:
#
44aacc
;
color
:white
;
}
}
/* Project Dashboard Page */
html
,
body
{
height
:
100%
;
}
body
.dashboard.project-page
.news-feed
h2
{
float
:
left
;}
body
.dashboard.project-page
.news-feed
.project-updates
{
margin-bottom
:
20px
;
display
:
block
;
width
:
100%
;}
body
.dashboard.project-page
.news-feed
.project-updates
.data
{
padding
:
0
}
body
.dashboard.project-page
.news-feed
.project-updates
a
.project-update
{
padding
:
10px
;
border-bottom
:
1px
solid
#eee
;
overflow
:
hidden
;
display
:
block
;}
body
.dashboard.project-page
.news-feed
.project-updates
a
.project-update
:last-child
{
border-bottom
:
0
}
body
.dashboard.project-page
.news-feed
.project-updates
a
.project-update
img
{
float
:
left
;
margin-right
:
10px
;}
body
.dashboard.project-page
.news-feed
.project-updates
a
.project-update
span
.update-title
,
.dashboard-page
.news-feed
.project-updates
li
a
span
.update-author
{
display
:
block
;}
body
.dashboard.project-page
.news-feed
.project-updates
a
.project-update
span
.update-title
{
margin-bottom
:
10px
}
body
.dashboard.project-page
.news-feed
.project-updates
a
.project-update
span
.update-author
{
color
:
#999
;
font-weight
:
normal
;
font-style
:
italic
;}
body
.dashboard.project-page
.news-feed
.project-updates
a
.project-update
span
.update-author
strong
{
font-weight
:
bold
;
font-style
:
normal
;}
/* eo Dashboard Page */
app/views/projects/_feed.html.haml
0 → 100644
浏览文件 @
8786aff2
%a
.project-update
{
:href
=>
dashboard_feed_path
(
project
,
update
)}
=
image_tag
gravatar_icon
(
update
.
author_email
),
:class
=>
"left"
,
:width
=>
40
%span
.update-title
=
dashboard_feed_title
(
update
)
%span
.update-author
%strong
=
update
.
author_name
authored
=
time_ago_in_words
(
update
.
created_at
)
ago
.right
-
klass
=
update
.
class
.
to_s
.
split
(
"::"
).
last
.
downcase
%span
.tag
{
:class
=>
klass
}=
klass
-
if
update
.
kind_of?
(
Grit
::
Commit
)
%span
.tag.commit
=
update
.
head
.
name
app/views/projects/_recent_commits.html.haml
已删除
100644 → 0
浏览文件 @
4dd5d9c8
%table
%thead
%th
Commits
.filter.right
=
form_tag
project_path
(
@project
),
:method
=>
:get
,
:class
=>
"right"
do
.left
=
radio_button_tag
:view
,
"recent"
,
(
params
[
:view
]
||
"recent"
)
==
"recent"
,
:onclick
=>
"this.form.submit()"
,
:id
=>
"recent_view"
=
label_tag
"recent_view"
,
"Recent"
.left
=
radio_button_tag
:view
,
"day"
,
params
[
:view
]
==
"day"
,
:onclick
=>
"this.form.submit()"
,
:id
=>
"day_view"
=
label_tag
"day_view"
,
"Today"
.left
=
radio_button_tag
:view
,
"week"
,
params
[
:view
]
==
"week"
,
:onclick
=>
"this.form.submit()"
,
:id
=>
"week_view"
=
label_tag
"week_view"
,
"Week"
-
@commits
.
each
do
|
commit
|
%tr
%td
%div
.commit
-
if
commit
.
author
.
email
=
image_tag
gravatar_icon
(
commit
.
author
.
email
),
:class
=>
"left"
,
:width
=>
40
,
:style
=>
"padding-right:5px;"
-
else
=
image_tag
"no_avatar.png"
,
:class
=>
"left"
,
:width
=>
40
,
:style
=>
"padding-right:5px;"
.title
%p
%span
.tag.commit
=
commit
.
head
.
name
=
link_to
truncate
(
commit
.
safe_message
,
:length
=>
40
),
project_commit_path
(
@project
,
:id
=>
commit
.
id
)
%span
%span
.author
%strong
=
commit
.
author
.
name
.
force_encoding
(
"UTF-8"
)
%cite
.cgray
=
time_ago_in_words
(
commit
.
committed_date
)
ago
app/views/projects/_recent_messages.html.haml
已删除
100644 → 0
浏览文件 @
4dd5d9c8
-
@messages
.
group_by
{
|
x
|
[
x
.
noteable_id
,
x
.
noteable_type
]}.
each
do
|
item
,
notes
|
-
id
,
type
=
item
[
0
],
item
[
1
]
-
parent
=
load_note_parent
(
id
,
type
,
@project
)
-
next
unless
parent
%table
%thead
%th
%div
{
:class
=>
"recent_message_parent"
}
=
link_to
(
truncate
(
dashboard_feed_title
(
parent
),
:length
=>
40
),
dashboard_feed_path
(
@project
,
parent
))
-
notes
.
sort
{
|
x
,
y
|
y
.
updated_at
<=>
x
.
updated_at
}.
each
do
|
note
|
%tr
%td
%div
.message
=
image_tag
gravatar_icon
(
note
.
author_email
),
:class
=>
"left"
,
:width
=>
40
,
:style
=>
"padding-right:5px;"
%div
.title
=
link_to
markdown
(
truncate
(
note
.
note
,
:length
=>
40
)),
dashboard_feed_path
(
@project
,
parent
)
+
"#note_
#{
note
.
id
}
"
-
if
note
.
attachment
.
url
%br
Attachment:
=
link_to
note
.
attachment_identifier
,
note
.
attachment
.
url
%div
.author
%strong
=
note
.
author_name
%cite
.cgray
=
time_ago_in_words
(
note
.
updated_at
)
ago
%br
app/views/projects/show.html.haml
浏览文件 @
8786aff2
.left.width-49p
=
render
"projects/recent_commits"
-
content_for
(
:body_class
,
"project-page dashboard"
)
.right.width-49p
=
render
"projects/recent_messages"
#news-feed
.news-feed
%h2
.icon
%span
>
Activities
.project-box.project-updates.ui-box.ui-box-small.ui-box-big
-
@project
.
updates
(
20
).
each
do
|
update
|
=
render
"projects/feed"
,
:update
=>
update
,
:project
=>
@project
:javascript
function
updateDashboard
(){
...
...
spec/requests/projects_spec.rb
浏览文件 @
8786aff2
...
...
@@ -73,7 +73,7 @@ describe "Projects" do
end
it
"should beahave like activities page"
do
within
".
commit
"
do
within
".
project-update
"
do
page
.
should
have_content
(
"master"
)
page
.
should
have_content
(
@project
.
commit
.
author
.
name
)
page
.
should
have_content
(
@project
.
commit
.
safe_message
)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录