Improved: notify message when adding a product to cart (OFBIZ-9521)

When a product is successfully added to the shopping cart, a notify
message is displayed with detail of the productId added.

Thanks Sourabh Punyani for your work.
This commit is contained in:
Giulio Speri
2022-04-22 00:26:34 +02:00
parent 389f90cbb6
commit 58d05e2e43
2 changed files with 6 additions and 0 deletions
@@ -16309,4 +16309,8 @@
<value xml:lang="en">Lookup Return Header</value>
<value xml:lang="nl">Retouren zoeken/vinden</value>
</property>
<property key="ItemAddedSuccessfully">
<value xml:lang="en">Item ${productId} added successfully</value>
<value xml:lang="it">Articolo ${productId} aggiunto con successo</value>
</property>
</resource>
@@ -695,6 +695,8 @@ public class ShoppingCartEvents {
if (cart.viewCartOnAdd()) {
return "viewcart";
}
request.setAttribute("_EVENT_MESSAGE_", UtilProperties.getMessage("OrderUiLabels", "ItemAddedSuccessfully",
UtilMisc.toMap("productId", productId), UtilHttp.getLocale(request)));
return "success";
}