[Product-Developers] dynamically generating form title
Mayank Mathur
mayankmathur at tetrain.com
Fri Oct 31 08:50:49 UTC 2008
i want to replace my form title and append with [MR- <formname>], so
that it'll save like MR- <formname>
here's my code for Archetype:
/*StringField('title',
required=1,
default='',
accessor='Title1',
widget=StringWidget(
label_msgid='masterentryform_program_label_title',
visible = {'edit': 'visible', 'view': 'invisible'},
#visible={'view' : 'invisible'},
#i18n_domain='masterentryform',
i18n_domain='masterentryform_program',
),
#storage=MySQLSQLStorage(),
),
*/code for method:/*
def Title1(self):
return "[MR] - [%s]" % (blurb),
*/where, blurb will retrurn form title.
but instead of returning title in this form, its saving form name with
name of folder inside which im creating this form.
Is there any prb with this code ??
thanks for any suggestion//
--
Regards,
Mayank Mathur
More information about the Product-Developers
mailing list