Changeset View
Changeset View
Standalone View
Standalone View
branches/5.2.x/core/install/upgrades.php
Show First 20 Lines • Show All 2052 Lines • ▼ Show 20 Line(s) | |||||
* @access private | * @access private | ||||
*/ | */ | ||||
private function _splitEmailBody() | private function _splitEmailBody() | ||||
{ | { | ||||
$id_field = $this->Application->getUnitOption('email-template', 'IDField'); | $id_field = $this->Application->getUnitOption('email-template', 'IDField'); | ||||
$table_name = $this->Application->getUnitOption('email-template', 'TableName'); | $table_name = $this->Application->getUnitOption('email-template', 'TableName'); | ||||
$fields = $this->Conn->Query('DESCRIBE ' . $table_name, 'Field'); | $fields = $this->Conn->Query('DESCRIBE ' . $table_name, 'Field'); | ||||
// The "_renameTables" method doesn't rename IDField, so find real one in DESCRIBE result. | |||||
if ( !isset($fields[$id_field]) ) { | |||||
$id_field = 'EventId'; | |||||
} | |||||
if ( !isset($fields['l1_Body']) ) { | if ( !isset($fields['l1_Body']) ) { | ||||
// column dropped - nothing to convert anymore | // column dropped - nothing to convert anymore | ||||
return; | return; | ||||
} | } | ||||
$ml_helper = $this->Application->recallObject('kMultiLanguageHelper'); | $ml_helper = $this->Application->recallObject('kMultiLanguageHelper'); | ||||
/* @var $ml_helper kMultiLanguageHelper */ | /* @var $ml_helper kMultiLanguageHelper */ | ||||
▲ Show 20 Lines • Show All 312 Lines • Show Last 20 Lines |