From 78db8ddfc0c68f2cc976e6fc79d9c4718d0e8e35 Mon Sep 17 00:00:00 2001 From: Marcel Werk Date: Sat, 29 Jun 2013 19:07:50 +0200 Subject: [PATCH] Added data import function (WIP) --- com.woltlab.wcf/acpMenu.xml | 6 + com.woltlab.wcf/objectType.xml | 38 +++ com.woltlab.wcf/objectTypeDefinition.xml | 10 + com.woltlab.wcf/userGroupOption.xml | 6 + .../files/acp/templates/dataImport.tpl | 202 ++++++++++++++++ .../lib/acp/form/DataImportForm.class.php | 227 ++++++++++++++++++ .../data/user/group/UserGroupAction.class.php | 6 +- .../exporter/AbstractExporter.class.php | 143 +++++++++++ .../lib/system/exporter/IExporter.class.php | 90 +++++++ .../lib/system/importer/IImporter.class.php | 23 ++ .../system/importer/ImportHandler.class.php | 106 ++++++++ .../importer/UserGroupImporter.class.php | 30 +++ .../system/importer/UserImporter.class.php | 40 +++ .../lib/system/worker/ImportWorker.class.php | 93 +++++++ wcfsetup/setup/db/install.sql | 10 + 15 files changed, 1028 insertions(+), 2 deletions(-) create mode 100644 wcfsetup/install/files/acp/templates/dataImport.tpl create mode 100644 wcfsetup/install/files/lib/acp/form/DataImportForm.class.php create mode 100644 wcfsetup/install/files/lib/system/exporter/AbstractExporter.class.php create mode 100644 wcfsetup/install/files/lib/system/exporter/IExporter.class.php create mode 100644 wcfsetup/install/files/lib/system/importer/IImporter.class.php create mode 100644 wcfsetup/install/files/lib/system/importer/ImportHandler.class.php create mode 100644 wcfsetup/install/files/lib/system/importer/UserGroupImporter.class.php create mode 100644 wcfsetup/install/files/lib/system/importer/UserImporter.class.php create mode 100644 wcfsetup/install/files/lib/system/worker/ImportWorker.class.php diff --git a/com.woltlab.wcf/acpMenu.xml b/com.woltlab.wcf/acpMenu.xml index 99f3c3fca3..cdb9d329c1 100644 --- a/com.woltlab.wcf/acpMenu.xml +++ b/com.woltlab.wcf/acpMenu.xml @@ -92,6 +92,12 @@ wcf.acp.menu.link.maintenance admin.system.canManageApplication + + + + wcf.acp.menu.link.maintenance + admin.system.canImportData + diff --git a/com.woltlab.wcf/objectType.xml b/com.woltlab.wcf/objectType.xml index c15955563d..4d1172930a 100644 --- a/com.woltlab.wcf/objectType.xml +++ b/com.woltlab.wcf/objectType.xml @@ -210,5 +210,43 @@ com.woltlab.wcf.label com.woltlab.wcf.acl + + + + com.woltlab.wcf.user + com.woltlab.wcf.importer + + + + com.woltlab.wcf.user.group + com.woltlab.wcf.importer + + + + \ No newline at end of file diff --git a/com.woltlab.wcf/objectTypeDefinition.xml b/com.woltlab.wcf/objectTypeDefinition.xml index b53929cef2..2fba986584 100644 --- a/com.woltlab.wcf/objectTypeDefinition.xml +++ b/com.woltlab.wcf/objectTypeDefinition.xml @@ -129,5 +129,15 @@ com.woltlab.wcf.poll + + + com.woltlab.wcf.importer + + + + + com.woltlab.wcf.exporter + + diff --git a/com.woltlab.wcf/userGroupOption.xml b/com.woltlab.wcf/userGroupOption.xml index 46add8db97..fe420e20b2 100644 --- a/com.woltlab.wcf/userGroupOption.xml +++ b/com.woltlab.wcf/userGroupOption.xml @@ -137,6 +137,12 @@ 0 1 +