You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
- <?php
-
- namespace domain\PointSale\SharedPointSale;
-
- use domain\_\AbstractRepositoryQuery;
- use domain\_\StatusInterface;
- use domain\Producer\Producer\Producer;
-
- class SharedPointSaleRepositoryQuery extends AbstractRepositoryQuery
- {
- protected SharedPointSaleDefinition $sharedPointSaleDefinition;
-
- public function loadDependencies(): void
- {
- $this->loadDefinition(SharedPointSaleDefinition::class);
- }
-
- public function filterIsStatusOnline()
- {
- $this->andWhere(['shared_point_sale.status' => StatusInterface::STATUS_ONLINE]);
- return $this;
- }
-
- public function filterByProducerOfPointSale(Producer $producer): self
- {
- $this->andWhere(['point_sale.id_producer' => $producer->id]);
- return $this;
- }
-
- public function filterByProducerWithSharing(Producer $producer): self
- {
- $this->andWhere(['id_producer_with_sharing' => $producer->id]);
- return $this;
- }
- }
|