Merge branch 'szzh' into develop

This commit is contained in:
sw 2015-03-13 17:48:42 +08:00
commit 00725aae93
10 changed files with 29 additions and 30 deletions

View File

@ -15,7 +15,7 @@ module Mobile
if attachment.nil?
raise '未发现客户端!'
end
url = Setting.host_name + "/attachments/download/" + attachment.id.to_s + "/" + attachment.filename
url = "http://" + Setting.host_name + "/attachments/download/" + attachment.id.to_s + "/" + attachment.filename
{
version: @current_version.version,
url: url,

View File

@ -20,9 +20,9 @@ class AttachmentsController < ApplicationController
before_filter :find_project, :only => [:show, :download, :thumbnail, :destroy, :delete_homework]#, :except => [:upload, :autocomplete]
before_filter :file_readable, :read_authorize, :only => [:show, :thumbnail]#Modified by young
before_filter :delete_authorize, :only => :destroy
before_filter :authorize_global, :only => :upload
before_filter :authorize_attachment_download1, :only => :download
before_filter :delete_authorize, :only => [:destroy]
before_filter :authorize_global, :only => [:upload]
before_filter :authorize_attachment_download1, :only => [:download]
#before_filter :login_without_softapplication, only: [:download]
accept_api_auth :show, :download, :upload
require 'iconv'

View File

@ -101,8 +101,8 @@
</div>
<!-- 项目得分 -->
<div class="cl"></div>
<div class="pr_info_name">
<%= link_to @project.name, project_path(@project) %>
<div class="pr_info_name f1">
<%= link_to @project.name, project_path(@project), :style => "color:#3E4040"%>
<% if !@project.is_public? %>
<span class="img_private"><%= l(:label_private)%></span>
<% end %>
@ -151,7 +151,7 @@
<span class="subnav_num">(<%= @project.issues.count %>)</span><span>
<% end %>
<% if User.current.member_of?(@project) %>
<%= link_to "+"+l(:label_release_issue), new_project_issue_path(@project) , :style => "font-size:12px;color:#fff; padding:1px 3px 3px 3px;height:18px;margin-top:3px;background:#28be6c;float:right;line-height:20px;" %></span>
<%= link_to "+"+l(:label_release_issue), new_project_issue_path(@project) , :style => "font-size:12px;color:#fff; padding:1px 3px 3px 3px;height:16px;margin-top:4px;background:#28be6c;float:right;line-height:20px;" %></span>
<% end %>
</div>
<% end %>
@ -162,7 +162,7 @@
<span class="subnav_num">(<%= @project.boards.first.topics.count %>)</span>
<% end %>
<% if User.current.member_of?(@project) %>
<%= link_to "+"+l(:project_module_boards_post), project_boards_path(@project, :flag => true), :layout => 'base_projects',:style => "font-size:12px;color:#fff; padding:1px 3px 3px 3px;height:18px;margin-top:4px;background:#28be6c;float:right;line-height:20px;" %>
<%= link_to "+"+l(:project_module_boards_post), project_boards_path(@project, :flag => true), :layout => 'base_projects',:style => "font-size:12px;color:#fff; padding:0px 3px 3px 3px;height:16px;margin-top:5px;background:#28be6c;float:right;line-height:20px;" %>
<% end %>
</div>
<% end%>
@ -173,16 +173,14 @@
<span class="subnav_num">(<%= @project.attachments.count %>)</span>
<% end %>
<% if User.current.member_of?(@project) %>
<%= link_to "+"+l(:label_upload_files), project_files_path(@project,:flag => true),:style => "font-size:12px;color:#fff; padding:1px 3px 3px 3px;height:18px;margin-top:3px;background:#28be6c;float:right;line-height:20px;" %>
<%= link_to "+"+l(:label_upload_files), project_files_path(@project,:flag => true),:style => "font-size:12px;color:#fff; padding:1px 3px 3px 3px;height:16px;margin-top:4px;background:#28be6c;float:right;line-height:20px;" %>
<% end %>
</div>
<% end%>
<% unless @project.enabled_modules.where("name = 'repository'").empty? %>
<% unless @project.enabled_modules.where("name = 'repository'").empty? || @project.repositories.count == 0 %>
<div class="subNav">
<%= link_to l(:project_module_repository), {:controller => 'repositories', :action => 'show', :id => @project.id}, :style => "color:#3CA5C6" %>
<% unless @project.repositories.count == 0 %>
<span class="subnav_num">(<%= @project.repositories.count %>)</span>
<% end %>
<%= link_to l(:project_module_repository), {:controller => 'repositories', :action => 'show', :id => @project.id}, :style => "color:#3CA5C6" %>
<span class="subnav_num">(<%= @project.repositories.count %>)</span>
<%# if User.current.member_of?(@project) %>
<%#= link_to "+"+l(:project_module_create_repository), new_project_repository_path(@project),:style => "font-size:12px;color:#fff; padding:1px 3px 3px 3px;height:18px;margin-top:3px;background:#28be6c;float:right;line-height:20px;" %>
<%# end %>

View File

@ -1,6 +1,6 @@
<div class="project_r_h">
<h2 class="project_h2">邀请加入</h2>
<h2 class="project_h2"><%= l(:label_invite_join) %></h2>
</div>
<%#= render_flash_messages %>
<%
@ -20,12 +20,12 @@
</div>
<div class="cl"></div>
<div class="box_main">
<h3 class="box_h3">邀请Trustie注册用户</h3>
<h3 class="box_h3"><%= l(:label_invite_trustie_user) %></h3>
<% if roles.any? %>
<%= form_for(@member, {:as => :membership, :url => project_memberships_path(@project), :method => :post}) do |f| %>
<div class="invi_search">
<input hidden="hidden" value="true" name="flag">
<input id="principal_search" class="invi_search_input fl" type="text" placeholder="输入用户名称搜索好友">
<input id="principal_search" class="invi_search_input fl" type="text" placeholder="输入用户名称搜索好友">
<%= javascript_tag "observeSearchfield('principal_search', null, '#{ escape_javascript autocomplete_project_memberships_path(@project, :format => 'js',:flag => true) }')" %>
<div class="cl"></div>

View File

@ -101,11 +101,6 @@
<% end %>
</span>
</div>
<% end %>
<% else %>
<span style="color:#8c8a8a">
&nbsp;&nbsp;&nbsp;
<%= l(:label_tags_no) %>
</span>
<% end %>
<% end %>
<% end %>

View File

@ -90,8 +90,11 @@ en:
label_send_email: Send
label_input_email: Please input email address
label_invite_trustie_user: "Invite Trustie registered users"
label_invite_trustie_user_tips: "Please enter the Trustie user name"
label_invite_project: "invites you to join the project"
label_invite_success: Successful invitation
label_invite_members: Invite
#

View File

@ -95,7 +95,10 @@ zh:
label_input_email: 请输入邮箱地址
label_invite_trustie_user: "邀请Trustie注册用户"
label_invite_trustie_user_tips: "请输入用户名称来搜索好友"
label_invite_project: 邀请您加入项目
label_invite_success: 邀请成功
label_invite_members: 邀请用户
#
# 项目托管平台
#

View File

@ -1714,9 +1714,7 @@ zh:
label_bids_task_list: 作业列表
label_join_course: 加入
label_invite_project: 邀请您加入项目
label_invite_success: 邀请成功
label_invite_members: 邀请用户
label_exit_course: 退出
label_exit_group: 退出当前分班
label_new_join: 加入
@ -2078,5 +2076,7 @@ zh:
label_recently_updated_courseware: 最近更新了课件
label_no_courses: 您没有参与任何课程,请搜索课程、加入课程,或者创建课程吧!
label_end_time: 截止时间
label_send_email: 确定发送
label_input_email: 请输入邮箱地址

BIN
public/images/jiantou1.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

@ -55,7 +55,7 @@ a:hover.info_foot_num{ color:#2390b2;}
/*左侧导航*/
.subNavBox{width:222px; background:#fff;margin:10px 10px 0 0;}
.subNav{border-bottom:solid 1px #e5e3da;cursor:pointer;font-weight:bold;font-size:14px;color:#3ca5c6;line-height:28px;padding-left:10px;background-color:#fff;}
.subNav_jiantou{background:url(../images/jiantou1.jpg) no-repeat;background-position:95% 50%; background-color:#fff;}
.subNav_jiantou{background:url(/images/jiantou1.jpg) no-repeat;background-position:95% 50%; background-color:#fff;}
.subNav_jiantou:hover{color:#0781b4; }
.currentDd{color:#0781b4; }
.currentDt{background-color:#fff; }
@ -100,7 +100,7 @@ a:hover.more{ color:#64bdd9;}
.box_close{ display:block; float:right; width:16px; height:16px; background:url(../images/img_floatbox.png) 0 0 no-repeat;}
.box_close:hover{background:url(../images/img_floatbox.png) -22px 0 no-repeat;}
/*邮件邀请*/
.box_main{ width:345px; margin:0 auto;padding-left:40px;}
.box_main{ width:345px; margin:0 auto;padding-left:28px;}
.box_h3{ color:#15bccf; text-align:center; font-size:16px;margin-right:40px;}
.box_p{ color:#404040; margin-bottom:5px;}
.fb_item{ color:#919191; border:1px solid #919191; height:28px; margin-bottom:10px; padding-left:5px; width:290px;}