summaryrefslogtreecommitdiff
path: root/app/views/projects/create.js.haml
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/projects/create.js.haml')
-rw-r--r--app/views/projects/create.js.haml6
1 files changed, 6 insertions, 0 deletions
diff --git a/app/views/projects/create.js.haml b/app/views/projects/create.js.haml
new file mode 100644
index 00000000000..c457527aed4
--- /dev/null
+++ b/app/views/projects/create.js.haml
@@ -0,0 +1,6 @@
+- if @project.valid?
+ :plain
+ location.href = "#{project_path(@project, :notice => 'Project was successfully created.')}";
+- else
+ :plain
+ $("#new_project").replaceWith("#{escape_javascript(render('form'))}");