Last change
on this file since 2261 was
2261,
checked in by mylan, 14 years ago
|
Added example content type
|
-
Property svn:eol-style set to
native
|
File size:
931 bytes
|
Rev | Line | |
---|
[2261] | 1 | from AccessControl import ClassSecurityInfo |
---|
| 2 | |
---|
| 3 | from Products.Archetypes.public import * |
---|
| 4 | from Products.ATContentTypes.content.base import ATCTContent |
---|
| 5 | |
---|
| 6 | |
---|
| 7 | from quintagroup.referencedatagridfield import PKG_NAME |
---|
| 8 | from quintagroup.referencedatagridfield import ReferenceDataGridField |
---|
| 9 | from quintagroup.referencedatagridfield import ReferenceDataGridWidget |
---|
| 10 | |
---|
| 11 | class ReferenceDataGridDemoType(ATCTContent): |
---|
| 12 | """ Simple ReferenceDataGridField demo.""" |
---|
| 13 | security = ClassSecurityInfo() |
---|
| 14 | schema = BaseSchema + Schema(( |
---|
| 15 | |
---|
| 16 | ReferenceDataGridField('DemoReferenceDataGridField', |
---|
| 17 | schemata='default', |
---|
| 18 | widget = ReferenceDataGridWidget( |
---|
| 19 | label = "Reference DataGrid Field(s)", |
---|
| 20 | visible = {'edit' : 'visible', 'view' : 'visible'} |
---|
| 21 | ) |
---|
| 22 | ), |
---|
| 23 | )) |
---|
| 24 | |
---|
| 25 | meta_type = portal_type = archetype_name = 'ReferenceDataGridDemoType' |
---|
| 26 | |
---|
| 27 | registerType(ReferenceDataGridDemoType, PKG_NAME) |
---|
Note: See
TracBrowser
for help on using the repository browser.