简体   繁体   English

Prestashop 1.6,在有条件时中止添加到购物车产品

[英]Prestashop 1.6, abort add to cart product when condition

I want to create function where addition product to cart will be aborted (with message) when product met the condition (specific category). 我想创建一个功能,其中当产品满足条件(特定类别)时,购物车中的其他产品将被中止(带有消息)。 Where should i put condition code? 我应该在哪里放置条件代码? I try to find method responsible for adding product to cart but i cant find it :-( 我尝试找到负责将产品添加到购物车的方法,但我找不到它:-(

对于1.6负责将产品添加到购物车的核心方法是/controllers/front/CartController.php中的processChangeProductInCart()

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM