def fetch_index_objects
      scope = index_properties.default_scope
      puts "<<<<<<<" * 100, scope
      if !scope.nil?

          # If user provided an scope for `index` section.

          if scope.respond_to? :call
            # If scope provided by a block
            scope = scope.call
          else
            # If scope provided by a symbol
            # which should be a method name
            scope = self.send(scope)
          end

        else
          scope = model.all
          #scope = ApplicationPolicy::Scope.new(current_user, model.all).resolve
        end

        scope = scope.order('created_at DESC').page(params[:page])
        policy_scope(scope)

      end
def fetch_index_objects
      scope = index_properties.default_scope
      puts "<<<<<<<" * 100, scope
      if !scope.nil?

          # If user provided an scope for `index` section.

          if scope.respond_to? :call
            # If scope provided by a block
            scope = scope.call
          else
            # If scope provided by a symbol
            # which should be a method name
            scope = self.send(scope)
          end

        else
          scope = model.all
          #scope = ApplicationPolicy::Scope.new(current_user, model.all).resolve
        end

        scope = scope.order('created_at DESC').page(params[:page])
        policy_scope(scope)

      end
Fetch all or part of the corresponding resource
 from data base with respect to `scope` DSL.

 The important thing here is that by using `scope`
 DSL this method will chain the resulted scope
 with other scopes like `page` and `policy_scope`