Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion bookstore/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
DEBUG = True

ALLOWED_HOSTS = ['localhost', '127.0.0.1', 'matheusdevfullstack.pythonanywhere.com']
# ALLOWED_HOSTS = ['*']
# Adicionado dominio do meu app no pythonanywhere no ALLOWED_HOSTS

# Application definition

Expand Down
1 change: 1 addition & 0 deletions bookstore/templates/hello_world.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<!DOCTYPE html>
{% comment %} Adicionada está Página {% endcomment %}
<html lang="en">
<head>
<meta charset="UTF-8">
Expand Down
3 changes: 2 additions & 1 deletion bookstore/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
re_path("bookstore/(?P<version>(v1|v2))/", include("order.urls")),
re_path("bookstore/(?P<version>(v1|v2))/", include("product.urls")),
path("api-token-auth/", obtain_auth_token, name="api_token_auth"),
path("update_server/", views.update, name="update"),
path("update_server/", views.update, name="update"),
path("hello/", views.hello_world, name="hello_world"),
# Adicionado novas URLS
]
4 changes: 3 additions & 1 deletion bookstore/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,6 @@ def update(request):

def hello_world(request):
template = loader.get_template('hello_world.html')
return HttpResponse(template.render())
return HttpResponse(template.render())

# Configurada essa view para integração continua com o pythonanywhere