socialforge/app/views/welcome/index.html.erb

540 lines
19 KiB
Plaintext
Raw Normal View History

<!--add by huang-->
<div style="height:280px; padding-top: 10px">
2013-08-12 10:25:23 +08:00
<div class="welcone_left">
2013-08-27 22:19:07 +08:00
<table width="388px">
2013-11-27 10:31:12 +08:00
<tr><td><span class="font_welcome_trustie"><%= l(:label_welcome_trustie) %> </span><span class="font_welcome_tdescription">, <%= l(:label_welcome_trustie_description) %></span></td></tr>
2013-08-12 10:25:23 +08:00
</table>
</div>
<table>
<tr>
2013-08-12 10:25:23 +08:00
<td> <%= call_hook :view_account_login_top %>
<div id="login-form_new">
<%= form_tag(signin_path) do %>
2013-11-21 17:11:55 +08:00
<%= back_url_hidden_field_tag if is_logout? %>
<% unless User.current.logged? %> <!--modified by young-->
<table>
<tr>
<td align="right"><label for="username"><%= l(:label_username) %></label></td>
<td align="left"><%= text_field_tag 'username', params[:username], :tabindex => '1' %></td>
</tr>
<tr>
<td align="right"><label for="password"><%= l(:label_password) %></label></td>
<td align="left"><%= password_field_tag 'password', nil, :tabindex => '2' %></td>
</tr>
<% if Setting.openid? %>
<tr>
<td align="right"><label for="openid_url"><%= l(:field_identity_url)%></label></td>
<td align="left"><%= text_field_tag "openid_url", nil, :tabindex => '3' %></td>
</tr>
<% end %>
<tr>
<td></td>
<td align="left">
<% if Setting.autologin? %> <label for="autologin"><%= check_box_tag 'autologin', 1, false, :tabindex => 4 %> <%= l(:label_stay_logged_in) %></label>
<% end %>
</td>
</tr>
<tr>
<td align="left">
<% if Setting.lost_password? %>
<%= link_to l(:label_password_lost), lost_password_path %>
<% end %>
</td>
<td align="right">
<input type="submit" name="login" value="<%= l(:button_login)%> &#187;" tabindex="5"/>
</td>
</tr>
</table>
<% else %>
<div>
2013-11-27 10:31:12 +08:00
<!--info: modified by huang-->
2013-11-21 17:11:55 +08:00
<table width="200" border="0">
<tr>
<td colspan="2" align="center" class="font_welcome_Cdescription" ><%= l(:label_welcome) %> <strong class="font_small_watch" style=" word-wrap: break-word; word-break: break-all"><%=link_to User.current.lastname<<User.current.firstname, user_path(User.current) %></strong> <%= l(:label_join) %></td>
</tr>
<tr>
2013-11-27 10:31:12 +08:00
<td rowspan="2" style="padding-left: 35px"><%= image_tag(url_to_avatar(User.current), :class => 'avatar') %></td>
2013-11-21 17:11:55 +08:00
<td><strong class="font_small_watch"><%= link_to l(:label_user_watcher)+"("+User.watched_by(User.current).count.to_s+")", user_path(User.current) %></strong>&nbsp
<strong class="font_small_watch"><%=link_to l(:label_x_user_fans, :count => User.current.watcher_users(User.current.id).count)+"("+User.current.watcher_users(User.current.id).count.to_s+")", user_path(User.current) %></strong></td>
</tr>
<tr>
<td align="left"><% unless User.current.memberships.empty? %>
<%= l(:label_x_welcome_participate, :count => User.current.memberships.count) %> <strong class="font_small_watch"><%= link_to User.current.memberships.count, {:controller => 'users', :action => 'user_projects', :id => User.current} %></strong> <%= l(:label_welcome_participate_project)%>
<% end %>
</td>
</tr>
</table>
</div>
2013-08-12 10:25:23 +08:00
<% end %>
<% end %>
2013-11-21 17:11:55 +08:00
</div>
<%= call_hook :view_account_login_bottom %>
2013-08-12 10:25:23 +08:00
<% if params[:username].present? %>
<%= javascript_tag "$('#password').focus();" %>
<% else %>
<%= javascript_tag "$('#username').focus();" %>
<% end %> </td>
</tr>
</table>
2013-08-04 10:56:56 +08:00
</div>
2013-08-12 10:25:23 +08:00
<!--model-->
<!-- fq -->
<script type="text/javascript" language="javascript">
function clearInfo(id, content) {
var text = $('#' + id);
if (text.val() == content) {
$('#' + id).val('');
}
}
function showInfo(id, content) {
var text = $('#' + id);
if (text.val() == '') {
$('#' + id).val(content);
}
}
</script>
2013-11-22 14:34:05 +08:00
<!-- info display block -->
2013-11-21 17:11:55 +08:00
<%= stylesheet_link_tag 'welcome' %>
<div class="body_resize">
2013-11-27 15:37:43 +08:00
<!-- <div class="right">
2013-11-22 08:19:40 +08:00
<div class="home"><%= l :label_hot_project%></div>
<% find_all_hot_project.map do |project| break if(project == find_all_hot_project[5]) %>
<div class="project">
2013-11-22 14:34:05 +08:00
<%=link_to( project.name, project_path(project.project_id), :class => "nowrap" )%>
2013-11-22 08:19:40 +08:00
<p><%= project.description %></p>
</div>
<% end %>
</div>
2013-11-21 17:11:55 +08:00
</div>
2013-11-27 15:37:43 +08:00
2013-11-21 17:11:55 +08:00
<div class="left">
2013-11-27 15:37:43 +08:00
<div class="home" ><%= l :label_newbie_faq %></div>
2013-11-22 08:19:40 +08:00
<% newbieTopicStickyList.each do |topic| break if(topic == newbieTopicStickyList[6])%>
<div class="project">
<%=link_to( topic.subject, board_message_path(find_board_by_topic(topic),topic), :class => "nowrap" )%>
<span class="grey"><strong><em>[ <%=find_project_by_topic(topic) %> ]</em></strong></span>
</div>
2013-11-27 15:37:43 +08:00
<% end %>
</div> -->
<div class="left" style="float: left; height: 445px;">
<ul class="welcome-message-list" style="width: 90%;">
<h3 style="">论坛热帖</h3>
<div class="welcome-box-list">
<li class="message-brief-intro">
<span style="color:gray">新建DIV测试项目对于本项目的作用</span> <span style="margin-left: 10px; color: green">yanpc</span><span style="margin-left:10px; color:blue">1分钟前</span>
</li>
<li class="message-brief-intro">
<span style="color:gray">热烈祝贺论坛新版本上线欢迎大家提交bug</span><span style="margin-left: 10px; color: green">yanpc</span><span style="margin-left:10px; color:blue">5分钟前</span>
</li>
<li class="message-brief-intro">
<span style="color:gray">论坛全新改版增加许多功能啦欢迎大家提交bug</span><span style="margin-left: 10px; color: green">yanpc</span><span style="margin-left:10px; color:blue">半小时前</span>
</li>
<li class="message-brief-intro">
<span style="color:gray">网站主页改版,欢迎大家提交意见和建议</span><span style="margin-left: 10px; color: green">yanpc</span><span style="margin-left:10px; color:blue">2013-11-12</span>
</li>
<li class="message-brief-intro">
<span style="color:gray">网站持续更新中,以期给大家带来更好的用户体验</span><span style="margin-left: 10px; color: green">yanpc</span><span style="margin-left:10px; color:blue">2013-11-9</span>
</li>
<li class="message-brief-intro">
<span style="color:gray">网站上线第一次发帖,欢迎大家来盖楼</span><span style="margin-left: 10px; color: green">yanpc</span><span style="margin-left:10px; color:blue">2013-11-9</span>
</li>
</div>
</ul>
</div>
<div class="right" style="float: right; margin-right: -80px; height: 445px;">
<ul class="user-welcome-message-list" style="width: 80%; margin-top: 80px;">
<h3 style="margin-left: -5px;">用户动态</h3>
<div class="user-message-box-list">
<li style="display: block;height:60px;">
<div class="inner-right" style="float: left; height: 100%;">
<img class="avatar-3" style="width: 40px; height: 40px; margin-top:10px;" src="/images/avatars/User/4861?1385345302"></img>
</div>
<div class="inner-right" style="float: right; width:88%; height: 100%;">
<span style="color: green;">yanpc</span>&nbsp;发表了评论:<span style="color: blue;">热烈庆祝OW2圆满结束让我们一起期待下一届的OW2比赛吧</span>
<p><span>1分钟前</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span>评论(4)</span></p>
</div>
</li>
<li style="display: block;height:60px;">
<div class="inner-right" style="float: left; height: 100%;">
<img class="avatar-3" style="width: 40px; height: 40px; margin-top:10px;" src="/images/avatars/User/4861?1385345302"></img>
</div>
<div class="inner-right" style="float: right; width:88%; height: 100%;">
<span style="color: green;">yanpc</span>&nbsp;发表了评论:<span style="color: blue;">热烈庆祝OW2圆满结束让我们一起期待下一届的OW2比赛吧</span>
<p><span>1分钟前</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span>评论(4)</span></p>
</div>
</li>
<li style="display: block;height:60px;">
<div class="inner-right" style="float: left; height: 100%;">
<img class="avatar-3" style="width: 40px; height: 40px; margin-top:10px;" src="/images/avatars/User/4861?1385345302"></img>
</div>
<div class="inner-right" style="float: right; width:88%; height: 100%;">
<span style="color: green;">yanpc</span>&nbsp;发表了评论:<span style="color: blue;">热烈庆祝OW2圆满结束让我们一起期待下一届的OW2比赛吧</span>
<p><span>1分钟前</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span>评论(4)</span></p>
</div>
</li>
<li style="display: block;height:60px;">
<div class="inner-right" style="float: left; height: 100%;">
<img class="avatar-3" style="width: 40px; height: 40px; margin-top:10px;" src="/images/avatars/User/4861?1385345302"></img>
</div>
<div class="inner-right" style="float: right; width:88%; height: 100%;">
<span style="color: green;">yanpc</span>&nbsp;发表了评论:<span style="color: blue;">热烈庆祝OW2圆满结束让我们一起期待下一届的OW2比赛吧</span>
<p><span>1分钟前</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span>评论(4)</span></p>
</div>
</li>
<li style="display: block;height:60px;">
<div class="inner-right" style="float: left; height: 100%;">
<img class="avatar-3" style="width: 40px; height: 40px; margin-top:10px;" src="/images/avatars/User/4861?1385345302"></img>
</div>
<div class="inner-right" style="float: right; width:88%; height: 100%;">
<span style="color: green;">yanpc</span>&nbsp;发表了评论:<span style="color: blue;">热烈庆祝OW2圆满结束让我们一起期待下一届的OW2比赛吧</span>
<p><span>1分钟前</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span>评论(4)</span></p>
</div>
</li>
</div>
</ul>
</div>
<div id="J_Slide" class="d-p-index-box d-p-index-hotproject">
<h2>热门项目</h2>
<!-- <ul class="d-p-index-hdright d-p-project-bytime ks-switchable-nav">
<li class="current">
<a class="" href="javascript:void(0);">今日</a>
</li>
<li>
<a class="" href="javascript:void(0);">本周</a>
</li>
<li>
<a class="" href="javascript:void(0);">本月</a>
</li>
</ul> -->
<div class="d-p-projectlist-box">
<ul class="d-p-projectlist">
<li style="background-image:none;">
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/tfs/" title="tfs">DIV布局测试</a>
</p>
<p class="layout-1" >
<span class="d-p-project-intro">给大家一个版本库路径为trustie2@10.0.47.245:/home/trustie2密码是http://10.0.47.245/trustie21234</span>
</p>
<!-- <span>更新于</span><span style="color: blue">5天前</span> -->
</li>
<li>
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/javatwx/" title="javatwx">javatwx</a>
</p>
<p class="layout-1">
<span class="d-p-project-intro">javamall</span>
</p>
</li>
<li>
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/sz_digital_ocean/" title="sz_digital_ocean">sz_digital_ocean</a>
</p>
<p class="layout-1">
<span class="d-p-project-intro">sz_digital_ocean</span>
</p>
</li>
<li>
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/android_1/" title="android_1">android_1</a>
</p>
<p class="layout-1">
<span class="d-p-project-intro">android study</span>
</p>
</li>
<li>
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/tair/" title="tair">tair</a>
</p>
<p class="layout-1">
<span class="d-p-project-intro">Tair is a distributed, high performance key/value storage sy...</span>
</p>
</li>
</ul>
</div>
</div>
<div id="J_Slide" class="d-p-index-box d-p-index-hotproject" style="float: right;">
<h2>热门竞赛</h2>
<!-- <ul class="d-p-index-hdright d-p-project-bytime ks-switchable-nav">
<li class="current">
<a class="" href="javascript:void(0);">今日</a>
</li>
<li>
<a class="" href="javascript:void(0);">本周</a>
</li>
<li>
<a class="" href="javascript:void(0);">本月</a>
</li>
</ul> -->
<div class="d-p-projectlist-box">
<ul class="d-p-projectlist">
<li style="background-image:none;" >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/tfs/" title="tfs">tfs</a>
</p>
<p class="layout">
<span class="d-p-project-intro">TFSTaobao FileSystem是一个高可扩展、高可用、高性能、面向互联网服务的分布式文件系统其设计目标是...</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/javatwx/" title="javatwx">javatwx</a>
</p>
<p class="layout">
<span class="d-p-project-intro">javamall</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/sz_digital_ocean/" title="sz_digital_ocean">sz_digital_ocean</a>
</p>
<p class="layout">
<span class="d-p-project-intro">sz_digital_ocean</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/android_1/" title="android_1">android_1</a>
</p>
<p class="layout">
<span class="d-p-project-intro">android study</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/tair/" title="tair">tair</a>
</p>
<p class="layout">
<span class="d-p-project-intro">Tair is a distributed, high performance key/value storage sy...</span>
</p>
</li>
</ul>
</div>
</div>
<div id="J_Slide" class="d-p-index-box d-p-index-hotproject" >
<h2>最新众包</h2>
<!-- <ul class="d-p-index-hdright d-p-project-bytime ks-switchable-nav">
<li class="current">
<a class="" href="javascript:void(0);">今日</a>
</li>
<li>
<a class="" href="javascript:void(0);">本周</a>
</li>
<li>
<a class="" href="javascript:void(0);">本月</a>
</li>
</ul> -->
<div class="d-p-projectlist-box">
<ul class="d-p-projectlist">
<li style="background-image:none;" >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/tfs/" title="tfs">tfs</a>
</p>
<p class="layout">
<span class="d-p-project-intro">TFSTaobao FileSystem是一个高可扩展、高可用、高性能、面向互联网服务的分布式文件系统其设计目标是...</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/javatwx/" title="javatwx">javatwx</a>
</p>
<p class="layout">
<span class="d-p-project-intro">javamall</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/sz_digital_ocean/" title="sz_digital_ocean">sz_digital_ocean</a>
</p>
<p class="layout">
<span class="d-p-project-intro">sz_digital_ocean</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/android_1/" title="android_1">android_1</a>
</p>
<p class="layout">
<span class="d-p-project-intro">android study</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/tair/" title="tair">tair</a>
</p>
<p class="layout">
<span class="d-p-project-intro">Tair is a distributed, high performance key/value storage sy...</span>
</p>
</li>
</ul>
</div>
</div>
<div id="J_Slide" class="d-p-index-box d-p-index-hotproject" style="float: right;">
<h2>热门课程</h2>
<!-- <ul class="d-p-index-hdright d-p-project-bytime ks-switchable-nav">
<li class="current">
<a class="" href="javascript:void(0);">今日</a>
</li>
<li>
<a class="" href="javascript:void(0);">本周</a>
</li>
<li>
<a class="" href="javascript:void(0);">本月</a>
</li>
</ul> -->
<div class="d-p-projectlist-box">
<ul class="d-p-projectlist">
<li style="background-image:none;" >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/tfs/" title="tfs">tfs</a>
</p>
<p class="layout">
<span class="d-p-project-intro">TFSTaobao FileSystem是一个高可扩展、高可用、高性能、面向互联网服务的分布式文件系统其设计目标是...</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/javatwx/" title="javatwx">javatwx</a>
</p>
<p class="layout">
<span class="d-p-project-intro">javamall</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/sz_digital_ocean/" title="sz_digital_ocean">sz_digital_ocean</a>
</p>
<p class="layout">
<span class="d-p-project-intro">sz_digital_ocean</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/android_1/" title="android_1">android_1</a>
</p>
<p class="layout">
<span class="d-p-project-intro">android study</span>
</p>
</li>
<li >
<p class="layout">
<a target="_blank" class="d-g-blue d-p-project-name" href="/p/tair/" title="tair">tair</a>
</p>
<p class="layout">
<span class="d-p-project-intro">Tair is a distributed, high performance key/value storage sy...</span>
</p>
</li>
</ul>
</div>
</div>
2013-11-21 17:11:55 +08:00
<div class="clr"></div>
</div>
2013-11-27 15:37:43 +08:00
2013-11-21 17:11:55 +08:00
<br/><br/><br/><br/><br/><br/><br/>
2013-11-27 15:37:43 +08:00
<!-- <div>
2013-08-22 23:39:21 +08:00
<table width="700" border="0" align="center" style="padding-top: 0px">
2013-11-21 17:11:55 +08:00
<tr>
<td colspan="5" align="center" style="padding-bottom: 10px; font-size: 18px; font-color: #5c5c5c ; font-family: 微软雅黑"><%= l(:label_welcome_leave_message) %> <strong><%= toggle_link l(:label_welcome_click_me), 'put-bid-form', {:focus => 'new_form_project_message'} %></strong>
</td>
2013-09-29 19:46:59 +08:00
</tr>
2013-11-21 17:11:55 +08:00
<tr><td colspan="5" align="center" ><div class="homepage_underline"></div></td></tr>
<tr>
<td colspan="5" align="center">
<div id="put-bid-form" style="display: none">
<%= form_for('new_form', :method => :post, :url => {:controller => 'words', :action => 'add_project_respond'}) do |f|%>
<table border="0" width="525px" align="center" >
<tr>
<td>
<%= f.text_area 'project_message',
:rows => 3,
:cols => 65,
:value => "#{l(:label_welcome_my_respond)}",
:onfocus => "clearInfo('new_form_project_message','#{l(:label_welcome_my_respond)}')",
:onblur => "showInfo('new_form_project_message','#{l(:label_welcome_my_respond)}')",
:style => "resize: none;",
:class => 'noline'%>
</td>
</tr>
</table>
<table border="0" width="525px" align="center">
<tr>
<td align="right"> <%= submit_tag l(:button_submit), :name => nil , :class => "bid_btn" %></td>
</tr>
</table>
<% end %>
</div>
</td>
2013-08-12 10:25:23 +08:00
</tr>
2013-11-21 17:11:55 +08:00
</table>
2013-11-27 15:37:43 +08:00
</div> -->
2013-08-09 11:14:53 +08:00