redesign table
some bug-fixes