Issue #4 resolved

PFW doesn't work with autocomplete widget

jredrejo avatarjredrejo created an issue

The bug is explained by me at https://groups.google.com/d/topic/web2py/kWWuvYzdHCU/discussion

I have done this fix, and I think it doesn't break anything, but it would be great if you can check it,as you know much better the plugin:

$ diff -u modules/plugin_PowerFormWizard.py.malo modules/plugin_PowerFormWizard.py
--- modules/plugin_PowerFormWizard.py.malo	2011-08-10 13:35:10.000000000 +0200
+++ modules/plugin_PowerFormWizard.py	2011-08-10 13:36:33.000000000 +0200
@@ -153,14 +153,16 @@
         
         self.record = record
 
-        from gluon.storage import Storage
-        self.custom = Storage() # Needed to silence errors, but Custom Forms are not allowed!
+        #from gluon.storage import Storage
+        #self.custom = Storage() # Needed to silence errors, but Custom Forms are not allowed!
 
         # NEEDED TO CREATE A SQLFORM OBJECT HERE TO EXTRACT DOM ELEMENTS, HOW TO DO BETTER?
         form = SQLFORM(self.table, formstyle=self.formstyle, **attributes)
         
 
         self.p_form = form
+        self.custom=form.custom
+        self.field_parent = form.field_parent
         self.p_steps = steps # [{'title':'Step Title', 'fields':['fieldname1','fieldname2']}]
         self.p_tablename = form.table._tablename
         self.p_attributes = form.attributes

Comments (4)

  1. Log in to comment
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.