OpenCart: como preencher corretamente oc_category_path
Eu usei um serviço online para transferir dados do meu outro site de comércio eletrônico paraOpenCart e tudo parece ter sido transferido corretamente.
Há, no entanto, um problema com as categorias de produtos. As categorias foram transferidas para ooc_category
mesa; no entanto, parece que há outra tabela chamadaoc_category_path
que precisa ser preenchido também se eu quiser editar minhas categorias no admin.
Você sabe o que esta tabela é e como posso preenchê-la corretamente (manualmente no meu caso, suponho). O que épath_id
elevel
para ser exato e o que determina o nível de uma categoria?
Tabelas Relacionadas:
CREATE TABLE `oc_category` (
`category_id` int(11) NOT NULL AUTO_INCREMENT,
`image` varchar(255) DEFAULT NULL,
`parent_id` int(11) NOT NULL DEFAULT '0',
`top` tinyint(1) NOT NULL,
`column` int(3) NOT NULL,
`sort_order` int(3) NOT NULL DEFAULT '0',
`status` tinyint(1) NOT NULL,
`date_added` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
`date_modified` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
PRIMARY KEY (`category_id`)
) ENGINE=MyISAM AUTO_INCREMENT=12 DEFAULT CHARSET=utf8
CREATE TABLE `oc_category_description` (
`category_id` int(11) NOT NULL,
`language_id` int(11) NOT NULL,
`name` varchar(255) NOT NULL,
`description` text NOT NULL,
`meta_description` varchar(255) NOT NULL,
`meta_keyword` varchar(255) NOT NULL,
`u_title` varchar(255) NOT NULL,
`u_h1` varchar(255) NOT NULL,
`u_h2` varchar(255) NOT NULL,
PRIMARY KEY (`category_id`,`language_id`),
KEY `name` (`name`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8
CREATE TABLE `oc_category_path` (
`category_id` int(11) NOT NULL,
`path_id` int(11) NOT NULL,
`level` int(11) NOT NULL,
PRIMARY KEY (`category_id`,`path_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8