What should I look for in this file, on this specific line?
Code: Select all
Warning: A non-numeric value encountered in /var/www/vhosts/122/346133/webspace/httpdocs/theplanter.nl/vqmod/vqcache/vq2-admin_controller_sale_order.php on line 1907
Code: Select all
Warning: A non-numeric value encountered in /var/www/vhosts/122/346133/webspace/httpdocs/theplanter.nl/vqmod/vqcache/vq2-admin_controller_sale_order.php on line 1907
The most generated errors being found on Opencart forum originates from contributed programming. The increased post counters are caused by redundancies of the same solutions that were already provided prior.
Regards,
Straightlight
Programmer / Opencart Tester
Code: Select all
$option_weight += $product_option_value_info['weight'];
Code: Select all
$shipping_address = str_replace(array("\r\n", "\r", "\n"), '<br />', preg_replace(array("/\s\s+/", "/\r\r+/", "/\n\n+/"), '<br />', trim(str_replace($find, $replace, $format))));
$this->load->model('tool/upload');
$product_data = array();
$products = $this->model_sale_order->getOrderProducts($order_id);
foreach ($products as $product) {
$option_weight = '';
$product_info = $this->model_catalog_product->getProduct($product['product_id']);
if ($product_info) {
$option_data = array();
$options = $this->model_sale_order->getOrderOptions($order_id, $product['order_product_id']);
foreach ($options as $option) {
if ($option['type'] != 'file') {
$value = $option['value'];
} else {
$upload_info = $this->model_tool_upload->getUploadByCode($option['value']);
if ($upload_info) {
$value = $upload_info['name'];
} else {
$value = '';
}
}
$option_data[] = array(
'name' => $option['name'],
'value' => $value
);
$product_option_value_info = $this->model_catalog_product->getProductOptionValue($product['product_id'], $option['product_option_value_id']);
if ($product_option_value_info) {
if ($product_option_value_info['weight_prefix'] == '+') {
$option_weight += $product_option_value_info['weight'];
} elseif ($product_option_value_info['weight_prefix'] == '-') {
$option_weight -= $product_option_value_info['weight'];
}
}
}
$product_data[] = array(
'name' => $product_info['name'],
'model' => $product_info['model'],
'option' => $option_data,
'quantity' => $product['quantity'],
'location' => $product_info['location'],
'sku' => $product_info['sku'],
'upc' => $product_info['upc'],
'ean' => $product_info['ean'],
'jan' => $product_info['jan'],
'isbn' => $product_info['isbn'],
'mpn' => $product_info['mpn'],
'weight' => $this->weight->format(($product_info['weight'] + (float)$option_weight) * $product['quantity'], $product_info['weight_class_id'], $this->language->get('decimal_point'), $this->language->get('thousand_point'))
);
}
}
The most generated errors being found on Opencart forum originates from contributed programming. The increased post counters are caused by redundancies of the same solutions that were already provided prior.
Regards,
Straightlight
Programmer / Opencart Tester
Simply leave the patch in as it is. You should be able to enter as many weight for many products.Do I have to change the code back if I enter a weight for many of my products, to prevent further errors?
The most generated errors being found on Opencart forum originates from contributed programming. The increased post counters are caused by redundancies of the same solutions that were already provided prior.
Regards,
Straightlight
Programmer / Opencart Tester
Users browsing this forum: No registered users and 24 guests