Ignore:
Timestamp:
19 Oct 2005, 09:42:03 (19 years ago)
Author:
joachim
Message:

=more

File:
1 edited

Legend:

Unmodified
Added
Removed
  • waeup_product/trunk/skins/waeup_default/getWAeUPLayouts.py

    r49 r57  
    419419        },
    420420        'sc_pin': {
    421             'type': 'String Widget',
     421            'type': 'Scratchcard Pin Widget',
    422422            'data': {
    423423                'title': 'SC Pin',
     
    477477###)
    478478
    479 jamb_layoutcreate = { ###(
    480     'widgets': {
     479jamb_widgets = { ###(
    481480        'reg_nr': {
    482481            'type': 'StudentId Widget',
     
    490489                'help': 'The Student ID from JAMB',
    491490                'is_i18n': False,
    492                 'readonly_layout_modes': (),
    493                 'hidden_layout_modes': (),
    494                 'hidden_readonly_layout_modes': (),
    495                 'hidden_empty': False,
    496                 'hidden_if_expr': '',
    497                 'css_class': '',
    498                 'widget_mode_expr': '',
    499                 'display_width': 8,
    500                 'size_max': 8,
    501             },
    502         },
    503         'name': {
    504             'type': 'String Widget',
    505             'data': {
    506                 'title': '',
    507                 'fields': ('name',),
    508                 'is_required': False,
    509                 'label': 'Name',
    510                 'label_edit': 'Name',
    511                 'description': '',
    512                 'help': 'Please enter your full name.',
     491                'display_width': 10,
     492                'size_max': 10,
     493            },
     494        },
     495        'firstname': {
     496            'type': 'String Widget',
     497            'data': {
     498                'title': 'First Name',
     499                'fields': ('firstname',),
     500                'is_required': False,
     501                'label': 'First Name',
     502                'label_edit': 'First Name',
     503                'description': 'First Name',
     504                'help': 'First name',
     505                'is_i18n': False,
     506                'display_width': 40,
     507            },
     508        },
     509        'middlename': {
     510            'type': 'String Widget',
     511            'data': {
     512                'title': '',
     513                'fields': ('middlename',),
     514                'is_required': False,
     515                'label': 'Middle Name',
     516                'label_edit': 'Middle Name',
     517                'description': '',
     518                'help': 'Middle name',
     519                'is_i18n': False,
     520                'readonly_layout_modes': (),
     521                'hidden_layout_modes': (),
     522                'hidden_readonly_layout_modes': (),
     523                'hidden_empty': False,
     524                'hidden_if_expr': '',
     525                'css_class': '',
     526                'widget_mode_expr': '',
     527                'display_width': 40,
     528                'size_max': 0,
     529            },
     530        },
     531        'lastname': {
     532            'type': 'String Widget',
     533            'data': {
     534                'title': '',
     535                'fields': ('lastname',),
     536                'is_required': False,
     537                'label': 'Surname',
     538                'label_edit': 'Surname',
     539                'description': '',
     540                'help': 'Surname',
    513541                'is_i18n': False,
    514542                'readonly_layout_modes': (),
     
    570598        },
    571599        'state': {
    572             'type': 'String Widget',
    573             'data': {
    574                 'title': '',
    575                 'fields': ('state_of_origin',),
     600            'type': 'Select Widget',
     601            'data': {
     602                'title': '',
     603                'fields': ('state',),
    576604                'is_required': False,
    577605                'label': 'State',
     
    580608                'help': '',
    581609                'is_i18n': False,
    582                 'readonly_layout_modes': (),
    583                 'hidden_layout_modes': (),
    584                 'hidden_readonly_layout_modes': (),
    585                 'hidden_empty': False,
    586                 'hidden_if_expr': '',
    587                 'css_class': '',
    588                 'widget_mode_expr': '',
    589                 'display_width': 20,
    590                 'size_max': 0,
     610                'vocabulary': 'nigerian_states',
    591611            },
    592612        },
     
    614634        },
    615635        'aggregate': {
    616             'type': 'String Widget',
     636            'type': 'Int Widget',
    617637            'data': {
    618638                'title': 'Agregate',
    619639                'fields': ('aggregate',),
    620640                'is_required': False,
    621                 'label': 'Aggregate',
    622                 'label_edit': 'Aggregate',
     641                'label': 'Score',
     642                'label_edit': 'Score',
     643                'description': '',
     644                'help': '',
     645                'is_i18n': False,
     646            },
     647        },
     648        'faculty': {
     649            'type': 'Select Widget',
     650            'data': {
     651                'title': 'Faculty',
     652                'fields': ('faculty',),
     653                'is_required': False,
     654                'label': 'Faculty',
     655                'label_edit': 'Faculty',
     656                'description': '',
     657                'help': '',
     658                'is_i18n': False,
     659                'vocabulary': 'faculties',
     660            },
     661        },
     662        'listing_date': {
     663            'type': 'Date Widget',
     664            'data': {
     665                'title': 'Listing Date',
     666                'fields': ('listing_date',),
     667                'is_required': False,
     668                'label': 'Listing Date',
     669                'label_edit': 'Listing Date',
    623670                'description': '',
    624671                'help': '',
     
    635682            },
    636683        },
    637         '2nd_choice': {
    638             'type': 'String Widget',
    639             'data': {
    640                 'title': 'Second choice',
    641                 'fields': ('2nd_choice',),
    642                 'is_required': False,
    643                 'label': 'Second choice',
    644                 'label_edit': 'Second choice',
    645                 'description': '',
    646                 'help': 'second_choice',
    647                 'is_i18n': False,
    648                 'readonly_layout_modes': (),
    649                 'hidden_layout_modes': (),
    650                 'hidden_readonly_layout_modes': (),
    651                 'hidden_empty': False,
    652                 'hidden_if_expr': '',
    653                 'css_class': '',
    654                 'widget_mode_expr': '',
    655                 'display_width': 20,
    656                 'size_max': 0,
    657             },
    658         },
    659         '3rd_choice': {
    660             'type': 'String Widget',
    661             'data': {
    662                 'title': 'Third_choice',
    663                 'fields': ('3rd_choice',),
    664                 'is_required': False,
    665                 'label': 'Third choice',
    666                 'label_edit': 'Third choice',
    667                 'description': 'third_choice',
    668                 'help': 'third_choice',
    669                 'is_i18n': False,
    670                 'readonly_layout_modes': (),
    671                 'hidden_layout_modes': (),
    672                 'hidden_readonly_layout_modes': (),
    673                 'hidden_empty': False,
    674                 'hidden_if_expr': '',
    675                 'css_class': '',
    676                 'widget_mode_expr': '',
    677                 'display_width': 20,
    678                 'size_max': 0,
    679             },
    680         },
     684##        '2nd_choice': { ###(
     685##            'type': 'String Widget',
     686##            'data': {
     687##                'title': 'Second choice',
     688##                'fields': ('2nd_choice',),
     689##                'is_required': False,
     690##                'label': 'Second choice',
     691##                'label_edit': 'Second choice',
     692##                'description': '',
     693##                'help': 'second_choice',
     694##                'is_i18n': False,
     695##                'readonly_layout_modes': (),
     696##                'hidden_layout_modes': (),
     697##                'hidden_readonly_layout_modes': (),
     698##                'hidden_empty': False,
     699##                'hidden_if_expr': '',
     700##                'css_class': '',
     701##                'widget_mode_expr': '',
     702##                'display_width': 20,
     703##                'size_max': 0,
     704##            },
     705##        },
     706##       
     707##        '3rd_choice': {
     708##            'type': 'String Widget',
     709##            'data': {
     710##                'title': 'Third_choice',
     711##                'fields': ('3rd_choice',),
     712##                'is_required': False,
     713##                'label': 'Third choice',
     714##                'label_edit': 'Third choice',
     715##                'description': 'third_choice',
     716##                'help': 'third_choice',
     717##                'is_i18n': False,
     718##                'readonly_layout_modes': (),
     719##                'hidden_layout_modes': (),
     720##                'hidden_readonly_layout_modes': (),
     721##                'hidden_empty': False,
     722##                'hidden_if_expr': '',
     723##                'css_class': '',
     724##                'widget_mode_expr': '',
     725##                'display_width': 20,
     726##                'size_max': 0,
     727##            },
     728##        },
     729###)
     730
    681731        'sc_id': {
    682732            'type': 'String Widget',
     
    723773            },
    724774        },
    725     },
     775    }
     776###)
     777
     778jamb_layoutcreate = { ###(
     779    'widgets': jamb_widgets,
    726780    'layout': {
    727781        'style_prefix': 'layout_jambcreate_',
     
    730784        'rows': [
    731785            [{'widget_id': 'reg_nr', 'ncols': 1},],
    732             [{'widget_id': 'name', 'ncols': 1},],
     786            [{'widget_id': 'firstname', 'ncols': 1},],
     787            [{'widget_id': 'middlename', 'ncols': 1},],
     788            [{'widget_id': 'lastname', 'ncols': 1},],
    733789            #[{'widget_id': 'sc_id', 'ncols': 1},],
    734790            #[{'widget_id': 'sc_pin', 'ncols': 1},],
     
    736792            [{'widget_id': 'sex', 'ncols': 1},],
    737793            [{'widget_id': 'state', 'ncols': 1},],
    738             [{'widget_id': 'exam_results', 'ncols': 1},],
     794            #[{'widget_id': 'exam_results', 'ncols': 1},],
    739795            [{'widget_id': 'aggregate', 'ncols': 1},],
    740             [{'widget_id': '2nd_choice', 'ncols': 1},],
    741             [{'widget_id': '3rd_choice', 'ncols': 1},],
     796            [{'widget_id': 'faculty', 'ncols': 1},],
     797            [{'widget_id': 'listing_date', 'ncols': 1},],
     798            #[{'widget_id': '2nd_choice', 'ncols': 1},],
     799            #[{'widget_id': '3rd_choice', 'ncols': 1},],
    742800        ]
    743801    },
     
    746804
    747805jamb_layout = { ###(
    748     'widgets': {
    749         'reg_nr': {
    750             'type': 'StudentId Widget',
    751             'data': {
    752                 'title': 'Student ID',
    753                 'fields': ('reg_nr',),
    754                 'is_required': True,
    755                 'label': 'Student ID',
    756                 'label_edit': 'Student ID',
    757                 'description': 'The Student ID from JAMB',
    758                 'help': 'The Student ID from JAMB',
    759                 'is_i18n': False,
    760                 'readonly_layout_modes': (),
    761                 'hidden_layout_modes': (),
    762                 'hidden_readonly_layout_modes': (),
    763                 'hidden_empty': False,
    764                 'hidden_if_expr': '',
    765                 'css_class': '',
    766                 'widget_mode_expr': '',
    767                 'display_width': 8,
    768                 'size_max': 8,
    769             },
    770         },
    771         'name': {
    772             'type': 'String Widget',
    773             'data': {
    774                 'title': '',
    775                 'fields': ('name',),
    776                 'is_required': False,
    777                 'label': 'Name',
    778                 'label_edit': 'Name',
    779                 'description': '',
    780                 'help': 'Please enter your full name.',
    781                 'is_i18n': False,
    782                 'readonly_layout_modes': (),
    783                 'hidden_layout_modes': (),
    784                 'hidden_readonly_layout_modes': (),
    785                 'hidden_empty': False,
    786                 'hidden_if_expr': '',
    787                 'css_class': '',
    788                 'widget_mode_expr': '',
    789                 'display_width': 40,
    790                 'size_max': 0,
    791             },
    792         },
    793         'age': {
    794             'type': 'Int Widget',
    795             'data': {
    796                 'title': '',
    797                 'fields': ('age',),
    798                 'is_required': False,
    799                 'label': 'Age',
    800                 'label_edit': 'Age',
    801                 'description': '',
    802                 'help': '',
    803                 'is_i18n': False,
    804                 'readonly_layout_modes': (),
    805                 'hidden_layout_modes': (),
    806                 'hidden_readonly_layout_modes': (),
    807                 'hidden_empty': False,
    808                 'hidden_if_expr': '',
    809                 'css_class': '',
    810                 'widget_mode_expr': '',
    811                 'display_width': 2,
    812                 'size_max': 2,
    813             },
    814         },
    815         'sex': {
    816             'type': 'Boolean Widget',
    817             'data': {
    818                 'title': '',
    819                 'fields': ('sex',),
    820                 'is_required': False,
    821                 'label': 'sex',
    822                 'label_edit': 'sex',
    823                 'label_false': 'male',
    824                 'label_true': 'female',
    825                 'description': '',
    826                 'help': '',
    827                 'is_i18n': False,
    828                 'readonly_layout_modes': (),
    829                 'hidden_layout_modes': (),
    830                 'hidden_readonly_layout_modes': (),
    831                 'hidden_empty': False,
    832                 'hidden_if_expr': '',
    833                 'css_class': '',
    834                 'widget_mode_expr': '',
    835                 'display_width': 20,
    836                 'size_max': 0,
    837             },
    838         },
    839         'state': {
    840             'type': 'String Widget',
    841             'data': {
    842                 'title': '',
    843                 'fields': ('state_of_origin',),
    844                 'is_required': False,
    845                 'label': 'State',
    846                 'label_edit': 'State',
    847                 'description': '',
    848                 'help': '',
    849                 'is_i18n': False,
    850                 'readonly_layout_modes': (),
    851                 'hidden_layout_modes': (),
    852                 'hidden_readonly_layout_modes': (),
    853                 'hidden_empty': False,
    854                 'hidden_if_expr': '',
    855                 'css_class': '',
    856                 'widget_mode_expr': '',
    857                 'display_width': 20,
    858                 'size_max': 0,
    859             },
    860         },
    861         'exam_results': {
    862             'type': 'String Widget',
    863             'data': {
    864                 'title': '',
    865                 'fields': ('exam_results',),
    866                 'is_required': False,
    867                 'label': 'Jamb Results',
    868                 'label_edit': 'Jamb Results',
    869                 'description': '',
    870                 'help': '',
    871                 'is_i18n': False,
    872                 'readonly_layout_modes': (),
    873                 'hidden_layout_modes': (),
    874                 'hidden_readonly_layout_modes': (),
    875                 'hidden_empty': False,
    876                 'hidden_if_expr': '',
    877                 'css_class': '',
    878                 'widget_mode_expr': '',
    879                 'display_width': 20,
    880                 'size_max': 0,
    881             },
    882         },
    883         'aggregate': {
    884             'type': 'String Widget',
    885             'data': {
    886                 'title': 'Agregate',
    887                 'fields': ('aggregate',),
    888                 'is_required': False,
    889                 'label': 'Aggregate',
    890                 'label_edit': 'Aggregate',
    891                 'description': '',
    892                 'help': '',
    893                 'is_i18n': False,
    894                 'readonly_layout_modes': (),
    895                 'hidden_layout_modes': (),
    896                 'hidden_readonly_layout_modes': (),
    897                 'hidden_empty': False,
    898                 'hidden_if_expr': '',
    899                 'css_class': '',
    900                 'widget_mode_expr': '',
    901                 'display_width': 3,
    902                 'size_max': 0,
    903             },
    904         },
    905         '2nd_choice': {
    906             'type': 'String Widget',
    907             'data': {
    908                 'title': 'Second choice',
    909                 'fields': ('2nd_choice',),
    910                 'is_required': False,
    911                 'label': 'Second choice',
    912                 'label_edit': 'Second choice',
    913                 'description': '',
    914                 'help': 'second_choice',
    915                 'is_i18n': False,
    916                 'readonly_layout_modes': (),
    917                 'hidden_layout_modes': (),
    918                 'hidden_readonly_layout_modes': (),
    919                 'hidden_empty': False,
    920                 'hidden_if_expr': '',
    921                 'css_class': '',
    922                 'widget_mode_expr': '',
    923                 'display_width': 20,
    924                 'size_max': 0,
    925             },
    926         },
    927         '3rd_choice': {
    928             'type': 'String Widget',
    929             'data': {
    930                 'title': 'Third_choice',
    931                 'fields': ('3rd_choice',),
    932                 'is_required': False,
    933                 'label': 'Third choice',
    934                 'label_edit': 'Third choice',
    935                 'description': 'third_choice',
    936                 'help': 'third_choice',
    937                 'is_i18n': False,
    938                 'readonly_layout_modes': (),
    939                 'hidden_layout_modes': (),
    940                 'hidden_readonly_layout_modes': (),
    941                 'hidden_empty': False,
    942                 'hidden_if_expr': '',
    943                 'css_class': '',
    944                 'widget_mode_expr': '',
    945                 'display_width': 20,
    946                 'size_max': 0,
    947             },
    948         },
    949         'sc_id': {
    950             'type': 'String Widget',
    951             'data': {
    952                 'title': '',
    953                 'fields': ('admission_sc_id',),
    954                 'is_required': False,
    955                 'label': 'Scratch card ID used',
    956                 'label_edit': 'Scratch card ID used',
    957                 'description': '',
    958                 'help': '',
    959                 'is_i18n': False,
    960                 'readonly_layout_modes': (),
    961                 'hidden_layout_modes': (),
    962                 'hidden_readonly_layout_modes': (),
    963                 'hidden_empty': False,
    964                 'hidden_if_expr': '',
    965                 'css_class': '',
    966                 'widget_mode_expr': '',
    967                 'display_width': 20,
    968                 'size_max': 0,
    969             },
    970         },
    971         'sc_pin': {
    972             'type': 'String Widget',
    973             'data': {
    974                 'title': '',
    975                 'fields': ('admission_sc_pin',),
    976                 'is_required': False,
    977                 'label': 'Scratch card PIN used',
    978                 'label_edit': 'Scratch card PIN used',
    979                 'description': '',
    980                 'help': '',
    981                 'is_i18n': False,
    982                 'readonly_layout_modes': (),
    983                 'hidden_layout_modes': (),
    984                 'hidden_readonly_layout_modes': (),
    985                 'hidden_empty': False,
    986                 'hidden_if_expr': '',
    987                 'css_class': '',
    988                 'widget_mode_expr': '',
    989                 'display_width': 20,
    990                 'size_max': 0,
    991             },
    992         },
    993     },
     806    'widgets': jamb_widgets,
    994807    'layout': {
    995808        'style_prefix': 'layout_default_',
     
    998811        'rows': [
    999812            [{'widget_id': 'reg_nr', 'ncols': 1},],
    1000             [{'widget_id': 'name', 'ncols': 1},],
    1001             [{'widget_id': 'sc_id', 'ncols': 1},],
    1002             [{'widget_id': 'sc_pin', 'ncols': 1},],
     813            [{'widget_id': 'firstname', 'ncols': 1},],
     814            [{'widget_id': 'middlename', 'ncols': 1},],
     815            [{'widget_id': 'lastname', 'ncols': 1},],
     816            #[{'widget_id': 'sc_id', 'ncols': 1},],
     817            #[{'widget_id': 'sc_pin', 'ncols': 1},],
    1003818            [{'widget_id': 'age', 'ncols': 1},],
    1004819            [{'widget_id': 'sex', 'ncols': 1},],
    1005820            [{'widget_id': 'state', 'ncols': 1},],
    1006             [{'widget_id': 'exam_results', 'ncols': 1},],
     821            #[{'widget_id': 'exam_results', 'ncols': 1},],
    1007822            [{'widget_id': 'aggregate', 'ncols': 1},],
    1008             [{'widget_id': '2nd_choice', 'ncols': 1},],
    1009             [{'widget_id': '3rd_choice', 'ncols': 1},],
     823            [{'widget_id': 'faculty', 'ncols': 1},],
     824            [{'widget_id': 'listing_date', 'ncols': 1},],
     825            #[{'widget_id': '2nd_choice', 'ncols': 1},],
     826            #[{'widget_id': '3rd_choice', 'ncols': 1},],
    1010827        ]
    1011828    },
Note: See TracChangeset for help on using the changeset viewer.