added ability to set an order parameter for the options list generated by the foreign keys