Thanks in advance -

I've created the sqlite table.  The records that I've added thus far
show up in the view.  I can add new records without difficulty using
SQLFORM.

However, when I convert the controller to an update/delete form and
hard wire the form to present a specific record in the view to be
updated or deleted - the record details appear and so does the option
to delete - but neither the request to update or delete takes.

The update form in the controller appears as:

def addkit():
    records= db(db.pumpkits.id=='3').select()
    form = SQLFORM(db.pumpkits, records[0], deletable=True)
    if form.accepts(request.vars, session):
        response.flash = 'form accepted'
    elif form.errors:
        response.flash = 'form has errors'

    records = SQLTABLE(db().select(db.pumpkits.ALL))
    return dict(form=form, records=records)

The view is simply:
{{extend 'layout.html'}}

<h1>Manage Kits</h1>
<div style="padding:10px;">
{{=form}}
</div>
{{ =records }

Reply via email to