修改了用户个人主页样式
This commit is contained in:
parent
29f058efba
commit
8ee5381e44
|
@ -20,12 +20,36 @@
|
||||||
<div id="wrapper">
|
<div id="wrapper">
|
||||||
<div id="wrapper2">
|
<div id="wrapper2">
|
||||||
<div id="wrapper3">
|
<div id="wrapper3">
|
||||||
<%=render :partial => 'layouts/base_header'%>
|
<%= render :partial => 'layouts/base_header'%>
|
||||||
<div id="main">
|
<div id="main">
|
||||||
<div class="top-content">
|
<div class="top-content">
|
||||||
<span><p>创客主页</p><p>forge.trustie.net</p></span>
|
<table><tr><td>
|
||||||
<span><p></p><p></p></span>
|
<div class="top-content-home">
|
||||||
<span></span>
|
<table>
|
||||||
|
<tr>
|
||||||
|
<td>创客主页</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>forge.trustie.net</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</div></td>
|
||||||
|
<td>
|
||||||
|
<div class="top-content-location">
|
||||||
|
<table>
|
||||||
|
<tr>
|
||||||
|
<td>当前位置</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>主页》软件创客》<%= @user.name %></td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</div></td>
|
||||||
|
<td>
|
||||||
|
<div class="top-content-search">
|
||||||
|
das
|
||||||
|
</div></td></tr>
|
||||||
|
</table>
|
||||||
</div>
|
</div>
|
||||||
<!--user page, add by huang-->
|
<!--user page, add by huang-->
|
||||||
<div id="sidebar">
|
<div id="sidebar">
|
||||||
|
@ -34,20 +58,15 @@
|
||||||
<div class="inf_user_image">
|
<div class="inf_user_image">
|
||||||
<table>
|
<table>
|
||||||
<tr>
|
<tr>
|
||||||
<td align="left" valign="middle" ><%= image_tag(url_to_avatar(@user), :class => 'avatar2') %></td>
|
<td align="left" valign="middle" ><%= image_tag(url_to_avatar(@user), :class => 'avatar2') %></td>
|
||||||
<td>
|
<td>
|
||||||
<table>
|
<table>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="info_font" align="center" style=" word-wrap: break-word; word-break: break-all"><%= h @user.lastname<<@user.firstname %>
|
<td class="info_font" align="center" style=" word-wrap: break-word; word-break: break-all"><%= h @user.lastname<<@user.firstname %> <!-- added by bai --> <% unless @user.user_extensions.nil?%>
|
||||||
<!-- added by bai -->
|
<% unless @user.user_extensions.identity == 2 %>
|
||||||
<% unless @user.user_extensions.nil?%>
|
<% if @user.user_extensions.gender == 1 %> <%= image_tag("/images/sidebar/female.png", weight:"22px", height:"22px") %>
|
||||||
<% unless @user.user_extensions.identity == 2 %>
|
<% else %> <%= image_tag("/images/sidebar/male.png", weight:"25px", height:"25px") %> <% end %><% end %>
|
||||||
<% if @user.user_extensions.gender == 1 %> <%=image_tag("/images/sidebar/female.png", weight:"22px", height:"22px") %>
|
<% else %> <%= image_tag("/images/sidebar/male.png", weight:"25px", height:"25px") %> <% end %> <!-- end --></td>
|
||||||
<% else %> <%=image_tag("/images/sidebar/male.png", weight:"25px", height:"25px") %> <% end %><% end %>
|
|
||||||
<% else %> <%=image_tag("/images/sidebar/male.png", weight:"25px", height:"25px") %> <% end %>
|
|
||||||
|
|
||||||
<!-- end -->
|
|
||||||
</td>
|
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td align="center"> <% unless User.current == @user %>
|
<td align="center"> <% unless User.current == @user %>
|
||||||
|
@ -60,45 +79,48 @@
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<strong class="font_small_watch"><%=link_to l(:label_user_watcher)+"("+User.watched_by(@user.id).count.to_s+")" ,:controller=>"users", :action=>"user_watchlist"%></strong>
|
<strong class="font_small_watch"><%= link_to l(:label_user_watcher)+"("+User.watched_by(@user.id).count.to_s+")" ,:controller=>"users", :action=>"user_watchlist"%></strong>
|
||||||
|
|
||||||
<strong class="font_small_watch"><%=link_to l(:label_x_user_fans, :count => User.current.watcher_users(User.current.id).count)+"("+@user.watcher_users(@user.id).count.to_s+")", :controller=>"users", :action=>"user_fanslist" %></strong>
|
<strong class="font_small_watch"><%= link_to l(:label_x_user_fans, :count => User.current.watcher_users(User.current.id).count)+"("+@user.watcher_users(@user.id).count.to_s+")", :controller=>"users", :action=>"user_fanslist" %></strong>
|
||||||
|
|
||||||
<strong class="font_small_watch"><%=link_to l(:label_requirement_focus)+"("+Bid.watched_by(@user).where('reward_type = ?', 1).count.to_s+")" ,:controller=>"users", :action=>"watch_bids"%></strong> <!-- added by huang -->
|
<strong class="font_small_watch"><%= link_to l(:label_requirement_focus)+"("+Bid.watched_by(@user).where('reward_type = ?', 1).count.to_s+")" ,:controller=>"users", :action=>"watch_bids"%></strong> <!-- added by huang -->
|
||||||
|
|
||||||
<!-- added by bai 个人签名-->
|
<!-- added by bai 个人签名-->
|
||||||
<% if @user.id == User.current.id %>
|
<% if @user.id == User.current.id %>
|
||||||
<p><%= toggle_link l(:label_brief_introduction), 'introduction', {:focus => 'new_form_user_introduction'} %></p>
|
<p>
|
||||||
<% end %>
|
<%= toggle_link l(:label_brief_introduction), 'introduction', {:focus => 'new_form_user_introduction'} %>
|
||||||
<% unless @user.user_extensions.nil? %>
|
</p>
|
||||||
<p>
|
<% end %>
|
||||||
<%= @user.user_extensions.brief_introduction %></p>
|
<% unless @user.user_extensions.nil? %>
|
||||||
<% end %>
|
<p>
|
||||||
<div id="introduction" style="display: none">
|
<%= @user.user_extensions.brief_introduction %>
|
||||||
<%= form_for('new_form', :method => :post,
|
</p>
|
||||||
:url => {:controller => 'words', :action => 'add_brief_introdution'}) do |f|%>
|
<% end %>
|
||||||
|
<div id="introduction" style="display: none">
|
||||||
|
<%= form_for('new_form', :method => :post,
|
||||||
|
:url => {:controller => 'words', :action => 'add_brief_introdution'}) do |f|%>
|
||||||
|
|
||||||
<table border="0" width="100%" align="center" >
|
<table border="0" width="100%" align="center" >
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td><%= f.text_area 'user_introduction', :rows => 3,
|
||||||
|
:cols => 65,
|
||||||
|
:placeholder => "#{l(:label_my_brief_introduction)}",
|
||||||
|
:style => "resize: none;",
|
||||||
|
:class => 'noline'%></td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
<table border="0" width="200px" align="center">
|
||||||
|
<tr>
|
||||||
|
<td align="right"> <%= submit_tag l(:button_submit), :name => nil ,
|
||||||
|
:class => "bid_btn" %></td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
<!-- end -->
|
||||||
|
|
||||||
<tr>
|
|
||||||
<td><%= f.text_area 'user_introduction', :rows => 3,
|
|
||||||
:cols => 65,
|
|
||||||
:placeholder => "#{l(:label_my_brief_introduction)}",
|
|
||||||
:style => "resize: none;",
|
|
||||||
:class => 'noline'%></td>
|
|
||||||
</tr>
|
|
||||||
</table>
|
|
||||||
<table border="0" width="200px" align="center">
|
|
||||||
<tr>
|
|
||||||
<td align="right"> <%= submit_tag l(:button_submit), :name => nil ,
|
|
||||||
:class => "bid_btn" %></td>
|
|
||||||
</tr>
|
|
||||||
</table>
|
|
||||||
<% end %>
|
|
||||||
</div>
|
</div>
|
||||||
<!-- end -->
|
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="user_underline"></div>
|
<div class="user_underline"></div>
|
||||||
|
@ -117,31 +139,29 @@
|
||||||
|
|
||||||
<!-- added by bai 在个人主页里显示“工作单位”“地区”"教师的职称"-->
|
<!-- added by bai 在个人主页里显示“工作单位”“地区”"教师的职称"-->
|
||||||
|
|
||||||
|
<% unless @user.user_extensions.nil? %>
|
||||||
|
<% unless @user.user_extensions.identity == 2 %>
|
||||||
<% unless @user.user_extensions.nil? %>
|
<tr>
|
||||||
<% unless @user.user_extensions.identity == 2 %>
|
|
||||||
<tr>
|
|
||||||
<td style="padding-left: 8px" width="70px"><%= l(:field_occupation) %>:</td><td class="font_lighter_sidebar" style="padding-left: 0px" width="170px"><%= @user.user_extensions.occupation %></td>
|
<td style="padding-left: 8px" width="70px"><%= l(:field_occupation) %>:</td><td class="font_lighter_sidebar" style="padding-left: 0px" width="170px"><%= @user.user_extensions.occupation %></td>
|
||||||
</tr><% end %>
|
</tr>
|
||||||
<tr>
|
<% end %>
|
||||||
|
<tr>
|
||||||
<td style="padding-left: 8px" width="70px"><%= l(:label_location) %>:</td><td class="font_lighter_sidebar" style="padding-left: 0px" width="170px"><%= @user.user_extensions.location %><%= @user.user_extensions.location_city %></td>
|
<td style="padding-left: 8px" width="70px"><%= l(:label_location) %>:</td><td class="font_lighter_sidebar" style="padding-left: 0px" width="170px"><%= @user.user_extensions.location %><%= @user.user_extensions.location_city %></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td style="padding-left: 8px" width="70px">
|
<td style="padding-left: 8px" width="70px"> <% if @user.user_extensions.identity == 0 %>
|
||||||
<% if @user.user_extensions.identity == 0 %>
|
<%= l(:label_technical_title) %>:</td><td class="font_lighter_sidebar" style="padding-left: 0px" width="170px"><%= @user.user_extensions.technical_title %></td>
|
||||||
<%= l(:label_technical_title) %>:</td><td class="font_lighter_sidebar" style="padding-left: 0px" width="170px"><%= @user.user_extensions.technical_title %></td>
|
|
||||||
<% end %>
|
|
||||||
</tr>
|
|
||||||
<% else%>
|
|
||||||
<tr>
|
|
||||||
<td style="padding-left: 8px" width="70px"><%= l(:field_occupation) %>:</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td style="padding-left: 8px" width="70px"><%= l(:label_location) %>:</td>
|
|
||||||
</tr>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
</tr>
|
</tr>
|
||||||
|
<% else%>
|
||||||
|
<tr>
|
||||||
|
<td style="padding-left: 8px" width="70px"><%= l(:field_occupation) %>:</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td style="padding-left: 8px" width="70px"><%= l(:label_location) %>:</td>
|
||||||
|
</tr>
|
||||||
|
<% end %>
|
||||||
|
</tr>
|
||||||
<!-- end -->
|
<!-- end -->
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
@ -149,19 +169,19 @@
|
||||||
<!--Modified by nie-->
|
<!--Modified by nie-->
|
||||||
<!--tags-->
|
<!--tags-->
|
||||||
<% if User.current.logged? %>
|
<% if User.current.logged? %>
|
||||||
<% if User.current.admin?||User.current.login==@user.login%>
|
<% if User.current.admin?||User.current.login==@user.login%>
|
||||||
<div class="user_underline"></div>
|
<div class="user_underline"></div>
|
||||||
<!-- <div class="user_fans"> -->
|
<!-- <div class="user_fans"> -->
|
||||||
<!-- added by william -for tag -->
|
<!-- added by william -for tag -->
|
||||||
<!-- <div class="user_tags"> -->
|
<!-- <div class="user_tags"> -->
|
||||||
<div class="user_tags">
|
<div class="user_tags">
|
||||||
<div id="tags">
|
<div id="tags">
|
||||||
<%= render :partial => 'tags/tag', :locals => {:obj => @user,:object_flag => "1"}%>
|
<%= render :partial => 'tags/tag', :locals => {:obj => @user,:object_flag => "1"}%>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
<!-- </div> -->
|
<% end %>
|
||||||
|
<!-- </div> -->
|
||||||
<!-- </div> -->
|
<!-- </div> -->
|
||||||
|
|
||||||
<!--watch-->
|
<!--watch-->
|
||||||
|
@ -170,7 +190,9 @@
|
||||||
<div class="font_title_left">
|
<div class="font_title_left">
|
||||||
<strong><%= l(:label_user_watcher) %></strong>
|
<strong><%= l(:label_user_watcher) %></strong>
|
||||||
<% if show_more_watchers?(@user) %>
|
<% if show_more_watchers?(@user) %>
|
||||||
<div style="font-size: 11px; display: inline; float: right; margin-top: 5px; margin-right: 20px" ><%= link_to l(:label_more), :controller => "users", :action => "user_watchlist"%></div>
|
<div style="font-size: 11px; display: inline; float: right; margin-top: 5px; margin-right: 20px" >
|
||||||
|
<%= link_to l(:label_more), :controller => "users", :action => "user_watchlist"%>
|
||||||
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -188,7 +210,9 @@
|
||||||
<div class="font_title_left">
|
<div class="font_title_left">
|
||||||
<strong><%= l(:label_x_user_fans, :count => User.current.watcher_users(User.current.id).count) %></strong>
|
<strong><%= l(:label_x_user_fans, :count => User.current.watcher_users(User.current.id).count) %></strong>
|
||||||
<% if show_more_fans?(@user) %>
|
<% if show_more_fans?(@user) %>
|
||||||
<div style="font-size: 11px; display: inline; float: right; margin-top: 5px; margin-right: 20px" ><%= link_to l(:label_more), :controller => "users", :action => "user_fanslist"%></div>
|
<div style="font-size: 11px; display: inline; float: right; margin-top: 5px; margin-right: 20px" >
|
||||||
|
<%= link_to l(:label_more), :controller => "users", :action => "user_fanslist"%>
|
||||||
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
<div class="left_wf">
|
<div class="left_wf">
|
||||||
|
@ -228,7 +252,7 @@
|
||||||
<div id="ajax-modal" style="display:none;"></div>
|
<div id="ajax-modal" style="display:none;"></div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<%= call_hook :view_layouts_base_body_bottom %>
|
<%= call_hook :view_layouts_base_body_bottom %>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
|
@ -13,10 +13,26 @@ h4 {border-bottom: 1px dotted #bbb;}
|
||||||
/**/
|
/**/
|
||||||
.top-content{
|
.top-content{
|
||||||
background-color: rgb(226, 244, 255);
|
background-color: rgb(226, 244, 255);
|
||||||
height: 40px;
|
height: 50px;
|
||||||
width: 940px;
|
width: 940px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.top-content-home{
|
||||||
|
background-color: rgb(226, 244, 255);
|
||||||
|
width: 25%;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
.top-content-search{
|
||||||
|
float: right
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
.top-content-location{
|
||||||
|
margin-left: 260px;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
.enterprise{
|
.enterprise{
|
||||||
padding-left: 400px;
|
padding-left: 400px;
|
||||||
padding-top: 10px;
|
padding-top: 10px;
|
||||||
|
|
Loading…
Reference in New Issue