From 7a86ba0b51cdb7c2521319c4b19231d6c8ffb745 Mon Sep 17 00:00:00 2001 From: halcyon <864072399@qq.com> Date: Mon, 5 Jan 2015 18:21:34 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B5=84=E4=BA=A7=E7=AE=A1=E7=90=86=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E5=BC=80=E5=A7=8B=EF=BC=8C=E5=A2=9E=E5=8A=A0=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=E8=B5=84=E4=BA=A7=E9=A1=B5=E9=9D=A2=EF=BC=8C=E4=BF=AE?= =?UTF-8?q?=E6=94=B9base=E9=A1=B5=E9=9D=A2=E7=AD=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jasset/urls.py | 8 +++ jasset/views.py | 15 ++++- jumpserver/urls.py | 5 +- templates/base.html | 2 +- templates/jasset/jadd.html | 113 +++++++++++++++++++++++++++++++++++ templates/jasset/jasset.html | 10 ++++ templates/nav.html | 5 +- 7 files changed, 150 insertions(+), 8 deletions(-) create mode 100644 jasset/urls.py create mode 100644 templates/jasset/jadd.html create mode 100644 templates/jasset/jasset.html diff --git a/jasset/urls.py b/jasset/urls.py new file mode 100644 index 000000000..48c32db05 --- /dev/null +++ b/jasset/urls.py @@ -0,0 +1,8 @@ +# coding:utf-8 +from django.conf.urls import patterns, include, url +from jasset.views import * + +urlpatterns = patterns('', + url(r'^$', index), + url(r'jadd', jadd), +) \ No newline at end of file diff --git a/jasset/views.py b/jasset/views.py index 91ea44a21..820b4b315 100644 --- a/jasset/views.py +++ b/jasset/views.py @@ -1,3 +1,16 @@ +#coding:utf-8 from django.shortcuts import render +from django.http import HttpResponse +from django.template import RequestContext +from django.shortcuts import render_to_response +from django.http import HttpResponseRedirect -# Create your views here. + +def index(request): + return render_to_response('jasset/jasset.html',) + + +def jadd(request): + if request.method == 'POST': + pass + return render_to_response('jasset/jadd.html',) \ No newline at end of file diff --git a/jumpserver/urls.py b/jumpserver/urls.py index 4e0a10643..9fcc7f7cf 100644 --- a/jumpserver/urls.py +++ b/jumpserver/urls.py @@ -3,10 +3,7 @@ from django.contrib import admin from jumpserver import views urlpatterns = patterns('', - # Examples: - # url(r'^$', 'jumpserver.views.home', name='home'), - # url(r'^blog/', include('blog.urls')), - + url(r'^jasset/', include('jasset.urls')), url(r'^admin/', include(admin.site.urls)), (r'^base/$', views.base), ) diff --git a/templates/base.html b/templates/base.html index e793c1d1c..1b76e9777 100644 --- a/templates/base.html +++ b/templates/base.html @@ -21,7 +21,7 @@
{% include 'nav_bar_header.html' %}
- {{ content }} + {% block content %}{% endblock %} {% include 'footer.html' %} diff --git a/templates/jasset/jadd.html b/templates/jasset/jadd.html new file mode 100644 index 000000000..81f4fa931 --- /dev/null +++ b/templates/jasset/jadd.html @@ -0,0 +1,113 @@ +{% extends 'base.html' %} +{% block content %} +

添加主机

+
+
+
+
+
请在以下填写主机详细信息
+
+
+
+
+
+
+ +
+
+
+
+ +
+
+
+
+
+
+
+
+ + +
+ + +
+
+
+
+ +
+
+
+
+ +
+
+
+
+
+
+
+ + + +
+
+
+
+ +
+
+
+
+ +
+
+
+ + +
+
+
+
+
+
+
+ + + + + + +{% endblock %} \ No newline at end of file diff --git a/templates/jasset/jasset.html b/templates/jasset/jasset.html new file mode 100644 index 000000000..e92bd8edd --- /dev/null +++ b/templates/jasset/jasset.html @@ -0,0 +1,10 @@ + + + + + 资产管理 + + +

welocome!

+ + \ No newline at end of file diff --git a/templates/nav.html b/templates/nav.html index c7b51cb9d..89c44928c 100644 --- a/templates/nav.html +++ b/templates/nav.html @@ -25,7 +25,7 @@ 资产管理 @@ -54,7 +54,8 @@ -
  • 访问官网