Changes between Version 20 and Version 21 of S3/S3Model/ComponentResources
- Timestamp:
- 12/03/11 22:45:11 (13 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
S3/S3Model/ComponentResources
v20 v21 55 55 s3mgr.model.add_component("my_component", # Tablename of the component 56 56 my_master=dict( # Tablename of the master table 57 name="alias", # Use this 'alias' as the component name 57 58 link="my_linktable", # Tablename of the link table 58 59 joinby="fieldname", # FK of the master table (=left key constraint) … … 70 71 Important: if you specify a widget for embedding (e.g. S3AddPersonWidget), then you must ensure that the foreign key in the link-table doesn't also use either this widget or any other widget validator! 71 72 73 If {{{name='alias'}}} is specified, the component would not be addressed in the URL as {{{master/component}}} but as {{{master/alias}}}. This allows to link the same component table to the same master table more than once using different link tables. 74 72 75 ---- 73 76