Adding functions for bills
This commit is contained in:
parent
23cb231bdc
commit
ebb48c1a42
@ -4,6 +4,8 @@ from jet.dashboard.dashboard import Dashboard, AppIndexDashboard
|
|||||||
|
|
||||||
|
|
||||||
class CustomIndexDashboard(Dashboard):
|
class CustomIndexDashboard(Dashboard):
|
||||||
|
# app_label = "api"
|
||||||
|
|
||||||
columns = 3
|
columns = 3
|
||||||
|
|
||||||
def init_with_context(self, context):
|
def init_with_context(self, context):
|
||||||
|
@ -29,7 +29,7 @@ SECRET_KEY = env("SECRET_KEY", default='django-insecure-7uajhmbt^@)mklk1ur=slkmn
|
|||||||
# SECURITY WARNING: don't run with debug turned on in production!
|
# SECURITY WARNING: don't run with debug turned on in production!
|
||||||
DEBUG = env("DEBUG")
|
DEBUG = env("DEBUG")
|
||||||
|
|
||||||
ALLOWED_HOSTS = ["127.0.0.1", "192.168.1.187", "192.168.1.23"]
|
ALLOWED_HOSTS = ["localhost", "127.0.0.1", "192.168.1.187", "192.168.1.23"]
|
||||||
|
|
||||||
|
|
||||||
# Application definition
|
# Application definition
|
||||||
@ -172,5 +172,5 @@ JET_THEMES = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
# JET_INDEX_DASHBOARD = 'jet.dashboard.dashboard.DefaultIndexDashboard'
|
# JET_INDEX_DASHBOARD = 'jet.dashboard.dashboard.DefaultIndexDashboard'
|
||||||
JET_APP_INDEX_DASHBOARD = 'dashboard.CustomIndexDashboard'
|
# JET_APP_INDEX_DASHBOARD = 'dashboard.CustomIndexDashboard'
|
||||||
# JET_INDEX_DASHBOARD = 'dashboard.CustomIndexDashboard'
|
JET_INDEX_DASHBOARD = 'dashboard.CustomIndexDashboard'
|
@ -8,5 +8,6 @@ from . import views
|
|||||||
urlpatterns = [
|
urlpatterns = [
|
||||||
|
|
||||||
path('', views.index, name='index'),
|
path('', views.index, name='index'),
|
||||||
path('admin/', admin.site.urls),
|
path('<int:bill_id>/', views.detail, name='detail')
|
||||||
|
# path('admin/', admin.site.urls),
|
||||||
]
|
]
|
||||||
|
@ -3,4 +3,6 @@ from django.http import HttpResponse
|
|||||||
|
|
||||||
def index(request):
|
def index(request):
|
||||||
return HttpResponse("Let there be bills!")
|
return HttpResponse("Let there be bills!")
|
||||||
# Create your views here.
|
|
||||||
|
def detail(request, bill_id):
|
||||||
|
return HttpResponse("You're looking at Bill %s." % bill_id)
|
||||||
|
Loading…
Reference in New Issue
Block a user