GravityView  2.1.1
The best, easiest way to display Gravity Forms entries on your website.
Variables
field-other_entries-html.php File Reference

Go to the source code of this file.

Variables

 $created_by = \GV\Utils::get( $gravityview->entry, 'created_by' )
 The default field output template displaying entries created by same author. More...
 
 $criteria = apply_filters( 'gravityview/field/other_entries/criteria', $search_criteria, $gravityview->view->settings->as_atts(), $gravityview->view->form->ID, $gravityview )
 
 $deprecated = apply_filters( 'gravityview/field/other_entries/args', array(), null )
 
 $entries = $gravityview->view->form->entries->filter( $filter )->limit( $gravityview->field->page_size ? : 10 )->all()
 
 $filter = \GV\GF_Entry_Filter::from_search_criteria( $search_criteria )
 
if(empty( $entries) && $gravityview->field->no_entries_hide) $list
 Don't show if no entries and the setting says so. More...
 
if(empty( $created_by)) $search_criteria
 There was no logged in user who created this entry. More...
 
 $search_criteria ['field_filters']['mode'] = 'all'
 Force mode all and filter out our own entry. More...
 
 $search_criteria ['field_filters'][]
 

Variable Documentation

◆ $created_by

$created_by = \GV\Utils::get( $gravityview->entry, 'created_by' )

The default field output template displaying entries created by same author.

$gravityview

Since
2.0

Definition at line 10 of file field-other_entries-html.php.

◆ $criteria

$criteria = apply_filters( 'gravityview/field/other_entries/criteria', $search_criteria, $gravityview->view->settings->as_atts(), $gravityview->view->form->ID, $gravityview )
Runs Filter:
gravityview/field/other_entries/criteria Modify the search parameters before the entries are fetched.
Since
1.11
Parameters
array$criteriaGravity Forms search criteria array, as used by GVCommon::get_entries()
array$view_settingsAssociative array of settings with plugin defaults used if not set by the View
int$form_idThe Gravity Forms ID
Since
2.0
Parameters
\GV\Template_Context$gravityviewThe context

Definition at line 42 of file field-other_entries-html.php.

◆ $deprecated

$deprecated = apply_filters( 'gravityview/field/other_entries/args', array(), null )
Since
1.7.6

Definition at line 78 of file field-other_entries-html.php.

◆ $entries

$entries = $gravityview->view->form->entries->filter( $filter )->limit( $gravityview->field->page_size ? : 10 )->all()

Definition at line 53 of file field-other_entries-html.php.

◆ $filter

$filter = \GV\GF_Entry_Filter::from_search_criteria( $search_criteria )

◆ $list

if (empty($entries) &&$gravityview->field->no_entries_hide) $list
Initial value:
array_map( function( $entry ) { return $entry->as_entry(); }, $entries ),
$gravityview->request->is_view() ? $gravityview->view->ID : is_object( $GLOBALS['post'] ) ? $GLOBALS['post']->ID : 0,
$gravityview->view->form->form,
$gravityview->field->link_format,
$gravityview->field->after_link,
'other_entries',
$gravityview
)
If this file is called directly, abort.
$entry
Definition: notes.php:27

Don't show if no entries and the setting says so.

If there are search results, get the entry list object.

Definition at line 61 of file field-other_entries-html.php.

◆ $search_criteria [1/3]

if (empty($created_by)) $search_criteria
Initial value:
= GravityView_frontend::process_search_only_approved( $gravityview->view->settings->as_atts(),
array(
'field_filters' => array(
array(
'key' => 'created_by',
'value' => $created_by,
'operator' => 'is'
)
),
'status' => apply_filters( 'gravityview_status', 'active', $gravityview->view->settings->as_atts() ),
)
)
static process_search_only_approved( $args, $search_criteria)
Process the approved only search criteria according to the View settings.
$created_by
The default field output template displaying entries created by same author.

There was no logged in user who created this entry.

Filter entries by approved and created_by.

Definition at line 18 of file field-other_entries-html.php.

Referenced by GF_Entry_Filter\as_search_criteria(), GVCommon\check_entry_display(), GravityView_Widget_Search\filter_entries(), GF_Form\from_form(), GF_Entry_Filter\from_search_criteria(), GVCommon\get_entry_id_from_slug(), GVCommon\get_entry_ids(), GravityView_frontend\get_search_criteria(), GravityView_Widget_Search\gf_query_filter(), gravityview_get_entry_ids(), GF_Entry_Filter\merge_search_criteria(), GravityView_Admin_ApproveEntries\process_bulk_action(), GravityView_frontend\process_search_dates(), and GravityView_frontend\process_search_only_approved().

◆ $search_criteria [2/3]

$search_criteria[ 'field_filters'][ 'mode'] = 'all'

Force mode all and filter out our own entry.

Definition at line 45 of file field-other_entries-html.php.

◆ $search_criteria [3/3]

$search_criteria[ 'field_filters'][]
Initial value:
= array(
'key' => 'id',
'value' => $gravityview->entry->ID,
'operator' => 'isnot'
)

Definition at line 46 of file field-other_entries-html.php.