From 564924e876d26d973487a00befb26601b4d9948a Mon Sep 17 00:00:00 2001 From: Stanislav Atanasov Date: Sun, 29 Jun 2014 11:48:06 +0300 Subject: [PATCH] [ticket/12786] Extend profilefield_base_migration.php class If extensions authors will use profilefield_base_migration.php class as base class for creation of CPFs, the class need to be extended a bit. At the moment there are two issues with it: It does not create entries for PROFILE_FIELDS_LANG_TABLE (as it can't know what fields to create). The migration is not "cleaning" the DBMS after purging the extension and leaves everything except the CPF column. Adding profilefield_language_data PHPBB3-12786 --- .../db/migration/profilefield_base_migration.php | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/phpBB/phpbb/db/migration/profilefield_base_migration.php b/phpBB/phpbb/db/migration/profilefield_base_migration.php index d416a9b228..1a88ef0d48 100644 --- a/phpBB/phpbb/db/migration/profilefield_base_migration.php +++ b/phpBB/phpbb/db/migration/profilefield_base_migration.php @@ -21,6 +21,22 @@ abstract class profilefield_base_migration extends \phpbb\db\migration\migration protected $profilefield_data; + /*Language data should be in array -> each language_data in seaprte key + * array( + * '1' => array( + * 'option_id' => value, + * 'field_type' => value, + * 'lang_value' => value, + * ), + * '2' => array( + * 'option_id' => value, + * 'field_type' => value, + * 'lang_value' => value, + * ), + * ) + */ + protected $profilefield_language_data; + protected $user_column_name; public function effectively_installed()