rearange buttons in the table