1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Moderation of threads...

Discussion in 'XenForo Questions and Support' started by Ryan McAdams, Dec 8, 2010.

  1. Ryan McAdams

    Ryan McAdams Active Member

    I've got about 390 threads that showed up in the moderation queue today... (out of no where) and I want to approve them all at once... does anyone know of a query to do it manually or a way to do it all at once in the web ui?
     
  2. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Your best option is probably the inline moderation menu inside of each forum:

    Screen shot 2010-12-07 at 10.13.28 PM.png

    The Select all is per page of threads. But the selected threads are saved between pages.

    You can also use the Moderation Queue at the top of the page, but it doesn't let you 'select all':

    Screen shot 2010-12-07 at 10.18.48 PM.png
     
  3. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    I came up with some queries for you. Backup first! :D

    Code:
    DELETE
    FROM xf_moderation_queue
    WHERE content_type = 'thread'
    
    Code:
    UPDATE xf_thread
    SET discussion_state = 'visible'
    WHERE discussion_state = 'moderated'
    
    Run these two queries in sequence to approve all currently moderated threads. I tested this and it appears to work. But it doesn't update the Moderation Queue number shown in the screenshot above. I can't figure out how to update that number.
     
    Blandt likes this.
  4. Floris

    Floris Guest

    Make sure your usergroup is set to "yes" for 'follow moderation rules', when set to inherit/revoke it might be 'no' which always puts them in mod-queue.
     
  5. Shadab

    Shadab Well-Known Member

    I think you'll have to clear the cache in the Data Registry too.
    Code:
    DELETE FROM xf_data_registry
    WHERE data_key = 'moderationCounts'
    There was a bug (fixed within 5 hours of reporting! Thanks Mike :)) which prevented this cache from being rebuilt under certain circumstances: [Fixed] "Moderation Queue" doesn't get rebuilt when key is missing in Data Registry.
     
    Jake Bunce likes this.
  6. Rudy

    Rudy Well-Known Member

    What would 'discussion_state' be if you wanted to soft-delete the entries rather than make them visible?
     
  7. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    discussion_state = 'deleted'

    In addition to that, soft deleted threads have an entry in xf_deletion_log.
     
  8. Rudy

    Rudy Well-Known Member

    Thanks, I'll look into that and get a query ready. (y)
     

Share This Page