Bruno to solve 'PowerFormWizard' object has no attribute 'readonly'
I added 2 lines to powerForm plugin
In modules/plugin_PowerFormWizard.py
def __init__(self,
table,
steps,
formstyle = 'divs',
options={},
_id = 'powerformwizard',
record = None,
fields = None,
ignore_rw = False,
record_id=None,
*readonly=None, #maybe another value for default*
**attributes
):
if formstyle not in ['divs','ul']:
raise AttributeError("SQLFORM formstyle not accepted")
from gluon import current
response = current.response
self.T = current.T
self.table = table
self.formstyle = formstyle
self.attributes = attributes
self.ignore_rw = ignore_rw
self.record_id = record_id
self.options = options
self._id = _id
*self.readonly=readonly*
*
*
*and the problem is gone....*
*
*
Happy New Year... to all from Chile
El lunes, 23 de julio de 2012 20:43:54 UTC-4, rochacbruno escribió:
>
> Hi,
>
> As I am not having time to keep the plugin updated (and no one wanted toa
> dopt the plugin)
>
> I recommend the method using steps and session, I use this sometimes and
> works well, take a look:
> http://www.web2pyslices.com/slice/show/1452/form-wizard
>
>
>
> *Bruno Cezar Rocha*
>
> http://www.CursoDePython.com.br
> [image: Facebook] <http://facebook.com/rochacbruno> [image:
> Twitter]<http://twitter.com/rochacbruno> [image:
> LinkedIn] <http://linkedin.com/in/rochacbruno> [image:
> about.me]<http://about.me/rochacbruno> [image:
> Amazon] <http://amazon.com/author/rochacbruno> [image:
> AngelList]<http://angel.co/rochacbruno> [image:
> Blog RSS] <http://www.web2pyslices.com/slice/list.rss?author=1> [image:
> Facebook Page] <http://facebook.com/CursoDePython> [image:
> foursquare]<http://foursquare.com/rochacbruno> [image:
> Google Plus] <https://plus.google.com/u/0/116110204708544946953/posts>
> [image:
> pinterest] <http://pinterest.com/rochacbruno> [image:
> SlideShare]<http://slideshare.com/rochacbruno> [image:
> YouTube] <http://youtube.com/user/brunovegan>
> [image: Google Talk] rochacbruno [image: Skype] blouweb
> Blog: Generate a thumbnail that fits in a
> box<http://www.web2pyslices.com/slice/show/1522/generate-a-thumbnail-that-fits-in-a-box>
> Get a signature like this.
> <http://r1.wisestamp.com/r/landing?promo=18&dest=http%3A%2F%2Fwww.wisestamp.com%2Femail-install%3Futm_source%3Dextension%26utm_medium%3Demail%26utm_campaign%3Dpromo_18>
> Click
> here.<http://r1.wisestamp.com/r/landing?promo=18&dest=http%3A%2F%2Fwww.wisestamp.com%2Femail-install%3Futm_source%3Dextension%26utm_medium%3Demail%26utm_campaign%3Dpromo_18>
>
>
>
>
> On Mon, Jul 23, 2012 at 9:41 PM, Don_X <[email protected]
> <javascript:>>wrote:
>
>> Bruno Rocha,
>>
>> This is a very nice plugin ! ... very useful, thanks for sharing !
>>
>> I have to create 2 registrations methods ( one short and one long method
>> to register )
>>
>> I have one problem, how would you suggest to user the wizard when there
>> are 3 tables involved in the long signup method ??
>>
>> for example in my db I have many tables ... but the full registration for
>> the app affects 3 tables, while the short one which is already done only
>> affects 1 table ( the auth-user table) !
>> I need to manipulate the powerformwizard for all 3 tables in the complete
>> registration approach
>>
>> table1 is the auth-user table with first and lastname, password and
>> email, birthdate and user type.
>> table2 is the coordinates of the user ( with street adress, city, Zip or
>> postal code, Country of residence, Origin and language spoken )
>> table3 is the profile informations ( like picture upload, description,
>> story, bio, ..)
>>
>> Any suggestions ? ...
>>
>> thanks
>>
>> Don
>>
>>
>> --
>>
>>
>>
>>
>
>
--