fixes cycling through parties in UI, but still fails to add to permutations table correctly