Best and simpler approach to Inline editing / deleting / appending (jqGrid, Jeditable,etc)

659 views
Skip to first unread message

clara

unread,
Feb 7, 2015, 11:00:45 PM2/7/15
to web...@googlegroups.com
Hello,

I know this has been asked before, there are Web2py Slices (some of which seem to be outdated), questions posted here on the subject but somehow it is not clear to me which path I should take to implement a grid with inline editable fields, appendable/deletable records. I am looking to some "compact" solution which I am not sure it exist that would have the functionality of current SQLFORM.smartgrid  but in addition to it: inline editable fields and deletable/appendable records.

I will greatly appreciate any input on this. 

Best regards,

Clara





 

Michael Beller

unread,
Feb 9, 2015, 9:50:00 PM2/9/15
to web...@googlegroups.com
I've started using http://www.datatables.net/ primarily for the great search and responsive behavior.  I've read about the inline support but haven't tried it yet but it looks very good.

The other option that looks very good is http://handsontable.com/ but I've only read through the documentation.

Massimo Di Pierro

unread,
Feb 11, 2015, 11:25:07 AM2/11/15
to web...@googlegroups.com
I have used both and I think handsontable is much superior and customizable.

Clara Ferrando

unread,
Feb 13, 2015, 6:36:48 AM2/13/15
to web...@googlegroups.com

Hello,

Thanks all for the support and suggestions.
I was able to get the slice using Jqgrid working (http://www.web2pyslices.com/slice/show/1714/jqgrid-viewing-and-updating-data). But I will take a look at the Massimo and Michael suggestions.

Thanks again,

Clara


--
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 a topic in the Google Groups "web2py-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/web2py/ZFG0Z3-oQSg/unsubscribe.
To unsubscribe from this group and all its topics, send an email to web2py+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Tim Richardson

unread,
Feb 13, 2015, 2:36:32 PM2/13/15
to web...@googlegroups.com
there is this approach as well, which makes the existing SQLGRID.grid widget editable.

WeiI Wang

unread,
Aug 28, 2016, 8:41:17 PM8/28/16
to web2py-users
Hi Tim,

I tried the inline edit for sqlform grid.
The problem I have is there is only one submit button and whenever I edit something and submit, all the records' update time becomes the same.
Is it possible to have one submit button for each row?

Tim Richardson

unread,
Aug 29, 2016, 6:22:05 PM8/29/16
to web...@googlegroups.com
I wonder if in that case you are better making lots of individual forms. That's what I would do.

To unsubscribe from this group and all its topics, send an email to web2py+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Tim Richardson

Henk huisman

unread,
Aug 29, 2016, 7:38:25 PM8/29/16
to web2py-users
Hi Clara,
I have been looking for a powerful grid component too. Started using jqGrid.  It's really nice and very powerful; I recommend it.
Depends a bit on what license you looking for. For non-commercial organisations it's free.

Henk




 

 

thomaska...@gmail.com

unread,
May 20, 2018, 3:40:19 PM5/20/18
to web2py-users
Hi Tim,

I tried your example from the link to the slice below, but I received the error 'NoneType' object is not callable:

1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
Traceback (most recent call last):
File "/Users/thomas_kappeler/Desktop/CAS-BigDATA_ML/MT-Abschlussarbeit/web2py/gluon/restricted.py", line 219, in restricted
exec(ccode, environment)
File "/Users/thomas_kappeler/Desktop/CAS-BigDATA_ML/MT-Abschlussarbeit/web2py/applications/sample_grid/controllers/default.py", line 104, in <module>
File "/Users/thomas_kappeler/Desktop/CAS-BigDATA_ML/MT-Abschlussarbeit/web2py/gluon/globals.py", line 419, in <lambda>
self._caller = lambda f: f()
File "/Users/thomas_kappeler/Desktop/CAS-BigDATA_ML/MT-Abschlussarbeit/web2py/applications/sample_grid/controllers/default.py", line 77, in editable_grid
for key, value in request.vars.iteritems():
TypeError: 'NoneType' object is not callable
Version info: web2py™

Version 2.16.1

Python: Python 3.6.4

Do you have any explanation for this? Has there been a change in web2py that makes this obsolete?

Thanks,
Thomas

Tim Richardson

unread,
May 20, 2018, 8:37:16 PM5/20/18
to web...@googlegroups.com
That approach was close to a hack. I don't know why it's not working and I don't use this code any longer. I think, unfortunately perhaps, a rich client approach has won the debate, so you'll probably need to find a JavaScript approach, but web2py power users may have other advice. 

thomaska...@gmail.com

unread,
May 21, 2018, 3:55:51 AM5/21/18
to web2py-users
Hi Tim,

thank you for answering. I found out that if you use 
    for key, value in request.post_vars.items():
instead of
for key, value in request.post_vars.iteritems():
and of course correct the typo (missing ' in Field('is_happy','boolean))
you can still make that code work.
So I'm still very grateful for that code.

Thanks,
Thomas
Reply all
Reply to author
Forward
0 new messages