| 7 |
|
|
| 8 |
schema = BaseSchema + Schema(( |
schema = BaseSchema + Schema(( |
| 9 |
|
|
| 10 |
|
################################### |
| 11 |
|
# default |
| 12 |
LinesField('country', |
LinesField('country', |
| 13 |
widget=MultiSelectionWidget(label='Participating Countries', |
widget=MultiSelectionWidget(label='Participating Countries', |
| 14 |
description="If the Uninted States is one of the countries, select the states that will be involved in this action"), |
description="If the Uninted States is one of the countries, select the states that will be involved in this action"), |
| 29 |
storage=PostgreSQLStorage(), |
storage=PostgreSQLStorage(), |
| 30 |
), |
), |
| 31 |
# CurrentOffice for politicians |
# CurrentOffice for politicians |
| 32 |
StringField('current_position', |
# StringField('current_position', |
| 33 |
widget=StringWidget(label='Current Position'), |
# widget=StringWidget(label='Current Position'), |
| 34 |
storage=PostgreSQLStorage(), |
# storage=PostgreSQLStorage(), |
| 35 |
), |
# ), |
| 36 |
# Empty for non-government |
# Empty for non-government |
| 37 |
StringField('current_district', |
# StringField('current_district', |
| 38 |
widget=StringWidget(label='Current District'), |
# widget=StringWidget(label='Current District'), |
| 39 |
storage=PostgreSQLStorage(), |
# storage=PostgreSQLStorage(), |
| 40 |
), |
# ), |
| 41 |
# US Government or company name |
# US Government or company name |
| 42 |
StringField('organization', |
# StringField('organization', |
| 43 |
widget=StringWidget(label='Organization'), |
# widget=StringWidget(label='Organization'), |
| 44 |
storage=PostgreSQLStorage(), |
# storage=PostgreSQLStorage(), |
| 45 |
default='US Government', |
# default='US Government', |
| 46 |
), |
# ), |
| 47 |
StringField('first_elected', |
# StringField('first_elected', |
| 48 |
widget=StringWidget(label='First Elected'), |
# widget=StringWidget(label='First Elected'), |
| 49 |
storage=PostgreSQLStorage(), |
# storage=PostgreSQLStorage(), |
| 50 |
), |
# ), |
| 51 |
StringField('last_elected', |
# StringField('last_elected', |
| 52 |
widget=StringWidget(label='Last Elected'), |
# widget=StringWidget(label='Last Elected'), |
| 53 |
storage=PostgreSQLStorage(), |
# storage=PostgreSQLStorage(), |
| 54 |
), |
# ), |
| 55 |
StringField('next_election', |
# StringField('next_election', |
| 56 |
widget=StringWidget(label='Next Election'), |
# widget=StringWidget(label='Next Election'), |
| 57 |
storage=PostgreSQLStorage(), |
# storage=PostgreSQLStorage(), |
| 58 |
), |
# ), |
| 59 |
# mmm, True == Male (of course, since I'm a guy) |
# mmm, True == Male (of course, since I'm a guy) |
| 60 |
BooleanField('gender', |
# BooleanField('gender', |
| 61 |
widget=BooleanWidget(label='Gender'), |
# widget=BooleanWidget(label='Gender'), |
| 62 |
storage=PostgreSQLStorage(), |
# storage=PostgreSQLStorage(), |
| 63 |
), |
# ), |
|
LinesField('family', |
|
|
widget=LinesWidget(label='Family'), |
|
|
storage=PostgreSQLStorage(), |
|
|
), |
|
|
StringField('birthdate', |
|
|
widget=StringWidget(label='Birthdate'), |
|
|
storage=PostgreSQLStorage(), |
|
|
), |
|
|
StringField('birthplace', |
|
|
widget=StringWidget(label='Birthplace'), |
|
|
storage=PostgreSQLStorage(), |
|
|
), |
|
|
StringField('home_city', |
|
|
widget=StringWidget(label='Home City'), |
|
|
storage=PostgreSQLStorage(), |
|
|
), |
|
| 64 |
# Some sort of selection widget? Perhaps something stored in pac_tool or |
# Some sort of selection widget? Perhaps something stored in pac_tool or |
| 65 |
# pac_properties? |
# pac_properties? |
| 66 |
StringField('religion', |
# StringField('religion', |
| 67 |
widget=StringWidget(label='Religion'), |
# widget=StringWidget(label='Religion'), |
| 68 |
storage=PostgreSQLStorage(), |
# storage=PostgreSQLStorage(), |
| 69 |
), |
# ), |
| 70 |
|
################################### |
| 71 |
|
|
| 72 |
|
################################### |
| 73 |
|
# recipients |
| 74 |
LinesField('action_recipients', |
LinesField('action_recipients', |
| 75 |
widget=ReferenceWidget(label='Action Recipients'), |
widget=ReferenceWidget(label='Action Recipients'), |
| 76 |
storage=PostgreSQLStorage(), |
storage=PostgreSQLStorage(), |
| 77 |
schemata='recipients', |
schemata='recipients', |
| 78 |
), |
), |
| 79 |
|
################################### |
| 80 |
|
|
| 81 |
)) + TemplateMixin.schema |
)) + TemplateMixin.schema |
| 82 |
|
|