Merge branch 'szzh' into develop

tmp v20150613_1
sw 10 years ago
commit 1637977159

@ -107,7 +107,7 @@
<!--邀请加入-->
<div class="subNavBox">
<% if User.current.member_of?(@project) %>
<div class="subNav currentDd currentDt subNav_jiantou" id="expand_tools_expand_invit" nhtype="toggle4cookie" data-id="expand_invit" data-target="#navContent_invit">
<div class="subNav currentDd currentDt subNav_jiantou" id="expand_tools_expand_invit" nhtype="toggle4cookie" data-id="expand_invit" data-target="#navContent_invit" data-val="expand">
<%= l(:label_invite)%>
</div>
<ul class="navContent " style="display:block" id="navContent_invit">

@ -1,64 +1,6 @@
<div class="project_r_h">
<h2 class="project_h2"><%= l(:label_news) %></h2>
</div>
<script type="text/javascript">
function regexTitle()
{
var name = $("#news_title").val();
if(name.length ==0)
{
$("#title_notice_span").text("<%= l(:label_title_blank)%>");
$("#title_notice_span").css('color','#ff0000');
$("#title_notice_span").focus();
return false;
}
else if(name.length <= 60)
{
$("#title_notice_span").text("<%= l(:label_field_correct)%>");
$("#title_notice_span").css('color','#008000');
return true;
}
else
{
$("#title_notice_span").text("<%= l(:label_title_long)%>");
$("#title_notice_span").css('color','#ff0000');
$("#title_notice_span").focus();
return false;
}
}
function submitComment()
{
$("#add_comment_form").submit();
}
function regexDescription()
{
var name = $("#news_description").val();
if(name.length ==0)
{
$("#description_notice_span").text("<%= l(:label_descripition_blank)%>");
$("#description_notice_span").css('color','#ff0000');
$("#description_notice_span").focus();
return false;
}
else
{
$("#description_notice_span").text("<%= l(:label_field_correct)%>");
$("#description_notice_span").css('color','#008000');
return true;
}
}
function submitNews()
{
if(regexTitle() && regexDescription())
{
$("#news-form").submit();
}
}
</script>
<% if authorize_for('news', 'edit') %>
<div id="edit-news" style="display:none;">

@ -265,6 +265,11 @@ function submitFocus(obj) {
$(obj).focus();
}
function submitComment()
{
$("#add_comment_form").submit();
}
//当项目描述长度小于112px时不显示更多按钮
$(function () {
// alert($("#course_description_content").height());

Loading…
Cancel
Save