|
@@ 659-674 (lines=16) @@
|
| 656 |
|
* @return array Simple object names |
| 657 |
|
* @since 2.3 |
| 658 |
|
*/ |
| 659 |
|
public function simple_objects () { |
| 660 |
|
if ( $this->setup_related_objects() || null === self::$names_simple ) { |
| 661 |
|
$simple_objects = array(); |
| 662 |
|
|
| 663 |
|
foreach ( self::$related_objects as $object => $related_object ) { |
| 664 |
|
if ( !isset( $related_object[ 'simple' ] ) || !$related_object[ 'simple' ] ) |
| 665 |
|
continue; |
| 666 |
|
|
| 667 |
|
$simple_objects[] = $object; |
| 668 |
|
} |
| 669 |
|
|
| 670 |
|
self::$names_simple = (array) apply_filters( 'pods_form_ui_field_pick_simple_objects', $simple_objects ); |
| 671 |
|
} |
| 672 |
|
|
| 673 |
|
return self::$names_simple; |
| 674 |
|
} |
| 675 |
|
|
| 676 |
|
/** |
| 677 |
|
* Return available bidirectional object names |
|
@@ 682-697 (lines=16) @@
|
| 679 |
|
* @return array Bidirectional object names |
| 680 |
|
* @since 2.3.4 |
| 681 |
|
*/ |
| 682 |
|
public function bidirectional_objects () { |
| 683 |
|
if ( $this->setup_related_objects() || null === self::$names_bidirectional ) { |
| 684 |
|
$bidirectional_objects = array(); |
| 685 |
|
|
| 686 |
|
foreach ( self::$related_objects as $object => $related_object ) { |
| 687 |
|
if ( !isset( $related_object[ 'bidirectional' ] ) || !$related_object[ 'bidirectional' ] ) |
| 688 |
|
continue; |
| 689 |
|
|
| 690 |
|
$bidirectional_objects[] = $object; |
| 691 |
|
} |
| 692 |
|
|
| 693 |
|
self::$names_bidirectional = (array) apply_filters( 'pods_form_ui_field_pick_bidirectional_objects', $bidirectional_objects ); |
| 694 |
|
} |
| 695 |
|
|
| 696 |
|
return self::$names_bidirectional; |
| 697 |
|
} |
| 698 |
|
|
| 699 |
|
/** |
| 700 |
|
* Define the current field's schema for DB table storage |