From: Marcel Werk Date: Mon, 8 Jul 2013 20:17:31 +0000 (+0200) Subject: Fixed label import issue X-Git-Tag: 2.0.0_Beta_5~87^2^2 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=221eee4bba6cdb11e93e9d7075d5cdf729405833;p=GitHub%2FWoltLab%2FWCF.git Fixed label import issue --- diff --git a/wcfsetup/install/files/lib/system/importer/LabelImporter.class.php b/wcfsetup/install/files/lib/system/importer/LabelImporter.class.php index a37362f183..b46f22a11c 100644 --- a/wcfsetup/install/files/lib/system/importer/LabelImporter.class.php +++ b/wcfsetup/install/files/lib/system/importer/LabelImporter.class.php @@ -18,6 +18,9 @@ class LabelImporter implements IImporter { * @see wcf\system\importer\IImporter::import() */ public function import($oldID, array $data, array $additionalData = array()) { + $data['groupID'] = ImportHandler::getInstance()->getNewID('com.woltlab.wcf.label.group', $data['groupID']); + if (!$data['groupID']) return 0; + $label = LabelEditor::create($data); ImportHandler::getInstance()->saveNewID('com.woltlab.wcf.label', $oldID, $label->labelID); diff --git a/wcfsetup/setup/db/install.sql b/wcfsetup/setup/db/install.sql index f8a67d2e20..2192af1c29 100644 --- a/wcfsetup/setup/db/install.sql +++ b/wcfsetup/setup/db/install.sql @@ -339,7 +339,7 @@ CREATE TABLE wcf1_label ( labelID INT(10) NOT NULL AUTO_INCREMENT PRIMARY KEY, groupID INT(10) NOT NULL, label VARCHAR(80) NOT NULL, - cssClassName VARCHAR(255) NOT NULL + cssClassName VARCHAR(255) NOT NULL DEFAULT '' ); DROP TABLE IF EXISTS wcf1_label_group;