|
|
|
|
Joined: 2/13/2010
Posts: 15
|
|
|
There is an error when a product is deleted, and it is in a subcategory. All other products in that subcategory lose their subcategory, retaining only their category.
I have replicated the problem in the test system. I have screen shots, but I don't see how to attach them to this post.
We are running DNN 5.4.2, and Cart 2.93.
Specific steps I took to replicate the error were:
Created two root-level categories, Main 1 and Main 2
Created two subcategories of Main 1, Sub 1-1 and Sub 1-2
Created three products: Product 1 in Main 1, Sub 1-1
Product 2 in Main 1, Sub 1-1
Product 3 in Main 1 only
I then deleted product 1
Product 2 no longer shows up in Sub 1-1, only shows in Main 1
|
|
|
|
| |
|
|
|
Joined: 2/13/2010
Posts: 15
|
|
|
I thought maybe a workaround would be to first remove the product from the subcategory, before deleting the product. In the test site, I created three new products in the Main 2 category, subcategory Sub 2-1. I could see them in the Main 2 category, and I could see them in the Main 2, Sub 2-1 subcategory.
I edited the second product, removing it from subcategory Sub 2-1, but when I went back to view subcategory Sub 2-1, there were no products. All three continue to show up in Main 2 category, but not in the subcategory. Viewing the three new products under Manage Products, all three show no sub-category, even though only Product 2 had the subcategory removed.
|
|
|
|
| |
|
|
|
Joined: 7/28/2009
Posts: 1452
|
|
|
We have fixed this in v2.96 to be released tomorrow. Thanks for reporting it!
At your service,
Dave Smith
|
|
|
|
| |
|
|
|
Joined: 4/20/2010
Posts: 18
|
|
|
Hi, we are using Cart 2.96. There is a similar problem indicated.
Product 1,2,3,4; Root-level categories: Main1, Main2; sub categories for Main1: Sub1-1, Sub1-2; sub categories for Main2: Sub2-1, Sub2-2.
Product1 in Main1, Sub1-1
Product2 in Main1, Sub1-1
Product3 in Main2, Sub2-1
When I change the sub category for Product1 to under Main1, Sub1-2, Product2 has gone to Main1. Product2 auto change to only under Main1, the reset of the products under Sub1-1 have all gone to the root-level category.
Is it a bug? Any solution? Thanks.
|
|
|
|
| |
|
|
|
|
Joined: 3/11/2010
Posts: 1979
|
|
|
We will look into this and let you know if we are able to replicate this on our test cart and will post back in this thread with the solution and/or a patch. Thanks for reporting this.
-Scott
Scott Kelly
Project Manager
|
|
|
|
| |
|
|
|
Joined: 2/13/2010
Posts: 15
|
|
|
As the reporter of the original issue in this thread, deleting one product from a subcategory caused all other products in the subcategory to lose subcategory status (fixed in 2.96, confirmed via the test system), I can also confirm that this error indeed is evident in the test system.
Changing one item in a subcategory to a different subcategory causes the other items in the same category/subcategory to lose subcategory status, only showing up in the original main category.
|
|
|
|
| |
|
|
|
Joined: 7/28/2009
Posts: 1452
|
|
|
I fixed the issue where changing one item in a subcategory to a different subcategory causes the other products in the same category/subcategory to lose subcategory. To fix the issue run the following stored procedure. Make sure you change the object qualifier to your object qualifier highlighted in yellow below. If your object qualifier is "dnn" you can run as is.
ALTER PROCEDURE [dbo].[dnn_Smith_UpdateProducts]
@ProductID int,
@CategoryID int,
@Manufacturer nvarchar(50),
@ModelNumber nvarchar(50),
@ModelName nvarchar(200),
@ProductImage nvarchar(500),
@ThumbnailImage nvarchar(500),
@UnitCost money,
@MemberPrice money,
@QuantityOnHand int,
@Summary nvarchar(1000),
@Description ntext,
@DownloadUrl nvarchar(1000),
@Featured bit,
@Archived bit,
@weight decimal(12,5),
@sortOrder int,
@ExcludeCoupon bit,
@Items int,
@Share bit,
@TabModuleId int,
@CreatedByUser nvarchar(100),
@CreatedDate datetime,
@LogicallyDeleted bit ,
@Recurring bit ,
@SubscriptionInterval varchar(50) ,
@RecurringOccurances int ,
--@RequiredProductID int ,
@UrlGUID varchar(50) ,
@EncryptUrl bit,
@AddDnnRole varchar(50),
@RequireLogin bit,
@UsePriPriceWght bit,
@bundleID int,
@masterBundleID int,
@RoleExpireDays varchar(50),
@SubCategoryID int,
@TaxExempt bit,
@AffiliateUrl nvarchar(1000),
@RequireCoupon bit,
@ShowPDUDF bit,
@AutoGUID bit,
@Description2 ntext,
@Description3 ntext,
@Description4 ntext,
@Description5 ntext,
@TabName1 varchar(50),
@TabName2 varchar(50),
@TabName3 varchar(50),
@TabName4 varchar(50),
@TabName5 varchar(50)
AS
UPDATE dnn_Smith_Products SET
[Manufacturer] = @Manufacturer,
[CategoryID] = @CategoryID ,
[ModelNumber] = @ModelNumber,
[ModelName] = @ModelName,
[ProductImage] = ISNULL(@ProductImage,ProductImage),
[ThumbnailImage] = ISNULL(@ThumbnailImage,ThumbnailImage),
[UnitCost] = @UnitCost,
[MemberPrice] = @MemberPrice,
[QuantityOnHand]=@QuantityOnHand,
[Summary] = @Summary,
[Description] = @Description,
[DownloadUrl] = @DownloadUrl,
[Featured] = @Featured,
[Archived] = @Archived,
[Weight]=@weight,
[SortOrder] = @SortOrder,
[ExcludeCoupon] = @ExcludeCoupon,
[Items] = @Items,
[Share] = @Share ,
[TabModuleId] = @TabModuleId,
[CreatedByUser] = @CreatedByUser,
[CreatedDate] = @CreatedDate,
[LogicallyDeleted]=@LogicallyDeleted,
[Recurring] = @Recurring,
[SubscriptionInterval] = @SubscriptionInterval,
[RecurringOccurances] = @RecurringOccurances ,
---- [RequiredProductID] = @RequiredProductID ,
[UrlGUID] = @UrlGUID ,
[EncryptUrl] = @EncryptUrl,
[AddDNNRole] = @AddDnnRole,
[RequireLogin] = @RequireLogin,
[UsePriPriceWght] = @UsePriPriceWght,
[BundleID] = @bundleID,
[MasterBundleID] = @masterBundleID,
[RoleExpireDays] = @RoleExpireDays,
[TaxExempt] = @TaxExempt,
[AffiliateUrl] = @AffiliateUrl,
[RequireCoupon] = @RequireCoupon,
[ShowPDUDF] = @ShowPDUDF,
AutoGUID = @AutoGUID,
Description2 = @Description2,
Description3 = @Description3,
Description4 = @Description4,
Description5 = @Description5,
TabName1 = @TabName1,
TabName2 = @TabName2,
TabName3 = @TabName3,
TabName4 = @TabName4,
TabName5 = @TabName5
WHERE
[ProductID] = @ProductID
delete from dnn_Smith_CategoryProduct WHERE ProductID = @ProductID
INSERT INTO dnn_Smith_CategoryProduct(ProductID, CategoryID) VALUES (@ProductID, @CategoryID)
INSERT INTO dnn_Smith_CategoryProduct(ProductID, CategoryID) VALUES (@ProductID, @SubCategoryID)
At your service,
Dave Smith
|
|
|
|
| |
|
|
|
Joined: 4/20/2010
Posts: 18
|
|
|
Hi, thanks for the quick solution. As I am not profession on DNN, could you state more detail on how to fix it.
My understanding on your solution is below.
First, login as "host", go to "host"-"SQL".
Second, copy and paste the script you posted above. And click "execute".
How to verify that my site's "object qualifier" is "dnn"?
|
|
|
|
| |