Divided ungleich landing sections into templates. Moved static files and all files path were adapted, Ungleich form conected to landing, Reconfigured django urls
This commit is contained in:
		
					parent
					
						
							
								5a04fc4969
							
						
					
				
			
			
				commit
				
					
						fd66c33299
					
				
			
		
					 13 changed files with 469 additions and 432 deletions
				
			
		| 
						 | 
				
			
			@ -2,9 +2,11 @@ from django.conf.urls import url
 | 
			
		|||
 | 
			
		||||
from django.utils.translation import ugettext_lazy as _
 | 
			
		||||
from . import views
 | 
			
		||||
from .views import ContactView
 | 
			
		||||
from .views import ContactView, IndexView, AboutView
 | 
			
		||||
 | 
			
		||||
urlpatterns = [
 | 
			
		||||
    url(_(r'index/?$'), IndexView.as_view(), name='index'),
 | 
			
		||||
    url(_(r'about/?$'), AboutView.as_view(), name='about'),
 | 
			
		||||
    url(_(r'contact/?$'), ContactView.as_view(), name='contact'),
 | 
			
		||||
    url(_(r'supporters/?$'), views.supporters, name='supporters'),
 | 
			
		||||
    url(_(r'support-us/?$'), views.support, name='support'),
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -5,7 +5,7 @@ from django.forms import ModelForm
 | 
			
		|||
from django.http import HttpResponseRedirect
 | 
			
		||||
from django.core.urlresolvers import reverse_lazy
 | 
			
		||||
from django.utils.translation import ugettext_lazy as _
 | 
			
		||||
 | 
			
		||||
from django.views.generic import TemplateView
 | 
			
		||||
from django.utils.translation import get_language
 | 
			
		||||
from djangocms_blog.models import Post
 | 
			
		||||
from django.contrib import messages
 | 
			
		||||
| 
						 | 
				
			
			@ -29,6 +29,13 @@ class ContactView(FormView):
 | 
			
		|||
        return super(ContactView, self).form_valid(form)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
class IndexView(TemplateView):
 | 
			
		||||
    template_name = "index.html"
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
class AboutView(TemplateView):
 | 
			
		||||
    template_name = "about.html"
 | 
			
		||||
 | 
			
		||||
def detail(request, message_id):
 | 
			
		||||
    p = get_object_or_404(Message, pk=message_id)
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			@ -38,6 +45,8 @@ def detail(request, message_id):
 | 
			
		|||
def about(request):
 | 
			
		||||
    return render(request, 'digitalglarus/about.html')
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#def index(request):
 | 
			
		||||
#    return render(request, 'digitalglarus/index.html')
 | 
			
		||||
#
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue