Single Type: Unable to reorder newly added relations.
<!--
Hello 👋 Thank you for submitting an issue.

Before you start, please make sure your issue is understandable and reproducible.
To make your issue readable make sure you use valid Markdown syntax.

https://guides.github.com/features/mastering-markdown/

Please ensure you have also read and understand the contributing guide.

https://github.com/strapi/strapi/blob/main/CONTRIBUTING.md#reporting-an-issue
-->

## Bug report

### Required System information

<!-- Please ensure you are using the Node LTS version (18, 20, or 22) -->
<!-- Strapi v3 is no longer supported, please update to Strapi v4 -->
<!-- If you are reporting a frontend bug please provide error logs after setting STRAPI_ENFORCE_SOURCEMAPS=true in your .env -->
<!-- This environment variable makes frontend errors easier to read and trace -->

- Node.js version: v18.20.4
- Yarn version: 1.22.22
- Strapi version: 5.3.0
- Database: MySQL
- Operating system: MacOS (darwin-arm64)
- Is your project Javascript or Typescript: TypeScript

<!-- Did you know you can run `yarn strapi report` or `npm run strapi report` to get this information easier? -->

### Describe the bug

I have a single type called Popular Article, which is related to the Article collection type. When I try to add more articles and reorder them, Strapi throws an Internal Server Error.

### Steps to reproduce the behavior

_Ensure there are already some existing records in the single type before adding new ones (the error can only be reproduced with a non-empty single-type list)._

1. Navigate to the **Single Types** section.
2. Click on **Add Relation** and add some records.
3. Reorder the newly added records.
4. Click the **Save** or **Publish** button.

### Expected behavior
The list of records should be reordered correctly.

### Screenshots

https://github.com/user-attachments/assets/2ad3c713-afff-414b-8c66-64291d7e7992

### Code snippets:
This is my popular article schema file:
```
{
  "kind": "singleType",
  "collectionName": "popular_articles",
  "info": {
    "singularName": "popular-article",
    "pluralName": "popular-articles",
    "displayName": "Popular article"
  },
  "options": {
    "draftAndPublish": true
  },
  "pluginOptions": {},
  "attributes": {
    "articles": {
      "type": "relation",
      "relation": "oneToMany",
      "target": "api::article.article"
    }
  }
}

```
### Additional context
- I only encounter this error when trying to reorder newly added records. If I add a new record (e.g., A) and reorder the existing records (B, C, D), the error does not occur.
- The terminal also throws this error, but I’m not sure if it’s related to my issue.
```
[2024-12-17 10:31:22.228] http: GET /content-manager/single-types/api::popular-article.popular-article/actions/countDraftRelations? (21 ms) 200
[2024-12-17 10:31:22.234] error: Expected a valid Number, got qnd2g1etq774egt4xo4zxioi
Error: Expected a valid Number, got qnd2g1etq774egt4xo4zxioi
    at NumberField.toDB (/Users/azoom/dev/azoom-column-site/node_modules/@strapi/database/dist/index.js:2819:13)
    at castValue (/Users/azoom/dev/azoom-column-site/node_modules/@strapi/database/dist/index.js:3935:42)
    at processSingleAttributeWhere (/Users/azoom/dev/azoom-column-site/node_modules/@strapi/database/dist/index.js:3942:14)
    at /Users/azoom/dev/azoom-column-site/node_modules/@strapi/database/dist/index.js:3958:31
    at Array.map (<anonymous>)
    at processAttributeWhere (/Users/azoom/dev/azoom-column-site/node_modules/@strapi/database/dist/index.js:3958:18)
    at processSingleAttributeWhere (/Users/azoom/dev/azoom-column-site/node_modules/@strapi/database/dist/index.js:3952:20)
    at processAttributeWhere (/Users/azoom/dev/azoom-column-site/node_modules/@strapi/database/dist/index.js:3960:10)
    at processWhere (/Users/azoom/dev/azoom-column-site/node_modules/@strapi/database/dist/index.js:4044:36)
    at processNested (/Users/azoom/dev/azoom-column-site/node_modules/@strapi/database/dist/index.js:3966:10)
```