PHP Class ForumMergePlugin, addons

Inheritance: implements Gdn_IPlugin
Mostra file Open project: vanilla/addons

Protected Properties

Property Type Description
$TableRowThreshold Limit of rows in a table before structural changes are aborted

Public Methods

Method Description
Base_GetAppSettingsMenuItems_Handler ( $Sender, $Args ) Add to the dashboard menu.
GetColumns ( $Table, $OldDatabase, $OldPrefix, $Options = [] ) : string Match up columns existing in both target and source tables.
MergeForums ( $OldDatabase, $OldPrefix, $LegacySlug ) Grab second forum's data and merge with current forum.
OldTableExists ( $TableName ) : boolean Do we have a corresponding table to merge?
Setup ( )
Structure ( )
UtilityController_MergeReset_Create ( ) Nuke every OldID column before a second merge.
UtilityController_Merge_Create ( $Sender ) Admin screen for merging forums.

Method Details

Base_GetAppSettingsMenuItems_Handler() public method

Add to the dashboard menu.
public Base_GetAppSettingsMenuItems_Handler ( $Sender, $Args )

GetColumns() public method

Match up columns existing in both target and source tables.
public GetColumns ( $Table, $OldDatabase, $OldPrefix, $Options = [] ) : string
return string CSV list of columns in both copies of the table minus the primary key.

MergeForums() public method

Merge Users on email address. Keeps this forum's username/password. Merge Roles, Tags, and Categories on precise name matches.
public MergeForums ( $OldDatabase, $OldPrefix, $LegacySlug )

OldTableExists() public method

Do we have a corresponding table to merge?
public OldTableExists ( $TableName ) : boolean
$TableName
return boolean

Setup() public method

public Setup ( )

Structure() public method

public Structure ( )

UtilityController_MergeReset_Create() public method

Nuke every OldID column before a second merge.

UtilityController_Merge_Create() public method

Admin screen for merging forums.
public UtilityController_Merge_Create ( $Sender )

Property Details

$TableRowThreshold protected_oe property

Limit of rows in a table before structural changes are aborted
protected $TableRowThreshold