Merge branch 'master' into cms-features
* master: added BSD license Update master use django-forms-bootstrap fixed account links on homepage fixed staticfiles settings removed homepage use of ifsetting_tag updated urls updated templates updated imports to reflect new layout updated imports to reflect new layout updated settings updated manage.py updated requirements to 1.4 / DUA and latest versions updated project layout for 1.4 (without content changes) Conflicts: requirements/base.txt symposion/settings.py symposion_project/urls.py
This commit is contained in:
		
						commit
						b06daba446
					
				
					 45 changed files with 214 additions and 89 deletions
				
			
		
							
								
								
									
										27
									
								
								LICENSE
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										27
									
								
								LICENSE
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,27 @@
 | 
				
			||||||
 | 
					Copyright (c) 2010-2012, Eldarion, Inc. and contributors
 | 
				
			||||||
 | 
					All rights reserved.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Redistribution and use in source and binary forms, with or without modification,
 | 
				
			||||||
 | 
					are permitted provided that the following conditions are met:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    * Redistributions of source code must retain the above copyright notice,
 | 
				
			||||||
 | 
					      this list of conditions and the following disclaimer.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    * Redistributions in binary form must reproduce the above copyright notice,
 | 
				
			||||||
 | 
					      this list of conditions and the following disclaimer in the documentation
 | 
				
			||||||
 | 
					      and/or other materials provided with the distribution.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    * Neither the name of Eldarion, Inc. nor the names of its contributors may
 | 
				
			||||||
 | 
					      be used to endorse or promote products derived from this software without
 | 
				
			||||||
 | 
					      specific prior written permission.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
 | 
				
			||||||
 | 
					ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
 | 
				
			||||||
 | 
					WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
 | 
				
			||||||
 | 
					DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
 | 
				
			||||||
 | 
					ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
 | 
				
			||||||
 | 
					(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
 | 
				
			||||||
 | 
					LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
 | 
				
			||||||
 | 
					ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
 | 
				
			||||||
 | 
					(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
 | 
				
			||||||
 | 
					SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 | 
				
			||||||
							
								
								
									
										4
									
								
								README
									
										
									
									
									
								
							
							
						
						
									
										4
									
								
								README
									
										
									
									
									
								
							| 
						 | 
					@ -0,0 +1,4 @@
 | 
				
			||||||
 | 
					SYMPOSION
 | 
				
			||||||
 | 
					A Django project for conference websites.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					A Pinax project sponsored by Eldarion and the Python Software Foundation.
 | 
				
			||||||
							
								
								
									
										9
									
								
								manage.py
									
										
									
									
									
										Executable file
									
								
							
							
						
						
									
										9
									
								
								manage.py
									
										
									
									
									
										Executable file
									
								
							| 
						 | 
					@ -0,0 +1,9 @@
 | 
				
			||||||
 | 
					#!/usr/bin/env python
 | 
				
			||||||
 | 
					import os, sys
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					if __name__ == "__main__":
 | 
				
			||||||
 | 
					    os.environ.setdefault("DJANGO_SETTINGS_MODULE", "symposion.settings")
 | 
				
			||||||
 | 
					    
 | 
				
			||||||
 | 
					    from django.core.management import execute_from_command_line
 | 
				
			||||||
 | 
					    
 | 
				
			||||||
 | 
					    execute_from_command_line(sys.argv)
 | 
				
			||||||
| 
						 | 
					@ -7,20 +7,21 @@
 | 
				
			||||||
--extra-index-url=http://dist.pinaxproject.com/alpha/
 | 
					--extra-index-url=http://dist.pinaxproject.com/alpha/
 | 
				
			||||||
--extra-index-url=http://dist.pinaxproject.com/fresh-start/
 | 
					--extra-index-url=http://dist.pinaxproject.com/fresh-start/
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Django==1.3.1
 | 
					Django==1.4
 | 
				
			||||||
Pinax
 | 
					pinax-theme-bootstrap==2.0.3
 | 
				
			||||||
 | 
					django-forms-bootstrap==2.0.3.post1
 | 
				
			||||||
 | 
					metron==0.1 # 0.2.dev3
 | 
				
			||||||
 | 
					pinax-utils==1.0b1.dev3
 | 
				
			||||||
django-debug-toolbar==0.9.1
 | 
					django-debug-toolbar==0.9.1
 | 
				
			||||||
django-staticfiles==1.1.2
 | 
					 | 
				
			||||||
django_compressor==1.0.1
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
django-mailer==0.2a1
 | 
					django-mailer==0.2a1
 | 
				
			||||||
django-email-confirmation==0.2
 | 
					 | 
				
			||||||
django-timezones==0.2
 | 
					django-timezones==0.2
 | 
				
			||||||
pytz==2011n
 | 
					pytz==2011n
 | 
				
			||||||
django-openid==0.3a1
 | 
					django-openid==0.3a1
 | 
				
			||||||
python-openid==2.2.5
 | 
					python-openid==2.2.5
 | 
				
			||||||
metron==0.1
 | 
					django_compressor==1.2a1
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					-e git+git://github.com/pinax/pinax-theme-bootstrap-account.git@70c0be0279d61bd2d0f949698f94b8f938918277#egg=pinax-theme-bootstrap-account
 | 
				
			||||||
 | 
					-e git+git://github.com/pinax/django-user-accounts.git@3676d2c7ea0e9a5c3f8510ac8e6f8d58175e6b5f#egg=django-user-accounts
 | 
				
			||||||
 | 
					
 | 
				
			||||||
django-mptt==0.5.2
 | 
					django-mptt==0.5.2
 | 
				
			||||||
django-taggit==0.9.3
 | 
					django-taggit==0.9.3
 | 
				
			||||||
| 
						 | 
					@ -28,6 +29,3 @@ django-reversion==1.5.1
 | 
				
			||||||
django-markitup==1.0.0
 | 
					django-markitup==1.0.0
 | 
				
			||||||
markdown==2.1.1
 | 
					markdown==2.1.1
 | 
				
			||||||
django-sitetree==0.6
 | 
					django-sitetree==0.6
 | 
				
			||||||
 | 
					 | 
				
			||||||
pinax-theme-bootstrap==2.0.3
 | 
					 | 
				
			||||||
django-forms-bootstrap==2.0.3.post1
 | 
					 | 
				
			||||||
							
								
								
									
										12
									
								
								symposion/cms/admin.py
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								symposion/cms/admin.py
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,12 @@
 | 
				
			||||||
 | 
					from django.contrib import admin
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					from mptt.admin import MPTTModelAdmin
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					from cms.models import Page
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					class PageAdmin(MPTTModelAdmin):
 | 
				
			||||||
 | 
					    prepopulated_fields = {"slug": ("title",)}
 | 
				
			||||||
 | 
					    list_display = ("title", "published", "status")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					admin.site.register(Page, PageAdmin)
 | 
				
			||||||
							
								
								
									
										65
									
								
								symposion/cms/models.py
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										65
									
								
								symposion/cms/models.py
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,65 @@
 | 
				
			||||||
 | 
					from datetime import datetime
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					from django.db import models
 | 
				
			||||||
 | 
					from django.utils.translation import ugettext_lazy as _
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					from markitup.fields import MarkupField
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					from taggit.managers import TaggableManager
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					from mptt.models import MPTTModel, TreeForeignKey
 | 
				
			||||||
 | 
					from mptt.utils import drilldown_tree_for_node
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					import reversion
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					class ContentBase(models.Model):
 | 
				
			||||||
 | 
					    
 | 
				
			||||||
 | 
					    STATUS_CHOICES = (
 | 
				
			||||||
 | 
					        (1, _("Draft")),
 | 
				
			||||||
 | 
					        (2, _("Public")),
 | 
				
			||||||
 | 
					    )
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    title = models.CharField(max_length=100)
 | 
				
			||||||
 | 
					    slug = models.CharField(max_length=100, blank=True, null=True)
 | 
				
			||||||
 | 
					    body = MarkupField()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    tags = TaggableManager(blank=True)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    status = models.IntegerField(choices=STATUS_CHOICES, default=2)
 | 
				
			||||||
 | 
					    published = models.DateTimeField(default=datetime.now)
 | 
				
			||||||
 | 
					    created = models.DateTimeField(editable=False, default=datetime.now)
 | 
				
			||||||
 | 
					    updated = models.DateTimeField(editable=False, default=datetime.now)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    class Meta:
 | 
				
			||||||
 | 
					        abstract = True
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					class Page(MPTTModel, ContentBase):
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    parent = TreeForeignKey("self", null=True, blank=True, related_name="children")
 | 
				
			||||||
 | 
					    ordering = models.PositiveIntegerField(default=1)
 | 
				
			||||||
 | 
					    path = models.TextField(blank=True, editable=False)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def __unicode__(self):
 | 
				
			||||||
 | 
					        return self.title
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def save(self, calculate_path=True, *args, **kwargs):
 | 
				
			||||||
 | 
					        super(Page, self).save(*args, **kwargs)
 | 
				
			||||||
 | 
					        if calculate_path:
 | 
				
			||||||
 | 
					            self.calculate_path()
 | 
				
			||||||
 | 
					    
 | 
				
			||||||
 | 
					    def calculate_path(self):
 | 
				
			||||||
 | 
					        self.path = ""
 | 
				
			||||||
 | 
					        for page in drilldown_tree_for_node(self):
 | 
				
			||||||
 | 
					            if page == self:
 | 
				
			||||||
 | 
					                self.path += page.slug
 | 
				
			||||||
 | 
					                break
 | 
				
			||||||
 | 
					            else:
 | 
				
			||||||
 | 
					                self.path += "%s/" % page.slug
 | 
				
			||||||
 | 
					        self.save(calculate_path=False)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    class MPTTMeta:
 | 
				
			||||||
 | 
					        order_insertion_by = ["ordering", "title"]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					reversion.register(Page)
 | 
				
			||||||
							
								
								
									
										15
									
								
								symposion/cms/views.py
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										15
									
								
								symposion/cms/views.py
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,15 @@
 | 
				
			||||||
 | 
					from django.shortcuts import render_to_response, get_object_or_404
 | 
				
			||||||
 | 
					from django.template import RequestContext
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					from cms.models import Page
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					def page(request, slug):
 | 
				
			||||||
 | 
					    
 | 
				
			||||||
 | 
					    page = get_object_or_404(Page, path=slug)
 | 
				
			||||||
 | 
					    siblings = page.get_siblings(include_self=True)
 | 
				
			||||||
 | 
					    
 | 
				
			||||||
 | 
					    return render_to_response("cms/page_detail.html", {
 | 
				
			||||||
 | 
					        "page": page,
 | 
				
			||||||
 | 
					        "siblings": siblings,
 | 
				
			||||||
 | 
					    }, context_instance=RequestContext(request))
 | 
				
			||||||
| 
						 | 
					@ -1,6 +1,6 @@
 | 
				
			||||||
from django.contrib import admin
 | 
					from django.contrib import admin
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from conference.models import Conference, Section
 | 
					from symposion.conference.models import Conference, Section
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
admin.site.register(Conference, list_display=("title", "start_date", "end_date"))
 | 
					admin.site.register(Conference, list_display=("title", "start_date", "end_date"))
 | 
				
			||||||
| 
						 | 
					@ -77,9 +77,8 @@ STATICFILES_DIRS = [
 | 
				
			||||||
]
 | 
					]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
STATICFILES_FINDERS = [
 | 
					STATICFILES_FINDERS = [
 | 
				
			||||||
    "staticfiles.finders.FileSystemFinder",
 | 
					    "django.contrib.staticfiles.finders.FileSystemFinder",
 | 
				
			||||||
    "staticfiles.finders.AppDirectoriesFinder",
 | 
					    "django.contrib.staticfiles.finders.AppDirectoriesFinder",
 | 
				
			||||||
    "staticfiles.finders.LegacyAppDirectoriesFinder",
 | 
					 | 
				
			||||||
    "compressor.finders.CompressorFinder",
 | 
					    "compressor.finders.CompressorFinder",
 | 
				
			||||||
]
 | 
					]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -96,8 +95,8 @@ SECRET_KEY = "8*br)9@fs!4nzg-imfrsst&oa2udy6z-fqtdk0*e5c1=wn)(t3"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# List of callables that know how to import templates from various sources.
 | 
					# List of callables that know how to import templates from various sources.
 | 
				
			||||||
TEMPLATE_LOADERS = [
 | 
					TEMPLATE_LOADERS = [
 | 
				
			||||||
    "django.template.loaders.filesystem.load_template_source",
 | 
					    "django.template.loaders.filesystem.Loader",
 | 
				
			||||||
    "django.template.loaders.app_directories.load_template_source",
 | 
					    "django.template.loaders.app_directories.Loader",
 | 
				
			||||||
]
 | 
					]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
MIDDLEWARE_CLASSES = [
 | 
					MIDDLEWARE_CLASSES = [
 | 
				
			||||||
| 
						 | 
					@ -107,14 +106,12 @@ MIDDLEWARE_CLASSES = [
 | 
				
			||||||
    "django.contrib.auth.middleware.AuthenticationMiddleware",
 | 
					    "django.contrib.auth.middleware.AuthenticationMiddleware",
 | 
				
			||||||
    "django_openid.consumer.SessionConsumer",
 | 
					    "django_openid.consumer.SessionConsumer",
 | 
				
			||||||
    "django.contrib.messages.middleware.MessageMiddleware",
 | 
					    "django.contrib.messages.middleware.MessageMiddleware",
 | 
				
			||||||
    "pinax.apps.account.middleware.LocaleMiddleware",
 | 
					 | 
				
			||||||
    "django.middleware.transaction.TransactionMiddleware",
 | 
					    "django.middleware.transaction.TransactionMiddleware",
 | 
				
			||||||
    "reversion.middleware.RevisionMiddleware",
 | 
					    "reversion.middleware.RevisionMiddleware",
 | 
				
			||||||
    "pinax.middleware.security.HideSensistiveFieldsMiddleware",
 | 
					 | 
				
			||||||
    "debug_toolbar.middleware.DebugToolbarMiddleware",
 | 
					    "debug_toolbar.middleware.DebugToolbarMiddleware",
 | 
				
			||||||
]
 | 
					]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
ROOT_URLCONF = "symposion_project.urls"
 | 
					ROOT_URLCONF = "symposion.urls"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
TEMPLATE_DIRS = [
 | 
					TEMPLATE_DIRS = [
 | 
				
			||||||
    os.path.join(PROJECT_ROOT, "templates"),
 | 
					    os.path.join(PROJECT_ROOT, "templates"),
 | 
				
			||||||
| 
						 | 
					@ -125,14 +122,12 @@ TEMPLATE_CONTEXT_PROCESSORS = [
 | 
				
			||||||
    "django.core.context_processors.debug",
 | 
					    "django.core.context_processors.debug",
 | 
				
			||||||
    "django.core.context_processors.i18n",
 | 
					    "django.core.context_processors.i18n",
 | 
				
			||||||
    "django.core.context_processors.media",
 | 
					    "django.core.context_processors.media",
 | 
				
			||||||
 | 
					    "django.core.context_processors.static",
 | 
				
			||||||
 | 
					    "django.core.context_processors.tz",
 | 
				
			||||||
    "django.core.context_processors.request",
 | 
					    "django.core.context_processors.request",
 | 
				
			||||||
    "django.contrib.messages.context_processors.messages",
 | 
					    "django.contrib.messages.context_processors.messages",
 | 
				
			||||||
    
 | 
					    "pinax_utils.context_processors.settings",
 | 
				
			||||||
    "staticfiles.context_processors.static",
 | 
					    "account.context_processors.account",
 | 
				
			||||||
    
 | 
					 | 
				
			||||||
    "pinax.core.context_processors.pinax_settings",
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
    "pinax.apps.account.context_processors.account",
 | 
					 | 
				
			||||||
]
 | 
					]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
INSTALLED_APPS = [
 | 
					INSTALLED_APPS = [
 | 
				
			||||||
| 
						 | 
					@ -143,22 +138,20 @@ INSTALLED_APPS = [
 | 
				
			||||||
    "django.contrib.sessions",
 | 
					    "django.contrib.sessions",
 | 
				
			||||||
    "django.contrib.sites",
 | 
					    "django.contrib.sites",
 | 
				
			||||||
    "django.contrib.messages",
 | 
					    "django.contrib.messages",
 | 
				
			||||||
 | 
					    "django.contrib.staticfiles",
 | 
				
			||||||
    "django.contrib.humanize",
 | 
					    "django.contrib.humanize",
 | 
				
			||||||
    
 | 
					    
 | 
				
			||||||
    "pinax.templatetags",
 | 
					 | 
				
			||||||
    
 | 
					 | 
				
			||||||
    # theme
 | 
					    # theme
 | 
				
			||||||
 | 
					    "pinax_theme_bootstrap_account",
 | 
				
			||||||
    "pinax_theme_bootstrap",
 | 
					    "pinax_theme_bootstrap",
 | 
				
			||||||
    "django_forms_bootstrap",
 | 
					    "django_forms_bootstrap",
 | 
				
			||||||
    
 | 
					    
 | 
				
			||||||
    # external
 | 
					    # external
 | 
				
			||||||
    "staticfiles",
 | 
					 | 
				
			||||||
    "compressor",
 | 
					    "compressor",
 | 
				
			||||||
    "debug_toolbar",
 | 
					    "debug_toolbar",
 | 
				
			||||||
    "mailer",
 | 
					    "mailer",
 | 
				
			||||||
    "django_openid",
 | 
					    "django_openid",
 | 
				
			||||||
    "timezones",
 | 
					    "timezones",
 | 
				
			||||||
    "emailconfirmation",
 | 
					 | 
				
			||||||
    "metron",
 | 
					    "metron",
 | 
				
			||||||
    "markitup",
 | 
					    "markitup",
 | 
				
			||||||
    "taggit",
 | 
					    "taggit",
 | 
				
			||||||
| 
						 | 
					@ -169,13 +162,12 @@ INSTALLED_APPS = [
 | 
				
			||||||
    "sitetree",
 | 
					    "sitetree",
 | 
				
			||||||
    
 | 
					    
 | 
				
			||||||
    # Pinax
 | 
					    # Pinax
 | 
				
			||||||
    "pinax.apps.account",
 | 
					    "account",
 | 
				
			||||||
    "pinax.apps.signup_codes",
 | 
					 | 
				
			||||||
    
 | 
					    
 | 
				
			||||||
    # project
 | 
					    # project
 | 
				
			||||||
    "about",
 | 
					    "symposion.about",
 | 
				
			||||||
    "sponsorship",
 | 
					    "symposion.sponsorship",
 | 
				
			||||||
    "conference",
 | 
					    "symposion.conference",
 | 
				
			||||||
]
 | 
					]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
FIXTURE_DIRS = [
 | 
					FIXTURE_DIRS = [
 | 
				
			||||||
| 
						 | 
					@ -193,9 +185,9 @@ ACCOUNT_EMAIL_VERIFICATION = False
 | 
				
			||||||
ACCOUNT_EMAIL_AUTHENTICATION = False
 | 
					ACCOUNT_EMAIL_AUTHENTICATION = False
 | 
				
			||||||
ACCOUNT_UNIQUE_EMAIL = EMAIL_CONFIRMATION_UNIQUE_EMAIL = False
 | 
					ACCOUNT_UNIQUE_EMAIL = EMAIL_CONFIRMATION_UNIQUE_EMAIL = False
 | 
				
			||||||
 | 
					
 | 
				
			||||||
AUTHENTICATION_BACKENDS = [
 | 
					# AUTHENTICATION_BACKENDS = [
 | 
				
			||||||
    "pinax.apps.account.auth_backends.AuthenticationBackend",
 | 
					#     "pinax.apps.account.auth_backends.AuthenticationBackend",
 | 
				
			||||||
]
 | 
					# ]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
LOGIN_URL = "/account/login/" # @@@ any way this can be a url name?
 | 
					LOGIN_URL = "/account/login/" # @@@ any way this can be a url name?
 | 
				
			||||||
LOGIN_REDIRECT_URLNAME = "what_next"
 | 
					LOGIN_REDIRECT_URLNAME = "what_next"
 | 
				
			||||||
| 
						 | 
					@ -1,6 +1,6 @@
 | 
				
			||||||
from django.contrib import admin
 | 
					from django.contrib import admin
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from sponsorship.models import SponsorLevel, Sponsor
 | 
					from symposion.sponsorship.models import SponsorLevel, Sponsor
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
admin.site.register(SponsorLevel)
 | 
					admin.site.register(SponsorLevel)
 | 
				
			||||||
| 
						 | 
					@ -3,7 +3,7 @@ import datetime
 | 
				
			||||||
from django.db import models
 | 
					from django.db import models
 | 
				
			||||||
from django.utils.translation import ugettext_lazy as _
 | 
					from django.utils.translation import ugettext_lazy as _
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from conference.models import Conference
 | 
					from symposion.conference.models import Conference
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
class SponsorLevel(models.Model):
 | 
					class SponsorLevel(models.Model):
 | 
				
			||||||
| 
						 | 
					@ -1,7 +1,7 @@
 | 
				
			||||||
from django import template
 | 
					from django import template
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from conference.models import current_conference
 | 
					from symposion.conference.models import current_conference
 | 
				
			||||||
from sponsorship.models import Sponsor, SponsorLevel
 | 
					from symposion.sponsorship.models import Sponsor, SponsorLevel
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
register = template.Library()
 | 
					register = template.Library()
 | 
				
			||||||
							
								
								
									
										8
									
								
								symposion/templates/_footer.html
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								symposion/templates/_footer.html
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,8 @@
 | 
				
			||||||
 | 
					{% load i18n %}
 | 
				
			||||||
 | 
					<div class="legal">
 | 
				
			||||||
 | 
					    <a href="http://pinax.github.com/symposion/"><b>symposion</b></a>:
 | 
				
			||||||
 | 
					    a Pinax project sponsored by
 | 
				
			||||||
 | 
					    <a href="http://eldarion.com/">Eldarion</a>
 | 
				
			||||||
 | 
					    and the
 | 
				
			||||||
 | 
					    <a href="http://www.python.org/psf/">Python Software Foundation</a>.
 | 
				
			||||||
 | 
					</div>
 | 
				
			||||||
							
								
								
									
										19
									
								
								symposion/templates/cms/page_detail.html
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										19
									
								
								symposion/templates/cms/page_detail.html
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,19 @@
 | 
				
			||||||
 | 
					{% extends "subnav_base.html" %}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					{% block subnav %}
 | 
				
			||||||
 | 
					    <ul class="nav nav-list">
 | 
				
			||||||
 | 
					        <li class="nav-header">{{ page.parent }}</li>
 | 
				
			||||||
 | 
					        {% for sibling in siblings %}
 | 
				
			||||||
 | 
					            {% if sibling == page %}
 | 
				
			||||||
 | 
					                <li>{{ sibling }}</li>
 | 
				
			||||||
 | 
					            {% else %}
 | 
				
			||||||
 | 
					                <li><a href="{% url cms_page sibling.path %}">{{ sibling }}</a>
 | 
				
			||||||
 | 
					            {% endif %}
 | 
				
			||||||
 | 
					        {% endfor %}
 | 
				
			||||||
 | 
					    </ul>
 | 
				
			||||||
 | 
					{% endblock %}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					{% block body %}
 | 
				
			||||||
 | 
					    <h1>{{ page.title }}</h1>
 | 
				
			||||||
 | 
					    {{ page.body }}
 | 
				
			||||||
 | 
					{% endblock %}
 | 
				
			||||||
| 
						 | 
					@ -1,7 +1,6 @@
 | 
				
			||||||
{% extends "banner_base.html" %}
 | 
					{% extends "banner_base.html" %}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
{% load i18n %}
 | 
					{% load i18n %}
 | 
				
			||||||
{% load ifsetting_tag %}
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
{% block head_title %}{% trans "Welcome" %}{% endblock %}
 | 
					{% block head_title %}{% trans "Welcome" %}{% endblock %}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -33,12 +32,8 @@
 | 
				
			||||||
        {% url what_next as what_next_url %}
 | 
					        {% url what_next as what_next_url %}
 | 
				
			||||||
        <p class="what_next">{% blocktrans %}Wondering <a href="{{ what_next_url }}" class="btn primary large">What Next</a>?{% endblocktrans %}</p>
 | 
					        <p class="what_next">{% blocktrans %}Wondering <a href="{{ what_next_url }}" class="btn primary large">What Next</a>?{% endblocktrans %}</p>
 | 
				
			||||||
    {% else %}
 | 
					    {% else %}
 | 
				
			||||||
        {% url acct_login as login_url %}
 | 
					        {% url account_login as login_url %}
 | 
				
			||||||
        {% ifsetting ACCOUNT_OPEN_SIGNUP %}
 | 
					        {% url account_signup as signup_url %}
 | 
				
			||||||
            {% url acct_signup as signup_url %}
 | 
					        <p>{% blocktrans %}You can <a href="{{ login_url }}" class="btn">Log In</a> or <a href="{{ signup_url }}" class="btn primary">Sign Up</a> to try out the site.{% endblocktrans %}</p>
 | 
				
			||||||
            <p>{% blocktrans %}You can <a href="{{ login_url }}" class="btn">Log In</a> or <a href="{{ signup_url }}" class="btn primary">Sign Up</a> to try out the site.{% endblocktrans %}</p>
 | 
					 | 
				
			||||||
        {% else %}
 | 
					 | 
				
			||||||
            <p>{% blocktrans %}You can <a href="{{ login_url }}" class="btn primary large">Log In</a> to try out the site.{% endblocktrans %}</p>
 | 
					 | 
				
			||||||
        {% endifsetting %}
 | 
					 | 
				
			||||||
    {% endif %}
 | 
					    {% endif %}
 | 
				
			||||||
{% endblock %}
 | 
					{% endblock %}
 | 
				
			||||||
| 
						 | 
					@ -13,9 +13,7 @@
 | 
				
			||||||
{% endblock %}
 | 
					{% endblock %}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
{% block footer %}
 | 
					{% block footer %}
 | 
				
			||||||
<div class="legal">
 | 
					 | 
				
			||||||
    {% include "_footer.html" %}
 | 
					    {% include "_footer.html" %}
 | 
				
			||||||
</div>
 | 
					 | 
				
			||||||
{% endblock %}
 | 
					{% endblock %}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
{% block extra_script %}
 | 
					{% block extra_script %}
 | 
				
			||||||
							
								
								
									
										11
									
								
								symposion/templates/sitetree/menu.html
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								symposion/templates/sitetree/menu.html
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,11 @@
 | 
				
			||||||
 | 
					{% load sitetree %}
 | 
				
			||||||
 | 
					<ul class="nav">
 | 
				
			||||||
 | 
						{% for item in sitetree_items %}
 | 
				
			||||||
 | 
						<li class="{{ item.is_current|yesno:"active ," }}">
 | 
				
			||||||
 | 
					        <a href="{% sitetree_url for item %}" title="{{ item.hint|default:"" }}">{{ item.title_resolved }}</a>
 | 
				
			||||||
 | 
							{% if item.has_children %}
 | 
				
			||||||
 | 
								{% sitetree_children of item for menu template "sitetree/menu.html" %}
 | 
				
			||||||
 | 
							{% endif %}
 | 
				
			||||||
 | 
						</li>
 | 
				
			||||||
 | 
						{% endfor %}
 | 
				
			||||||
 | 
					</ul>
 | 
				
			||||||
| 
						 | 
					@ -1,14 +1,13 @@
 | 
				
			||||||
from django.conf import settings
 | 
					from django.conf import settings
 | 
				
			||||||
from django.conf.urls.defaults import *
 | 
					from django.conf.urls.defaults import *
 | 
				
			||||||
 | 
					from django.conf.urls.static import static
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from django.views.generic.simple import direct_to_template
 | 
					from django.views.generic.simple import direct_to_template
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from django.contrib import admin
 | 
					from django.contrib import admin
 | 
				
			||||||
admin.autodiscover()
 | 
					admin.autodiscover()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
from pinax.apps.account.openid_consumer import PinaxConsumer
 | 
					# from pinax.apps.account.openid_consumer import PinaxConsumer
 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
handler500 = "pinax.views.server_error"
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
WIKI_SLUG = r"(([\w-]{2,})(/[\w-]{2,})*)"
 | 
					WIKI_SLUG = r"(([\w-]{2,})(/[\w-]{2,})*)"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -16,17 +15,14 @@ urlpatterns = patterns("",
 | 
				
			||||||
    url(r"^$", direct_to_template, {
 | 
					    url(r"^$", direct_to_template, {
 | 
				
			||||||
        "template": "homepage.html",
 | 
					        "template": "homepage.html",
 | 
				
			||||||
    }, name="home"),
 | 
					    }, name="home"),
 | 
				
			||||||
    url(r"^admin/invite_user/$", "pinax.apps.signup_codes.views.admin_invite_user", name="admin_invite_user"),
 | 
					 | 
				
			||||||
    url(r"^admin/", include(admin.site.urls)),
 | 
					    url(r"^admin/", include(admin.site.urls)),
 | 
				
			||||||
    url(r"^about/", include("about.urls")),
 | 
					    url(r"^about/", include("symposion.about.urls")),
 | 
				
			||||||
    url(r"^account/", include("pinax.apps.account.urls")),
 | 
					    url(r"^account/", include("account.urls")),
 | 
				
			||||||
    url(r"^openid/", include(PinaxConsumer().urls)),
 | 
					    # url(r"^openid/", include(PinaxConsumer().urls)),
 | 
				
			||||||
    url(r"^markitup/", include("markitup.urls")),
 | 
					    
 | 
				
			||||||
    url(r"^(?P<slug>%s)/$" % WIKI_SLUG, "cms.views.page", name="cms_page"),
 | 
					    url(r"^(?P<slug>%s)/$" % WIKI_SLUG, "cms.views.page", name="cms_page"),
 | 
				
			||||||
 | 
					    url(r"^markitup/", include("markitup.urls")),
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
if settings.SERVE_MEDIA:
 | 
					urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
 | 
				
			||||||
    urlpatterns += patterns("",
 | 
					 | 
				
			||||||
        url(r"", include("staticfiles.urls")),
 | 
					 | 
				
			||||||
    )
 | 
					 | 
				
			||||||
| 
						 | 
					@ -1,20 +0,0 @@
 | 
				
			||||||
#!/usr/bin/env python
 | 
					 | 
				
			||||||
import sys
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
try:
 | 
					 | 
				
			||||||
    import pinax
 | 
					 | 
				
			||||||
except ImportError:
 | 
					 | 
				
			||||||
    sys.stderr.write("Error: Can't import Pinax. Make sure you are in a "
 | 
					 | 
				
			||||||
        "virtual environment that has\nPinax installed.\n")
 | 
					 | 
				
			||||||
    sys.exit(1)
 | 
					 | 
				
			||||||
else:
 | 
					 | 
				
			||||||
    import pinax.env
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
from django.core.management import execute_from_command_line
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
pinax.env.setup_environ(__file__)
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
if __name__ == "__main__":
 | 
					 | 
				
			||||||
    execute_from_command_line()
 | 
					 | 
				
			||||||
| 
						 | 
					@ -1,4 +0,0 @@
 | 
				
			||||||
{% load i18n %}
 | 
					 | 
				
			||||||
<div class="legal">
 | 
					 | 
				
			||||||
    {% trans "© 2012 <your company here>" %}
 | 
					 | 
				
			||||||
</div>
 | 
					 | 
				
			||||||
		Loading…
	
	Add table
		
		Reference in a new issue