Developer forum

Forum » Development » EcomUpdator issue.

EcomUpdator issue.

Jeppe Jakobsen
Reply

Hello Dynamicweb

During project development we ran into a issue with the "add product to group" feature in the admin panel. It would throw a timeout-exception when searching for products, since our solution contains an huge amount. To solve this we had one of you, from dynamicweb, develop a GroupProductAttacherAddIn to handle this instead, which it does, nearly.

Here's a small snippit:

var selectedProducts = "";
$('#attach_form :checkbox:not(:disabled):checked').each(function () {
    selectedProducts += "[" + $(this).val() + "];";
});
$.get("/admin/module/ecom_catalog/dw7/edit/EcomUpdator.aspx?CMD=AppendProductsToGroup&GroupID=@groupId&ProdArr=" + selectedProducts)
.done(function () {
    window.close();
});

Reading this, the problem suddenly becomes apparent. The entire form of products is being added to the url, so when the user reaches +300 products, the url becomes too large to handle. To this end i thought a simple fix would be changing the $.get to the following:

$.ajax({
    type: "POST",
    url: "/admin/module/ecom_catalog/dw7/edit/EcomUpdator.aspx",
    data: {
        CMD: "AppendProductsToGroup",
        GroupID: "@groupId",
        ProdArr: selectedProducts
    },
    success: function () {
        window.close();
    }
});

After the post has finished, nothing happened to the product-group-relation.

So my first guess would be that the EcomUpdator doesn't accept parameters as Form Data, or is there something else that i am missing? 

 

Best Regards, Jeppe


Replies

 
Oleg Rodionov
Reply

Hi, 

New TFS 26308 has been created to fix the bug, thanks.

BR, Oleg QA

 
Kristian Kirkholt Dynamicweb Employee
Kristian Kirkholt
Reply
This post has been marked as an answer

Hi Jeppe

The problem TFS#26308 "EcomUpdator issue"  has now been fixed in version 8.8.1.18

You are able to find this build in the download section:

http://doc.dynamicweb.com/releases-and-downloads/latest-releases

Please contact Dynamicweb Support if you need any additional help regarding this.

Kind Regards
Dynamicweb Support
Kristian Kirkholt

Votes for this answer: 1
 
Jeppe Jakobsen
Reply

Thank you very much. Just tested it and it works :) 

 

You must be logged in to post in the forum