修改重复加入项目提示语
This commit is contained in:
parent
9f6ff04e65
commit
d135274281
|
@ -10,8 +10,10 @@ class AppliedProjectController < ApplicationController
|
|||
if @applieds.count == 0
|
||||
appliedproject = AppliedProject.create(:user_id => params[:user_id], :project_id => params[:project_id])
|
||||
Mailer.applied_project(appliedproject).deliver
|
||||
@status = 2
|
||||
else
|
||||
@status = 1
|
||||
end
|
||||
@status = 1
|
||||
else
|
||||
@status = 0
|
||||
end
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
<% if @status == 0%>
|
||||
alert("您申请的项目不存在");
|
||||
<% elsif @status == 1%>
|
||||
alert("请勿重复申请加入该项目");
|
||||
<% elsif @status == 2%>
|
||||
alert("申请成功");
|
||||
<%else%>
|
||||
alert("申请失败");
|
||||
|
|
Loading…
Reference in New Issue