socialforge/app/views/applied_project/applied_join_project.js.erb

14 lines
818 B
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

// @status: 0 该项目不存在1 不重复加入2 成功加入; 3 已是项目成员;其它 加入失败
<% if @status == 0%>
alert("<%= l('project.join.tips.notexist') %>");
<% elsif @status == 1%>
alert("<%= l('project.join.tips.repeat') %>");
<% elsif @status == 2%>
alert("<%= l('project.join.tips.success') %>");
hideModal($("#popbox"));
$("#applied_project_link_<%= @project.id%>").replaceWith("<%=escape_javascript(link_to '取消申请',appliedproject_applied_path(:project_id => @project.id,:user_id => User.current.id),:class => "blue_n_btn fr mt20", :remote => "true",:method => "delete",:id => "applied_project_link_#{@project.id}")%>");
<% elsif @status == 3%>
alert("<%= l('project.join.tips.has') %>");
<%else%>
alert("<%= l('project.join.tips.fail') %>");
<%end%>