function uc_product_update_6001 in Ubercart 6.2
Makes sure that those who had the faulty 6000 update have the right precision and scale.
File
- uc_product/
uc_product.install, line 263 - Install, update and uninstall functions for the uc_product module.
Code
function uc_product_update_6001() {
$ret = array();
db_change_field($ret, 'uc_products', 'list_price', 'list_price', array(
'type' => 'numeric',
'precision' => 10,
'scale' => 2,
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0,
));
db_change_field($ret, 'uc_products', 'cost', 'cost', array(
'type' => 'numeric',
'precision' => 10,
'scale' => 2,
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0,
));
db_change_field($ret, 'uc_products', 'sell_price', 'sell_price', array(
'type' => 'numeric',
'precision' => 10,
'scale' => 2,
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0,
));
return $ret;
}