added product import node for the product import system

This commit is contained in:
JT Smith 2008-05-25 21:59:46 +00:00
parent 4445735a52
commit 86be08b3b2
2 changed files with 23 additions and 4 deletions

View file

@ -912,14 +912,15 @@ sub mergeProductsWithCommerce {
print "\tMerge old Commerce Products to new SKU based Products.\n" unless ($quiet);
my $productSth = $session->db->read('select * from products order by title');
my $variantSth = $session->db->prepare('select * from productVariants where productId=?');
my $productFolder = WebGUI::Asset->getRoot($session)->addChild({
my $productFolder = WebGUI::Asset->getImportNode($session)->addChild({
className => 'WebGUI::Asset::Wobject::Folder',
title => 'Converted products from Commerce',
url => 'converted_products',
title => 'Products',
url => 'import/products',
isHidden => 1,
groupIdView => 14,
groupIdEdit => 14,
});
},'PBproductimportnode001');
$session->db->write("update asset set isSystem=1 where assetId=?",[$productFolder->getId]);
while (my $productData = $productSth->hashRef) {
my $sku = $productFolder->addChild({
className => 'WebGUI::Asset::Sku::Product',