Jump to content

Edit History

icaroamb

icaroamb

Hello, I'm using the "delivery date" module, I found the module very interesting, now I had a question, how could I insert another option for calculating delivery data? Like I put a new input that is not registered for the product, so that the module, in addition to the delivery time, also makes a calculation with a possible production time for the product, already properly registered on the product.

In the image I put for example the input "ean13", if in it we have for example a number 5.

	$date_minimal_time = $date_now + ($carrier_rule['minimal_time'] * 24 * 3600)+ ($product['ean13'] * 24 * 3600) + (Configuration::get('DOD_EXTRA_TIME_PREPARATION') * 24 * 3600);
		$date_maximal_time = $date_now + ($carrier_rule['maximal_time'] * 24 * 3600)+ ($product['ean13'] * 24 * 3600) + (Configuration::get('DOD_EXTRA_TIME_PREPARATION') * 24 * 3600);

if in the place of "$ product ['ean13']" I put the number I want directly he already does the right account the way I want, but I need that value to come out of the product registration.

Prestashop version 1.6.1.24

Capturar.PNG

icaroamb

icaroamb

Hello, I'm using the "delivery date" module, I found the module very interesting, now I had a question, how could I insert another option for calculating delivery data? Like I put a new input that is not registered for the product, so that the module, in addition to the delivery time, also makes a calculation with a possible production time for the product, already properly registered on the product.

In the image I put for example the input "ean13", if in it we have for example a number 5.

	$date_minimal_time = $date_now + ($carrier_rule['minimal_time'] * 24 * 3600)+ ($product['ean13'] * 24 * 3600) + (Configuration::get('DOD_EXTRA_TIME_PREPARATION') * 24 * 3600);
		$date_maximal_time = $date_now + ($carrier_rule['maximal_time'] * 24 * 3600)+ ($product['ean13'] * 24 * 3600) + (Configuration::get('DOD_EXTRA_TIME_PREPARATION') * 24 * 3600);

 

Capturar.PNG

×
×
  • Create New...