<%= link_to "返回合并请求列表
".html_safe, project_pull_requests_path(@project), :class => "fl linkBlue2 mt3" %>
|<%= @request.title %>
<% if User.current.login == @request.author.try(:username) || is_project_manager?(User.current.id, @project.id) %>
<% unless @request.state == "merged" %>
<%= link_to "#{@request.state == 'closed' ? '重新打开' : '关闭'}", update_pull_request_project_pull_request_path(@request.id, :project_id => @project.id, :state => @request.state =="closed" ? "reopen" : "close"), :class => "fr c_grey" %>
<% end %>
<% end %>
编辑