项目留言重复提交问题

This commit is contained in:
huang 2015-12-11 09:52:17 +08:00
parent 1ba0dae3c4
commit 01b21ceda1
2 changed files with 7 additions and 3 deletions

View File

@ -33,7 +33,7 @@
<p nhname='contentmsg_'></p> <p nhname='contentmsg_'></p>
<div nhname='toolbar_container_' style="float:left;padding-top:3px;margin-bottom: 15px;"></div> <div nhname='toolbar_container_' style="float:left;padding-top:3px;margin-bottom: 15px;"></div>
<a id="new_message_cancel_btn_" href="javascript:void(0)" class="grey_btn fr mt10">取消</a> <a id="new_message_cancel_btn_" href="javascript:void(0)" class="grey_btn fr mt10">取消</a>
<a href="javascript:void(0);" class="blue_btn fr ml10 mt10" id="submit_message" >留言</a> <a href="javascript:void(0);" class="blue_btn fr ml10 mt10" id="submit_feedback_course" >留言</a>
<% end %> <% end %>
</div> </div>
<% end %> <% end %>
@ -52,7 +52,7 @@
<script type="text/javascript"> <script type="text/javascript">
$(function(){ $(function(){
$("#submit_message").one('click',function() { $("#submit_feedback_course").one('click',function() {
$("#course_feedback_new").submit(); $("#course_feedback_new").submit();
}); });
KindEditor.ready(function(K){ KindEditor.ready(function(K){

View File

@ -29,7 +29,8 @@
<p nhname="contentmsg"></p> <p nhname="contentmsg"></p>
<div class="fl mt10" style="padding-top:5px;" nhname="toolbar_container"></div> <div class="fl mt10" style="padding-top:5px;" nhname="toolbar_container"></div>
<%#= submit_tag l(:button_leave_meassge), :name => nil , :class => "blue_btn fr mt10 mb10" %> <%#= submit_tag l(:button_leave_meassge), :name => nil , :class => "blue_btn fr mt10 mb10" %>
<%= link_to l(:button_leave_meassge), "javascript:void(0)", :onclick => 'submitProjectFeedback();', :onmouseover => 'submitFocus(this);', :class => 'blue_btn fr mt10 mb10' %> <a href="javascript:void(0);" class="blue_btn fr ml10 mt10" id="submit_feedback_project" >留言</a>
<%#= link_to l(:button_leave_meassge), "javascript:void(0)", :onclick => 'submitProjectFeedback();', :onmouseover => 'submitFocus(this);', :class => 'blue_btn fr mt10 mb10' %>
<% end %> <% end %>
<% end %> <% end %>
@ -43,6 +44,9 @@
<div style="display:none;"><a href="#" id="nhjump"></a></div> <div style="display:none;"><a href="#" id="nhjump"></a></div>
<script type="text/javascript"> <script type="text/javascript">
$(function(){ $(function(){
$("#submit_feedback_project").one('click',function() {
$("#project_feedback_form").submit();
});
function init_editor(params){ function init_editor(params){
params.textarea.removeAttr('placeholder'); params.textarea.removeAttr('placeholder');