Compare commits
No commits in common. "b740838b13330a2eea7db428490d73fdc76c0c71" and "4e6f36048dc197a76036670f3e3a3f2ea4316bf3" have entirely different histories.
b740838b13
...
4e6f36048d
|
@ -1,5 +1 @@
|
||||||
<form action="saved" method="post">
|
|
||||||
{% csrf_token %}
|
|
||||||
{{formset}}
|
{{formset}}
|
||||||
<input type="submit" value="Submit">
|
|
||||||
</form>
|
|
||||||
|
|
|
@ -4,5 +4,4 @@ from . import views
|
||||||
|
|
||||||
urlpatterns = [
|
urlpatterns = [
|
||||||
path('', views.index, name='index'),
|
path('', views.index, name='index'),
|
||||||
path('saved', views.done, name='done')
|
|
||||||
]
|
]
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
from django.shortcuts import render
|
from django.shortcuts import render
|
||||||
from django.forms import modelformset_factory
|
from django.forms import modelformset_factory
|
||||||
from .models import Project
|
from .models import Project
|
||||||
from django.http import HttpResponse
|
# Create your views here.
|
||||||
|
# from django.http import HttpResponse
|
||||||
|
|
||||||
|
|
||||||
def index(request):
|
def index(request):
|
||||||
|
@ -15,6 +16,3 @@ def index(request):
|
||||||
else:
|
else:
|
||||||
formset = ProjectFormSet()
|
formset = ProjectFormSet()
|
||||||
return render(request, 'input/project.html', {'formset': formset})
|
return render(request, 'input/project.html', {'formset': formset})
|
||||||
|
|
||||||
def done(request):
|
|
||||||
return HttpResponse("Your data is save now.")
|
|
||||||
|
|
Loading…
Reference in New Issue