Unable to update the status of a singleton content

I have…

Current behavior

Hi all,
I created a new app by copying and importing the schemas via cli from a different app. Among these schemas, some are singletons, and when I create a new draft, I cannot publish them. Is it possible to force the publication?

Best regards,
Federica

Environment

  • [X ] Self hosted with docker
  • Self hosted with IIS
  • Self hosted with other version
  • Cloud version

Version: [7.6.1]

Browser:

  • [X ] Chrome (desktop)
  • Chrome (Android)
  • Chrome (iOS)
  • Firefox
  • Safari (desktop)
  • Safari (iOS)
  • IE
  • Edge

What happens when you publish it? Any logs in chrome or squidex?

I don’t have the option to publish the content
Immagine 2025-02-21 171208

Hi Sebastian, just to update you on this topic.
Using version 7.6.1 we are having problems with some single content schemas.
The original app used to duplicate the app works perfectly, but when Federica copied the app and imported it into a new app, the single content schemas seemed as though they aren’t being registered with the workflow properly. The result is that the page is modifiable (we are able to create a new draft o delete the draft), but other than this nothing. I have checked the logs and there isn’t any signs of problems during the loading of the page in squidex.
I also tried importing the content into squidex and tried to use postman to publish via “/api/content/sardegna-statistiche/carta-identita/{id}/status” with the payload

{
    "Status": "published",
    "DueTime": "2025-04-02T14:15:22Z",
    "CheckReferrers": true
}

the result was this:

{
    "message": "Singleton content cannot be updated.",
    "traceId": "00-f174dca6cc9872e0c8b35eb9dbfce339-9485f13cb21b38ce-01",
    "type": "https://www.rfc-editor.org/rfc/rfc7231#section-6.5.1",
    "statusCode": 400
}

Lannie

I can try again to reproduce it, but when I am unable I need a full backup of the database (via mongo restore). I see no other options.

Ciao Sebastian,
we have currently updated Squidex to 7.20.0 in our DEV environment.
We were hoping that the sync we use duplicate a new app would have resolved with the upgrade, but unfortunately the singleton problem still persists.
We have also made a backup of mongoDB, not sure how to send it to you (53mb).

I forgot to mention that the Apps (App base, Statistiche and Elezioni) have problem where as (CRC and Programmazione) don’t have the problem.

Statistiche and Elezioni were created via the duplication of the CRC App.

Lannie

Just send me a private message here with a link to download the backup.

Okay, I got it now.

You have create a custom workflow to translate the default workflow names like Draft and Archived.

But a singleton is special and can only have Draft and Published as system workflow states. Somehow your content ended in a Bozza state, which is not valid for a singleton content.

What you can do:

  1. Go to your database, find your content: { "id" : "3f314d0f-285f-488a-a7ae-4b6f1756d86f" }
  2. Change the status field to “Draft” (the field ist called “ns”)
  3. Then publish via UI

Hi Sebastian,
ok, perfect. Now we are able to place the article in a Draft state and Publish.

Lannie