Hi there,
Yes I'm new to wep2py *and* to Python (other than having edited some
Gentoo ebuilds many summers ago), but it was the advice for the simplest
web framework to create simple input/edit functionality for a database to
have customer details captured in a closed environment (ie. only trusted
employees on the network and the office, and I mean trusted as in they all
have all the access to all the paper and other files in the current
environment)
So, I have a SOLIDFORM for entry (though the table and row things doesn't
work that great as I have 2/4/3/1/4/2/2/2/2 columns per row and spacing is
off), and now I try to get a SQLFORM.grid going to list and edit the
entries already inserted. I've also cleaned up the standard layout.html to
only show what I need/want (like removing the auth links on the top right).
Yesterday I had an hour to look at the buttons in SQLFORM.grid to edit
their actions, but on first search only tried the links= which just add an
extra link, not replaced/edit the buttons, which pointed me to the jquery
etc. to be investigated, at which point I had to rush out for the rest of
the day.
This morning somethings broke... and yes, it *was* me, but I don't know
where/what ;( (had too many customers telling me "I/we didn't do do
nothing" and then I showed them what and then they remember something
totally different):
1) The SQLFORM.grid nice and gray buttons disappeared, and they just show
up as normal links, no javascript ;(
Where do I start to find that problem/issue?
2) buttons_placement='yes' throws an error when included in the
SQLFORM.grid parameter list:
Traceback (most recent call last):
File "/home/www-data/web2py/gluon/restricted.py", line 220, in restricted
exec ccode in environment
File "/home/www-data/web2py/applications/hvt/controllers/members.py"
<https://quinn-server.quin/admin/default/edit/hvt/controllers/members.py>, line
54, in <module>
File "/home/www-data/web2py/gluon/globals.py", line 385, in <lambda>
self._caller = lambda f: f()
File "/home/www-data/web2py/applications/hvt/controllers/members.py"
<https://quinn-server.quin/admin/default/edit/hvt/controllers/members.py>, line
50, in list
links=[lambda row: A('View',_href=URL('view',args=[grdb.clients,row.id]))]
TypeError: __call__() got an unexpected keyword argument 'buttons_placement'
def list():
grid = SQLFORM.grid(grdb.clients,
buttons_placement='left',
fields=[grdb.clients.id,grdb.clients.Surname,grdb.clients.Initials,grdb.clients.Email],
user_signature=False,
links=[lambda row:
A('View',_href=URL('view',args=[grdb.clients,row.id]))]
)
What do I miss where?
Thanks for the help thus far
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.