Ejemplo n.º 1
0
def get_campaign_choices():
    campaigns = db.fetch_campaigns()
    campaign_choices = map(lambda c: (c.key.urlsafe(), c.name), campaigns)
    return campaign_choices
Ejemplo n.º 2
0
 def render_campaigns(self, add_campaign_form=None):
     campaigns = db.fetch_campaigns()
     if add_campaign_form is None:
         add_campaign_form = AddCampaignForm().get_form()
     self.render_template('admin/admin_campaigns.html', campaigns=campaigns, add_campaign_form=add_campaign_form) 
Ejemplo n.º 3
0
def get_campaign_choices():
    campaigns = db.fetch_campaigns()
    campaign_choices = map(lambda c: (c.key.urlsafe(), c.name), campaigns)
    return campaign_choices