Ejemplo n.º 1
0
 public function __construct()
 {
     $this->name = 'importerosc';
     $this->tab = 'migration_tools';
     $this->version = '1.0';
     $this->author = 'PrestaShop';
     $this->theImporter = 1;
     $this->need_instance = 1;
     parent::__construct();
     $this->displayName = $this->l('Importer osCommerce');
     $this->description = $this->l('This module allows you to import from osCommerce to Prestashop.');
 }
Ejemplo n.º 2
0
 public function __construct()
 {
     global $cookie;
     $this->name = 'shopimporter';
     $this->tab = 'migration_tools';
     $this->version = '1.0';
     $this->author = 'PrestaShop';
     parent::__construct();
     $this->displayName = $this->l('Shop Importer');
     $this->description = $this->l('This module allows you to import your shop from another system into Prestashop.');
     $this->supportedImports = array('language' => array('methodName' => 'getLangagues', 'name' => $this->l('Language'), 'className' => 'Language', 'label' => $this->l('Import Languages'), 'table' => 'lang', 'identifier' => 'id_lang', 'alterTable' => array('id_lang' => 'int(10)'), 'info' => $this->l('New languages will automatically add translations.'), 'defaultId' => 'PS_LANG_DEFAULT'), 'currency' => array('methodName' => 'getCurrencies', 'name' => $this->l('Currency'), 'className' => 'Currency', 'label' => $this->l('Import Currencies'), 'table' => 'currency', 'identifier' => 'id_currency', 'alterTable' => array('id_currency' => 'int(10)'), 'delete' => true, 'defaultId' => 'PS_CURRENCY_DEFAULT'), 'zone' => array('methodName' => 'getZones', 'name' => $this->l('Zone'), 'className' => 'Zone', 'label' => $this->l('Import Zones'), 'table' => 'zone', 'identifier' => 'id_zone', 'alterTable' => array('id_zone' => 'int(10)'), 'delete' => true), 'country' => array('methodName' => 'getCountries', 'name' => $this->l('Country'), 'className' => 'Country', 'label' => $this->l('Import Countries'), 'table' => 'country', 'identifier' => 'id_country', 'foreign_key' => array('id_zone', 'id_currency'), 'alterTable' => array('id_country' => 'int(10)'), 'delete' => true, 'defaultId' => 'PS_COUNTRY_DEFAULT'), 'state' => array('methodName' => 'getStates', 'name' => $this->l('State'), 'className' => 'State', 'label' => $this->l('Import States'), 'table' => 'state', 'identifier' => 'id_state', 'foreign_key' => array('id_zone', 'id_country'), 'alterTable' => array('id_state' => 'int(10)'), 'delete' => true), 'group' => array('methodName' => 'getGroups', 'name' => $this->l('Group'), 'className' => 'Group', 'label' => $this->l('Import Groups'), 'table' => 'group', 'identifier' => 'id_group', 'alterTable' => array('id_group' => 'int(10)'), 'delete' => true), 'customer' => array('methodName' => 'getCustomers', 'name' => $this->l('Customer'), 'className' => 'Customer', 'label' => $this->l('Import Customers'), 'table' => 'customer', 'identifier' => 'id_customer', 'foreign_key' => array('id_group'), 'alterTable' => array('id_customer' => 'int(10)', 'passwd' => 'varchar(100)'), 'delete' => true, 'association' => array(array('table' => 'customer_group', 'fields' => array('id_customer', 'id_group'), 'matchTable' => array('customer', 'group')))), 'address' => array('methodName' => 'getAddresses', 'name' => $this->l('Address'), 'className' => 'Address', 'label' => $this->l('Import Addresses'), 'table' => 'address', 'identifier' => 'id_address', 'foreign_key' => array('id_country', 'id_state', 'id_customer'), 'alterTable' => array('id_address' => 'int(10)'), 'delete' => true), 'manufacturer' => array('methodName' => 'getManufacturers', 'name' => $this->l('Manufacturer'), 'className' => 'Manufacturer', 'label' => $this->l('Import Manufacturers'), 'table' => 'manufacturer', 'identifier' => 'id_manufacturer', 'delete' => true, 'alterTable' => array('id_manufacturer' => 'int(10)'), 'hasImage' => true), 'supplier' => array('methodName' => 'getSuppliers', 'name' => $this->l('Supplier'), 'className' => 'Supplier', 'label' => $this->l('Import Suppliers'), 'table' => 'supplier', 'identifier' => 'id_supplier', 'delete' => true, 'alterTable' => array('id_supplier' => 'int(10)'), 'hasImage' => true), 'category' => array('methodName' => 'getCategories', 'name' => $this->l('Category'), 'className' => 'Category', 'label' => $this->l('Import Categories'), 'table' => 'category', 'identifier' => 'id_category', 'alterTable' => array('id_category' => 'int(10)'), 'delete' => true, 'hasImage' => true), 'attributegroup' => array('methodName' => 'getAttributesGroups', 'name' => $this->l('AttributeGroup'), 'className' => 'AttributeGroup', 'label' => $this->l('Import Attributes Groups'), 'table' => 'attribute_group', 'identifier' => 'id_attribute_group', 'alterTable' => array('id_attribute_group' => 'int(10)'), 'delete' => true), 'attribute' => array('methodName' => 'getAttributes', 'name' => $this->l('Attribute'), 'className' => 'Attribute', 'label' => $this->l('Import Attributes'), 'table' => 'attribute', 'identifier' => 'id_attribute', 'alterTable' => array('id_attribute' => 'int(10)'), 'foreign_key' => array('id_attribute_group'), 'delete' => true), 'product' => array('methodName' => 'getProducts', 'name' => $this->l('Product'), 'className' => 'Product', 'label' => $this->l('Import Products'), 'table' => 'product', 'identifier' => 'id_product', 'alterTable' => array('id_product' => 'int(10)'), 'foreign_key' => array('id_category'), 'delete' => true, 'association' => array(array('table' => 'category_product', 'fields' => array('id_category', 'id_product'), 'matchTable' => array('category', 'product'))), 'hasImage' => true), 'combination' => array('methodName' => 'getProductsCombination', 'name' => $this->l('Combination'), 'className' => 'Combination', 'label' => $this->l('Import Products Combinations'), 'table' => 'product_attribute', 'identifier' => 'id_product_attribute', 'alterTable' => array('id_product_attribute' => 'int(10)', 'id_product' => 'int(10)'), 'foreign_key' => array('id_product'), 'delete' => false, 'association' => array(array('table' => 'product_attribute_combination', 'fields' => array('id_attribute', 'id_product_attribute'), 'matchTable' => array('attribute', 'product_attribute')))), 'orderstate' => array('methodName' => 'getOrdersStates', 'name' => $this->l('Orders States'), 'className' => 'OrderState', 'label' => $this->l('Import Orders States'), 'table' => 'order_state', 'identifier' => 'id_order_state', 'alterTable' => array('id_order_state' => 'int(10)')), 'cart' => array('methodName' => 'getOrders', 'name' => $this->l('Order'), 'className' => 'Cart', 'label' => $this->l('Import Orders'), 'table' => 'cart', 'identifier' => 'id_cart', 'foreign_key' => array('id_address_delivery', 'id_address_invoice', 'id_customer'), 'alterTable' => array('id_cart' => 'int(10)')), 'orderhistory' => array('methodName' => 'getOrdersHistory', 'name' => $this->l('OrderHistory'), 'className' => 'OrderHistory', 'label' => $this->l('Import Order History'), 'table' => 'order_history', 'identifier' => 'id_order_history', 'foreign_key' => array('id_order', 'id_order_state'), 'alterTable' => array('id_order_history' => 'int(10)'), 'hidden' => true), 'order' => array('methodName' => 'getOrders', 'name' => $this->l('Order'), 'className' => 'Order', 'label' => $this->l('Import Order History'), 'table' => 'orders', 'identifier' => 'id_order', 'alterTable' => array('id_order' => 'int(10)'), 'hidden' => true));
 }