### Apache Airflow version

Other Airflow 2 version (please specify below)

### What happened

Hi, I'm currently on Airflow 2.4.2
In /home when sorting by DAG/Owner/Next Run and going to the next page the sort resets.
This feature only works if  I'm looking for last or first, everything in the middle is unreachable.

### What you think should happen instead

The sorting should continue over the pagination

### How to reproduce

Sort by any sortable field on DagList and go to the next page

### Operating System

apache/airflow:2.4.2-python3.10

### Versions of Apache Airflow Providers

_No response_

### Deployment

Official Apache Airflow Helm Chart

### Deployment details

_No response_

### Anything else

_No response_

### Are you willing to submit PR?

- [ ] Yes I am willing to submit a PR!

### Code of Conduct

- [X] I agree to follow this project's [Code of Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)

children_states = {item["state"] for item in child_instances}
            group_state = next((state for state in wwwutils.priority if state in children_states), None)
            group_start_date = min(filter(None, children_start_dates), default=None)
            group_end_date = max(filter(None, children_end_dates), default=None)
            return {
                "task_id": task_group.group_id,
                "run_id": dag_run.run_id,
                "state": group_state,
                "start_date": group_start_date,
                "end_date": group_end_date,
            }
        def get_mapped_group_summaries():
            mapped_ti_query = (
                session.query(
                    TaskInstance.task_id, TaskInstance.state, TaskInstance.run_id, TaskInstance.map_index
                )
                .filter(
                    TaskInstance.dag_id == dag.dag_id,
                    TaskInstance.task_id.in_(child["id"] for child in children),
                    TaskInstance.run_id.in_(r.run_id for r in dag_runs),
                )
                .order_by(TaskInstance.task_id, TaskInstance.run_id)
            )
            
            mapped_tis: Mapping[str, Mapping[int, list[TaskInstance]]] = collections.defaultdict(
                lambda: collections.defaultdict(list),
            )
            for ti in mapped_ti_query:
                mapped_tis[ti.run_id][ti.map_index].append(ti)
            def get_mapped_group_summary(run_id: str, mapped_instances: Mapping[int, list[TaskInstance]]):