Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Laurent Lequenne 123 posts 248 karma points
    Aug 06, 2018 @ 07:06
    Laurent Lequenne
    0

    Sorting content issue

    We currently have some issues with sorting content, we have a node with around 100 children which can not be sorted anymore =>

    1. No logs in the audit table => so the content is not sorted, or the procedure doesn't reach the line that create an audit record
    2. no errors in the log files.
    3. the API call is running and returns null, and the parameters seems to be OK

    I reproduced the issue on DEV environment, but when connecting from my local environment, issue didn't appeared, and even worth, it fixed the issue on the dev environment.

    Did anyone got this issue, and found out a workaround ?

  • Ismail Mayat 4511 posts 10092 karma points MVP 2x admin c-trib
    Aug 06, 2018 @ 08:10
    Ismail Mayat
    0

    Laurent,

    What's the exact version of umbraco you are using? I recall this used to be an issue with older version of Umbraco.

    Regards

    Ismail

  • Laurent Lequenne 123 posts 248 karma points
    Aug 06, 2018 @ 09:07
    Laurent Lequenne
    0

    7.6.4 ... From the code in the sort method of content service This is the only thing I can thing the sorting is not happening, but is it ?

                    if (raiseEvents && uow.Events.DispatchCancelable(Saving, this,                 saveEventArgs, "Saving"))
                    {
                        uow.Commit();
                        return false;
                    }
    
  • Simon Dingley 1474 posts 3431 karma points c-trib
    Nov 12, 2021 @ 10:56
    Simon Dingley
    0

    Did you ever find the reason why this was failing? I have a project on v7 with the same issue, nothing in the logs to suggest there is an underlying error and nothing in the console either. Inspecting the request in the network panel of the developer tools in the browser shows the response as being...

    {"d":null} ...so my guess is that whatever error is occurring is being caught but not logged.

  • Simon Dingley 1474 posts 3431 karma points c-trib
    Nov 17, 2021 @ 15:29
    Simon Dingley
    0

    Debugging the source for the Umbraco version I'm dealing with (v7.15.6) it seems that the reason the sorting is not happening is because the method doing the sorting exits early before the sorting takes place:

    if (raiseEvents && uow.Events.DispatchCancelable(Saving, this, saveEventArgs, "Saving"))
    {
        uow.Commit();
        return false;
    }
    

    https://github.com/umbraco/Umbraco-CMS/blob/9d995f5054d2d93a206f45c279c02dffbbcaf07a/src/Umbraco.Core/Services/ContentService.cs#L2121

    Short of modifying this and running a custom build, something which I'd rather avoid, I can't see any way around this issue?

Please Sign in or register to post replies

Write your reply to:

Draft