commit
deb3383ad9
@ -0,0 +1,7 @@
|
|||||||
|
class CourseActivity < ActiveRecord::Base
|
||||||
|
attr_accessible :user_id, :course_act_id,:course_act_type,:course_id
|
||||||
|
# 虚拟关联
|
||||||
|
belongs_to :course_act ,:polymorphic => true
|
||||||
|
belongs_to :course
|
||||||
|
belongs_to :user
|
||||||
|
end
|
@ -0,0 +1,50 @@
|
|||||||
|
<h3 style="float: left">
|
||||||
|
<%=l(:label_school_plural)%>
|
||||||
|
</h3>
|
||||||
|
<%= form_tag({:controller => 'admin', :action => 'schools' }, :method => :get,:id=>"search_course_form") do %>
|
||||||
|
<%= submit_tag "搜索",:style => "float: right;margin-right: 15px;"%>
|
||||||
|
<input style="float: right;margin-right: 10px;" id="v_subject" placeholder="学校名称" type="text" name="school_name" value="<%= @school_name%>">
|
||||||
|
<% end %>
|
||||||
|
<div class="cl"></div>
|
||||||
|
|
||||||
|
<div class="autoscroll" style="margin-top: 40px;">
|
||||||
|
<table class="list" style="width: 100%;table-layout: fixed">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th style="width: 50px;">
|
||||||
|
序号
|
||||||
|
</th>
|
||||||
|
<th style="width: 100px;">
|
||||||
|
LOGO
|
||||||
|
</th>
|
||||||
|
<th>
|
||||||
|
学校名称
|
||||||
|
</th>
|
||||||
|
<th style="width: 100px;"></th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<% @schools.each do |school|%>
|
||||||
|
<tr class="<%= cycle("odd", "even") %>">
|
||||||
|
<td style="text-align:center;vertical-align: middle;">
|
||||||
|
<%= school.id %>
|
||||||
|
</td>
|
||||||
|
<td align="center">
|
||||||
|
<%= image_tag(school.logo_link,width:40,height:40) %>
|
||||||
|
</td>
|
||||||
|
<td style="text-align:center;vertical-align: middle;white-space: nowrap;overflow: hidden;text-overflow: ellipsis;" class="name" title='<%=school.name%>'>
|
||||||
|
<span>
|
||||||
|
<%= link_to school.name,"http://#{Setting.host_course}/?school_id=#{school.id}" %>
|
||||||
|
</span>
|
||||||
|
</td>
|
||||||
|
<td class="buttons" style="vertical-align: middle;">
|
||||||
|
<%= link_to("修改", upload_logo_school_path(school.id,:school_name => @school_name), :class => 'icon icon-copy') %>
|
||||||
|
<%#= link_to(l(:button_delete), organization_path(school.id), :method => :delete,:confirm => l(:text_are_you_sure), :class => 'icon icon-del') %>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<% end%>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<% html_title(l(:label_project_plural)) -%>
|
@ -0,0 +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%>");
|
||||||
|
<% 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%>
|
@ -0,0 +1,46 @@
|
|||||||
|
<div id="Footer">
|
||||||
|
<div class="footerAboutContainer">
|
||||||
|
<ul class="footerAbout">
|
||||||
|
<li class="fl"><a href="javascript:void:(0);" class="f_grey mw20" target="_blank"><%= l(:label_about_us)%></a>|</li>
|
||||||
|
<li class="fl"><a href="http://forge.trustie.net/projects/2/feedback" class="f_grey mw20" target="_blank"><%= l(:label_contact_us)%></a>|</li>
|
||||||
|
<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>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="cl"></div>
|
||||||
|
<ul class="departments">
|
||||||
|
<li class="fl mr10">
|
||||||
|
<strong><%= l(:label_hosted_organization)%></strong><a href="http://www.nudt.edu.cn/ArticleShow.asp?ID=47" class=" ml10 f_grey" target="_blank"><%= l(:label_hosted_by)%></a>
|
||||||
|
</li>
|
||||||
|
<li class="fl">
|
||||||
|
<a href="http://www.nudt.edu.cn/ArticleShow.asp?ID=41" class="mr45 f_grey" target="_blank"><%= l(:label_sponsor)%></a>
|
||||||
|
</li>
|
||||||
|
<li class="fl mr10">
|
||||||
|
<strong><%= l(:label_partners)%></strong><a href="http://eecs.pku.edu.cn" class="ml10 f_grey" target="_blank"><%= l(:label_co_organizer_EECS)%></a>
|
||||||
|
</li>
|
||||||
|
<li class="fl">
|
||||||
|
<a href="http://scse.buaa.edu.cn/" class="mr10 f_grey" target="_blank"><%= l(:label_co_organizer_BHU)%></a>
|
||||||
|
</li>
|
||||||
|
<li class="fl">
|
||||||
|
<a href="http://www.iscas.ac.cn/" class="mr10 f_grey" target="_blank"><%= l(:label_co_organizer_CAS)%></a>
|
||||||
|
</li>
|
||||||
|
<li class="fl">
|
||||||
|
<a href="http://www.inforbus.com/" class="f_grey" target="_blank"><%= l(:label_co_organizer_InforS)%></a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
<div class="cl"></div>
|
||||||
|
<ul class="copyright">
|
||||||
|
<li class="fl"><%= l(:label_rights_reserved)%></li>
|
||||||
|
<span class="fl mw15">|</span>
|
||||||
|
<li class="fl"><a href="http://www.miibeian.gov.cn/" class="fl f_grey" target="_blank"><%= l(:label_license)%></a></li>
|
||||||
|
</ul>
|
||||||
|
</div><!--Footer end-->
|
||||||
|
<div class="cl"></div>
|
@ -1,8 +1,11 @@
|
|||||||
<% if(User.current.logged? && User.current!=target)%>
|
<% if User.current.logged?%>
|
||||||
<%if(target.watched_by?(User.current))%>
|
<% if User.current == target%>
|
||||||
<a id="user_watch_id" href="<%= watch_path(:object_type=>
|
<a href="<%= url_for(:controller => 'my', :action => 'account') %>" class="fr gz_btn mr10 ">编辑资料</a>
|
||||||
'user',:object_id=>target.id,:target_id=>target.id) %>" class="fr qx_btn mr10" data-method="delete" data-remote="true" title="取消关注">取消关注</a>
|
<%else%>
|
||||||
<% else %>
|
<%if(target.watched_by?(User.current))%>
|
||||||
<a id="user_watch_id" href="<%= watch_path(:object_type=>'user',:object_id=>target.id,:target_id=>target.id) %>" class="fr gz_btn mr10" data-method="post" data-remote="true" title="添加关注">关注</a>
|
<a id="user_watch_id" href="<%= watch_path(:object_type=> 'user',:object_id=>target.id,:target_id=>target.id) %>" class="fr qx_btn mr10" data-method="delete" data-remote="true" title="取消关注">取消关注</a>
|
||||||
<% end %>
|
<% else %>
|
||||||
|
<a id="user_watch_id" href="<%= watch_path(:object_type=>'user',:object_id=>target.id,:target_id=>target.id) %>" class="fr gz_btn mr10" data-method="post" data-remote="true" title="添加关注">添加关注</a>
|
||||||
|
<% end %>
|
||||||
|
<% end%>
|
||||||
<% end %>
|
<% end %>
|
@ -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();">导 入</a>
|
||||||
|
<a href="javascript:void(0)" class="blue_btn grey_btn fl c_white " onclick="closeModal();">取 消</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>
|
@ -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>
|
@ -1,5 +1,8 @@
|
|||||||
|
|
||||||
<div class="ur_page_head ur_editor02" ><!--头部显示 start-->
|
<div class="ur_page_head ur_editor02" ><!--头部显示 start-->
|
||||||
|
|
||||||
<a href="javascript:" class="ur_icon_edit" title="编辑" onclick="pollsEdit();"></a>
|
<a href="javascript:" class="ur_icon_edit" title="编辑" onclick="pollsEdit();"></a>
|
||||||
|
<!-- <a class='ur_icon_add' title='导入' id="import_btn" onclick="importPoll();"></a> -->
|
||||||
<h1 class="ur_page_title" id="polls_name_h"><%= poll.polls_name%></h1>
|
<h1 class="ur_page_title" id="polls_name_h"><%= poll.polls_name%></h1>
|
||||||
<%= @poll.polls_description.nil? ? "" : @poll.polls_description.html_safe%>
|
<%= @poll.polls_description.nil? ? "" : @poll.polls_description.html_safe%>
|
||||||
<div class="cl"></div>
|
<div class="cl"></div>
|
||||||
|
@ -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>');
|
@ -0,0 +1,4 @@
|
|||||||
|
/**
|
||||||
|
* Created by lizanle on 2015/7/29.
|
||||||
|
*/
|
||||||
|
$("#poll_content").html('<%= escape_javascript(render :partial => 'poll_content', :locals => {:poll => @poll})%>');
|
@ -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 %>
|
@ -1,77 +0,0 @@
|
|||||||
<div class="project_r_h">
|
|
||||||
<h2 class="project_h22"><%= l(:label_project_dts_new) %></h2>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!--JS进度条-->
|
|
||||||
<style type="text/css">
|
|
||||||
#out{}
|
|
||||||
#in{width:10px; height:20px;background:#15BCCF;color:white;text-align:center;}
|
|
||||||
#font_color{background:yellow;text-align:center;color:white;}
|
|
||||||
td.redBox {border:1px solid #b0b0b0; width:80px; background-color:#EAEAEA; }
|
|
||||||
td.redBox2 {border:1px solid #b0b0b0; width:120px; }
|
|
||||||
</style>
|
|
||||||
<div style="padding-left: 200px;">
|
|
||||||
<div id='out'>
|
|
||||||
<p style="padding-left: 100px;padding-bottom: 10px;font-size: 14px;">代码上传分析中...</p>
|
|
||||||
<div style="width:300px;height:20px;background:#EEE;">
|
|
||||||
<div id="in" style="width:1%">1%</div>
|
|
||||||
<div>
|
|
||||||
<script type="text/javascript">
|
|
||||||
i=0;
|
|
||||||
$(function(){
|
|
||||||
ba=setInterval("begin()",70);//setInterval 返回的是一个全局变量,一个间隔数值.这个数值是表示调用setInterval的次数
|
|
||||||
});
|
|
||||||
function begin()
|
|
||||||
{
|
|
||||||
i+=1;
|
|
||||||
if(i<=100)
|
|
||||||
{
|
|
||||||
document.getElementById("in").style.width=i+"%";
|
|
||||||
document.getElementById("in").innerHTML=i+"%";}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
clearInterval(ba);
|
|
||||||
$("#show_content_div").show();
|
|
||||||
$("#out").hide();
|
|
||||||
// document.getElementById("out").style.display="none";
|
|
||||||
// document.write("<span style='background:yellow;text-align:center;color:white;'>Successs!</span>");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
</script>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div id="show_content_div" style="display: none;padding-top: 0px;">
|
|
||||||
<p class="fr f14 " style="padding-right: 32px;padding-bottom: 10px;">语言:<span style="color: red">Java</span> 总文件数:<span style="color: red">361</span> 代码行数:<span style="color: red">48662</span></p>
|
|
||||||
|
|
||||||
<% @dts.each do |dt| %>
|
|
||||||
<div style="padding-left: 35px;padding-top: 10px;">
|
|
||||||
<table width="600" border="0" style="padding-left: 30px;padding-top: 100px; border-spacing:0; border-collapse:collapse; border: 1px solid #b0b0b0;">
|
|
||||||
<tr>
|
|
||||||
<td align="center" class="redBox">错误变量</td>
|
|
||||||
<td class="redBox2"> <%= dt.Variable %></td>
|
|
||||||
<td align="center" class="redBox">起始行</td>
|
|
||||||
<td class="redBox2"> <%= dt.StartLine %></td>
|
|
||||||
<td align="center" class="redBox">IP行</td>
|
|
||||||
<td class="redBox2"> <%= dt.IPLine %></td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td align="center" class="redBox">缺陷代码</td>
|
|
||||||
<td colspan="5" class="redBox2"> <%= dt.IPLineCode %></td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td align="center" class="redBox">错误描述</td>
|
|
||||||
<td colspan="5" class="redBox2"> <%= dt.Description %></td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td align="center" class="redBox">文件</td>
|
|
||||||
<td colspan="5" class="redBox2"> <%= dt.File %></td>
|
|
||||||
</tr>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
</div>
|
|
@ -1,3 +0,0 @@
|
|||||||
<div class="project_r_h">
|
|
||||||
<h2 class="project_h2"><%= l(:label_project_dts) %></h2>
|
|
||||||
</div>
|
|
@ -1,46 +0,0 @@
|
|||||||
<div class="project_r_h">
|
|
||||||
<h2 class="project_h22"><%= l(:label_project_soft_file) %></h2>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!--JS进度条-->
|
|
||||||
<style type="text/css">
|
|
||||||
#out{}
|
|
||||||
#in{width:10px; height:20px;background:#15BCCF;color:white;text-align:center;}
|
|
||||||
#font_color{background:yellow;text-align:center;color:white;}
|
|
||||||
</style>
|
|
||||||
<div style="padding-left: 200px;">
|
|
||||||
<div id='out'>
|
|
||||||
<p style="padding-left: 100px;padding-bottom: 10px;font-size: 14px;">软件资源库部署中...</p>
|
|
||||||
<div style="width:300px;height:20px;background:#EEE;">
|
|
||||||
<div id="in" style="width:1%">0%</div>
|
|
||||||
<div>
|
|
||||||
<script type="text/javascript">
|
|
||||||
i=0;
|
|
||||||
$(function(){
|
|
||||||
ba=setInterval("begin()",30);//setInterval 返回的是一个全局变量,一个间隔数值.这个数值是表示调用setInterval的次数
|
|
||||||
});
|
|
||||||
function begin()
|
|
||||||
{
|
|
||||||
i+=1;
|
|
||||||
if(i<=100)
|
|
||||||
{
|
|
||||||
document.getElementById("in").style.width=i+"%";
|
|
||||||
document.getElementById("in").innerHTML=i+"%";}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
clearInterval(ba);
|
|
||||||
$("#show_content_div").show();
|
|
||||||
$("#out").hide();
|
|
||||||
// document.getElementById("out").style.display="none";
|
|
||||||
// document.write("<span style='background:yellow;text-align:center;color:white;'>Successs!</span>");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div id="show_content_div" style="display: none;padding-top: 0px;">
|
|
||||||
<p class="pl10 f14 "><a href="http://rubyblog.forge.trustie.net/myblog">云化部署工具部署完后的网址</a></p>
|
|
||||||
</div>
|
|
@ -1,46 +0,0 @@
|
|||||||
<div class="project_r_h">
|
|
||||||
<h2 class="project_h22"><%= l(:label_project_soft_knowledge) %></h2>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!--JS进度条-->
|
|
||||||
<style type="text/css">
|
|
||||||
#out{}
|
|
||||||
#in{width:10px; height:20px;background:#15BCCF;color:white;text-align:center;}
|
|
||||||
#font_color{background:yellow;text-align:center;color:white;}
|
|
||||||
</style>
|
|
||||||
<div style="padding-left: 200px;">
|
|
||||||
<div id='out'>
|
|
||||||
<p style="padding-left: 120px;padding-bottom: 10px;font-size: 14px;">云化部署中...</p>
|
|
||||||
<div style="width:300px;height:20px;background:#EEE;">
|
|
||||||
<div id="in" style="width:1%">0%</div>
|
|
||||||
<div>
|
|
||||||
<script type="text/javascript">
|
|
||||||
i=0;
|
|
||||||
$(function(){
|
|
||||||
ba=setInterval("begin()",30);//setInterval 返回的是一个全局变量,一个间隔数值.这个数值是表示调用setInterval的次数
|
|
||||||
});
|
|
||||||
function begin()
|
|
||||||
{
|
|
||||||
i+=1;
|
|
||||||
if(i<=100)
|
|
||||||
{
|
|
||||||
document.getElementById("in").style.width=i+"%";
|
|
||||||
document.getElementById("in").innerHTML=i+"%";}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
clearInterval(ba);
|
|
||||||
$("#show_content_div").show();
|
|
||||||
$("#out").hide();
|
|
||||||
// document.getElementById("out").style.display="none";
|
|
||||||
// document.write("<span style='background:yellow;text-align:center;color:white;'>Successs!</span>");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div id="show_content_div" style="display: none;padding-top: 0px;">
|
|
||||||
<p class="pl10 f14 "><a href="http://rubyblog.forge.trustie.net/myblog">云化部署工具部署完后的网址</a></p>
|
|
||||||
</div>
|
|
@ -1,46 +0,0 @@
|
|||||||
<div class="project_r_h">
|
|
||||||
<h2 class="project_h22"><%= l(:label_project_soft_service) %></h2>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!--JS进度条-->
|
|
||||||
<style type="text/css">
|
|
||||||
#out{}
|
|
||||||
#in{width:10px; height:20px;background:#15BCCF;color:white;text-align:center;}
|
|
||||||
#font_color{background:yellow;text-align:center;color:white;}
|
|
||||||
</style>
|
|
||||||
<div style="padding-left: 200px;">
|
|
||||||
<div id='out'>
|
|
||||||
<p style="padding-left: 120px;padding-bottom: 10px;font-size: 14px;">云化部署中...</p>
|
|
||||||
<div style="width:300px;height:20px;background:#EEE;">
|
|
||||||
<div id="in" style="width:1%">0%</div>
|
|
||||||
<div>
|
|
||||||
<script type="text/javascript">
|
|
||||||
i=0;
|
|
||||||
$(function(){
|
|
||||||
ba=setInterval("begin()",30);//setInterval 返回的是一个全局变量,一个间隔数值.这个数值是表示调用setInterval的次数
|
|
||||||
});
|
|
||||||
function begin()
|
|
||||||
{
|
|
||||||
i+=1;
|
|
||||||
if(i<=100)
|
|
||||||
{
|
|
||||||
document.getElementById("in").style.width=i+"%";
|
|
||||||
document.getElementById("in").innerHTML=i+"%";}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
clearInterval(ba);
|
|
||||||
$("#show_content_div").show();
|
|
||||||
$("#out").hide();
|
|
||||||
// document.getElementById("out").style.display="none";
|
|
||||||
// document.write("<span style='background:yellow;text-align:center;color:white;'>Successs!</span>");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div id="show_content_div" style="display: none;padding-top: 0px;">
|
|
||||||
<p class="pl10 f14 "><a href="http://rubyblog.forge.trustie.net/myblog">云化部署工具部署完后的网址</a></p>
|
|
||||||
</div>
|
|
@ -1,47 +0,0 @@
|
|||||||
<div class="project_r_h">
|
|
||||||
<h2 class="project_h22"><%= l(:label_project_dts_yun) %></h2>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!--JS进度条-->
|
|
||||||
<style type="text/css">
|
|
||||||
#out{}
|
|
||||||
#in{}
|
|
||||||
#font_color{background:yellow;text-align:center;color:white;}
|
|
||||||
</style>
|
|
||||||
<div style="padding-left: 200px;">
|
|
||||||
<div id='out'>
|
|
||||||
<p style="padding-left: 100px;padding-bottom: 10px;font-size: 14px;padding-top: 10px;">云化部署中....</p>
|
|
||||||
<div>
|
|
||||||
<div id="in" style="width:0%"></div>
|
|
||||||
<div>
|
|
||||||
<script type="text/javascript">
|
|
||||||
i=0;
|
|
||||||
$(function(){
|
|
||||||
ba=setInterval("begin()",60);//setInterval 返回的是一个全局变量,一个间隔数值.这个数值是表示调用setInterval的次数
|
|
||||||
});
|
|
||||||
function begin()
|
|
||||||
{
|
|
||||||
i+=1;
|
|
||||||
if(i<=100)
|
|
||||||
{
|
|
||||||
document.getElementById("in").style.width="";
|
|
||||||
document.getElementById("in").innerHTML="";}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
clearInterval(ba);
|
|
||||||
$("#show_content_div").show();
|
|
||||||
$("#out").hide();
|
|
||||||
// document.getElementById("out").style.display="none";
|
|
||||||
// document.write("<span style='background:yellow;text-align:center;color:white;'>Successs!</span>");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div id="show_content_div" style="display: none;padding-top: 0px; ">
|
|
||||||
<p class="pl10 f14 "><span style="color: #7f7f7f;font-size: 14px; ">所部署服务的网址:</span>
|
|
||||||
<span><a href="http://rubyblog.forge.trustie.net/accounts/login" target="_Blank" style="color: #15BCCF;font-size: 14px;">http://rubyblog.forge.trustie.net/accounts/login</a></span></p>
|
|
||||||
</div>
|
|
@ -1,37 +1,30 @@
|
|||||||
<div class="project_r_h">
|
<div class="project_r_h">
|
||||||
<h2 class="project_h2"><%= l(:label_statistics) %></h2>
|
<h2 class="project_h2"><%= l(:label_statistics) %></h2>
|
||||||
</div>
|
</div>
|
||||||
<div class="riviseRed fl"></div><div class="fl">修订 是版本库的提交次数, 显示为橘红色。</div><br>
|
<% if @status_commit_count ==0 %>
|
||||||
<div class="changeBlue fl"></div><div class="fl">变更 是对版本库中文件的修改次数, 显示为蓝色。</div>
|
<div class="flash notice">该项目目前还没有提交过代码!</div>
|
||||||
<p style="padding-top:35px;">
|
<% else %>
|
||||||
<%= tag("embed", :width => 670, :height => 300, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "commits_per_month")) %>
|
<div class="riviseRed fl"></div><div class="fl">修订 是版本库的提交次数, 显示为橘红色。</div><br>
|
||||||
</p>
|
<div class="changeBlue fl"></div><div class="fl">变更 是对版本库中文件的修改次数, 显示为蓝色。</div>
|
||||||
<p style="padding-top: 50px;">
|
|
||||||
<%# 用户每月提交代码次数 %>
|
<p style="padding-top:35px;">
|
||||||
<%= tag("embed", :width => 670, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "commits_per_author")) %>
|
<%= tag("embed", :width => 670, :height => 300, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "commits_per_month")) %>
|
||||||
</p>
|
</p>
|
||||||
<p style="padding-top: 50px;">
|
<p style="padding-top: 50px;">
|
||||||
<%= tag("embed", :width => 670, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "author_commits_per_month")) %>
|
<%# 用户每月提交代码次数 %>
|
||||||
</p>
|
<%= tag("embed", :width => 670, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "commits_per_author")) %>
|
||||||
<p style="padding-top: 50px;">
|
</p>
|
||||||
<%# 用户每月提交代码量 %>
|
<p style="padding-top: 50px;">
|
||||||
<%= tag("embed", :width => 670, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "author_qoc_per_author")) %>
|
<%= tag("embed", :width => 670, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "author_commits_per_month")) %>
|
||||||
</p>
|
</p>
|
||||||
<p style="padding-top: 50px;">
|
<p style="padding-top: 50px;">
|
||||||
<%# 用户最近六个月的提交次数 %>
|
<%# 用户最近六个月的提交次数 %>
|
||||||
<%= tag("embed", :width => 670, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "author_commits_six_month")) %>
|
<%= tag("embed", :width => 670, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "author_commits_six_month")) %>
|
||||||
</p>
|
</p>
|
||||||
<p style="padding-top: 50px;">
|
<p style="padding-top: 50px;">
|
||||||
<%# 用户最近一年的提交次数 %>
|
<%# 用户最近六个月的代码量 %>
|
||||||
<%= tag("embed", :width => 670, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "author_qoc_per_author")) %>
|
<%= tag("embed", :width => 670, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "author_code_six_months")) %>
|
||||||
</p>
|
</p>
|
||||||
<p style="padding-top: 50px;">
|
<p><%= link_to l(:button_back), :action => 'show', :id => @project %></p>
|
||||||
<%# 用户最近六个月的代码量 %>
|
<% html_title(l(:label_repository), l(:label_statistics)) -%>
|
||||||
<%= tag("embed", :width => 670, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "author_code_six_months")) %>
|
<% end %>
|
||||||
</p>
|
|
||||||
<p style="padding-top: 50px;">
|
|
||||||
<%# 用户最近一年的代码量 %>
|
|
||||||
<%= tag("embed", :width => 670, :height => 400, :type => "image/svg+xml", :src => url_for(:controller => 'repositories', :action => 'graph', :id => @project, :repository_id => @repository.identifier_param, :graph => "author_code_year")) %>
|
|
||||||
</p>
|
|
||||||
<p><%= link_to l(:button_back), :action => 'show', :id => @project %></p>
|
|
||||||
<% html_title(l(:label_repository), l(:label_statistics)) -%>
|
|
@ -1,5 +1,28 @@
|
|||||||
<%= form_tag({action: :upload},method: "post", multipart: true) do %>
|
<script>
|
||||||
<%= text_field_tag 'school'%>
|
function showPreview(source) {
|
||||||
<%= file_field_tag 'logo' %>
|
var file = source.files[0];
|
||||||
<%= submit_tag('Upload') %>
|
if(window.FileReader) {
|
||||||
|
var fr = new FileReader();
|
||||||
|
fr.onloadend = function(e) {
|
||||||
|
document.getElementById("avatar_image").src = e.target.result;
|
||||||
|
};
|
||||||
|
fr.readAsDataURL(file);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<%= form_tag(upload_school_path(@school.id),method: "post", multipart: true) do %>
|
||||||
|
<%#= text_field_tag 'school'%>
|
||||||
|
<div style="margin: 20px;">
|
||||||
|
<input type="hidden" value="<%= @school_name%>" name="school_name">
|
||||||
|
<%= image_tag(@school.logo_link, id: "avatar_image", :class=>"school_avatar")%>
|
||||||
|
<a type="button" onclick="$('#file').click();" style="margin: 90px 0 0 10px;float: left;padding: 2px 5px;border: 1px solid #eaeaea;cursor: pointer;text-decoration: none;width: 55px;">上传图片</a>
|
||||||
|
<%= file_field_tag 'logo',:style => "display:none;", :id => "file", :onchange => "showPreview(this)"%>
|
||||||
|
<div style="clear: both;"></div>
|
||||||
|
<div style="margin-top: 10px;">
|
||||||
|
<%= submit_tag('上传') %>
|
||||||
|
<%= submit_tag('取消') %>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
|
@ -1,15 +1,6 @@
|
|||||||
<div id="tags_show">
|
<div id="tags">
|
||||||
<%= render :partial => "tags/tag_name",:locals => {:obj => obj,:non_list_all => false ,:object_flag => object_flag} %>
|
<div id="tags_show">
|
||||||
|
<%= render :partial => "tags/tag_project_new_name",:locals => {:obj => obj,:non_list_all => false ,:object_flag => object_flag} %>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<% if User.current.logged?%>
|
|
||||||
<a href="javascript:void(0)" class="yellowBtn f_l" onclick="$('#add_tag01').slideToggle();"><%= l(:label_add_tag)%></a>
|
|
||||||
<span id="add_tag01" style="display:none; vertical-align: middle;" class="ml10 f_l">
|
|
||||||
<%= form_for "tag_for_save",:remote=>true,:url=>save_tag_path,:update => "tags_show",:complete => '$("#put-tag-form").slideUp();' do |f| %>
|
|
||||||
<%= f.text_field :name ,:id => "tags_name",:size=>"20",:require=>true,:maxlength => Setting.tags_max_length,:minlength=>Setting.tags_min_length,:class =>"isTxt w90 f_l" %>
|
|
||||||
<%= f.text_field :object_id,:value=> obj.id,:style=>"display:none"%>
|
|
||||||
<%= f.text_field :object_flag,:value=> object_flag,:style=>"display:none"%>
|
|
||||||
<input type="button" class="submit f_l" onclick="$('#tags_name').parent().submit();" />
|
|
||||||
<% end %>
|
|
||||||
</span>
|
|
||||||
<% end%>
|
|
||||||
|
|
||||||
|
@ -0,0 +1,30 @@
|
|||||||
|
<% @tags = obj.reload.tag_list %>
|
||||||
|
<% if non_list_all && @tags.size > 0 %>
|
||||||
|
|
||||||
|
<% else %>
|
||||||
|
<!-- 用来显示三大对象的主页中的tag 故是全部显示 -->
|
||||||
|
<% if @tags.size > 0 %>
|
||||||
|
<% @tags.each do |tag| %>
|
||||||
|
<span class="re_tag f_l " id="tag">
|
||||||
|
<%= link_to tag, :controller => "tags", :action => "index", :q => tag, :object_flag => object_flag, :obj_id => obj.id, :class => 'pt5' %>
|
||||||
|
<span class="del">
|
||||||
|
<%= link_to('x', remove_tag_path(:tag_name => tag,:taggable_id => obj.id, :taggable_type => object_flag), :remote => true, :confirm => l(:text_are_you_sure) ) if (ProjectInfo.find_by_project_id(obj.id)).try(:user_id) == User.current.id %>
|
||||||
|
</span>
|
||||||
|
</span>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% if User.current.logged?%>
|
||||||
|
<a href="javascript:void(0)" class="yellowBtn f_l" onclick="$('#add_tag02').slideToggle();"><%= l(:label_add_tag)%></a>
|
||||||
|
<span id="add_tag02" style="display:none; vertical-align: middle;" class="ml10 f_l">
|
||||||
|
<%= form_for "tag_for_save",:remote => true,:url=>save_tag_path,:update => "tags_show",:complete => '$("#put-tag-form").slideUp();' do |f| %>
|
||||||
|
<%= f.text_field :name ,:id => "tags_name2",:size=>"20",:require=>true,:maxlength => Setting.tags_max_length,:minlength=>Setting.tags_min_length,:class =>"isTxt w90 f_l" %>
|
||||||
|
<%= f.text_field :object_id,:value=> obj.id,:style=>"display:none"%>
|
||||||
|
<%= f.text_field :object_flag,:value=> object_flag,:style=>"display:none"%>
|
||||||
|
<input type="button" class="submit f_l" onclick="$('#tags_name2').parent().submit();" />
|
||||||
|
<% end %>
|
||||||
|
</span>
|
||||||
|
<% end%>
|
||||||
|
|
||||||
|
|
@ -0,0 +1,30 @@
|
|||||||
|
<% @tags = obj.reload.tag_list %>
|
||||||
|
<% if non_list_all && @tags.size > 0 %>
|
||||||
|
|
||||||
|
<% else %>
|
||||||
|
<!-- 用来显示三大对象的主页中的tag 故是全部显示 -->
|
||||||
|
<% if @tags.size > 0 %>
|
||||||
|
<% @tags.each do |tag| %>
|
||||||
|
<span class="re_tag f_l " id="tag">
|
||||||
|
<%= link_to tag, :controller => "tags", :action => "index", :q => tag, :object_flag => object_flag, :obj_id => obj.id, :class => 'pt5' %>
|
||||||
|
<span class="del">
|
||||||
|
<%= link_to('x', remove_tag_path(:tag_name => tag,:taggable_id => obj.id, :taggable_type => object_flag), :remote => true, :confirm => l(:text_are_you_sure) ) if User.current.eql?(obj) %>
|
||||||
|
</span>
|
||||||
|
</span>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% if User.current.logged?%>
|
||||||
|
<a href="javascript:void(0)" class="yellowBtn f_l" onclick="$('#add_tag03').slideToggle();"><%= l(:label_add_tag)%></a>
|
||||||
|
<span id="add_tag03" style="display:none; vertical-align: middle;" class="ml10 f_l">
|
||||||
|
<%= form_for "tag_for_save",:remote => true,:url=>save_tag_path,:update => "tags_show",:complete => '$("#put-tag-form").slideUp();' do |f| %>
|
||||||
|
<%= f.text_field :name ,:id => "tags_name3",:size=>"20",:require=>true,:maxlength => Setting.tags_max_length,:minlength=>Setting.tags_min_length,:class =>"isTxt w90 f_l" %>
|
||||||
|
<%= f.text_field :object_id,:value=> obj.id,:style=>"display:none"%>
|
||||||
|
<%= f.text_field :object_flag,:value=> object_flag,:style=>"display:none"%>
|
||||||
|
<input type="button" class="submit f_l" onclick="$('#tags_name3').parent().submit();" />
|
||||||
|
<% end %>
|
||||||
|
</span>
|
||||||
|
<% end%>
|
||||||
|
|
||||||
|
|
@ -0,0 +1,5 @@
|
|||||||
|
<div id="tags">
|
||||||
|
<div id="tags_show">
|
||||||
|
<%= render :partial => "tags/tag_user_new_name",:locals => {:obj => obj,:non_list_all => false ,:object_flag => object_flag} %>
|
||||||
|
</div>
|
||||||
|
</div>
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue