KonaKart Community Forum

Installation / Configuration => Programming of KonaKart => Topic started by: PiotrN on March 02, 2012, 11:25:43 am

Title: Cannot update product price
Post by: PiotrN on March 02, 2012, 11:25:43 am
Hello,

I would like to update product price using Web Services.
I am obtaining a fully populated AdminProduct object but when I invoke the following code:

public boolean updateProductPrice(AdminProduct product, BigDecimal price) {
    try {
        product.setPrice0(price);
        admin.editProduct(sessionId, product);
    } catch (KKAdminException e) {
        e.printStackTrace();
        return false;
    }
    return true;
}


The value is not updated in the database.

Do I need to explicitly invoke some kind of flush to let the correct data be inserted into DB?