digitalfabrik / integreat-cms

Simplified content management back end for the Integreat App - a multilingual information platform for newcomers
https://digitalfabrik.github.io/integreat-cms/
Apache License 2.0
55 stars 33 forks source link

Page with content reports "successfully updated" instead of "no changes" #2673

Open PeterNerlich opened 4 months ago

PeterNerlich commented 4 months ago

Describe the Bug

Because we try to normalize the page content before saving it to the database in a format different to the one that tinymce exports, django always reports that the content field changed (except on empty pages), even when just clicking "Update".

This should largely be fixed by #2668

Steps to Reproduce

  1. Go to a page with >1 lines of content
  2. Compare the source in tinymce with the content in the database (e.g. via django admin) → They are different (e.g. <br> vs. \r\n)
  3. Click on Update

Expected Behavior

The page should show No changes detected, but date refreshed

Actual Behavior

The page shows Page "<page name>" was successfully updated

seluianova commented 4 months ago

This should largely be fixed by https://github.com/digitalfabrik/integreat-cms/pull/2668

Not really :) In 2668, only the text in the request to TextLab is updated. This doesn’t affect the content we save to the database.