Using postgres i debug IntegrityError: insert or update on table "plugin_webfolder_files" violates foreign key constraint "plugin_webfolder_files_parent_fkey" DETAIL: Key (parent)=(0) is not present in table "plugin_webfolder_files". Have you a suggest?
On 29 Gen, 10:38, selecta <[email protected]> wrote: > Here is a webfolder plug-in. It is still quite > raw.http://jaguar.biologie.hu-berlin.de/~fkrause/web2py.plugin.webfolder.w2p > Feel free to use and improve it. > > It depends on an improved IS_IN_SET validator. To use the plug-in you > need to replace the constructor of IS_IN_SET (gluon/validators.py) > with > > def __init__( > self, > theset, > labels=None, > error_message='value not allowed', > multiple=False, > zero='', > sort=False, > ): > self.multiple = multiple > self.labels = labels > if theset and (isinstance(theset[0], list) or isinstance(theset > [0], tuple)) and len(theset[0])==2: > self.theset = [str(item) for item,label in theset] > self.labels = [str(label) for item,label in theset] > else: > self.theset = [str(item) for item in theset] > if isinstance(theset, dict): > self.labels = theset.values() > self.error_message = error_message > self.zero = zero > self.sort = sort -- You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/web2py?hl=en.

