Changeset View
Changeset View
Standalone View
Standalone View
branches/5.2.x/core/units/page_revisions/page_revisions_config.php
Show All 15 Lines | |||||
$config = Array ( | $config = Array ( | ||||
'Prefix' => 'page-revision', | 'Prefix' => 'page-revision', | ||||
'ItemClass' => Array ('class' => 'kDBItem', 'file' => '', 'build_event' => 'OnItemBuild'), | 'ItemClass' => Array ('class' => 'kDBItem', 'file' => '', 'build_event' => 'OnItemBuild'), | ||||
'ListClass' => Array ('class' => 'kDBList', 'file' => '', 'build_event' => 'OnListBuild'), | 'ListClass' => Array ('class' => 'kDBList', 'file' => '', 'build_event' => 'OnListBuild'), | ||||
'EventHandlerClass' => Array ('class' => 'PageRevisionEventHandler', 'file' => 'page_revision_eh.php', 'build_event' => 'OnBuild'), | 'EventHandlerClass' => Array ('class' => 'PageRevisionEventHandler', 'file' => 'page_revision_eh.php', 'build_event' => 'OnBuild'), | ||||
'TagProcessorClass' => Array ('class' => 'PageRevisionTagProcessor', 'file' => 'page_revision_tp.php', 'build_event' => 'OnBuild'), | 'TagProcessorClass' => Array ('class' => 'PageRevisionTagProcessor', 'file' => 'page_revision_tp.php', 'build_event' => 'OnBuild'), | ||||
'Hooks' => array( | |||||
array( | |||||
'Mode' => hAFTER, | |||||
'Conditional' => false, | |||||
'HookToPrefix' => 'content', | |||||
'HookToSpecial' => '*', | |||||
'HookToEvent' => array('OnAfterItemCreate', 'OnAfterItemUpdate', 'OnAfterItemDelete'), | |||||
'DoPrefix' => '', | |||||
'DoSpecial' => '', | |||||
'DoEvent' => 'OnAfterPageContentChangedHook', | |||||
), | |||||
), | |||||
'AutoLoad' => true, | 'AutoLoad' => true, | ||||
'QueryString' => Array ( | 'QueryString' => Array ( | ||||
1 => 'id', | 1 => 'id', | ||||
2 => 'Page', | 2 => 'Page', | ||||
3 => 'PerPage', | 3 => 'PerPage', | ||||
4 => 'event', | 4 => 'event', | ||||
5 => 'mode', // needed? | 5 => 'mode', // needed? | ||||
Show All 37 Lines | |||||
'PageId' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0), | 'PageId' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0), | ||||
'RevisionNumber' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0), | 'RevisionNumber' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0), | ||||
'IsDraft' => Array ( | 'IsDraft' => Array ( | ||||
'type' => 'int', | 'type' => 'int', | ||||
'formatter' => 'kOptionsFormatter', 'options' => Array (1 => 'la_Yes', 0 => 'la_No'), 'use_phrases' => 1, | 'formatter' => 'kOptionsFormatter', 'options' => Array (1 => 'la_Yes', 0 => 'la_No'), 'use_phrases' => 1, | ||||
'not_null' => 1, 'default' => 0 | 'not_null' => 1, 'default' => 0 | ||||
), | ), | ||||
'FromRevisionId' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0), | 'FromRevisionId' => Array ('type' => 'int', 'not_null' => 1, 'default' => 0), | ||||
'PageContent' => array( | |||||
'type' => 'string', | |||||
'formatter' => 'kMultiLanguage', 'db_type' => 'longtext', | |||||
'default' => null, | |||||
), | |||||
'CreatedById' => Array ( | 'CreatedById' => Array ( | ||||
'type' => 'int', | 'type' => 'int', | ||||
'formatter' => 'kLEFTFormatter', 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'), 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Users WHERE %s', 'left_key_field' => 'PortalUserId', 'left_title_field' => USER_TITLE_FIELD, 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'sample_value' => 'Guest', 'required' => 1, | 'formatter' => 'kLEFTFormatter', 'options' => Array (USER_ROOT => 'root', USER_GUEST => 'Guest'), 'left_sql' => 'SELECT %s FROM ' . TABLE_PREFIX . 'Users WHERE %s', 'left_key_field' => 'PortalUserId', 'left_title_field' => USER_TITLE_FIELD, 'error_msgs' => Array ('invalid_option' => '!la_error_UserNotFound!'), 'sample_value' => 'Guest', 'required' => 1, | ||||
'default' => NULL | 'default' => NULL | ||||
), | ), | ||||
'CreatedOn' => Array ('type' => 'int', 'formatter' => 'kDateFormatter', 'default' => '#NOW#'), | 'CreatedOn' => Array ('type' => 'int', 'formatter' => 'kDateFormatter', 'default' => '#NOW#'), | ||||
'AutoSavedOn' => Array ('type' => 'int', 'formatter' => 'kDateFormatter', 'default' => NULL), | 'AutoSavedOn' => Array ('type' => 'int', 'formatter' => 'kDateFormatter', 'default' => NULL), | ||||
'Status' => Array ('type' => 'int', 'formatter' => 'kOptionsFormatter', 'options' => Array (2 => 'la_Pending', 1 => 'la_opt_Published', 0 => 'la_opt_Declined'), 'use_phrases' => 1, 'not_null' => 1, 'default' => 2) | 'Status' => Array ('type' => 'int', 'formatter' => 'kOptionsFormatter', 'options' => Array (2 => 'la_Pending', 1 => 'la_opt_Published', 0 => 'la_opt_Declined'), 'use_phrases' => 1, 'not_null' => 1, 'default' => 2) | ||||
Show All 11 Lines |