| 1 | [wiki:Haiti] |
| 2 | == Code Cleanups == |
| 3 | * RepresentSafety |
| 4 | * crud_strings format |
| 5 | * Move from the older, slow, more memory-hungry style: |
| 6 | {{{ |
| 7 | title_create = T('Add Key') |
| 8 | title_display = T('Key Details') |
| 9 | title_list = T('List Keys') |
| 10 | title_update = T('Edit Key') |
| 11 | title_search = T('Search Keys') |
| 12 | subtitle_create = T('Add New Key') |
| 13 | subtitle_list = T('Keys') |
| 14 | label_list_button = T('List Keys') |
| 15 | label_create_button = T('Add Key') |
| 16 | msg_record_created = T('Key added') |
| 17 | msg_record_modified = T('Key updated') |
| 18 | msg_record_deleted = T('Key deleted') |
| 19 | msg_list_empty = T('No Keys currently defined') |
| 20 | s3.crud_strings[table] = Storage(title_create=title_create,title_display=title_display,title_list=title_list,title_update=title_update,title_search=title_search,subtitle_create=subtitle_create,subtitle_list=subtitle_list,label_list_button=label_list_button,label_create_button=label_create_button,msg_record_created=msg_record_created,msg_record_modified=msg_record_modified,msg_record_deleted=msg_record_deleted,msg_list_empty=msg_list_empty) |
| 21 | }}} |
| 22 | to the leaner, easier to read: |
| 23 | {{{ |
| 24 | s3.crud_strings[table] = Storage( |
| 25 | title_create = T('Add Hospital'), |
| 26 | title_display = T('Hospital Details'), |
| 27 | title_list = T('List Hospitals'), |
| 28 | title_update = T('Edit Hospital'), |
| 29 | title_search = T('Search Hospitals'), |
| 30 | subtitle_create = T('Add New Hospital'), |
| 31 | subtitle_list = T('Hospitals'), |
| 32 | label_list_button = T('List Hospitals'), |
| 33 | label_create_button = T('Add Hospital'), |
| 34 | label_delete_button = T('Delete Hospital'), |
| 35 | msg_record_created = T('Hospital information added'), |
| 36 | msg_record_modified = T('Hospital information updated'), |
| 37 | msg_record_deleted = T('Hospital information deleted'), |
| 38 | msg_list_empty = T('No hospitals currently registered')) |
| 39 | }}} |
| 40 | |
| 41 | ---- |
| 42 | [wiki:Haiti] |