• Hi,
    Can I request a feature is:
    Group Posts (Pages, Categories, etc) by Translate?
    Example:
    – I have 3 Language EN, FR, RU. With EN is Default Language
    – I Create 3 EN Posts: A – EN, B – EN, C – EN
    – Every Posts I create “translate Posts” for FR and RU Language:
    — Foo A – FR, Bar A – RU
    — Something B – FR, Something else B – RU
    — Something else C – FR, Something C – RU

    In admin, I want list all Posts as Group by Default Language (as below)?

    A - EN
    -- Foo A - FR
    -- Bar A - RU
    B - EN
    -- Something B - FR
    -- Something else B - RU
    C - EN
    -- Something else C - FR
    -- Something C - RU

    It’s helpful for manage bulk of posts with many translate language.
    Current have any idea PHP code help for this?

    Thanks

    • This topic was modified 2 years, 6 months ago by datverse.
    • This topic was modified 2 years, 6 months ago by datverse.
    • This topic was modified 2 years, 6 months ago by datverse.
    • This topic was modified 2 years, 6 months ago by datverse.
    • This topic was modified 2 years, 6 months ago by datverse.
Viewing 1 replies (of 1 total)
  • Thread Starter datverse

    (@datverse)

    Hi, I found some php code change order of admin posts listing. But what I should add to orderby?

    function set_custom_post_types_admin_order($wp_query) {
      if (is_admin()) {
    
        $post_type = $wp_query->query['post_type'];
    
        if ( $post_type == 'POST_TYPE') {
    
          $wp_query->set('orderby', 'what-is-it?');
          $wp_query->set('order', 'ASC');
        }
      }
    }
    
    add_filter('pre_get_posts', 'set_custom_post_types_admin_order');
Viewing 1 replies (of 1 total)
  • The topic ‘Group Posts in Admin by Translate’ is closed to new replies.