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 @@