Change index link logic to match history. Make history table descending instead of ascending