示例#1
0
def worship1():
    worship = Worship(name='Worship Test',
                      week_day='sunday',
                      schedule='09:00',
                      pastor='Abriran Abilu')
    worship.put()
    return worship
示例#2
0
def edit(id):
    method = 'POST'
    action = '.'
    worship = Worship.get_by_id(id)
    form = WorshipForm(request.form, worship)
    if form.validate_on_submit():
        worship = Worship.get_by_id(id)
        form.populate_obj(worship)
        worship.put()
        flash('Worship updated!')
    return render_template("worships/edit.html", form=form, method=method, action=action)
示例#3
0
def new():
    method = 'POST'
    action = '.'
    form = WorshipForm(request.form)
    if form.validate_on_submit():
        worship = Worship()
        form.populate_obj(worship)
        worship.put()
        flash('Worship created!')
        return redirect(url_for('.index'))
    return render_template("worships/new.html", form=form, method=method, action=action)
示例#4
0
def edit(id):
    method = 'POST'
    action = '.'
    worship = Worship.get_by_id(id)
    form = WorshipForm(request.form, worship)
    if form.validate_on_submit():
        worship = Worship.get_by_id(id)
        form.populate_obj(worship)
        worship.put()
        flash('Worship updated!')
    return render_template("worships/edit.html",
                           form=form,
                           method=method,
                           action=action)
示例#5
0
def new():
    method = 'POST'
    action = '.'
    form = WorshipForm(request.form)
    if form.validate_on_submit():
        worship = Worship()
        form.populate_obj(worship)
        worship.put()
        flash('Worship created!')
        return redirect(url_for('.index'))
    return render_template("worships/new.html",
                           form=form,
                           method=method,
                           action=action)
示例#6
0
def index():
    worships = Worship.query()
    return render_template("worships/index.html", worships=worships)
示例#7
0
def worships():
    worships = Worship.all()
    return render_template("site/worships.html", worships=worships)
示例#8
0
def worships():
  worships = Worship.all()
  return render_template("site/worships.html", worships=worships)
示例#9
0
def worship1():
  worship = Worship(name='Worship Test',week_day='sunday', schedule='09:00',pastor='Abriran Abilu')
  worship.put()
  return worship
示例#10
0
def index():
    worships = Worship.query()
    return render_template("worships/index.html",worships=worships)