Merge branch 'szzh' into dev_hjq

This commit is contained in:
huang 2015-08-11 15:27:38 +08:00
commit 6e5f6069bd
34 changed files with 318 additions and 81 deletions

View File

@ -39,9 +39,14 @@ class CoursesController < ApplicationController
else
@state = 5 #未登录
end
respond_to do |format|
format.js { render :partial => 'set_join', :locals => {:user => user, :course => course, :object_id => params[:object_id]} }
end
# if @state == 1 || @state == 3
# respond_to course_path(course.id)
# else
respond_to do |format|
format.js { render :partial => 'set_join', :locals => {:user => user, :course => course, :object_id => params[:object_id]} }
end
#end
rescue Exception => e
@state = 4 #已经加入了课程
respond_to do |format|

View File

@ -177,11 +177,11 @@ class FilesController < ApplicationController
def index
@flag = params[:flag] || false
#sort_init 'filename', 'asc'
sort_init 'created_on', 'desc'
sort_update 'created_on' => "#{Attachment.table_name}.created_on",
'filename' => "#{Attachment.table_name}.filename",
'size' => "#{Attachment.table_name}.filesize",
'downloads' => "#{Attachment.table_name}.downloads"
# sort_init 'created_on', 'desc'
# sort_update 'created_on' => "#{Attachment.table_name}.created_on",
# 'filename' => "#{Attachment.table_name}.filename",
# 'size' => "#{Attachment.table_name}.filesize",
# 'downloads' => "#{Attachment.table_name}.downloads"
sort = ""
@sort = ""
@order = ""

View File

@ -23,7 +23,7 @@ class HomeworkCommonController < ApplicationController
#
# @homework = HomeworkCommon.new
# @homework.safe_attributes = params[:homework_common]
# @homework.late_penalty = 0
# @homework.late_penalty = 2
# @homework.end_time = (Time.now + 3600 * 24).strftime('%Y-%m-%d')
# @homework.publish_time = Time.now.strftime('%Y-%m-%d')
#
@ -31,7 +31,7 @@ class HomeworkCommonController < ApplicationController
# #匿评作业相关属性
# @homework_detail_manual = HomeworkDetailManual.new
# @homework_detail_manual.ta_proportion = 0.6
# @homework_detail_manual.absence_penalty = 0
# @homework_detail_manual.absence_penalty = 2
# @homework_detail_manual.evaluation_num = 3
# @homework_detail_manual.evaluation_start = Time.now.strftime('%Y-%m-%d')
# @homework_detail_manual.evaluation_end = (Time.now + 3600 * 24).strftime('%Y-%m-%d')
@ -52,7 +52,7 @@ class HomeworkCommonController < ApplicationController
@homework = HomeworkCommon.new
@homework.safe_attributes = params[:homework_common]
@homework.late_penalty = 0
@homework.late_penalty = 2
@homework.end_time = (Time.now + 3600 * 24).strftime('%Y-%m-%d')
@homework.publish_time = Time.now.strftime('%Y-%m-%d')
@ -60,7 +60,7 @@ class HomeworkCommonController < ApplicationController
#匿评作业相关属性
@homework_detail_manual = HomeworkDetailManual.new
@homework_detail_manual.ta_proportion = 0.6
@homework_detail_manual.absence_penalty = 0
@homework_detail_manual.absence_penalty = 2
@homework_detail_manual.evaluation_num = 3
@homework_detail_manual.evaluation_start = Time.now.strftime('%Y-%m-%d')
@homework_detail_manual.evaluation_end = (Time.now + 3600 * 24).strftime('%Y-%m-%d')
@ -107,6 +107,7 @@ class HomeworkCommonController < ApplicationController
homework_test.input = v
homework_test.output = params[:output][k]
homework_test.result = params[:result][k]
homework_test.error_msg = params[:error_msg]
homework.homework_tests << homework_test
question[:input] << homework_test.input
question[:output] << homework_test.output
@ -231,11 +232,13 @@ class HomeworkCommonController < ApplicationController
homework_test.input = v
homework_test.output = params[:output][k]
homework_test.result = params[:result][k]
homework_test.error_msg = params[:error_msg]
else #不存在的测试,增加
homework_test = HomeworkTest.new
homework_test.input = v
homework_test.output = params[:output][k]
homework_test.result = params[:result][k]
homework_test.error_msg = params[:error_msg]
homework_test.homework_common = @homework
end
homework_test.save
@ -367,6 +370,7 @@ class HomeworkCommonController < ApplicationController
client.request(request)
end
result = JSON.parse(res.body)
@err_msg = result["compile_error_msg"]
result["results"].each do |re|
@result = re["status"]
end

View File

@ -72,7 +72,7 @@ class NewsController < ApplicationController
@news_count = scope.count
@q = params[:subject]
if params[:subject].nil?
if params[:subject].nil? || params[:subject].blank?
scope_order = scope.all(:include => [:author, :course],
:order => "#{News.table_name}.created_on DESC")
else

View File

@ -1,3 +1,4 @@
#encoding utf-8
class PollController < ApplicationController
before_filter :find_poll_and_course, :only => [:edit,:update,:destroy,:show,:statistics_result,:create_poll_question,:commit_poll,:commit_answer,:publish_poll,:republish_poll,:poll_result,:close_poll,:export_poll]
before_filter :find_container, :only => [:new,:create, :index]
@ -410,6 +411,70 @@ class PollController < ApplicationController
end
end
# 将其他地方的问卷导出来
def other_poll
# 查作者是我,或者作者是当前课程的老师,且不在当前课程内的问卷 进行导入
tea_ids = '('
tea_ids << Course.find(params[:polls_group_id]).tea_id.to_s << ','<< User.current.id.to_s << ')'
@polls = Poll.where("user_id in #{tea_ids} and polls_type = 'course' and polls_group_id != #{params[:polls_group_id]}")
@polls_group_id = params[:polls_group_id]
respond_to do |format|
format.js
end
end
# 将问卷导入本课程
def import_other_poll
course_id = params[:course_id]
@course = Course.find(course_id)
params[:polls].each_with_index do |p,i|
poll = Poll.find(p)
option = {
:polls_name => poll.polls_name || l(:label_poll_new),
:polls_type => 'Course',
:polls_group_id => course_id,
:polls_status => 1,
:user_id => User.current.id,
:published_at => Time.now,
:closed_at => Time.now,
:show_result => 1,
:polls_description => poll.polls_description
}
@poll = Poll.create option
poll.poll_questions.each do | q|
#question_title = params[:poll_questions_title].nil? || params[:poll_questions_title].empty? ? l(:label_enter_single_title) : params[:poll_questions_title]
option = {
:is_necessary => q[:is_necessary],
:question_title => q[:question_title],
:question_type => q[:question_type] || 1,
:question_number => q[:question_number]
}
@poll_questions = @poll.poll_questions.new option
for i in 1..q.poll_answers.count
answer = q.poll_answers[i-1].nil? ? l(:label_new_answer) : q.poll_answers[i-1][:answer_text]
question_option = {
:answer_position => i,
:answer_text => answer
}
@poll_questions.poll_answers.new question_option
end
end
@poll.save
end
@is_teacher = User.current.allowed_to?(:as_teacher,@course)
if @is_teacher
polls = Poll.where("polls_type = 'Course' and polls_group_id = #{@course.id}")
else
polls = Poll.where("polls_type = 'Course' and polls_group_id = #{@course.id} and polls_status = 2")
end
@polls = paginateHelper polls,20 #分页
respond_to do |format|
format.js
end
end
private
def find_poll_and_course
@poll = Poll.find params[:id]

View File

@ -262,9 +262,11 @@ class UsersController < ApplicationController
# modified by fq
def user_newfeedback
jours = @user.journals_for_messages.where('m_parent_id IS NULL').order('created_on DESC')
jours.update_all(:is_readed => true, :status => false)
jours.each do |journal|
fetch_user_leaveWord_reply(journal).update_all(:is_readed => true, :status => false)
if User.current == @user
jours.update_all(:is_readed => true, :status => false)
jours.each do |journal|
fetch_user_leaveWord_reply(journal).update_all(:is_readed => true, :status => false)
end
end
@jour = paginateHelper jours,10
@state = false

View File

@ -2378,4 +2378,26 @@ module ApplicationHelper
end
notice.html_safe
end
def stantard_code
"// 这是一个C语言的样例程序
//
//
// 123
// 347
//
//
// argv传入
//
#include <stdio.h> //引用必须头文件
int main(int argc, char** argv) {
int a = atoi(argv[1]); //
int b = atoi(argv[2]); //
printf(\"%d\",a+b); //输出a+b
return 0;
}".html_safe
end
end

View File

@ -66,4 +66,31 @@ module HomeworkCommonHelper
link
end
#将状态转换为错误信息
def status_to_err_msg status
case status.to_i
when -1
'编译出错'
when -2
'输入和输出不匹配'
when -3
'输入和输出不匹配'
when 1
'运行出错'
when 2
'超时'
when 3
'内存超出'
when 4
'输出超出'
when 5
'禁用函数'
when 6
'其他错误'
when 0
'成功'
else
'未知错误'
end
end
end

View File

@ -74,4 +74,13 @@ module PollHelper
end
end
#带勾选框的问卷列表
def poll_check_box_tags(name,polls,current_poll)
s = ''
polls.each do |poll|
s << "<label>#{ check_box_tag name, poll.id, false, :id => nil } #{h poll.polls_name.blank? ? l(:label_poll_new) : poll.polls_name } [#{ h Course.find(poll.polls_group_id).name}]</label><br/>"
end
s.html_safe
end
end

View File

@ -163,7 +163,7 @@ class Journal < ActiveRecord::Base
# Description 公共表中需要保存一份该记录
def act_as_forge_activity
self.forge_acts << ForgeActivity.new(:user_id => self.user_id,
:project_id => self.issue.project.id)
:project_id => self.issue.project.id)
end

View File

@ -258,7 +258,7 @@ class User < Principal
###添加留言 fq
def add_jour(user, notes, reference_user_id = 0, options = {})
if options.count == 0
self.journals_for_messages << JournalsForMessage.new(:user_id => user.id, :notes => notes, :reply_id => reference_user_id, :status => true)
self.journals_for_messages << JournalsForMessage.new(:user_id => user.id, :notes => notes, :reply_id => reference_user_id, :status => true, :is_readed => false)
else
jfm = self.journals_for_messages.build(options)
jfm.save
@ -291,9 +291,10 @@ class User < Principal
name
end
## end
# 查询用户未读过的记录
def count_new_jour
count = self.new_jours.count
count = self.journals_for_messages.where("status=? and is_readed = ? " ,1, 0).count
end
#added by nie

View File

@ -21,7 +21,7 @@
<img src="/images/pic_del.gif" width="11" height="12" alt="删除班级" title="删除该班级" />
</a>
<% end%>
<a href="javascript:void(0)" class="f_l" style="padding-left: 5px;" onclick="$('#group_name_<%= group.id %>').val('');$('#edit_group_<%= group.id %>').slideToggle();$('#new_group_name').hide();">
<a href="javascript:void(0)" class="f_l" style="padding-left: 5px;" onclick="$('#group_name_<%= group.id %>').val('<%= group.name%>');$('#edit_group_<%= group.id %>').slideToggle();$('#new_group_name').hide();">
<img src="/images/pic_edit.png" width="14" height="15" alt="编辑班级" />
</a>
<% end %>

View File

@ -6,12 +6,14 @@
alert("加入成功");
hideModal($("#popbox02"));
$("#try_join_course_link").replaceWith("<a href='<%=url_for(:controller => 'homework_common', :action => 'index',:course=>course.id, :host=>Setting.host_course)%>' target='_blank' class='blue_n_btn fr mt20'>提交作品</a>");
window.location.href= "http://"+"<%= Setting.host_name%>"+"/courses/" + "<%= course.id%>"
<% elsif @state == 1 %>
alert("密码错误");
<% elsif @state == 2 %>
alert("课程已过期\n请联系课程管理员重启课程。(在配置课程处)");
<% elsif @state == 3 %>
alert("您已经加入了课程");
window.location.href= "http://"+"<%= Setting.host_name%>"+"/courses/" + "<%= course.id%>"
<% elsif @state == 4 %>
alert("您加入的课程不存在");
<% elsif @state == 5 %>

View File

@ -78,7 +78,7 @@
<li >
<label class="label02">&nbsp;标准代码:&nbsp;</label>
<textarea name="standard_code" class=" w547 h150 mb10 fl" oninput="init_programing_test();" onpropertychange="init_programing_test()"><%= homework.homework_detail_programing.standard_code%></textarea>
<textarea name="standard_code" class=" w547 h350 mb10 fl" oninput="init_programing_test();" onpropertychange="init_programing_test()"><%= homework.homework_detail_programing.standard_code || stantard_code%></textarea>
<div class="cl"></div>
</li>
@ -98,7 +98,7 @@
<a class="icon_remove" href="javascript:void(0);" title="删除测试" onclick="remove_programing_test($(this).parent().parent())"></a>
<% if homework_test.result && !homework_test.result.to_s.empty?%>
<% if homework_test.result == 0%>
<a class="green_btn fl ml5 mt1 programing_test" onclick="programing_test('<%= homework_test.id%>')" id="test_send_<%= homework_test.id%>">成功</a>
<a class="green_btn fl ml5 mt1 programing_test" onclick="programing_test('<%= homework_test.id%>')" id="test_send_<%= homework_test.id%>">正确</a>
<% else%>
<a class="red_btn fl ml5 mt1 programing_test" onclick="programing_test('<%= homework_test.id%>')" id="test_send_<%= homework_test.id%>">错误</a>
<% end%>
@ -114,11 +114,11 @@
<div>
<li>
<label class="label02">&nbsp;测试输入:&nbsp;</label>
<input type="text" class="fl h26 w190 mb10" name="input[0]" />
<input type="text" class="fl h26 w190 mb10" name="input[0]" value="1 2"/>
</li>
<li >
<label class=" fl f14 ml10">&nbsp;输出:&nbsp;</label>
<input type="text" class="fl h26 w190 mb10" name="output[0]" />
<input type="text" class="fl h26 w190 mb10" name="output[0]" value="3"/>
</li>
<li>
<a class="icon_add ml10 " href="javascript:void(0);" title="添加测试" onclick="add_programing_test($(this).parent().parent())"></a>
@ -129,6 +129,21 @@
<div class="cl"></div>
</div>
<% end %>
<input type="hidden" name="error_msg" id="homework_test_error_msg" value="<%= homework.homework_tests.first.error_msg if homework.homework_tests.first && homework.homework_tests.first && homework.homework_tests.first.error_msg%>">
<table class="border_ce" cellpadding="0" cellspacing="0" id="homework_work_test_show" style="display: <%= homework.homework_tests.first && homework.homework_tests.first && homework.homework_tests.first.error_msg && !homework.homework_tests.first.error_msg.empty? ? "block" : "none"%>">
<tbody>
<tr class="border_t" >
<td class="td_end fb c_red w60 td_board_left">
错误信息:
</td>
<td class="td_end wl" id="homework_work_test_desc">
<% if homework.homework_tests.first && homework.homework_tests.first && homework.homework_tests.first.error_msg %>
<%= homework.homework_tests.first.error_msg%>
<% end%>
</td>
</tr>
</tbody>
</table>
</ul>
</div>

View File

@ -1,2 +1,12 @@
$("#test_send_<%= @index%>").replaceWith("<a class='<%= @result == 0 ? 'green_btn' : 'red_btn'%> fl ml5 mt1 programing_test' onclick='programing_test(<%= @index%>)' id='test_send_<%= @index%>'><%= @result == 0 ? '正确' : '错误'%></a>");
$("#test_result_<%= @index%>").val("<%= @result%>");
$("#test_result_<%= @index%>").val("<%= @result%>");
<% if @err_msg || @result != 0%>
$("#homework_work_test_show").show();
$("#homework_work_test_desc").text("<%= escape_javascript(@err_msg || status_to_err_msg(@result))%>");
<% if @err_msg%>
$("#homework_test_error_msg").val("<%= escape_javascript(@err_msg)%>");
<% end%>
<% else%>
$("#homework_work_test_show").hide();
$("#homework_test_error_msg").val("");
<% end%>

View File

@ -6,10 +6,12 @@
<li class="fl"><a href="javascript:void:(0);" class="f_grey mw20" target="_blank"><%= l(:label_recruitment_information)%></a>|</li>
<li class="fl"><a href="http://forge.trustie.net/forums/1/memos/1168" class="f_grey mw20" target="_blank"><%= l(:label_surpport_group)%></a>|</li>
<li class="fl"><a href="javascript:void:(0);" class="f_grey mw20" target="_blank"><%= l(:label_forums)%></a>|</li>
<li class="fl"><a href="javascript:void:(0);" class="f_grey ml20" target="_blank"><%= l(:label_language)%></a><select class="languageBox">
<option value="Chinese" selected="selected">中文</option>
<option value="English">英文</option>
</select></li>
<li class="fl"><a href="javascript:void:(0);" class="f_grey ml20" target="_blank"><%= l(:label_language)%></a>
<select class="languageBox">
<option value="Chinese" selected="selected">中文</option>
<option value="English">英文</option>
</select>
</li>
</ul>
</div>

View File

@ -180,7 +180,7 @@
</div><!--Content end-->
<div class="cl"></div>
<%= render :partial => 'layouts/base_footer_public' %>
<%= render :partial => 'layouts/new_footer' %>
<div class="cl"></div>
</div><!--Container end-->
<%= render :partial => 'layouts/new_feedback' %>

View File

@ -173,7 +173,7 @@
</div>
<div style="clear:both;"></div>
<div class="cl"></div>
<%= render :partial => 'layouts/base_footer_public'%>
<%= render :partial => 'layouts/new_footer'%>
<div class="cl"></div>
</div><!--Container end-->
<div id="light" class="white_content02">

View File

@ -169,7 +169,7 @@
<div class="cl"></div>
<div class="leftbox">
<div class="leftbox mt10">
<ul class="leftbox_ul_left">
<% if @user.user_extensions && @user.user_extensions.identity == 0 %>
<% if(get_create_course_count(@user)) != 0 %>
@ -271,7 +271,7 @@
</div><!--Content end-->
<div class="cl"></div>
<%= render :partial => 'layouts/base_footer_public'%>
<%= render :partial => 'layouts/new_footer'%>
<div class="cl"></div>
</div><!--Container end-->

View File

@ -0,0 +1,37 @@
<div id="popbox_upload" style="margin-top: -30px;margin-left: -20px;margin-right: -10px;">
<div class="upload_con">
<h2>选择问卷导入本课程</h2>
<div class="upload_box">
<div id="error_show" style="color: red;"></div>
<%= form_tag import_other_poll_poll_index_path,
method: :post,
remote: true,
id: "relation_file_form" do %>
<input type="hidden" name="course_id" value="<%= polls_group_id%>" />
<%= content_tag('div', poll_check_box_tags('polls[]', polls,polls_group_id), :id => 'courses',:style=> 'width: 300px;')%>
<a id="submit_quote" href="javascript:void(0)" class="blue_btn fl c_white" style="margin-left: 0px !important;" onclick="submit_quote();">导&nbsp;&nbsp;入</a>
<a href="javascript:void(0)" class="blue_btn grey_btn fl c_white " onclick="closeModal();">取&nbsp;&nbsp;消</a>
<% end -%>
</div>
</div>
</div>
<script>
function submit_quote() {
$('#error_show').html('');
var selected = false;
for(var i = 0; i < $("input[name='polls[]']").length;i++){
if($("input[name='polls[]']")[i].checked){
selected = true;
}
}
if (selected){
$('#submit_quote').parent().submit();
closeModal();
}else{
$('#error_show').html('您没有选择任何问卷');
}
}
</script>

View File

@ -41,6 +41,7 @@
<li class="polls_de_grey fr ml5">导出</li>
<% elsif poll.polls_status == 2 || poll.polls_status == 3 %>
<li><%= link_to "导出", export_poll_poll_path(poll.id,:format => "xls"), :class => "polls_de fr ml5"%></li>
<% end%>

View File

@ -3,20 +3,14 @@
<span><%= @obj_count%></span>
</h2>
<% if @is_teacher%>
<%= link_to "导入", other_poll_poll_index_path(:polls_group_id => @course.id), :remote=>true,:class => "newbtn"%>
<%= link_to l(:label_new_poll), new_poll_path(:polls_type => "Course",:polls_group_id => @course.id), :class => "newbtn" %>
<% end%>
</div>
<div class="cl"></div>
<div class="polls_list">
<% @polls.each do |poll|%>
<ul id="polls_<%= poll.id %>" class="polls_list_ul">
<%= render :partial => 'poll', :locals => {:poll => poll} %>
</ul>
<div class="cl"></div>
<% end%>
<div id="polls_list" class="polls_list">
<%= render :partial => 'polls_list', :locals => {:polls => @polls,:obj_pages=>@obj_pages,:obj_count=>@obj_count} %>
<ul class="wlist">
<%= pagination_links_full @obj_pages, @obj_count, :per_page_links => false, :remote => false, :flag => true%>
</ul>
<div class="cl"></div>
</div><!--列表end-->

View File

@ -0,0 +1,10 @@
<% polls.each do |poll|%>
<ul id="polls_<%= poll.id %>" class="polls_list_ul">
<%= render :partial => 'poll', :locals => {:poll => poll} %>
</ul>
<div class="cl"></div>
<% end%>
<ul class="wlist">
<%= pagination_links_full obj_pages, obj_count, :per_page_links => false, :remote => false, :flag => true%>
</ul>

View File

@ -0,0 +1 @@
$('#polls_list').html('<%= escape_javascript(render :partial => 'polls_list', :locals => {:polls => @polls,:obj_pages=>@obj_pages,:obj_count=>@obj_count}) %> <div class="cl"></div>');

View File

@ -80,6 +80,11 @@
$('#ajax-modal').parent().css("top","").css("left","");
$('#ajax-modal').parent().addClass("popbox_polls");
}
function closeModal()
{
hideModal($("#popbox_upload"));
}
</script>
<div class="polls_content02" id="polls">
<%= render :partial => 'poll_list'%>

View File

@ -0,0 +1,13 @@
<% if @polls.empty? %>
alert('您目前还没有自己新建的问卷');
<% else %>
$('#ajax-modal').html('<%= escape_javascript(render :partial => 'other_poll',:locals => {:polls => @polls,:polls_group_id=>@polls_group_id}) %>');
showModal('ajax-modal', '513px');
$('#ajax-modal').siblings().remove();
$('#ajax-modal').before("<a href='javascript:void(0)' onclick='closeModal()' style='margin-left: 480px;'><img src='/images/bid/close.png' width='26px' height='26px' /></a>");
$('#ajax-modal').parent().css("top","").css("left","");
$('#ajax-modal').parent().addClass("popbox_polls");
<% end %>

View File

@ -44,7 +44,7 @@
</p>
<div class="cl"></div>
<p id="about_project" class="about_project" >
<label class="fl">&nbsp;&nbsp;&nbsp;关联项目&nbsp;&nbsp;&nbsp;&nbsp;</label>
<label class="fl">&nbsp;&nbsp;&nbsp;选择项目&nbsp;&nbsp;&nbsp;&nbsp;</label>
<%= f.select :project_id,options_for_select(user_projects_option), {},{:class => "bo02 mb10"} %>
</p>
<div class="cl"></div>
@ -54,7 +54,11 @@
<%= @homework.homework_type == 2 ? "提交代码" : "作品描述"%>
&nbsp;&nbsp;&nbsp;
</label>
<%= f.text_area "description", :class => "w620 hwork_txt ", :placeholder => "作品描述不能为空", :onkeyup => "regexStudentWorkDescription();"%>
<% if @homework.homework_type == 2%>
<%= f.text_area "description", :class => "w620 hwork_txt h350", :placeholder => "作品描述不能为空", :onkeyup => "regexStudentWorkDescription();", :value => stantard_code%>
<% else %>
<%= f.text_area "description", :class => "w620 hwork_txt", :placeholder => "作品描述不能为空", :onkeyup => "regexStudentWorkDescription();"%>
<% end%>
<div class="cl"></div>
<p id="student_work_description_textarea" class="c_red ml90 mb10"></p>
</p>

View File

@ -10,7 +10,7 @@
</span>
<a href="<%= user_path(rec[:item].user.id) %>" class="c_orange course_name fl mr5" title="<%= rec[:item].user.show_name %>"><%= rec[:item].user.show_name %></a>
<span class="fl mr5 c_grey"><%= get_activity_opt(rec[:item],rec[:e]) %></span>
<% if( rec[:e].is_public == false || rec[:e].is_public == 0 ) %>
<% if(( rec[:e].is_public == false || rec[:e].is_public == 0 )&& !rec[:e].visible?)%>
<a href="<%= get_activity_url(rec[:item],rec[:e]) %>"
class="c_grey fl users_courses_txt hidepic"
title="<% if(rec[:item].activity_container_type=='Project')%><%='该项目是私有的,您无权查看。'%><% else %><%='该课程是私有的,您无权查看。' %><% end %>">

View File

@ -2058,22 +2058,22 @@ zh:
lable_unset: 未设置
label_chose_group: 请选择分班
label_hosted_organization: 主办单位
label_hosted_by: 国防科学技术大学并行与分布处理国家重点实验室
label_sponsor: 计算机科学与技术系
label_partners: 合作单位
label_co_organizer_NUDT: 国防科学技术大学计算机学院
label_co_organizer_EECS: 北京大学
label_co_organizer_BHU: 北京航空航天大学
label_co_organizer_CAS: 中国科学院软件研究所
label_co_organizer_InforS: 中创软件
label_rights_reserved: Copyright 2007~2015, All Rights Riserved
label_about_us: 关于我们
label_contact_us: 联系我们
label_recruitment_information: 招聘信息
label_surpport_group: 帮助中心
label_forums: 论坛反馈
label_language: 语言
label_license: 湘ICP备09019772
# label_hosted_organization: 主办单位
# label_hosted_by: 国防科学技术大学并行与分布处理国家重点实验室
# label_sponsor: 计算机科学与技术系
# label_partners: 合作单位
# label_co_organizer_NUDT: 国防科学技术大学计算机学院
# label_co_organizer_EECS: 北京大学
# label_co_organizer_BHU: 北京航空航天大学
# label_co_organizer_CAS: 中国科学院软件研究所
# label_co_organizer_InforS: 中创软件
# label_rights_reserved: Copyright 2007~2015, All Rights Riserved
# label_about_us: 关于我们
# label_contact_us: 联系我们
# label_recruitment_information: 招聘信息
# label_surpport_group: 帮助中心
# label_forums: 论坛反馈
# label_language: 语言
# label_license: 湘ICP备09019772

View File

@ -83,10 +83,13 @@ RedmineApp::Application.routes.draw do
get 'close_poll'
get 'export_poll'
get 'import_poll'
end
collection do
delete 'delete_poll_question'
post 'update_poll_question'
get 'other_poll'
post 'import_other_poll'
end
end

View File

@ -226,6 +226,7 @@ a:hover.ping_sub{ background:#14a8b9;}
.w430{ width:470px;}
.w557{ width:557px;}
.w350{ width:350px;}
.h350{height: 350px !important;}
.w620{ width:480px; height:160px; border:1px solid #CCC;}
.bo{height:26px; border:1px solid #CCC; padding-left:5px; background:#fff;width:470px; }
.bo02{height:26px; border:1px solid #CCC; padding-left:5px; background:#fff;width:480px; margin-left:2px; color: #999; }
@ -694,6 +695,9 @@ a.work_list_tit{width:580px; display:block; overflow:hidden; font-size:14px; f
.border_l{border-left:1px solid #e4e4e4;}
.border_t{ border-top:1px solid #e4e4e4;}
.td_end{border-top:1px solid #e4e4e4; height:auto; padding:5px; }
.wl{text-align: left;}
.vt{vertical-align: top;}
.td_board_left{border-right: 1px solid #e4e4e4;}
.c_w{ color:#fff;}
.filename { background: url(../images/pic_file.png) 0 -25px no-repeat;color: #3ca5c6;max-width: 150px;border: none; padding-left: 20px;margin-right: 10px;margin-bottom: 5px; white-space: nowrap; text-overflow:ellipsis;}
@ -709,6 +713,7 @@ a:hover.about_me{ color:#0781b4;}
.mb5 li{width:200px;word-wrap: break-word;
word-break: normal;
}
#homework_work_test_show{margin-left: 35px;width: 94%;}

View File

@ -130,7 +130,7 @@ a:hover.btn_de{ background:#ff5d31;}
a.btn_pu{ border:1px solid #3cb761; color:#3cb761; }
a:hover.btn_pu{ background:#3cb761;}
.pollsbtn_grey{ border:1px solid #b1b1b1; color:#b1b1b1; padding:0px 9px; height:19px; padding-top:3px; }
.polls_title_w { width:300px; overflow: hidden;white-space: nowrap;text-overflow: ellipsis;}
.polls_title_w { width:280px; overflow: hidden;white-space: nowrap;text-overflow: ellipsis;}
.polls_title_st { max-width:530px; overflow: hidden;white-space: nowrap;text-overflow: ellipsis;}
.polls_de_grey{ color:#b1b1b1; margin-top:3px;}
.ml5{ margin-left:5px;}

View File

@ -459,11 +459,11 @@ img,embed{max-width: 100%;}
.ke-container-default{max-width: 100%;}
/*底部*/
#Footer{background-color:#ffffff; margin-bottom:10px; padding-bottom:15px; color:#666666;}
.footerAboutContainer {width:auto; border-bottom:1px solid #efefef;}
.footerAbout{ width:585px; margin:0 auto;height:35px; line-height:35px; border-bottom:1px solid #efefef; }
.languageBox {width:55px; height:20px; margin-left:5px; outline:none; color:#666666; border:1px solid #d9d9d9;}
.departments{ width:890px; margin:5px auto 0 auto;height:30px;line-height:30px;}
.copyright{ width:390px; margin:0 auto;height:20px;line-height:20px;}
a.f_grey {color:#666666;}
a.f_grey:hover {color:#000000;}
/*#Footer{background-color:#ffffff; margin-bottom:10px; padding-bottom:15px; color:#666666;}*/
/*.footerAboutContainer {width:auto; border-bottom:1px solid #efefef;}*/
/*.footerAbout{ width:585px; margin:0 auto;height:35px; line-height:35px; border-bottom:1px solid #efefef; }*/
/*.languageBox {width:55px; height:20px; margin-left:5px; outline:none; color:#666666; border:1px solid #d9d9d9;}*/
/*.departments{ width:890px; margin:5px auto 0 auto;height:30px;line-height:30px;}*/
/*.copyright{ width:390px; margin:0 auto;height:20px;line-height:20px;}*/
/*a.f_grey {color:#666666;}*/
/*a.f_grey:hover {color:#000000;}*/

View File

@ -436,12 +436,12 @@ a:hover.box_close{background:url(../images/img_floatbox.png) -22px 0 no-repeat;}
div.ke-statusbar{height:1px; border-top:none;}
/*底部*/
#Footer{background-color:#ffffff; margin-bottom:10px; padding-bottom:15px; color:#666666;}
.footerAboutContainer {width:auto; border-bottom:1px solid #efefef;}
.footerAbout{ width:585px; margin:0 auto;height:35px; line-height:35px; border-bottom:1px solid #efefef; }
.languageBox {width:55px; height:20px; margin-left:5px; outline:none; color:#666666; border:1px solid #d9d9d9;}
.departments{ width:890px; margin:5px auto 0 auto;height:30px;line-height:30px;}
.copyright{ width:390px; margin:0 auto;height:20px;line-height:20px;}
a.f_grey {color:#666666;}
a.f_grey:hover {color:#000000;}
/*#Footer{background-color:#ffffff; margin-bottom:10px; padding-bottom:15px; color:#666666;}*/
/*.footerAboutContainer {width:auto; border-bottom:1px solid #efefef;}*/
/*.footerAbout{ width:585px; margin:0 auto;height:35px; line-height:35px; border-bottom:1px solid #efefef; }*/
/*.languageBox {width:55px; height:20px; margin-left:5px; outline:none; color:#666666; border:1px solid #d9d9d9;}*/
/*.departments{ width:890px; margin:5px auto 0 auto;height:30px;line-height:30px;}*/
/*.copyright{ width:390px; margin:0 auto;height:20px;line-height:20px;}*/
/*a.f_grey {color:#666666;}*/
/*a.f_grey:hover {color:#000000;}*/