fixed bugs in saving relational data and repopulating select fields