25 lines
590 B
PHP
25 lines
590 B
PHP
<?php
|
|
|
|
if (!defined('_PS_VERSION_')) {
|
|
exit;
|
|
}
|
|
|
|
function upgrade_module_1_11_0($module)
|
|
{
|
|
$groups = Db::getInstance()->executeS(
|
|
'SELECT `id_ws_customhtml_group` FROM `' . _DB_PREFIX_ . 'ws_customhtml_group` ORDER BY `id_ws_customhtml_group` ASC'
|
|
);
|
|
|
|
foreach ($groups as $index => $group) {
|
|
if (!Db::getInstance()->update(
|
|
'ws_customhtml_group',
|
|
['ordering' => (int) $index],
|
|
'`id_ws_customhtml_group` = ' . (int) $group['id_ws_customhtml_group']
|
|
)) {
|
|
return false;
|
|
}
|
|
}
|
|
|
|
return true;
|
|
}
|