主页国际化

This commit is contained in:
kaizheng 2013-08-10 16:09:07 +08:00
parent aafc00ec77
commit db1815ba1a
16 changed files with 68 additions and 37 deletions

View File

@ -67,7 +67,7 @@
<td colspan="2" valign="top" width="50" ><img src="/images/new/user.jpg" width="40" height="40"/></td>
<td><table width="580px" border="0">
<tr>
<td colspan="2" valign="top"><strong> <%= h(e.project) if @project.nil? || @project != e.project %></strong> <span class="font_lighter">有了最新动态</span> <%= link_to format_activity_title(e.event_title), e.event_url %></td>
<td colspan="2" valign="top"><strong> <%= h(e.project) if @project.nil? || @project != e.project %></strong> <span class="font_lighter"><%= l(:label_new_activity) %></span> <%= link_to format_activity_title(e.event_title), e.event_url %></td>
</tr>
<tr>
<td colspan="2" width="580px" ><p class="font_description"><%= format_activity_description(e.event_description) %></p></td>

View File

@ -44,7 +44,7 @@
</span>
</span>
<a href="javascript:void(0);" class="btn_addPic" style="text-decoration:none;">
<span>上传图片</span>
<span><%= l(:button_upload_photo) %></span>
</a>
<span class="add_avatar" style="width:20px;">
<%= file_field_tag 'avatar[image]',

View File

@ -1,7 +1,7 @@
<!-- fq -->
<%= render_flash_messages %>
<table width="1000px" border="0" style="padding-left: 15px">
<td class="font_lighter" style="font-size: 18px;">应标项目(<%= @bidding_project.count%>)</td>
<td class="font_lighter" style="font-size: 18px;"><%= l(:label_bidding_project) %>(<%= @bidding_project.count%>)</td>
<% if User.current.logged? %>
<td>
<div class='icon icon-add'>

View File

@ -1,4 +1,4 @@
$('#bidding_project_list').html('<%= escape_javascript(render(:partial => 'project_list', :locals => {:bidding_project => @bidding_project})) %>');
$("#project_id").val("请选择项目");
$("#bid_message").val("请输入应标理由");
$("#bid_message").val("#{l(:label_bid_reason)} ");
$("#put-bid-form").hide();

View File

@ -37,17 +37,17 @@
</style>
<script type="text/javascript" language="javascript">
function clearInfo(id) {
function clearInfo(id,content) {
var text = $('#' + id);
if (text.val() == "请输入应标理由") {
if (text.val() == content) {
$('#' + id).val('');
}
}
function showInfo(id) {
function showInfo(id,content) {
var text = $('#' + id);
if (text.val() == '') {
$('#' + id).val('请输入应标理由');
$('#' + id).val(content);
}
}
@ -68,8 +68,8 @@
</tr>
<tr>
<td><%= f.text_area :bid_message, :id => "bid_message", :required => true, :rows => 4, :cols => 40,
:onfocus => "clearInfo('bid_message')", :onblur => "showInfo('bid_message')",
:value => "请输入应标理由", :style => "resize: none;", :class => 'noline'%></td>
:onfocus => "clearInfo('bid_message','#{l(:label_bid_reason)}')", :onblur => "showInfo('bid_message','#{l(:label_bid_reason)}')",
:value => "#{l(:label_bid_reason)}", :style => "resize: none;", :class => 'noline'%></td>
</tr>
<tr>
<td align="right"><%= submit_tag l(:button_add), :name => nil , :class => "bid_btn", :onmouseout => "this.style.backgroundPosition = 'left top'", :onmouseover => "this.style.backgroundPosition = 'left -30px'"%>

View File

@ -1,11 +1,11 @@
<div id="praise">
<% if is_praise_or_tread(obj,user_id).size > 0 %>
<%= image_tag("/images/praise.png") %>
<%= link_to "取消贊",:controller=>"praise_tread",:action=>"praise_minus",:remote=>true,:obj => obj %>
<%= link_to "#{l(:label_cancel_praise)}",:controller=>"praise_tread",:action=>"praise_minus",:remote=>true,:obj => obj %>
(<%= get_praise_num(obj)%>)
<% else %>
<%= image_tag("/images/tread.png") %>
<%= link_to "",:controller=>"praise_tread",:action=>"praise_plus",:remote=>true,:obj => obj %>
<%= link_to "#{l(:label_praise)}",:controller=>"praise_tread",:action=>"praise_plus",:remote=>true,:obj => obj %>
(<%= get_praise_num(obj)%>)
<% end %>
</div>

View File

@ -27,7 +27,7 @@
<td colspan="2" valign="top" width="50" ><%= image_tag(url_to_avatar(e.event_author), :class => "avatar")%></td>
<td><table width="580px" border="0">
<tr>
<td colspan="2" valign="top"><strong> <%= h(e.project) if @project.nil? || @project != e.project %></strong> <span class="font_lighter"><%= link_to_user(e.event_author) if e.respond_to?(:event_author) %> 有了最新动态</span> <%= link_to format_activity_title(e.event_title), e.event_url %></td>
<td colspan="2" valign="top"><strong> <%= h(e.project) if @project.nil? || @project != e.project %></strong> <span class="font_lighter"><%= link_to_user(e.event_author) if e.respond_to?(:event_author) %> <%= l(:label_new_activity) %></span> <%= link_to format_activity_title(e.event_title), e.event_url %></td>
</tr>
<tr>
<td colspan="2" width="580px" ><p class="font_description"><%= format_activity_description(e.event_description) %></p></td>

View File

@ -9,10 +9,10 @@
<table width="580" border="0">
<tr>
<% if e.event_author == User.current%>
<td colspan="2" valign="top"><strong> <%= link_to("我", user_path(e.event_author)) %></strong><span class="font_lighter">有了最新动态</span> <%= link_to format_activity_title(e.event_title), e.event_url %></td>
<td colspan="2" valign="top"><strong> <%= link_to("我", user_path(e.event_author)) %></strong><span class="font_lighter"><%= l(:label_new_activity) %></span> <%= link_to format_activity_title(e.event_title), e.event_url %></td>
<% else %>
<td colspan="2" valign="top"><strong> <%= link_to(h(e.event_author), user_path(e.event_author)) %></strong><span class="font_lighter">有了最新动态</span> <%= link_to format_activity_title(e.event_title), e.event_url %></td>
<td colspan="2" valign="top"><strong> <%= link_to(h(e.event_author), user_path(e.event_author)) %></strong><span class="font_lighter"><%= l(:label_new_activity) %></span> <%= link_to format_activity_title(e.event_title), e.event_url %></td>
<% end %>
</tr>
<tr>

View File

@ -224,7 +224,7 @@
<td colspan="2" valign="top" width="50" ><img src="/images/new/news.png" width="40" height="40"/></td>
<td><table width="760" border="0">
<tr>
<td colspan="2" valign="top"><strong> <%= link_to_project(membership.project) %></strong> <a class="font_lighter">创建了</a> <%= link_to_project(membership.project) %></td>
<td colspan="2" valign="top"><strong> <%= link_to_project(membership.project) %></strong> <a class="font_lighter"><%= l(:label_create_project) %></a> <%= link_to_project(membership.project) %></td>
</tr>
<tr>
<td colspan="2" width="760" ><p class="font_description"><%= membership.project.description%></p></td>

View File

@ -27,7 +27,7 @@
<td colspan="2" valign="top" width="50" ><img src="/images/new/news.png" width="40" height="40"/></td>
<td><table width="580" border="0">
<tr>
<td colspan="2" valign="top"><strong> <%= content_tag('span', h(e.project), :class => 'project') %></strong> <span class="font_lighter">有了最新动态</span> <%= link_to format_activity_title(e.event_title), e.event_url %></td>
<td colspan="2" valign="top"><strong> <%= content_tag('span', h(e.project), :class => 'project') %></strong> <span class="font_lighter"><%= l(:label_new_activity) %></span> <%= link_to format_activity_title(e.event_title), e.event_url %></td>
</tr>
<tr>
<td colspan="2" width="580" ><p class="font_description"><%= format_activity_description(e.event_description) %></p></td>

View File

@ -11,7 +11,7 @@
<table width="580" border="0">
<tr>
<td colspan="2" valign="top"><strong> <%= link_to_user(membership.user) if membership.respond_to?(:user) %></strong>
<a class="font_lighter"> 创建了</a> <%= link_to_project(membership.project) %></td>
<a class="font_lighter"> <%= l(:label_create_project) %></a> <%= link_to_project(membership.project) %></td>
</tr>
<tr>
<td colspan="2" width="580" >

View File

@ -134,11 +134,11 @@
<td><img src="/images/welcome/3.png" width="200" height="200" /></td>
</tr>
<tr align="center">
<td><p class="font_welcome2">创建项目</p></td>
<td><p class="font_welcome2"><%= l(:label_create_new_projects) %></p></td>
<td>&nbsp;</td>
<td><p class="font_welcome2">发布需求</p></td>
<td><p class="font_welcome2"><%= l(:label_call_for_bids) %></p></td>
<td>&nbsp;</td>
<td><p class="font_welcome2">创建课程</p></td>
<td><p class="font_welcome2"><%= l(:label_create_course) %></p></td>
</tr>
<tr align="center" class="font_lighter" >
<td>添加描述添加描述添加描述添加描述...</td>
@ -152,17 +152,17 @@
<!--feature-->
<div class="font_welcome_feature">
<div align="center">特性
<div align="center"><%= l(:label_features) %>
<div class="user_underline3"></div></div>
</div>
<div style="padding-top: 30px">
<table width="700" border="0" align="center" >
<tr class="font_welcome" align="center" >
<td><img src="/images/welcome/discuss.png" width="30" height="26" /><span style="vertical-align: top">讨论区</span></td>
<td><img src="/images/welcome/discuss.png" width="30" height="26" /><span style="vertical-align: top"><%= l(:label_board) %></span></td>
<td width="50">&nbsp;</td>
<td><img src="/images/welcome/news.png" width="30" height="26" /><span style="vertical-align: top">新闻</span></td>
<td><img src="/images/welcome/news.png" width="30" height="26" /><span style="vertical-align: top"><%= l(:label_news) %></span></td>
<td width="50">&nbsp;</td>
<td><img src="/images/welcome/boards.png" width="30" height="26" /><span style="vertical-align: top">里程碑</span></td>
<td><img src="/images/welcome/boards.png" width="30" height="26" /><span style="vertical-align: top"><%= l(:label_milestone) %></span></td>
</tr>
<tr align="center" class="font_lighter">
<td>互信、分享互信、分享互信、分享互信、分享互信、分享互信、分享互信、分享互信、分享...</td>

View File

@ -10,9 +10,9 @@
<tr>
<td colspan="2" valign="top"><strong> <%=link_to journal.user, user_path(journal.user)%></strong>
<% if @user == User.current%>
<a class="font_lighter">给我留言了</a>
<a class="font_lighter"><%= l(:label_leave_me_message) %></a>
<% else %>
<a class="font_lighter">给他留言了</a>
<a class="font_lighter"><%= l(:label_leave_others_message) %></a>
<% end %>
</td>
</tr>

View File

@ -37,9 +37,9 @@
</style>
<script type="text/javascript" language="javascript">
function clearInfo(id) {
function clearInfo(id, content) {
var text = $('#' + id);
if (text.val() == "给他留言") {
if (text.val() == content) {
$('#' + id).val('');
}
}
@ -47,7 +47,7 @@
function showInfo(id) {
var text = $('#' + id);
if (text.val() == '') {
$('#' + id).val('给他留言');
$('#' + id).val(content);
}
}
</script>
@ -60,7 +60,7 @@
<% if User.current.logged? %>
<table border="0" width="525px" align="center" >
<tr>
<td><%= f.text_area 'user_message', :rows => 3, :cols => 65, :value => "给他留言", :onfocus => "clearInfo('new_form_user_message')", :onblur => "showInfo('new_form_user_message')", :style => "resize: none;", :class => 'noline'%></td>
<td><%= f.text_area 'user_message', :rows => 3, :cols => 65, :value => "#{l(:label_leave_a_message)}", :onfocus => "clearInfo('new_form_user_message','#{l(:label_leave_a_message)}')", :onblur => "showInfo('new_form_user_message','#{l(:label_leave_a_message)}')", :style => "resize: none;", :class => 'noline'%></td>
</tr>
</table>
<%= f.text_field :reference_user_id, :style=>"display:none"%>

View File

@ -1114,7 +1114,7 @@ en:
label_user_watchered: "Followed" # huang添加的
label_user_newfeedback: "Leave a message" ## huang添加的
label_user_login: "Lastest login:"
label_user_mail: "Mail address:"
label_user_mail: "E-mail:"
label_user_joinin: "Join date:"
label_user_activities: "You have no activities,come and join us!"
label_project_overview: "Overview"
@ -1147,7 +1147,7 @@ en:
label_user_information: "My information"
#Customer addedAdded by nie
label_create_time: Creat time
label_create_time: Created time
label_current_contributors: current contributors
label_lines_of_code: lines of code
label_since_last_commits: since last commit
@ -1165,10 +1165,10 @@ en:
label_member_list: Member list
label_author_name: Posted by %{author_name}
label_comments_count: (%{count} numbers of comments)
label_post_on: Post on
label_post_on: post on
label_find_all_comments: view all comments
label_updated_time_on: " Updated on %{value} "
label_bid_plural: Requirement
label_bid_plural: Requirement list
label_requirement_list: Requirement list
label_competitive_bidding: biddings
@ -1185,4 +1185,20 @@ en:
label_requirement_description: descriptionshow you requirement>find Witkey to help you>pay the bargain money>check,pay and give comments
label_requirement_bargain_money: pay the bargain money
label_wrong_budget: The error format of money
label_wrong_date: wrong date format, input right date yyyy-mm-dd
label_wrong_date: wrong date format, input right date yyyy-mm-dd
button_upload_photo: Upload photo
label_leave_me_message: leave message to me
label_leave_others_message: leave message to him/her
label_leave_a_message: Leave him/her a message
label_new_activity: has new activity
label_create_project: has created
label_praise: praise
label_cancel_praise: cancel praise
label_bid_reason: Please show your reason
default_tracker_task: Task
label_create_new_projects: Create projects
label_call_for_bids: Call for bids
label_create_course: Create courses
label_news: News
label_milestone: Milestone
label_features: Features

View File

@ -1195,4 +1195,19 @@ zh:
label_deadline: 投资时限yyyy-mm-dd
label_requirement_name: 为你的需求起个名字~~
label_requirement_description: 内容:说出你的需求>找到威客来帮你>支付担保金让威客开始工作>验收付款并评价
label_requirement_bargain_money: 支付担保金额
label_requirement_bargain_money: 支付担保金额
button_upload_photo: 上传图片
label_leave_me_message: 给我留言了
label_leave_others_message: 给他留言了
label_leave_a_message: 给他(她)留言
label_new_activity: 有了最新动态
label_create_project: 创建了
label_praise:
label_cancel_praise: 取消赞
label_bid_reason: 请输入应标理由
label_create_new_projects: 创建项目
label_call_for_bids: 发布需求
label_create_course: 创建课程
label_news: 新闻
label_milestone: 里程碑
label_features: 特性