|
|
|
@ -102,83 +102,6 @@
|
|
|
|
|
<%= render :partial => 'layouts/footer' %>
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div id="light" class="white_content02">
|
|
|
|
|
<!-- 这里写需弹出框的HTML代码 -->
|
|
|
|
|
<% text = @project.project_new_type == 1 ? "development_group" : (@project.project_new_type == 2 ? "research_group" : "friend_organization")%>
|
|
|
|
|
<div ><a href="javascript:void(0)" onClick="close_window('<%= text%>');" class="box_close" id="close_light"></a></div>
|
|
|
|
|
<div class=" mt10">
|
|
|
|
|
<h3 class="mb10 c_blue">请选择项目类型:</h3>
|
|
|
|
|
<ul class="mb10" id="project_type">
|
|
|
|
|
<li><input type="radio" name="project_type" <%= @project.project_new_type == 1 ? 'checked' : ''%> id="development_group"/><label class="f14"> 开发模式:<span class="f12 ml5 c_grey">面向小组开发,支持问题跟踪、代码托管、论坛交流等所有功能。</span></label></li>
|
|
|
|
|
<li><input type="radio" name="project_type" <%= @project.project_new_type == 2 ? 'checked' : ''%> id="research_group"/><label class="f14"> 研讨模式:<span class="f12 ml5 c_grey">面向小组研究,支持任务分工、论坛交流、资源分享等。</span></label></li>
|
|
|
|
|
<li><input type="radio" name="project_type" <%= @project.project_new_type == 3 ? 'checked' : ''%> id="friend_organization"/><label class="f14"> 圈子模式:<span class="f12 ml5 c_grey">面向好友分享,支持论坛交流、资源分享等。</span></label></li>
|
|
|
|
|
</ul>
|
|
|
|
|
<a href="javascript:void(0)" class="orange_btn" onclick="click_ok('<%= change_project_type_project_path @project%>');" >确定</a>
|
|
|
|
|
</div>
|
|
|
|
|
<!--项目的三种类型-->
|
|
|
|
|
<script type="text/javascript">
|
|
|
|
|
function click_ok(url)
|
|
|
|
|
{
|
|
|
|
|
$('#light').css('display','none');
|
|
|
|
|
$('#fade').css('display','none');
|
|
|
|
|
//ajax处理请求
|
|
|
|
|
var project_type;
|
|
|
|
|
if($("#development_group").attr("checked") == "checked"){
|
|
|
|
|
project_type = 1;
|
|
|
|
|
}
|
|
|
|
|
else if($("#research_group").attr("checked") == "checked"){
|
|
|
|
|
project_type = 2;
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
else if($("#friend_organization").attr("checked") == "checked"){
|
|
|
|
|
project_type = 3;
|
|
|
|
|
}
|
|
|
|
|
$.get(
|
|
|
|
|
url,
|
|
|
|
|
{ project_type: project_type},
|
|
|
|
|
function (data) {
|
|
|
|
|
if(data == 1)
|
|
|
|
|
{
|
|
|
|
|
$("#setting_project_type").replaceWith("<%= escape_javascript(project_type_link(l(:label_development_team), 1))%>");
|
|
|
|
|
$("#project_memu_list").html('<%= escape_javascript(render(:partial => 'projects/development_group', :locals => {:project => @project})) %>');
|
|
|
|
|
$("#close_light").attr("onClick","close_window('development_group');");
|
|
|
|
|
}
|
|
|
|
|
else if(data == 2)
|
|
|
|
|
{
|
|
|
|
|
$("#setting_project_type").replaceWith("<%= escape_javascript(project_type_link(l(:label_research_group), 2))%>");
|
|
|
|
|
$("#project_memu_list").html('<%= escape_javascript(render(:partial => 'projects/research_team', :locals => {:project => @project})) %>');
|
|
|
|
|
$("#close_light").attr("onClick","close_window('research_group');");
|
|
|
|
|
}
|
|
|
|
|
else if(data == 3)
|
|
|
|
|
{
|
|
|
|
|
$("#setting_project_type").replaceWith("<%= escape_javascript(project_type_link(l(:label_friend_organization), 3))%>");
|
|
|
|
|
$("#project_memu_list").html('<%= escape_javascript(render(:partial => 'projects/friend_group', :locals => {:project => @project})) %>');
|
|
|
|
|
$("#close_light").attr("onClick","close_window('friend_organization');");
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
alert("服务器异常,请与管理员联系");
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function project_files_upload()
|
|
|
|
|
{
|
|
|
|
|
$('#ajax-modal').html('<%= escape_javascript(render :partial => 'files/upload_project_files',:locals => {:project => @project, :project_attachment_type => 1}) %>');
|
|
|
|
|
showModal('ajax-modal', '513px');
|
|
|
|
|
$('#ajax-modal').siblings().remove();
|
|
|
|
|
$('#ajax-modal').before("<a href='javascript:void(0)' onclick='hideModal()' style='margin-left: 480px;'><img src='/images/bid/close.png' width='26px' height='26px' /></a>");
|
|
|
|
|
$('#ajax-modal').parent().css("top","40%").css("left","36%").css("border","3px solid #269ac9");
|
|
|
|
|
$('#ajax-modal').parent().addClass("popbox_polls");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$("#expand_tools_expand").click(function(){
|
|
|
|
|
$("#navContent").toggle();
|
|
|
|
|
});
|
|
|
|
|
</script>
|
|
|
|
|
</div>
|
|
|
|
|
<% if hidden_unproject_infos %>
|
|
|
|
|
<%= render :partial => 'layouts/new_feedback' %>
|
|
|
|
|
<% end %>
|
|
|
|
|