def __init__(self, login):
		Node.__init__(self)
		self.login = template.Variable(login)
Example #2
0
	def __init__(self):
		Node.__init__(self)
Example #3
0
def all(section):
    nodes_query = Node.all().filter('section =', section.key()).order('inserted')
    return nodes_query
Example #4
0
def index(section):
    # have to return an iterable (since I have no idea how to assign it to one var in the template)
    nodes = Node.all().filter('section =', section.key()).filter('name =', 'index')
    return nodes
Example #5
0
def latest(section, limit):
    nodes_query = Node.all().filter('section =', section.key()).order('-inserted')
    nodes = None
    if limit > 0:
        nodes = nodes_query.fetch(limit)
    return nodes or nodes_query
Example #6
0
 def __init__(self):
     Node.__init__(self)
Example #7
0
 def __init__(self, login):
     Node.__init__(self)
     self.login = template.Variable(login)
Example #8
0
	def __init__(self, asvar=None):
		Node.__init__(self)
		self.asvar = asvar
Example #9
0
from django.http import HttpRequest
from django.template import Node, RequestContext
from django.shortcuts import render_to_response, redirect

from mediasync.templatetags.media import BaseTagNode as mds_node

S3_PATH = mds_node(Node()).get_media_url(RequestContext(
    HttpRequest())) + '/img/holidays/'

CARD_LIST = [{
    'slug':
    'burgess',
    'image_url':
    S3_PATH + 'Burgess%20-%20Image.jpg',
    'thumbnail_url':
    S3_PATH + 'thumbs/Burgess%20-%20Image.jpg',
    'audio_url':
    S3_PATH + 'Burgess%20-%20Audio.mp3',
    'email_url':
    'http://organizing.sunlightfoundation.com/page/share/capitol-greetings-sledding',
    'share_text':
    "It's going to be tough sledding in the Senate. #CongressSez http://snlg.ht/urKxui via @sunfoundation",
}, {
    'slug':
    'collins1',
    'image_url':
    S3_PATH + 'Collins1%20-%20Image.jpg',
    'thumbnail_url':
    S3_PATH + 'thumbs/Collins1%20-%20Image.jpg',
    'email_url':
    'http://organizing.sunlightfoundation.com/page/share/capitol-greetings-tree',