我收到的issues
This commit is contained in:
parent
432c98881b
commit
82a253765c
|
@ -39,7 +39,7 @@ class UsersController < ApplicationController
|
|||
:unfinished_poll_list, :user_homeworks,:student_homeworks, :destroy_membership, :user_activities, :user_projects, :user_newfeedback, :user_comments,
|
||||
:anonymous_evaluation_list,:unfinished_test_list, :watch_contests, :info, :watch_projects, :show_score, :topic_score_index, :project_score_index,
|
||||
:unapproval_applied_list, :activity_score_index, :influence_score_index, :score_index,:show_new_score, :topic_new_score_index, :project_new_score_index,
|
||||
:activity_new_score_index, :influence_new_score_index, :score_new_index,:user_projects_index,:user_resource,:user_contestlist, :user_manage_issues,
|
||||
:activity_new_score_index, :influence_new_score_index, :score_new_index,:user_projects_index,:user_resource,:user_contestlist, :user_manage_issues, :user_receive_issues,
|
||||
:user_courses4show,:user_projects4show,:user_contests4show,:user_course_activities,:user_project_activities,:user_feedback4show,:user_visitorlist,:user_messages,:edit_brief_introduction,
|
||||
:user_import_homeworks,:user_search_homeworks,:user_import_resource, :user_system_messages,:choose_user_course,:user_courselist,:user_projectlist,:sort_syllabus_list,
|
||||
:sort_project_list,:my_homeworks,:manage_or_receive_homeworks,:search_m_r_homeworks, :cancel_or_collect,:expand_courses,:homepage, :user_issues, :course_community, :project_community, :contest_community]
|
||||
|
@ -150,7 +150,9 @@ class UsersController < ApplicationController
|
|||
end
|
||||
end
|
||||
|
||||
# 我发布的issue
|
||||
def user_manage_issues
|
||||
@manage_issues = "我发布的Issue"
|
||||
# 排序(默认以更新时间降序)
|
||||
order = "updated_on desc"
|
||||
if params[:reorder_release_time]
|
||||
|
@ -159,9 +161,9 @@ def user_manage_issues
|
|||
order = "updated_on #{params[:reorder_turnover_time]}"
|
||||
end
|
||||
|
||||
@type = params[:type] unless params[:type].nil?
|
||||
@subject = params[:subject]
|
||||
params[:assigned_to_id].to_i == 0 ? @assigned_to = nil : @assigned_to = params[:assigned_to_id].to_i
|
||||
params[:author_id].to_i == 0 ? author_id = nil : author_id = params[:author_id].to_i
|
||||
params[:project_id].to_i == 0 ? @project_id = nil : @project_id = params[:project_id]
|
||||
if @project_id.nil?
|
||||
@issues = Issue.where("author_id =? and subject like ?",
|
||||
|
@ -194,6 +196,52 @@ def user_manage_issues
|
|||
end
|
||||
end
|
||||
|
||||
# 我收到的issue
|
||||
def user_receive_issues
|
||||
@receive_issues = "我收到的Issue"
|
||||
# 排序(默认以更新时间降序)
|
||||
order = "updated_on desc"
|
||||
if params[:reorder_release_time]
|
||||
order = "created_on #{params[:reorder_release_time]}"
|
||||
elsif params[:reorder_turnover_time]
|
||||
order = "updated_on #{params[:reorder_turnover_time]}"
|
||||
end
|
||||
|
||||
@subject = params[:subject]
|
||||
params[:assigned_to_id].to_i == 0 ? @assigned_to = nil : @assigned_to = params[:assigned_to_id].to_i
|
||||
params[:author_id].to_i == 0 ? author_id = nil : author_id = params[:author_id].to_i
|
||||
params[:project_id].to_i == 0 ? @project_id = nil : @project_id = params[:project_id]
|
||||
if @project_id.nil?
|
||||
@issues = Issue.where("assigned_to_id =? and subject like ?",
|
||||
@user.id, "%#{@subject}%").order(order)
|
||||
else
|
||||
@issues = Issue.where("assigned_to_id =? and project_id=? and subject like ?",
|
||||
@user.id, @project_id, "%#{@subject}%").order(order)
|
||||
end
|
||||
@issues_filter = Issue.where("assigned_to_id =?", @user.id).order('updated_on desc')
|
||||
@issue_open_count = Issue.where(:assigned_to_id => @user.id, :status_id => [1, 2, 3, 4, 6]).count
|
||||
@issue_close_count = Issue.where(:assigned_to_id => @user.id, :status_id => 5).count
|
||||
|
||||
# 导出excel的issues
|
||||
@excel_issues = @issues
|
||||
@issue_count = @issues.count
|
||||
@limit = 10
|
||||
@is_remote = true
|
||||
@issue_pages = Paginator.new @issue_count, @limit, params['page'] || 1
|
||||
@offset ||= @issue_pages.offset
|
||||
@issues = paginateHelper @issues, @limit
|
||||
# @issues.limit(@issue_pages.per_page).offset(@issue_pages.offset).reorder(order).all
|
||||
respond_to do |format|
|
||||
format.html{render :layout => 'static_base'}
|
||||
format.xls{
|
||||
filename = "我发布的_#{l(:label_issue_list_xls)}.xls"
|
||||
send_data(issue_list_xls(@excel_issues), :type => 'application/octet-stream', :filename => filename_for_content_disposition(filename))
|
||||
}
|
||||
format.api
|
||||
format.js
|
||||
end
|
||||
end
|
||||
|
||||
#展开所有回复
|
||||
def show_all_replies
|
||||
case params[:type]
|
||||
|
|
|
@ -1348,6 +1348,10 @@ module ApplicationHelper
|
|||
title << @course_community
|
||||
elsif !@contest_community.blank?
|
||||
title << @contest_community
|
||||
elsif !@manage_issues.blank?
|
||||
title << @manage_issues
|
||||
elsif !@receive_issues.blank?
|
||||
title << @receive_issues
|
||||
else
|
||||
title << @user.try(:realname)
|
||||
end
|
||||
|
|
|
@ -198,7 +198,7 @@
|
|||
</li>
|
||||
<li class="home-user-leftnav-li icons-issue clear">
|
||||
<%= link_to issues_assigned_is_self_count > 0 ? "我收到的issue<span class='issues_nav_tag mr10 fr' style='line-height:18px;margin-top:9px;font-size:11px;background-color:#f5f2f2;color:#666;'>#{issues_assigned_is_self_count}</span>".html_safe : "我收到的issue",
|
||||
user_issues_user_path(@user, :type => "assigned"), :target => "_blank" %>
|
||||
user_receive_issues_user_path(@user), :target => "_blank" %>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
|
@ -0,0 +1,84 @@
|
|||
<% unless activity.author.nil? %>
|
||||
<div class="issues_list_box clear" id="user_activity_<%= user_activity_id%>">
|
||||
<div class="issues_ciricons fl ">
|
||||
<% if activity.status_id.to_i == 5 %>
|
||||
<span class="issues_ciricons_02"></span>
|
||||
<% else %>
|
||||
<span class="issues_ciricons_01"></span>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class=" fl ml5">
|
||||
<div class="issues_list_titlebox clear">
|
||||
<a href="<%= issue_path(activity) %>" class="issues_list_title fl" style="width: 400px" target="_blank" title="<%= activity.subject.to_s %>"><%= activity.subject.to_s %></a>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
<div class="issues_list_small">
|
||||
<p class="fl issues_list_name" ><span class="mr5"><%= format_time(activity.created_on) %> </span>发布</p>
|
||||
<p class="fl ml10"> <span class="mr5"><%= format_time(activity.updated_on) %> </span>更新</p>
|
||||
</div>
|
||||
</div>
|
||||
<ul class="issues_list_txt fr">
|
||||
<li class=" c_grey issues_list_max mr5">
|
||||
<%= Project.find(activity.project_id).name %>
|
||||
</li>
|
||||
<li class="c_grey">
|
||||
<% if activity.try(:author).try(:realname) == ' ' %>
|
||||
<%= link_to activity.try(:author), user_path(activity.author_id)%>
|
||||
<% else %>
|
||||
<%= link_to activity.try(:author).try(:realname), user_path(activity.author_id)%>
|
||||
<% end %>
|
||||
</li>
|
||||
<li class="issues_list_min c_grey">
|
||||
<% case activity.tracker_id %>
|
||||
<% when 1 %>
|
||||
缺陷
|
||||
<% when 2 %>
|
||||
功能
|
||||
<% when 3 %>
|
||||
支持
|
||||
<% when 4 %>
|
||||
任务
|
||||
<% when 5 %>
|
||||
周报
|
||||
<% end %>
|
||||
</li>
|
||||
<li class="issues_list_min c_grey">
|
||||
<%= activity.priority.name %>
|
||||
</li>
|
||||
|
||||
<li class="c_grey issues_list_max" title="<%= activity.fixed_version %>"><%= activity.fixed_version %></li>
|
||||
<li class="issues_list_min c_grey mr5" ><%= activity.status.name %></li>
|
||||
<li class="<%= (activity.done_ratio == 100 ? 'c_green issues_list_min mr5' : 'c_red issues_list_min mr5') %>"><%= activity.done_ratio %>%</li>
|
||||
<li class="issues_list_min">
|
||||
<% if activity.journals.count > 0 %>
|
||||
<span class="issues_icons_mes fl mr5 mt12"></span>
|
||||
<span class="fl mr5"><%= activity.journals.count %></span>
|
||||
<% end %>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<script>
|
||||
$(".issues_list_box").mouseover(function(){
|
||||
var iconOrder;
|
||||
var iconSize = $(this).children().eq(2).children().eq(7).children().size();
|
||||
if(iconSize > 1){
|
||||
iconOrder = 2;
|
||||
} else{
|
||||
iconOrder = 0;
|
||||
}
|
||||
$(this).children().eq(2).children().eq(7).children().eq(iconOrder).show();
|
||||
});
|
||||
$(".issues_list_box").mouseout(function(){
|
||||
var iconOrder;
|
||||
var iconSize = $(this).children().eq(2).children().eq(7).children().size();
|
||||
if(iconSize > 1){
|
||||
iconOrder = 2;
|
||||
} else{
|
||||
iconOrder = 0;
|
||||
}
|
||||
$(this).children().eq(2).children().eq(7).children().eq(iconOrder).hide();
|
||||
});
|
||||
</script>
|
||||
|
|
@ -0,0 +1,24 @@
|
|||
<% issue_list(issues) do |issue| -%>
|
||||
<script>
|
||||
$(function () {
|
||||
sd_create_editor_from_data(<%= issue.id %>, null, "100%", "<%= issue.class.name %>");
|
||||
});
|
||||
</script>
|
||||
<%= render :partial => 'users/my_receive_issue_list', :locals => {:activity => issue, :user_activity_id => issue.id} %>
|
||||
<% end %>
|
||||
|
||||
<div style="text-align:left;">
|
||||
<div style="width:auto; display:inline-block;">
|
||||
<ul>
|
||||
<%= link_to "导出EXCEL", user_manage_issues_user_path(:format => 'xls'), :class => "hw_btn_blue ml10 mt10 mb10", :id => "sendexcel",
|
||||
:onclick => "remote_function_export('#{User.current}')"%>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
<div class="pages fr" style="width:auto; display:inline-block;margin-top:10px">
|
||||
<ul id="issue_list_pagination" class="fr">
|
||||
<%= pagination_links_full @issue_pages, @issue_count, :per_page_links => false, :remote => @is_remote, :flag => true, :is_new => true %>
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
</div>
|
|
@ -170,8 +170,8 @@
|
|||
$("#done_ratio").removeClass('issues_filter_active');
|
||||
$("#test").removeClass('issues_filter_active');
|
||||
$("#reorder_turnover_time").removeClass("sortArrowActiveU");
|
||||
$("#reorder_turnover_time").removeClass("sortArrowActiveD");
|
||||
$("#reorder_release_time").addClass("sortArrowActiveD");
|
||||
$("#reorder_turnover_time").addClass("sortArrowActiveD");
|
||||
$("#reorder_release_time").removeClass("sortArrowActiveD");
|
||||
$("#reorder_release_time").removeClass("sortArrowActiveU");
|
||||
remote_function();
|
||||
}
|
||||
|
@ -239,8 +239,8 @@
|
|||
<a href="javascript:void(0);" class="sy_btn_grey fl ml5" onclick="all_reset_form();">清除</a>
|
||||
<div class="fr">
|
||||
<a href="javascript:void(0);" class="linkGrey2 fl">排序: </a>
|
||||
<div id="release_time" class="w70 fl"><a href="javascript:void(0);" class="linkGrey2 fl">发布时间</a><a href="javascript:void(0);" id="reorder_release_time" class="sortArrowActiveD"></a></div>
|
||||
<div id="turnover_time" class="w70 fl"><a href="javascript:void(0);" class="linkGrey2 fl">更新时间</a><a href="javascript:void(0);" id="reorder_turnover_time" class=""></a></div>
|
||||
<div id="release_time" class="w65 fl"><a href="javascript:void(0);" class="linkGrey2 fl">发布时间</a><a href="javascript:void(0);" id="reorder_release_time" class=""></a></div>
|
||||
<div id="turnover_time" class="w65 fl"><a href="javascript:void(0);" class="linkGrey2 fl">更新时间</a><a href="javascript:void(0);" id="reorder_turnover_time" class="sortArrowActiveD"></a></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -0,0 +1,313 @@
|
|||
<%= content_for(:header_tags) do %>
|
||||
<%= import_ke(enable_at: true,init_activity: true) %>
|
||||
<% end %>
|
||||
|
||||
<script xmlns="http://www.w3.org/1999/html">
|
||||
function add_style(){
|
||||
// $("#proeject_id").val("来源");
|
||||
if($("select[id='tracker_id']").val() != 0){
|
||||
$("#tracker_id").addClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='author_id']").val() != 0){
|
||||
$("#author_id").addClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='assigned_to_id']").val() !=0){
|
||||
$("#assigned_to_id").addClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='priority_id']").val() !=0){
|
||||
$("#priority_id").addClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='fixed_version_id']").val() !=0){
|
||||
$("#fixed_version_id").addClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='status_id']").val() != 0 ){
|
||||
$("#status_id").addClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='done_ratio']").val() != -1){
|
||||
$("#done_ratio").addClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='test']").val() != 0 ){
|
||||
$("#test").addClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='tracker_id']").val() == 0){
|
||||
$("#tracker_id").removeClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='author_id']").val() == 0){
|
||||
$("#author_id").removeClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='assigned_to_id']").val() ==0){
|
||||
$("#assigned_to_id").removeClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='priority_id']").val() ==0){
|
||||
$("#priority_id").removeClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='fixed_version_id']").val() ==0){
|
||||
$("#fixed_version_id").removeClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='status_id']").val() == 0 ){
|
||||
$("#status_id").removeClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='done_ratio']").val() == -1){
|
||||
$("#done_ratio").removeClass('issues_filter_active');
|
||||
}
|
||||
if($("select[id='test']").val() == 0 ){
|
||||
$("#test").removeClass('issues_filter_active');
|
||||
}
|
||||
};
|
||||
//issues列表
|
||||
function g(o){
|
||||
return document.getElementById(o);
|
||||
}
|
||||
function HoverLi(n){
|
||||
//如果有N个标签,就将i<=N;
|
||||
for(var i=1;i<=3;i++){
|
||||
g('issues_list_nav_'+i).className='issues_nav_nomal';
|
||||
g('issues_list_content_'+i).className='undis';
|
||||
}
|
||||
g('issues_list_content_'+n).className='dis';
|
||||
g('issues_list_nav_'+n).className='issues_nav_hover';
|
||||
}
|
||||
$(function(){
|
||||
$("#RSide").removeAttr("id");
|
||||
$("#Container").css("width","1000px");
|
||||
$("input[nhname='date_show']").change(function(){
|
||||
if($(this).val()=='创建日期起始' || $(this).val()=='创建日期结束')return;
|
||||
$("input[nhname='date_val']",$(this).parent('div')).val($(this).val());
|
||||
remote_function();
|
||||
});
|
||||
|
||||
});
|
||||
function remote_function() {
|
||||
$("#issue_query_form").submit();
|
||||
}
|
||||
|
||||
function remote_function_export(user) {
|
||||
var project_id = $("#project_id").attr("value");
|
||||
var tracker_id = $("#tracker_id").attr("value");
|
||||
var subject = $("#v_subject").attr("value");
|
||||
var assigned_to_id = $("#assigned_to_id").attr("value");
|
||||
var fixed_version_id = $("#fixed_version_id").attr("value");
|
||||
var status_id = $("#status_id").attr("value");
|
||||
var done_ratio = $("#done_ratio").attr("value");
|
||||
var test = $("#test").attr("value");
|
||||
var author_id = $("#author_id").attr("value");
|
||||
var priority_id = $("#priority_id").attr("value");
|
||||
var issue_create_date_start = $("#issue_date_start_issue_export").attr("value");
|
||||
var issue_create_date_end = $("#issue_date_end_issue_export").attr("value");
|
||||
$("#sendexcel").attr("href","/users/"+user+"/user_receive_issues.xls?project_id="+project_id+"&tracker_id="+tracker_id+"&assigned_to_id="+assigned_to_id+"&fixed_version_id="+fixed_version_id+"&status_id="+status_id+"&done_ratio="+done_ratio+"&test="+test+"&author_id="+author_id+"&subject="+subject+"&issue_create_date_start="+issue_create_date_start+"&issue_create_date_end="+issue_create_date_end+"&priority_id="+priority_id);
|
||||
///projects/1811/issues.xls?export=true&set_filter=1
|
||||
}
|
||||
function EnterPress(e){
|
||||
var e = e || window.event;
|
||||
if(e.keyCode == 13){
|
||||
remote_function();
|
||||
}
|
||||
}
|
||||
|
||||
// 点击的时候让过滤条件选中assign_to
|
||||
function switch_assign_to(assign) {
|
||||
var assign = "option[value =" + assign + "]";
|
||||
$("#issues_type_2").click(function(){
|
||||
|
||||
});
|
||||
$("select[id='assigned_to_id']").find(assign).attr("selected", "selected");
|
||||
$("select[id='author_id']").val('');
|
||||
$("select[id='priority_id']").val('');
|
||||
$("select[id='project_id']").val('');
|
||||
$("select[id='tracker_id']").val('');
|
||||
$("select[id='fixed_version_id']").val('');
|
||||
$("select[id='status_id']").val('');
|
||||
$("select[id='done_ratio']").val('');
|
||||
$("select[id='test']").val('');
|
||||
$("#tracker_id").removeClass('issues_filter_active');
|
||||
$("#author_id").removeClass('issues_filter_active');
|
||||
$("#assigned_to_id").addClass('issues_filter_active');
|
||||
$("#priority_id").removeClass('issues_filter_active');
|
||||
$("#fixed_version_id").removeClass('issues_filter_active');
|
||||
$("#status_id").removeClass('issues_filter_active');
|
||||
$("#done_ratio").removeClass('issues_filter_active');
|
||||
$("#test").removeClass('issues_filter_active');
|
||||
remote_function();
|
||||
}
|
||||
|
||||
// 点击的时候让过滤条件选中user_id
|
||||
function createByMe(user_id) {
|
||||
var user = "option[value =" + user_id + "]";
|
||||
$("#createByMe").click(function(){
|
||||
|
||||
});
|
||||
$("select[id='author_id']").find(user).attr("selected", "selected");
|
||||
$("select[id='assigned_to_id']").val('');
|
||||
$("select[id='priority_id']").val('');
|
||||
$("select[id='project_id']").val('');
|
||||
$("select[id='tracker_id']").val('');
|
||||
$("select[id='fixed_version_id']").val('');
|
||||
$("select[id='status_id']").val('');
|
||||
$("select[id='done_ratio']").val('');
|
||||
$("select[id='test']").val('');
|
||||
$("#tracker_id").removeClass('issues_filter_active');
|
||||
$("#author_id").addClass('issues_filter_active');
|
||||
$("#assigned_to_id").removeClass('issues_filter_active');
|
||||
$("#priority_id").removeClass('issues_filter_active');
|
||||
$("#fixed_version_id").removeClass('issues_filter_active');
|
||||
$("#status_id").removeClass('issues_filter_active');
|
||||
$("#done_ratio").removeClass('issues_filter_active');
|
||||
$("#test").removeClass('issues_filter_active');
|
||||
remote_function();
|
||||
}
|
||||
// 清楚表单所有选项
|
||||
function all_reset_form() {
|
||||
$("#issue_query_form")[0].reset();
|
||||
$("select[id='author_id']").val('');
|
||||
$("select[id='assigned_to_id']").val('');
|
||||
$("input[nhname='date_val']").val('');
|
||||
$("#tracker_id").removeClass('issues_filter_active');
|
||||
$("#author_id").removeClass('issues_filter_active');
|
||||
$("#assigned_to_id").removeClass('issues_filter_active');
|
||||
$("#priority_id").removeClass('issues_filter_active');
|
||||
$("#fixed_version_id").removeClass('issues_filter_active');
|
||||
$("#status_id").removeClass('issues_filter_active');
|
||||
$("#done_ratio").removeClass('issues_filter_active');
|
||||
$("#test").removeClass('issues_filter_active');
|
||||
$("#reorder_turnover_time").removeClass("sortArrowActiveU");
|
||||
$("#reorder_turnover_time").addClass("sortArrowActiveD");
|
||||
$("#reorder_release_time").removeClass("sortArrowActiveD");
|
||||
$("#reorder_release_time").removeClass("sortArrowActiveU");
|
||||
remote_function();
|
||||
}
|
||||
function add_class(id){
|
||||
if($("#"+id).hasClass("sortArrowActiveD")){
|
||||
$("#"+id).removeClass("sortArrowActiveD");
|
||||
$("#"+id).addClass("sortArrowActiveU");
|
||||
$.ajax({
|
||||
type: 'GET',
|
||||
url: '<%= user_receive_issues_user_path(@user) %>' + '.js?' + id + '=asc&page='+<%= @issue_pages.page %>,
|
||||
data: $("#issue_query_form").serialize()
|
||||
});
|
||||
}else if($("#"+id).hasClass("sortArrowActiveU")){
|
||||
$("#"+id).removeClass("sortArrowActiveU");
|
||||
$("#"+id).addClass("sortArrowActiveD");
|
||||
$.ajax({
|
||||
type: 'GET',
|
||||
url: '<%= user_receive_issues_user_path(@user) %>' + '.js?' + id + '=desc&page='+<%= @issue_pages.page %>,
|
||||
data: $("#issue_query_form").serialize()
|
||||
});
|
||||
}else{
|
||||
$("#"+id).addClass("sortArrowActiveD");
|
||||
$.ajax({
|
||||
type: 'GET',
|
||||
url: '<%= user_receive_issues_user_path(@user) %>' + '.js?' + id + '=desc&page='+<%= @issue_pages.page%>,
|
||||
data: $("#issue_query_form").serialize()
|
||||
});
|
||||
}
|
||||
}
|
||||
$(function() {
|
||||
$("#release_time").click(function(){
|
||||
$("#reorder_turnover_time").removeClass("sortArrowActiveU");
|
||||
$("#reorder_turnover_time").removeClass("sortArrowActiveD");
|
||||
add_class("reorder_release_time");
|
||||
});
|
||||
$("#turnover_time").click(function () {
|
||||
$("#reorder_release_time").removeClass("sortArrowActiveD");
|
||||
$("#reorder_release_time").removeClass("sortArrowActiveU");
|
||||
add_class("reorder_turnover_time");
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<!--缺陷列表开始-->
|
||||
<div id="myissues_con" class="myissues_con mb10">
|
||||
<div class="myissues_head mb5">
|
||||
<h2 class="ml15">我收到的Issue</h2>
|
||||
</div>
|
||||
<div class="clear mb5">
|
||||
<div class="issues_statistics fl">
|
||||
<ul>
|
||||
<li>所有<a href="javascript:void(0);" class="issues_greycirbg_btn "><%= @issues_filter.count %></a></li>
|
||||
<li>开启<a href="javascript:void(0);" class="issues_greycirbg_btn "><%= @issue_open_count %></a></li>
|
||||
<li>关闭<a href="javascript:void(0);" class="issues_greycirbg_btn "><%= @issue_close_count %></a></li>
|
||||
</ul>
|
||||
</div><!--issues_statistics end-->
|
||||
|
||||
</div>
|
||||
<%= form_tag( user_receive_issues_user_path(@user), :remote => 'xls', :method => "post", :id => "issue_query_form", :class => 'query_form') do %>
|
||||
<div class="clear mb10">
|
||||
<div class="hw_search_box fl ">
|
||||
<input class="hw_search-input" placeholder="输入Issue名称进行搜索" type="text" id="v_subject" name="subject" onkeypress="EnterPress(event)" onkeydown="EnterPress()">
|
||||
<a href="javascript:void(0);" class="hw_btn_search" onclick="remote_function();" ></a>
|
||||
</div>
|
||||
<a href="javascript:void(0);" class="sy_btn_grey fl ml5" onclick="all_reset_form();">清除</a>
|
||||
<div class="fr">
|
||||
<a href="javascript:void(0);" class="linkGrey2 fl">排序: </a>
|
||||
<div id="release_time" class="w65 fl"><a href="javascript:void(0);" class="linkGrey2 fl">发布时间</a><a href="javascript:void(0);" id="reorder_release_time" class=""></a></div>
|
||||
<div id="turnover_time" class="w65 fl"><a href="javascript:void(0);" class="linkGrey2 fl">更新时间</a><a href="javascript:void(0);" id="reorder_turnover_time" class="sortArrowActiveD"></a></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="issues_con_list" style="position: relative;">
|
||||
<ul id="issues_list_nav" >
|
||||
<li id="issues_list_nav_1" class="issues_nav_hover" onclick="HoverLi(1);all_reset_form();">
|
||||
<a href="javascript:void(0);" id="issues_type_1" onclick="all_reset_form();" >搜索结果</a>
|
||||
<span id="issue_filter_all"><%= render :partial => "users/my_issue_filter_all" %></span>
|
||||
</li>
|
||||
<div class="cl"></div>
|
||||
</ul>
|
||||
<div class="issues_filter">
|
||||
<div class="issues_form_filter mt5 mr5">
|
||||
<%= select( :project, :project_id, options_for_issue_project_list(@issues_filter),
|
||||
{ :include_blank => false,:selected => @project_id ? @project_id : 0 },
|
||||
{ :onchange => "remote_function();add_style();", :id => "project_id", :name => "project_id", :class => "fl", :style=>"width: 80px; margin-right:20px;"}
|
||||
)%>
|
||||
<select placeholder=" 发布人" class="fl my_issues_filter" disabled="disabled" style="padding:0px;width: 50px;margin-right: 15px;">
|
||||
<option value="0" selected="selected">发布人</option>
|
||||
</select>
|
||||
<%= select( :issue, :user_id, [[@user.show_name, @user.id]].unshift(["发布人",0]),
|
||||
{:include_blank => false,:selected => @author_id ? @author_id : 0},
|
||||
{:onchange => "remote_function();add_style();",:id => "author_id", :name => "author_id", :class => "fl", :style => "visibility:hidden;width: 0px;margin:0px;padding:0px;"}
|
||||
)
|
||||
%>
|
||||
<select placeholder=" 类型" class="fl my_issues_filter" disabled="disabled" style="padding:0px; margin:0px;width:35px; margin-right:10px;">
|
||||
<option value="0" selected="selected">类型</option>
|
||||
</select>
|
||||
<select placeholder=" 优先度" class="fl my_issues_filter" disabled="disabled" style="padding:0px; margin:0px">
|
||||
<option value="0" selected="selected">优先度</option>
|
||||
</select>
|
||||
<select placeholder=" 里程碑" class="fl my_issues_filter" disabled="disabled" style="padding:0px;margin-left: 20px; margin-right: 10px">
|
||||
<option value="0" selected="selected">里程碑</option>
|
||||
</select>
|
||||
<select placeholder=" 状态" class="fl my_issues_filter" disabled="disabled" style="padding:0px; margin-right:10px;width:35px;">
|
||||
<option value="0" selected="selected">状态</option>
|
||||
</select>
|
||||
<select placeholder=" 完成度" class="fl my_issues_filter" disabled="disabled" style="padding:0px; margin:0px">
|
||||
<option value="0" selected="selected">完成度</option>
|
||||
</select>
|
||||
<select placeholder=" 排序" class="fl my_issues_filter" disabled="disabled" style="width:50px;visibility:hidden;margin-left: 0px;margin-right: 0px;">
|
||||
<option value="0" selected="selected">排序</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
<% end %>
|
||||
<% if @issues.empty? %>
|
||||
<p class="nodata mt10"><%= l(:label_no_data) %></p>
|
||||
<% else %>
|
||||
<div id="issue_list">
|
||||
<%= render :partial => 'users/user_receive_issues_list', :locals => {:issues => @issues, :issue_pages => @issue_pages, :issue_count => @issue_count, :subject => @subject } %>
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
</div><!--issues_filter end-->
|
||||
<div id="issues_list_content_1">
|
||||
</div><!--issues_list_content_1 end-->
|
||||
<div id="issues_list_content_2" class="undis">
|
||||
</div><!--issues_list_content_2 end-->
|
||||
<div id="issues_list_content_3" class="undis">
|
||||
</div><!--issues_list_content_3 end-->
|
||||
<!--issues_con_list end-->
|
||||
|
||||
|
||||
<!--缺陷列表结束-->
|
||||
|
||||
<!--缺陷列表结束-->
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
$("#issue_filter_all").html("<%= escape_javascript(render :partial => 'users/my_issue_filter_all') %>");
|
||||
$("#issue_list").html("<%= escape_javascript(render :partial => 'users/user_receive_issues_list',:locals => {:issues => @issues, :issue_pages=> @issue_pages, :issue_count => @issue_count })%>");
|
||||
$("#issue_list_pagination").html('<%= pagination_links_full @issue_pages, @issue_count, :issues => @issues, :per_page_links => false, :remote => @is_remote, :flag => true, :is_new => true %>');
|
|
@ -738,6 +738,7 @@ RedmineApp::Application.routes.draw do
|
|||
get "user_resource"
|
||||
match "user_issues", :to => 'users#user_issues', :via => [:get, :post], :as => "user_issues"
|
||||
match "user_manage_issues", :to => 'users#user_manage_issues', :via => [:get, :post], :as => "user_manage_issues"
|
||||
match "user_receive_issues", :to => 'users#user_receive_issues', :via => [:get, :post], :as => "user_receive_issues"
|
||||
get "import_resources"
|
||||
get "import_resources_search"
|
||||
post "import_into_container"
|
||||
|
|
|
@ -248,6 +248,7 @@ h4{ font-size:14px;}/*color:#3b3b3b;*/
|
|||
.w56 {width:56px;}
|
||||
.w60{ width:60px;}
|
||||
.w61{ width:61px;}
|
||||
.w65{ width:65px;}
|
||||
.w70{ width:70px;}
|
||||
.w80{ width:80px;}
|
||||
.w90{ width:90px;}
|
||||
|
|
Loading…
Reference in New Issue