diff --git a/app/helpers/issues_helper.rb b/app/helpers/issues_helper.rb
index 5a124849f..489854ead 100644
--- a/app/helpers/issues_helper.rb
+++ b/app/helpers/issues_helper.rb
@@ -57,6 +57,15 @@ module IssuesHelper
"#{@cached_label_priority}: #{h(issue.priority.name)}".html_safe
end
+ def states_done_ratio(issue)
+ done_ratio = issue.done_ratio
+ if done_ratio == 100
+ "#{l(:label_done_ratio_endding)}".html_safe
+ else
+ "#{l(:label_done_ratio_doing)}".html_safe
+ end
+ end
+
def issue_heading(issue)
#h("#{issue.tracker} ##{issue.id}")
# h("#{issue.tracker} #{issue.source_from}")
diff --git a/app/views/common/_calendar.html.erb b/app/views/common/_calendar.html.erb
index e4ce4da2c..b2aad3812 100644
--- a/app/views/common/_calendar.html.erb
+++ b/app/views/common/_calendar.html.erb
@@ -1,4 +1,4 @@
-
+
|
@@ -20,6 +20,7 @@
<%= h("#{i.project} -") unless @project && @project == i.project %>
<%= link_to_issue i, :truncate => 30 %>
+ (<%= states_done_ratio i %>)
<%= render_issue_tooltip i %>
<% else %>
diff --git a/config/locales/projects/zh.yml b/config/locales/projects/zh.yml
index 792ff35fd..de3a83e19 100644
--- a/config/locales/projects/zh.yml
+++ b/config/locales/projects/zh.yml
@@ -462,3 +462,6 @@ zh:
label_state_open: 待处理
label_state_closed: 关闭
label_state_merged: 已合并
+
+ label_done_ratio_endding: 已完成
+ label_done_ratio_doing: 未完成
diff --git a/public/stylesheets/css/calendar.css b/public/stylesheets/css/calendar.css
index e69de29bb..11cd99637 100644
--- a/public/stylesheets/css/calendar.css
+++ b/public/stylesheets/css/calendar.css
@@ -0,0 +1,53 @@
+/***** Calendar *****/
+table#calender td{padding: 2px;}
+table.cal {border-collapse: collapse; width: 100%; margin: 0px 0 6px 0;border: 1px solid #d7d7d7;}
+table.cal thead th {width: 14%; background-color:#EEEEEE; padding: 4px; }
+table.cal thead th.week-number {width: auto;}
+table.cal tbody tr {height: 100px;}
+table.cal td {border: 1px solid #d7d7d7; vertical-align: top; font-size: 0.9em;}
+table.cal td.week-number { background-color:#EEEEEE; padding: 4px; border:none; font-size: 1em;}
+table.cal td p.day-num {font-size: 1.1em; text-align:right;}
+table.cal td.odd p.day-num {color: #bbb;}
+table.cal td.today {background:#ffffdd;}
+table.cal td.today p.day-num {font-weight: bold;}
+table.cal .starting a, p.cal.legend .starting {background: url(/images/bullet_go.png) no-repeat -1px -2px; padding-left:16px;}
+table.cal .ending a, p.cal.legend .ending {background: url(/images/bullet_end.png) no-repeat -1px -2px; padding-left:16px;}
+table.cal .starting.ending a, p.cal.legend .starting.ending {background: url(/images/bullet_diamond.png) no-repeat -1px -2px; padding-left:16px;}
+p.cal.legend span {display:block;}
+
+/***** Tooltips ******/
+.tooltip{position:relative;z-index:24;}
+.tooltip:hover{z-index:25;color:#000;}
+.tooltip span.tip{display: none; text-align:left;}
+
+div.tooltip:hover span.tip{
+ display:block;
+ position:absolute;
+ top:12px; left:24px; width:270px;
+ border:1px solid #555;
+ background-color:#fff;
+ padding: 4px;
+ font-size: 0.8em;
+ color:#505050;
+}
+
+img.ui-datepicker-trigger {
+ display: block;
+ background: url(/images/public_icon.png) -31px 0 no-repeat;
+ cursor: pointer;
+ vertical-align: middle;
+ margin-left: 5px;
+ margin-top: 5px;
+ width: 16px;
+ height: 15px;
+ float: left;
+}
+
+div.issue {background:#FFFFEC; padding:6px; margin-bottom:6px;border: 1px solid #d7d7d7;}
+.tooltip{position:relative;z-index:24;}
+.tooltip:hover{z-index:25;color:#000;}
+.tooltip span.tip{display: none; text-align:left;}
+.task.parent.marker.starting { position: absolute; background: url(/images/task_parent_end.png) no-repeat 0 0; width: 8px; height: 16px; margin-left: -4px; left: 0px; top: -1px;}
+
+/*.icon*/
+.icon-package { background-image: url(/images/package.png); }
\ No newline at end of file