A button will be present in next version of HikaShop to rebuild the category tree automatically.
We're currently working towards the release and we plan on doing it next week.
In the mean time, you would have to add the code:
<?php $class = hikashop_get('class.category');
$database = JFactory::getDBO();
$query = 'SELECT category_left,category_right,category_depth,category_id,category_parent_id FROM #__hikashop_category ORDER BY category_left ASC';
$database->setQuery($query);
$root = null;
$categories = $database->loadObjectList();
$class->categories = array();
foreach($categories as $cat){
$class->categories[$cat->category_parent_id][]=$cat;
if(empty($cat->category_parent_id)){
$root = $cat;
}
}
$class->rebuildTree($root,0,1);
?>
in a view file via the menu Display->Views and display that view so that the code gets executed and that the category tree gets rebuilt.