Version 4.3.6
This commit is contained in:
1 parent
fe1acf984a
commit
1a0c7fd3c2
609 files changed
+14707
-5726
No files matched your search
@@ -29,9 +29,10 @@ class _Core extends \IPS\convert\Library
|
||||
/**
|
||||
* Returns an array of items that we can convert, including the amount of rows stored in the Community Suite as well as the recommend value of rows to convert per cycle
|
||||
*
|
||||
* @param bool $rowCounts enable row counts
|
||||
* @return array
|
||||
*/
|
||||
public function menuRows()
|
||||
public function menuRows( $rowCounts=FALSE )
|
||||
{
|
||||
$return = array();
|
||||
|
||||
@@ -43,8 +44,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_acronyms',
|
||||
'step_method' => 'convertAcronyms',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_acronyms' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_acronyms' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 1000,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_acronyms',
|
||||
@@ -64,8 +65,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_administrators',
|
||||
'step_method' => 'convertAdministrators',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_admin_permission_rows' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_admin_permission_rows' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => $dependencies,
|
||||
'link_type' => 'core_administrators',
|
||||
@@ -76,8 +77,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_announcements',
|
||||
'step_method' => 'convertAnnouncements',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_announcements' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_announcements' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array( 'convertMembers' ),
|
||||
'link_type' => 'core_announcements',
|
||||
@@ -88,8 +89,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_attachments',
|
||||
'step_method' => 'convertAttachments',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_attachments' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_attachments' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array( 'convertMembers' ),
|
||||
'link_type' => 'core_attachments',
|
||||
@@ -100,8 +101,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_banfilters',
|
||||
'step_method' => 'convertBanfilters',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_banfilters' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_banfilters' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_banfilters',
|
||||
@@ -112,8 +113,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[$k] = array(
|
||||
'step_title' => 'convert_custom_bbcode',
|
||||
'step_method' => 'convertCustomBbcode',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'custom_bbcode' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'custom_bbcode' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 2000,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_bbcode',
|
||||
@@ -124,8 +125,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_dname_changes',
|
||||
'step_method' => 'convertDnameChanges',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_member_history', array( 'log_app=? AND log_type=?', 'core', 'display_name' ) )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_member_history', array( 'log_app=? AND log_type=?', 'core', 'display_name' ) ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 2000,
|
||||
'dependencies' => array( 'convertMembers' ),
|
||||
'link_type' => 'core_dname_changes',
|
||||
@@ -136,8 +137,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_edit_history',
|
||||
'step_method' => 'convertEditHistory',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_edit_history' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_edit_history' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 1500,
|
||||
'dependencies' => array( 'convertMembers' ),
|
||||
'link_type' => 'core_edit_history',
|
||||
@@ -148,8 +149,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_emoticons',
|
||||
'step_method' => 'convertEmoticons',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_emoticons' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_emoticons' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_emoticons',
|
||||
@@ -160,8 +161,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_groups',
|
||||
'step_method' => 'convertGroups',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_groups' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_groups' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_groups',
|
||||
@@ -172,8 +173,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_ignored_users',
|
||||
'step_method' => 'convertIgnoredUsers',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_ignored_users' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_ignored_users' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 2000,
|
||||
'dependencies' => array( 'convertMembers' ),
|
||||
'link_type' => 'core_ignored_users',
|
||||
@@ -184,8 +185,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_leader_groups',
|
||||
'step_method' => 'convertLeaderGroups',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_leaders_groups' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_leaders_groups' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_leader_groups',
|
||||
@@ -211,8 +212,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_leaders',
|
||||
'step_method' => 'convertLeaders',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_leaders' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_leaders' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => $dependencies,
|
||||
'link_type' => 'core_leaders',
|
||||
@@ -223,8 +224,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_ranks',
|
||||
'step_method' => 'convertRanks',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_member_ranks' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_member_ranks' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_member_ranks',
|
||||
@@ -235,8 +236,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_reactions',
|
||||
'step_method' => 'convertReactions',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_reactions' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_reactions' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_reactions',
|
||||
@@ -247,8 +248,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_statuses',
|
||||
'step_method' => 'convertStatuses',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_member_status_updates' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_member_status_updates' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 1500,
|
||||
'dependencies' => array( 'convertMembers' ),
|
||||
'link_type' => 'core_member_status_updates',
|
||||
@@ -259,8 +260,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_status_replies',
|
||||
'step_method' => 'convertStatusReplies',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_member_status_replies' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_member_status_replies' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 2000,
|
||||
'dependencies' => array( 'convertMembers', 'convertStatuses' ),
|
||||
'link_type' => 'core_member_status_replies',
|
||||
@@ -284,8 +285,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_members',
|
||||
'step_method' => 'convertMembers',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_members' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_members' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 250,
|
||||
'dependencies' => $dependencies,
|
||||
'link_type' => 'core_members',
|
||||
@@ -296,8 +297,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_member_history',
|
||||
'step_method' => 'convertMemberHistory',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_member_history' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_member_history' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 250,
|
||||
'dependencies' => array( 'convertMembers' ),
|
||||
'link_type' => 'core_member_history',
|
||||
@@ -308,8 +309,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_warn_actions',
|
||||
'step_method' => 'convertWarnActions',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_members_warn_actions' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_members_warn_actions' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_members_warn_actions',
|
||||
@@ -320,8 +321,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_warn_reasons',
|
||||
'step_method' => 'convertWarnReasons',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_members_warn_reasons' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_members_warn_reasons' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_members_warn_reasons',
|
||||
@@ -332,8 +333,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_private_messages',
|
||||
'step_method' => 'convertPrivateMessages',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_message_topics' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_message_topics' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 1000,
|
||||
'dependencies' => array( 'convertMembers' ),
|
||||
'link_type' => array( 'core_message_topics', 'core_message_topic_user_map' ),
|
||||
@@ -344,8 +345,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_private_message_replies',
|
||||
'step_method' => 'convertPrivateMessageReplies',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_message_posts' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_message_posts' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 1000,
|
||||
'dependencies' => array( 'convertPrivateMessages' ),
|
||||
'link_type' => array( 'core_message_posts' ),
|
||||
@@ -357,8 +358,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_moderators',
|
||||
'step_method' => 'convertModerators',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_moderators' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_moderators' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array( 'convertMembers' ),
|
||||
'link_type' => 'core_members',
|
||||
@@ -369,8 +370,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_profile_field_groups',
|
||||
'step_method' => 'convertProfileFieldGroups',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_pfields_groups' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_pfields_groups' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_pfields_groups',
|
||||
@@ -388,8 +389,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_profile_fields',
|
||||
'step_method' => 'convertProfileFields',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_pfields_data' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_pfields_data' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 100,
|
||||
'dependencies' => $dependencies,
|
||||
'link_type' => 'core_pfields_data',
|
||||
@@ -400,8 +401,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_profanity_filters',
|
||||
'step_method' => 'convertProfanityFilters',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_profanity_filters' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_profanity_filters' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 2000,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_profanity_filters',
|
||||
@@ -412,8 +413,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_question_and_answers',
|
||||
'step_method' => 'convertQuestionAndAnswers',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_question_and_answer' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_question_and_answer' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 2000,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_question_and_answer',
|
||||
@@ -424,8 +425,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_report_comments',
|
||||
'step_method' => 'convertReportComments',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_rc_comments' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_rc_comments' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 1500,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_report_comments',
|
||||
@@ -436,8 +437,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_reputation_levels',
|
||||
'step_method' => 'convertReputationLevels',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_reputation_levels' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_reputation_levels' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 2000,
|
||||
'dependencies' => array(),
|
||||
'link_type' => 'core_reputation_levels',
|
||||
@@ -448,8 +449,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_clubs',
|
||||
'step_method' => 'convertClubs',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_clubs' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_clubs' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 2000,
|
||||
'dependencies' => array( 'convertMembers' ),
|
||||
'link_type' => 'core_clubs'
|
||||
@@ -460,8 +461,8 @@ class _Core extends \IPS\convert\Library
|
||||
$return[ $k ] = array(
|
||||
'step_title' => 'convert_club_members',
|
||||
'step_method' => 'convertClubMembers',
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_clubs_memberships' )->first(),
|
||||
'source_rows' => $this->software->countRows( $v['table'], $v['where'] ),
|
||||
'ips_rows' => \IPS\Db::i()->select( 'COUNT(*)', 'core_clubs_memberships' ),
|
||||
'source_rows' => array( 'table' => $v['table'], 'where' => $v['where'] ),
|
||||
'per_cycle' => 2000,
|
||||
'dependencies' => array( 'convertClubs' ),
|
||||
'link_type' => 'core_clubs_memberships'
|
||||
@@ -471,7 +472,13 @@ class _Core extends \IPS\convert\Library
|
||||
}
|
||||
|
||||
$return = $this->software->extraMenuRows( $return );
|
||||
|
||||
|
||||
/* Run the queries if we want row counts */
|
||||
if( $rowCounts )
|
||||
{
|
||||
$return = $this->getDatabaseRowCounts( $return );
|
||||
}
|
||||
|
||||
return $return;
|
||||
}
|
||||
|
||||
@@ -764,7 +771,7 @@ class _Core extends \IPS\convert\Library
|
||||
|
||||
if ( isset( $info['row_updated'] ) )
|
||||
{
|
||||
if ( $info['row_update'] instanceof \IPS\DateTIme )
|
||||
if ( $info['row_update'] instanceof \IPS\DateTime )
|
||||
{
|
||||
$info['row_updated'] = $info['row_updated']->getTimestamp();
|
||||
}
|
||||
@@ -893,7 +900,7 @@ class _Core extends \IPS\convert\Library
|
||||
|
||||
if ( !isset( $info['announce_page_location'] ) )
|
||||
{
|
||||
$info['announce_page_location'] = 'sidebar';
|
||||
$info['announce_page_location'] = array( 'sidebar' );
|
||||
}
|
||||
elseif( !is_array( $info['announce_page_location'] ) )
|
||||
{
|
||||
@@ -1047,16 +1054,17 @@ class _Core extends \IPS\convert\Library
|
||||
|
||||
$info['attach_location'] = (string) $file;
|
||||
}
|
||||
catch( \Exception $e )
|
||||
{
|
||||
$this->software->app->log( 'attachment_creation_fail', __METHOD__, \IPS\convert\App::LOG_WARNING, $info['attach_id'] );
|
||||
return FALSE;
|
||||
}
|
||||
catch( \ErrorException $e )
|
||||
{
|
||||
$this->software->app->log( $e->getMessage(), __METHOD__, \IPS\convert\App::LOG_WARNING, $info['attach_id'] );
|
||||
return FALSE;
|
||||
}
|
||||
catch( \Exception $e )
|
||||
{
|
||||
\IPS\Log::log( array( 'exception' => $e, 'file' => $info ), 'converter_attachment_fail' );
|
||||
$this->software->app->log( 'attachment_creation_fail_exception', __METHOD__, \IPS\convert\App::LOG_WARNING, $info['attach_id'] );
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if( $file === NULL )
|
||||
{
|
||||
@@ -1090,14 +1098,14 @@ class _Core extends \IPS\convert\Library
|
||||
|
||||
$info['attach_thumb_location'] = (string) $thumbnail;
|
||||
}
|
||||
catch( \Exception $e )
|
||||
{
|
||||
$this->software->app->log( 'attachment_thumb_creation_fail', __METHOD__, \IPS\convert\App::LOG_WARNING, $info['attach_id'] );
|
||||
}
|
||||
catch( \ErrorException $e )
|
||||
{
|
||||
$this->software->app->log( $e->getMessage(), __METHOD__, \IPS\convert\App::LOG_WARNING, $info['attach_id'] );
|
||||
}
|
||||
catch( \Exception $e )
|
||||
{
|
||||
$this->software->app->log( 'attachment_thumb_creation_fail', __METHOD__, \IPS\convert\App::LOG_WARNING, $info['attach_id'] );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -1674,7 +1682,6 @@ class _Core extends \IPS\convert\Library
|
||||
$filepathx2 = NULL;
|
||||
}
|
||||
$filex2 = \IPS\File::create( 'core_Emoticons', $info['filenamex2'], $filedatax2, 'emoticons', FALSE, NULL, static::$obscureFilenames );
|
||||
unset( $info['filenamex2'] );
|
||||
$info['image_2x'] = (string) $filex2;
|
||||
}
|
||||
catch( \Exception $e )
|
||||
@@ -1686,7 +1693,8 @@ class _Core extends \IPS\convert\Library
|
||||
$info['image_2x'] = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
unset( $info['filenamex2'] );
|
||||
|
||||
if ( $haveID )
|
||||
{
|
||||
$id = $info['id'];
|
||||
@@ -3209,7 +3217,7 @@ class _Core extends \IPS\convert\Library
|
||||
$photo = \IPS\File::create( 'core_Profile', $profilePhotoName, $profileFileData );
|
||||
$info['pp_photo_type'] = 'custom';
|
||||
$info['pp_main_photo'] = (string) $photo;
|
||||
$info['pp_thumb_photo'] = (string) $photo->thumbnail( 'core_Profile', \IPS\PHOTO_THUMBNAIL_SIZE, \IPS\PHOTO_THUMBNAIL_SIZE );
|
||||
$info['pp_thumb_photo'] = (string) $photo->thumbnail( 'core_Profile', \IPS\PHOTO_THUMBNAIL_SIZE, \IPS\PHOTO_THUMBNAIL_SIZE, TRUE );
|
||||
}
|
||||
catch( \Exception $e )
|
||||
{
|
||||
@@ -4359,7 +4367,7 @@ class _Core extends \IPS\convert\Library
|
||||
'friend_only' => NULL,
|
||||
);
|
||||
|
||||
$permId = \IPS\Db::i()->insert( 'core_permission_index', $perm );
|
||||
$permId = \IPS\Db::i()->replace( 'core_permission_index', $perm );
|
||||
$perm['perm_id'] = $permId;
|
||||
}
|
||||
|
||||
@@ -4545,16 +4553,16 @@ class _Core extends \IPS\convert\Library
|
||||
$name = $info['pf_name'];
|
||||
unset( $info['pf_name'] );
|
||||
}
|
||||
|
||||
if ( !isset( $info['pf_desc'] ) )
|
||||
|
||||
if ( !isset( $info['pf_desc'] ) OR empty( $info['pf_desc'] ) )
|
||||
{
|
||||
$desc = '';
|
||||
}
|
||||
else
|
||||
{
|
||||
$desc = $info['pf_desc'];
|
||||
unset( $info['pf_desc'] );
|
||||
}
|
||||
unset( $info['pf_desc'] );
|
||||
|
||||
if ( isset( $info['pf_content'] ) )
|
||||
{
|
||||
@@ -4613,47 +4621,38 @@ class _Core extends \IPS\convert\Library
|
||||
{
|
||||
$info['pf_format'] = NULL;
|
||||
}
|
||||
|
||||
if ( isset( $info['pf_group_id'] ) )
|
||||
|
||||
/* !Profile Field Group */
|
||||
try
|
||||
{
|
||||
try
|
||||
if ( isset( $info['pf_group_id'] ) )
|
||||
{
|
||||
$info['pf_group_id'] = $this->software->app->getLink( $info['pf_group_id'], 'core_pfields_groups' );
|
||||
}
|
||||
catch( \OutOfRangeException $e )
|
||||
{
|
||||
/* Create an orphan group */
|
||||
$info['pf_group_id'] = $this->convertProfileFieldGroup( array(
|
||||
'pf_group_id' => '__orphaned__',
|
||||
'pf_group_name' => 'Converted',
|
||||
) );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
try
|
||||
else
|
||||
{
|
||||
$info['pf_group_id'] = $this->software->app->getLink( '__orphaned__', 'core_pfields_groups' );
|
||||
}
|
||||
|
||||
/* Make sure it exists */
|
||||
try
|
||||
{
|
||||
\IPS\Db::i()->select( 'pf_group_id', 'core_pfields_groups', array( 'pf_group_id=?', $info['pf_group_id'] ) )->first();
|
||||
}
|
||||
catch( \UnderflowException $e )
|
||||
{
|
||||
/* Delete the relation if it no longer exists */
|
||||
$this->software->app->deleteLink( '__orphaned__', 'core_pfields_groups' );
|
||||
throw new \OutOfRangeException;
|
||||
}
|
||||
}
|
||||
catch( \OutOfRangeException $e )
|
||||
/* Make sure it exists */
|
||||
try
|
||||
{
|
||||
$info['pf_group_id'] = $this->convertProfileFieldGroup( array(
|
||||
'pf_group_id' => '__orphaned__',
|
||||
'pf_group_name' => 'Converted',
|
||||
) );
|
||||
\IPS\Db::i()->select( 'pf_group_id', 'core_pfields_groups', array( 'pf_group_id=?', $info['pf_group_id'] ) )->first();
|
||||
}
|
||||
catch( \UnderflowException $e )
|
||||
{
|
||||
/* Delete the relation if it no longer exists */
|
||||
$this->software->app->deleteLink( '__orphaned__', 'core_pfields_groups' );
|
||||
throw new \OutOfRangeException;
|
||||
}
|
||||
}
|
||||
catch( \OutOfRangeException $e )
|
||||
{
|
||||
/* Create an orphan group */
|
||||
$info['pf_group_id'] = $this->convertProfileFieldGroup( array(
|
||||
'pf_group_id' => '__orphaned__',
|
||||
'pf_group_name' => 'Converted',
|
||||
) );
|
||||
}
|
||||
|
||||
if ( !isset( $info['pf_search_type'] ) )
|
||||
|
||||
Reference in new issue
Block a user