Jump to content

[SOLUCIONADO] Error al incrementar cantidad producto, pagina producto


Recommended Posts

Buenos d铆as,

tengo la versi贸n 1.7.5.1 de prestashop y tengo el siguiente error cuando intento incrementar o decrementar la cantidad de producto para a帽adir al carro en mi p谩gina de producto.

Cita

Invalid parameter $idAttributes with value: "" at line 6246 in file classes/Product.php

Recibo ese error en los logs, en los productos sin atributos.

Yendo a la linea que da error en cuesti贸n, es el siguiente bloque de c贸digo:

Cita

聽public static function getIdProductAttributeByIdAttributes($idProduct, $idAttributes, $findBest = false)
聽 聽 {
聽 聽 聽 聽 $idProduct = (int) $idProduct;

聽 聽 聽 聽 if (!is_array($idAttributes) && is_numeric($idAttributes)) {
聽 聽 聽 聽 聽 聽 $idAttributes = array((int) $idAttributes);
聽 聽 聽 聽 }

聽 聽 聽 聽 if (!is_array($idAttributes) || empty($idAttributes)) {
聽 聽 聽 聽 聽 聽 throw new PrestaShopException(
聽 聽 聽 聽 聽 聽 聽 聽 sprintf(
聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 'Invalid parameter $idAttributes with value: "%s"',
聽 聽 聽 聽 聽 聽 聽 聽 聽 聽 print_r($idAttributes, true)
聽 聽 聽 聽 聽 聽 聽 聽 )
聽 聽 聽 聽 聽 聽 );
聽 聽 聽 聽 }

Como dato, tengo tambi茅n instalado el modulo de Pretty Urls... ya que me mosquea que pueda tener algo que ver, porque me ha dado muchos problemas desde su instalaci贸n. He escrito una incidencia al soporte t茅cnico del plugin por si acaso.

A alguien m谩s le ha dado este error? 驴Alguna idea de como solventarlo?

Gracias,

Un saludo!

Edited by korsakov14 (see edit history)
Link to comment
Share on other sites

Solucionado, es un bug del plugin Pretty Urls versi贸n 2.2.2 en PS 1.7.5.1.

Corregido tras sustituir el ProductController de la carpeta /overrides proporcionado por soporte del plugin. (Archivo adjunto).

Ya puedo incrementar la cantidad de mis productos sin problemas聽馃

https://www.turronartesano.com/es/turrones-de-jijona/turron-jijona-blando-300g

ProductController.php.txt

Edited by korsakov14 (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...