var/classes/DataObject/News/Listing.php line 15

Open in your IDE?
  1. <?php
  2. namespace Pimcore\Model\DataObject\News;
  3. use Pimcore\Model;
  4. use Pimcore\Model\DataObject;
  5. /**
  6.  * @method DataObject\News|false current()
  7.  * @method DataObject\News[] load()
  8.  * @method DataObject\News[] getData()
  9.  * @method DataObject\News[] getObjects()
  10.  */
  11. class Listing extends DataObject\Listing\Concrete
  12. {
  13. protected $classId "News";
  14. protected $className "News";
  15. /**
  16. * Filter by date (Date)
  17. * @param string|int|float|array|Model\Element\ElementInterface $data  comparison data, can be scalar or array (if operator is e.g. "IN (?)")
  18. * @param string $operator  SQL comparison operator, e.g. =, <, >= etc. You can use "?" as placeholder, e.g. "IN (?)"
  19. * @return static
  20. */
  21. public function filterByDate ($data$operator '=')
  22. {
  23.     $this->getClass()->getFieldDefinition("date")->addListingFilter($this$data$operator);
  24.     return $this;
  25. }
  26. /**
  27. * Filter by Category (Category)
  28. * @param mixed $data
  29. * @param string $operator SQL comparison operator, e.g. =, <, >= etc. You can use "?" as placeholder, e.g. "IN (?)"
  30. * @return static
  31. */
  32. public function filterByCategory ($data$operator '=')
  33. {
  34.     $this->getClass()->getFieldDefinition("Category")->addListingFilter($this$data$operator);
  35.     return $this;
  36. }
  37. /**
  38. * Filter by headline (Headline)
  39. * @param string|int|float|array|Model\Element\ElementInterface $data  comparison data, can be scalar or array (if operator is e.g. "IN (?)")
  40. * @param string $operator  SQL comparison operator, e.g. =, <, >= etc. You can use "?" as placeholder, e.g. "IN (?)"
  41. * @return static
  42. */
  43. public function filterByHeadline ($data$operator '=')
  44. {
  45.     $this->getClass()->getFieldDefinition("headline")->addListingFilter($this$data$operator);
  46.     return $this;
  47. }
  48. /**
  49. * Filter by intro (Intro)
  50. * @param string|int|float|array|Model\Element\ElementInterface $data  comparison data, can be scalar or array (if operator is e.g. "IN (?)")
  51. * @param string $operator  SQL comparison operator, e.g. =, <, >= etc. You can use "?" as placeholder, e.g. "IN (?)"
  52. * @return static
  53. */
  54. public function filterByIntro ($data$operator '=')
  55. {
  56.     $this->getClass()->getFieldDefinition("intro")->addListingFilter($this$data$operator);
  57.     return $this;
  58. }
  59. /**
  60. * Filter by teaserImage (Teaser Image)
  61. * @param mixed $data
  62. * @param string $operator SQL comparison operator, e.g. =, <, >= etc. You can use "?" as placeholder, e.g. "IN (?)"
  63. * @return static
  64. */
  65. public function filterByTeaserImage ($data$operator '=')
  66. {
  67.     $this->getClass()->getFieldDefinition("teaserImage")->addListingFilter($this$data$operator);
  68.     return $this;
  69. }
  70. /**
  71. * Filter by shadowImage (Shadow Image)
  72. * @param string|int|float|array|Model\Element\ElementInterface $data  comparison data, can be scalar or array (if operator is e.g. "IN (?)")
  73. * @param string $operator  SQL comparison operator, e.g. =, <, >= etc. You can use "?" as placeholder, e.g. "IN (?)"
  74. * @return static
  75. */
  76. public function filterByShadowImage ($data$operator '=')
  77. {
  78.     $this->getClass()->getFieldDefinition("shadowImage")->addListingFilter($this$data$operator);
  79.     return $this;
  80. }
  81. }