docs: def list_pages_ajax(request, invalid_move=False):
      """Render pages table for ajax function."""
      language = get_language_from_request(request)
      pages = Page.objects.root()
      context = {
          'can_publish': request.user.has_perm('pages.can_publish'),
          'invalid_move': invalid_move,
          'language': language,
          'pages': pages,
      }
      return render(
          request, "admin/pages/page/change_list_table.html",
          context)