Restructured _search_pairs_to_dict() so it only has a single regex match.
Single record queries by pk were not being processed correctly. Rearranged url pattern matching order.