Place some initial files for migration view

This restores some of the original files and routes from the migration
view of the classic ui with the eventual goal of fully reintegrating this
system with the new ui.

See: https://github.com/ansible/awx/commit/b39db745d4addd7aa4612a43cf3ebd12c4d206cd
This commit is contained in:
Jake McDermott
2020-12-09 11:32:14 -05:00
parent 4c5757b3bd
commit 704029459f
3 changed files with 32 additions and 2 deletions
+1 -1
View File
@@ -181,4 +181,4 @@ class MigrationRanCheckMiddleware(MiddlewareMixin):
plan = executor.migration_plan(executor.loader.graph.leaf_nodes())
if bool(plan) and \
getattr(resolve(request.path), 'url_name', '') != 'migrations_notran':
return redirect(reverse("ui:migrations_notran"))
return redirect(reverse("ui_next:migrations_notran"))
+25
View File
@@ -0,0 +1,25 @@
<!DOCTYPE html>
<html lang="en-US">
<head>
<meta
http-equiv="Content-Security-Policy"
content="default-src 'self'; connect-src 'self' ws: wss:; style-src 'self' 'nonce-{{ csp_nonce }}'; script-src 'self' 'nonce-{{ csp_nonce }}' *.pendo.io; img-src 'self' *.pendo.io data:;"
/>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<script nonce="{{ csp_nonce }}">
setInterval(function() {
window.location = '/';
}, 10000);
</script>
</head>
<body>
<div>
<span>
<p>AWX is installing.</p>
<p>This page will refresh when complete.</p>
</span>
</div>
</body>
</html>
+6 -1
View File
@@ -7,9 +7,14 @@ class IndexView(TemplateView):
template_name = 'index.html'
class MigrationsNotran(TemplateView):
template_name = 'installing.html'
app_name = 'ui_next'
urlpatterns = [
url(r'^$', IndexView.as_view(), name='index'),
#url(r'^migrations_notran/$', migrations_notran, name='migrations_notran'),
url(r'^migrations_notran/$', MigrationsNotran.as_view(), name='migrations_notran'),
]