From bfe8f6800ff845aaa0881b006fa0ebb089bac12e Mon Sep 17 00:00:00 2001 From: p31729568 Date: Tue, 30 Apr 2019 16:18:28 +0800 Subject: [PATCH] fix css display issue && fix export school report error --- .../managements/schools/_data_contrast_list.html.erb | 9 ++++++--- app/views/managements/schools/statistics.html.erb | 4 ++-- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/app/views/managements/schools/_data_contrast_list.html.erb b/app/views/managements/schools/_data_contrast_list.html.erb index ef5b5b17..23893cb3 100644 --- a/app/views/managements/schools/_data_contrast_list.html.erb +++ b/app/views/managements/schools/_data_contrast_list.html.erb @@ -6,9 +6,12 @@ options_for_select(@select_options, params[:contrast_column]), class: 'fl task-height-30 contrast-column-select', style: 'position: absolute; right: 30px; top: 15px;' %> -
- 说明:新增数=时段二-时段一;新增百分比=(新增数/时段一)*100%(保留小数点后五位) -
+ + <% if @obj_count.nonzero? %> +
+ 说明:新增数=时段二-时段一;新增百分比=(新增数/时段一)*100%(保留小数点后五位) +
+ <% end %> <% if @obj_count.nonzero? %> diff --git a/app/views/managements/schools/statistics.html.erb b/app/views/managements/schools/statistics.html.erb index 5a68f75c..3aba8ab1 100644 --- a/app/views/managements/schools/statistics.html.erb +++ b/app/views/managements/schools/statistics.html.erb @@ -39,7 +39,7 @@ function exportSchoolStatistic(){ var form = $("#school_report_search_form") var exportLink = form.find(".export-statistic-btn"); - var keyword = form.find("input[name='keyword'").val(); - exportLink.attr("href", exportLink.attr("href") + "?keyword=" + keyword); + var keyword = form.find("input[name='keyword']").val(); + exportLink.attr("href", exportLink.attr("href").split('?')[0] + "?keyword=" + keyword); } \ No newline at end of file