add sorting to bills and fix tests for sorting and search in invoices and bills